49 StreamProvider(
const char* nm=0);
50 void set(
const char*);
52 inline bool isBad()
const {
return fname_.isEmpty(); }
54 bool exists(
bool forread)
const;
55 bool remove(
bool recursive=
true)
const;
56 bool setReadOnly(
bool yn)
const;
57 bool isReadOnly()
const;
62 StreamData makeOStream(
bool binary=
true,
bool editmode=
false)
const;
67 StreamData makeIStream(
bool binary=
true,
bool allowpreloaded=
true)
const;
70 const char* fullName()
const;
71 const char*
fileName()
const {
return fname_.buf(); }
72 const char*
command()
const {
return fileName(); }
73 const char*
hostName()
const {
return hostname_.buf(); }
75 void setFileName(
const char* fn );
76 void setCommand(
const char* cmd,
const char* hostnm=0);
77 void addPathIfNecessary(
const char*);
80 bool isFile()
const {
return !iscomm_; }
83 static const char* sStdIO();
84 static const char* sStdErr();
87 static bool isPreLoaded(
const char*,
bool isid);
89 static bool preLoad(
const char*,
TaskRunner&,
const char*
id);
97 static int getPreLoadedDataPackID(
const char*);
98 static void unLoad(
const char*,
bool isid=
false);
100 static void unLoadAll();
111 static void sendCBMsg(
const CallBack*,
const char*);
bool rename(const char *oldname, const char *newname)
#define mExpClass(module)
Definition: commondefs.h:160
Provides I/O stream for file or system command.
Definition: strmprov.h:46
bool iscomm_
Definition: strmprov.h:105
BufferString fname_
Definition: strmprov.h:104
const char * fileName() const
Definition: strmprov.h:71
bool isBad() const
Definition: strmprov.h:52
Set of BufferString objects.
Definition: bufstringset.h:28
BufferString hostname_
Definition: strmprov.h:106
Class that can execute a task.
Definition: task.h:169
Holds data to use and close an iostream.
Definition: strmdata.h:28
OD::String with its own variable length buffer. The buffer has a guaranteed minimum size...
Definition: bufstring.h:40
bool isFile() const
Definition: strmprov.h:80
const char * hostName() const
Definition: strmprov.h:73
const char * command() const
Definition: strmprov.h:72
CallBacks object-oriented (object + method).
Definition: callback.h:57
bool exists(const char *)
bool isCommand() const
Definition: strmprov.h:81