OK, now I'm confused :-). REPLACE|APPEND only applies to the OUTPUT and
ERROR connections which could never be redirected to an input stream.
Of course, if the outputstream interface doesn't require open and close
either, then we can't do open("write replace").
As far as the command handler interface goes, I suspect we need to make
this a class with attributes for the name, (possibly) the full path, and
the state of any redirection of connections that has been specified. At
least that is what I'd do if I was writing something like this in
ooRexx. Can't say if that is appropriate for C++.
Gil
PS I now have a checkout of the sandbox and have begun looking at
integrating the changes needed in order to implement redirection. More
questions will be forthcoming! GB
On 3/31/2018 2:26 PM, Rick McGuire wrote:
On Sat, Mar 31, 2018 at 2:22 PM Erich Steinböck
<[email protected] <mailto:[email protected]>> wrote:
After a little think time at the dog park
You're, of course, calling your dog "Rex" aren't you? :-)
Since the intent here is to write to an already prepared
stream object, REPLACE is really not doable
We could close the stream, and re-open with "write replace",
couldn't we?
Am I misunderstanding something here?
an input stream does not require that the stream be for a file. It can
be any object that implements the inputstream interface, which does
not require open and close.
As we're intending to change how the command handlers work,
there's one comment I'd like to make.
I had experimented how to best resolve the full path to a given
shell (commend environment) name. As I wouldn't want to do this
on each command handler call, but as a one-time setup only, I
noticed that there's no way to do that because of the fixed
command handler interface.
Might we have an additional full-path argument to command handlers?
On Sat, Mar 31, 2018 at 1:49 PM, Rick McGuire
<[email protected] <mailto:[email protected]>> wrote:
1) After a little think time at the dog park, I restructured
my code a bit and now am able to cleanup implement the full
ADDRESS WITH semantics.
2) I'm planning on adding File as one of the objects support
with USING
3) I have been able to implement the APPEND/REPLACE options
for all USING types except for the Stream object type. Since
the intent here is to write to an already prepared stream
object, REPLACE is really not doable, and APPEND doesn't
really have any meaning either since the stream might be set
to a given position. I plan on raising an error if either
option exists. It's a little awkward that REPLACE is the
default for all of the other situations, but we'll just have
to document this as a special case.
4) btw, I realized while I was writing this that the Stream
object you supply could be a socketStream instance, allowing
out to send or read data elsewhere :-)
Rick
------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
Oorexx-devel mailing list
[email protected]
<mailto:[email protected]>
https://lists.sourceforge.net/lists/listinfo/oorexx-devel
------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org!
http://sdm.link/slashdot_______________________________________________
Oorexx-devel mailing list
[email protected]
<mailto:[email protected]>
https://lists.sourceforge.net/lists/listinfo/oorexx-devel
------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
Oorexx-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/oorexx-devel
--
Gil Barmwater
------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
Oorexx-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/oorexx-devel