name: Sof

synopsis:

 
g++ [flags ...] file ... -l /isip/tools/lib/$ISIP_BINARY/lib_io.a

#include <Sof.h>

Sof();
boolean open(const SysString& filename, File::MODE mode = File::READ_ONLY,
	       File::TYPE type = File::DEF_TYPE);
boolean put(const SysString& name, long size);
long write(const void* ptr, long size, long nitems);
quick start:

long j = 27;
Sof sof1;
SysString file1(L"temp.out");
if (sof1.open(file1, File::WRITE_ONLY, File::BINARY) != true) {
 return Error::handle(file1, L"open", Error::TEST, __FILE__, __LINE__);
}
SysString cname(L"MyLong");
sof1.put(cname, 0, sizeof(long));
sof1.write(&j, sizeof(j), 1);
sof1.close();
description:

Sof is used by all data objects in the ISIP environment to unify and simplify I/O. An index is maintained pointing to all objects within the file, but all data is left on the disk until needed. Sof deals with both ASCII and binary files. Binary files inherently handle machine architecture differences with automatic byte transformations. User input parameter files in the ISIP environment are ASCII Sof files, but binary mode is typically used for large quantities of data for the obvious efficiency gains. Since Sof is at the base of all ISIP software, it has to be very efficient. To accomplish efficiency, the objects are stored in a binary tree and a symbol table is used to hold the object class names.

dependencies:

public constants:

error codes:

protected data:

required public methods:

class-specific public methods:

private methods:

friend classes:

examples:

notes: