Global Identifiers (IDNT)


Functions

bool isIDNT (SatAddr src)
 is the object at src an IDNT?
char * IDNTdecode (SatAddr src, char *dst)
 Convert an IDNT to a null-terminated string.
SatAddr IDNTencode (const char *src, SatAddr dst)
 Convert a null-terminated C string into an IDNT object.
SatAddr makeIDNT (unsigned size)
 Allocate space for an IDNT with size characters.
int IDNTnibbles (SatAddr src)
 Return the size in nibbles of the IDNT at src.
int IDNTnumChars (SatAddr src)
 return the number of characters in an IDNT

Function Documentation

char* IDNTdecode ( SatAddr  src,
char *  dst 
)

Convert an IDNT to a null-terminated string.

Parameters:
src The Saturn address of an IDNT
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:
IDNTnumChars()

SatAddr IDNTencode ( const char *  src,
SatAddr  dst 
)

Convert a null-terminated C string into an IDNT object.

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

int IDNTnibbles ( SatAddr  src  ) 

Return the size in nibbles of the IDNT at src.

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

int IDNTnumChars ( SatAddr  src  ) 

return the number of characters in an IDNT

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

bool isIDNT ( SatAddr  src  ) 

is the object at src an IDNT?

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

SatAddr makeIDNT ( unsigned  size  ) 

Allocate space for an IDNT with size characters.

Parameters:
size The number of characters in the IDNT
Returns:
The Saturn address of a new empty IDNT, or zero if the IDNT 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