Local Identifiers (LAM)

is the object at src a LAM? More...

Functions

bool isLAM (SatAddr src)
char * LAMdecode (SatAddr src, char *dst)
 Convert a LAM to a null-terminated string.
SatAddr LAMencode (const char *src, SatAddr dst)
 Convert a null-terminated C string into a LAM object.
SatAddr makeLAM (unsigned size)
 Allocate space for a LAM with size characters.
int LAMnibbles (SatAddr src)
 Return the size in nibbles of the LAM at src.
int LAMnumChars (SatAddr src)
 return the number of characters in a LAM

Detailed Description

is the object at src a LAM?

Parameters:
src Saturn address of an object
Returns:
true if the object at src is a LAM

Function Documentation

char* LAMdecode ( SatAddr  src,
char *  dst 
)

Convert a LAM to a null-terminated string.

Parameters:
src The Saturn address of a LAM
dst A pointer to a buffer with sufficient space to hold the name, or zero. If the value is zero then space will be malloc'ed to hold the name.
Returns:
The null-terminated string.
See also:
LAMnumChars()

SatAddr LAMencode ( const char *  src,
SatAddr  dst 
)

Convert a null-terminated C string into a LAM object.

Parameters:
src The null-terminated string. It must be less than 256 characters in length.
dst The Saturn address where the LAM should be stored. If dst is zero then space is allocated for the LAM Otherwise dst must point to sufficient space for the LAM
Returns:
The Saturn address of the LAM, or zero on error. Errors occur if the LAM can't be allocated, or if src points to a string that is longer than 255 characters.

int LAMnibbles ( SatAddr  src  ) 

Return the size in nibbles of the LAM at src.

Parameters:
src the Saturn address of a LAM object
Returns:
the size of the LAM in nibbles, or zero if src is not a LAM

int LAMnumChars ( SatAddr  src  ) 

return the number of characters in a LAM

Parameters:
src The Saturn address of a LAM
Returns:
the number of characters in the LAM, or -1 if src isn't a LAM.

SatAddr makeLAM ( unsigned  size  ) 

Allocate space for a LAM with size characters.

Parameters:
size The number of characters in the LAM
Returns:
The Saturn address of a new empty LAM, or zero if the LAM can't be allocated or size is larger than 255.


Generated on Sat Apr 3 16:38:31 2010 for HPObjects by  doxygen 1.5.0