The Prosody S server provides a virtual Prosody card which is used by
opening it, and then using the
tSMCardId value with the Prosody API to refer to that card.
The function to open a card is
sm_open_prosody_s().
The declarations for this API are in apilib/prosody_s.h
and applications using this library must be linked with the
appropriate object file, which is
apilib/gen-LINUX/prosody_s.o
(Linux),
apilib/gen-SOL_32/prosody_s.o
(Solaris 32-bit),
apilib/gen-SOL_64/prosody_s.o
(Solaris 64-bit),
apilib/gen-WINNT/prosody_s.obj
(Windows).
Note that global symbols named aculab_TiNG* may be defined
by the API library. All such names are reserved for internal use in the
API library code, and should not be used by applications.
From time to time new features are added to this API. This may require new fields to be added to structures. A mechanism is available to ensure that this does not cause any problems for code developed prior to the addition. This is achieved by defining all new fields such that the value zero selects backward compatible behaviour. To take advantage of this, structures should be cleared before use. For example,
SM_OPEN_PROSODY_S_PARMS ap; memset(&ap, 0, sizeof(ap)); ap.card_id = 123456; ... etc
This ensures that if a new field is ever added to this structure the new field is not left uninitialised.
The list of error codes that a function can return is only a list of typical errors. If a function is described as returning a standard error then it can return any such error. Also, when the description of a function says that it can return a particular error code (for example, ERR_SM_FIRMWARE_NOT_RUNNING), this does not mean that the function guarantees to detect this error condition in all circumstances. It merely means that if it does detect this error condition, then this is the code it will return.
This is part of Prosody.