Main Page   Namespace List   Class Hierarchy   Compound List   File List   Compound Members   File Members   Related Pages  

reference.c File Reference

#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include "reference.h"

Compounds

struct  rnamlREFERENCE

Functions

rnamlReferencernamlnewReference ()
 Creates a new rnamlReference structure.

rnamlReferencernamlcloneReference (const rnamlReference *reference)
 Clones a rnamlReference struture.

void rnamldeleteReference (rnamlReference *reference)
 Frees the rnamlReference structure.

int rnamlisReference (const rnamlObject *obj)
 Tells wheter the object is a rnamlReference.

int rnamlequalsReference (const rnamlReference *left, const rnamlReference *right)
 Tells if left and right are equals.

const char * rnamlgetReferenceId (const rnamlReference *reference)
 Gets the reference id.

void rnamlsetReferenceId (rnamlReference *reference, const char *id)
 Sets the reference id.

void rnamladdReferenceChild (rnamlReference *reference, rnamlObject *obj)
 Adds a reference child.

xmlcpgListrnamlgetReferenceChildren (const rnamlReference *reference)
 Gets the children from the reference collection.

xmlcpgObjectrnamltoXMLReference (const rnamlReference *reference)
 Translates the rnamlReference structure into a xmlcpgElement conforming to the RNAML standard.


Function Documentation

void rnamladdReferenceChild rnamlReference   reference,
rnamlObject   child
 

Adds a reference child.

Parameters:
reference  the rnamlReference structure.
child  the rnaml substructure converted into xmlcpgObject.

rnamlReference* rnamlcloneReference const rnamlReference   reference
 

Clones a rnamlReference struture.

Parameters:
reference  the structure to clone.
Returns:
the new allocated structure or NULL if something goes wrong.

void rnamldeleteReference rnamlReference   reference
 

Frees the rnamlReference structure.

Parameters:
reference  the rnamlReference structure to free.

int rnamlequalsReference const rnamlReference   left,
const rnamlReference   right
 

Tells if left and right are equals.

Parameters:
left  the left object to compare.
right  the right object to compare.
Returns:
1 if the objects are equals or 0 otherwise.

xmlcpgList* rnamlgetReferenceChildren const rnamlReference   reference
 

Gets the children from the reference collection.

Parameters:
reference  the rnamlReference structure.
Returns:
the reference children collection

const char* rnamlgetReferenceId const rnamlReference   reference
 

Gets the reference id.

Parameters:
reference  the rnamlReference structure.
Returns:
the reference id string or NULL if reference is NULL or not an rnamlReference.

int rnamlisReference const rnamlObject   obj
 

Tells wheter the object is a rnamlReference.

Parameters:
obj  the rnamlObject to test.
Returns:
1 if the object is a rnamlReference, 0 otherwise.

rnamlReference* rnamlnewReference  
 

Creates a new rnamlReference structure.

Returns:
the new allocated structure or NULL if something goes wrong.

void rnamlsetReferenceId rnamlReference   reference,
const char *    id
 

Sets the reference id.

The previous reference id is freed and a copy of id is generated.

Parameters:
reference  the rnamlReference structure.
id  the reference id.

xmlcpgObject* rnamltoXMLReference const rnamlReference   reference
 

Translates the rnamlReference structure into a xmlcpgElement conforming to the RNAML standard.

Parameters:
molecule  the rnamlReference structure to translate.
Returns:
the xmlcpgObject or NULL if something goes wrong.


Generated on Tue Nov 11 14:59:52 2003 for xmlcpg by doxygen1.2.18