Bio-SPHERE Library


Functions

const char * get_library_version_string (void)
bs_status init_library (void)
bs_status cleanup_library (void)
bs_status get_services_list (bs_definition **def, bs_uint16 port)
bs_status make_service_request (bs_service_request *request, bs_service_response **response, bs_uint16 port)
bs_definitioncopy_bs_definition (const bs_definition *def)
void delete_bs_definition (bs_definition *def)
bs_service_responsecopy_bs_service_response (const bs_service_response *response)

Function Documentation

bs_status cleanup_library ( void   ) 

Cleanup the library by freeing its data structures. Call this function at the end of your program.

Returns:
Status code

Definition at line 63 of file libbiosphere.c.

References BS_OK.

Referenced by main().

bs_definition* copy_bs_definition ( const bs_definition def  ) 

Create a deep copy of the given bs_definition using conventional memory allocating techniques.

Parameters:
def The definition to copy
Returns:
The copied definition allocated with malloc/calloc etc or NULL if there was an error.

Definition at line 112 of file libbiosphere.c.

References copy_definition().

Referenced by get_services_list(), and main().

Here is the call graph for this function:

bs_service_response* copy_bs_service_response ( const bs_service_response response  ) 

Create a deep copy of the given bs_service_response using conventional memory allocation techniques. This way the user of the library is not relient on memory pools.

Parameters:
response The response to copy
Returns:
The copied response or NULL.

Definition at line 124 of file libbiosphere.c.

References copy_response().

Referenced by make_service_request().

Here is the call graph for this function:

void delete_bs_definition ( bs_definition def  ) 

Delete a bs_definition structure (and its substructures) which is allocated through conventional memory allocation techniques. Internal datastructures are assumed to be pointer to other structures, ie. the type member of a message_part points to the previously allocated data_type somewhere else in the struct. Doubles will not be freed.

Parameters:
def The definition to delete

Definition at line 118 of file libbiosphere.c.

References delete_definition().

Referenced by main().

Here is the call graph for this function:

const char* get_library_version_string ( void   ) 

Return a string describing the library's version.

Returns:
String describing the library's version.

Definition at line 50 of file libbiosphere.c.

References BIOSPHERE_VERSION_STRING.

Referenced by main().

bs_status get_services_list ( bs_definition **  def,
bs_uint16  port 
)

Retrieve all the services known to the daemon.

Parameters:
defs Result pointer which gets filled with all the know services
port The port on which the (local) biosphered is listening are to be retrieved
Returns:
Status code.

Definition at line 70 of file libbiosphere.c.

References BS_OK, connect_and_get(), copy_bs_definition(), and runtestsuite::rv.

Here is the call graph for this function:

bs_status init_library ( void   ) 

Initialize the biosphere library. This function must be called before any other functions in the library.

Returns:
Status code.

Definition at line 56 of file libbiosphere.c.

References BS_OK.

Referenced by main().

bs_status make_service_request ( bs_service_request request,
bs_service_response **  response,
bs_uint16  port 
)

Make a service request to the daemon.

Parameters:
request The request
response Result pointer to the response
port The port on which the (local) biosphered is listening
Returns:
Status code.

Definition at line 87 of file libbiosphere.c.

References BS_OK, connect_and_post(), copy_bs_service_response(), and runtestsuite::rv.

Referenced by make_request().

Here is the call graph for this function:


Generated on Tue Jul 17 09:51:34 2007 for Bio-SPHERE by  doxygen 1.5.1