NORSYS SOFTWARE © 2012 | NETICA API | C   VERSION   5.04  |
stream_ns* NewFileStream_ns ( | const char* filename, environ_ns* env, const char* access ) |
Returns a Norsys stream for the file with name filename.
This stream can then be passed as an argument to functions which read or write a file, to identify which file to read or write.
Pass NULL for access; it is only for future expansion.
When finished with the stream_ns created, delete it with DeleteStream_ns.
filename may contain a path to indicate in which directory the file is located. It should be a string in the format normally understood by the operating system currently being used (see the examples below).
filename does not have to indicate a file which already exists.
Netica won't modify or free the passed filename string.
Version:
See also:
DeleteStream_ns | Delete it when done | |
WriteNet_bn | Saves a net to a file with name specified by the passed stream | |
WriteNetFindings_bn | ||
ReadNetFindings2_bn | ||
ReadNet_bn | Reads a net from the file identified by the passed stream |
Example:
See WriteNet_bn// // Examples for UNIX / Linux // file = NewFileStream_ns ("temp3", env, NULL); file = NewFileStream_ns ("/local/project1/configure.bn.txt", env, NULL); file = NewFileStream_ns ("../nets/Umbrella.dne", env, NULL); // // Examples for MS Windows // file = NewFileStream_ns ("temp3", env, NULL); file = NewFileStream_ns ("C:local\project1\configur.txt", env, NULL); file = NewFileStream_ns ("..\nets\Umbrella.dne", env, NULL); // // Examples for MacOS // file = NewFileStream_ns ("temp3", env, NULL); file = NewFileStream_ns ("local:project1:configure.bn.txt", env, NULL); file = NewFileStream_ns ("::nets:Umbrella.dne", env, NULL);