Up: GEOS SDK TechDocs| Up | Prev: EvalErrorData ... | Next: FileAttrs ...

FALSE

#define FALSE		 0
#define TRUE		(~0)	/* use as return value, not for comparisons */

 

FieldCategory

typedef ByteEnum FieldCategory
#define FC_NONE				0x0
#define FC_NAME				0x1
#define FC_DATE				0x2
#define FC_TELEPHONE				0x3
#define FC_ADDRESS				0x4
#define FC_EMAIL				0x5

When you add a field to a datatstore, you define its FieldCategory . FieldCategory is the type of information the data represents (not to be confused with FieldType ; see below).

FieldData

typedef struct {
FieldType			FD_type;
FieldCategory			FD_category;
FieldFlags			FD_flags;
} FieldData;

Structure used to get and set field information (see FieldDescriptor below).

FieldDescriptor

typedef struct {
FieldData			FD_data;
TCHAR			*FD_name;
} FieldDescriptor;

Structure used to get and set field information (see FieldData above).

FieldHeader

typedef struct {
FieldID		FH_id;
word		FH_size;
} FieldHeader;

Structure containing metadata about a variable-sized field (such as a string field); field data follows this header.

FieldHeaderFixed

typedef struct {
FieldID		FHF_id;
} FieldHeaderFixed;

Structure containing metadata about a fixed-sized field; field data follows this header.

FieldType

typedef ByteEnum FieldType
#define DSFT_FLOAT				0x0
#define DSFT_SHORT				0x1
#define DSFT_LONG				0x2
#define DSFT_TIMESTAMP				0x3
#define DSFT_DATE				0x4
#define DSFT_TIME				0x5
#define DSFT_STRING				0x6
#define DSFT_BINARY				0x7
#define DSFT_GRAPHICS				0x8
#define DSFT_INK				0x9

When you add a field to a datatstore, you define its FieldType . FieldType is the type of data the field contains (not to be confused with FieldCategory ; see above). Note that fields of type DSFT_FLOAT expect data of type FloatNum .

FileAccess

typedef ByteEnum FileAccess
#define FA_READ_ONLY				0
#define FA_WRITE_ONLY				1
#define FA_READ_WRITE				2

 

FileAccessFlags

typedef ByteFlags FileAccessFlags;
#define FILE_DENY_RW 0x10
#define FILE_DENY_W 0x20
#define FILE_DENY_R 0x30
#define FILE_DENY_NONE 0x40
#define FILE_ACCESS_R 0x00
#define FILE_ACCESS_W 0x01
#define FILE_ACCESS_RW 0x02
#define FILE_NO_ERRORS 0x80

When you open a file for bytewise access, you must pass a record of FileAccessFlags . The FileAccessFlags record specifies two things: what kind of access the caller wants, and what type of access is permitted to other geodes. A set of FileAccessFlags is thus a bit-wise "or" of two different values. The first specifies what kind of access the calling geode wants and has the following values:

FILE_ACCESS_R
The geode will only be reading from the file.
FILE_ACCESS_W
The geode will write to the file but will not read from it.
FILE_ACCESS_RW
The geode will read from and write to the file.

The second part specifies what kind of access other geodes may have. Note that if you try to deny a permission which has already been given to another geode (e.g. you open a file with FILE_DENY_W when another geode has the file open for write-access), the call will fail. It has the following values:

FILE_DENY_RW
No geode may open the file for any kind of access, whether read, write, or read/write.
FILE_DENY_R
No geode may open the file for read or read/write access.
FILE_DENY_W
No geode may open the file for write or read/write access.
FILE_DENY_NONE
Other geodes may open the file for any kind of access.

Two flags, one from each of these sets of values, are combined to make up a proper FileAccessFlags value. For example, to open the file for read-only access while prohibiting other geodes from writing to the file, you would pass the flags "(FILE_ACCESS_R | FILE_DENY_W)".

FileAccessRights

typedef char FileAccessRights[FILE_RIGHTS_SIZE];

 


Up: GEOS SDK TechDocs| Up | Prev: EvalErrorData ... | Next: FileAttrs ...