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

molecule.c File Reference

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

Compounds

struct  rnamlMOLECULE

Functions

rnamlMoleculernamlnewMolecule ()
 Creates a new rnamlMolecule structure.

rnamlMoleculernamlcloneMolecule (const rnamlMolecule *molecule)
 Clones a rnamlMolecule struture.

void rnamldeleteMolecule (rnamlMolecule *molecule)
 Frees the rnamlMolecule structure.

int rnamlisMolecule (const rnamlObject *obj)
 Tells wheter the object is a rnamlMolecule.

int rnamlequalsMolecule (const rnamlMolecule *left, const rnamlMolecule *right)
 Tells if left and right are equals.

const char * rnamlgetMoleculeId (const rnamlMolecule *molecule)
 Gets the molecule id.

void rnamlsetMoleculeId (rnamlMolecule *molecule, const char *id)
 Sets the molecule id.

const char * rnamlgetMoleculeType (const rnamlMolecule *molecule)
 Gets the molecule type.

void rnamlsetMoleculeType (rnamlMolecule *molecule, const char *type)
 Sets the molecule type.

rnamlIdentityrnamlgetMoleculeIdentity (rnamlMolecule *molecule)
 Gets the identity from the molecule.

void rnamlsetMoleculeIdentity (rnamlMolecule *molecule, rnamlIdentity *identity)
 Sets the molecule identity.

void rnamladdMoleculeSequence (rnamlMolecule *molecule, rnamlSequence *sequence)
 Adds a sequence into a molecule.

xmlcpgListrnamlgetMoleculeSequences (rnamlMolecule *molecule)
 Gets the molecule's sequence list.

rnamlStructurernamlgetMoleculeStructure (rnamlMolecule *molecule)
 Gets the structure from the molecule.

void rnamlsetMoleculeStructure (rnamlMolecule *molecule, rnamlStructure *structure)
 Sets the molecule structure.

xmlcpgObjectrnamltoXMLMolecule (const rnamlMolecule *molecule)
 Translates the rnamlMolecule structure into a xmlcpgElement conforming to the RNAML standard.


Function Documentation

void rnamladdMoleculeSequence rnamlMolecule   molecule,
rnamlSequence   sequence
 

Adds a sequence into a molecule.

Parameters:
molecule  the rnamlMolecule structure.
sequence  the rnamlSequence structure.

rnamlMolecule* rnamlcloneMolecule const rnamlMolecule   molecule
 

Clones a rnamlMolecule struture.

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

void rnamldeleteMolecule rnamlMolecule   molecule
 

Frees the rnamlMolecule structure.

Parameters:
molecule  the rnamlMolecule structure to free.

int rnamlequalsMolecule const rnamlMolecule   left,
const rnamlMolecule   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.

const char* rnamlgetMoleculeId const rnamlMolecule   molecule
 

Gets the molecule id.

Parameters:
molecule  the rnamlMolecule structure.
Returns:
the molecule id string or NULL if molecule is NULL or not an rnamlMolecule.

rnamlIdentity* rnamlgetMoleculeIdentity rnamlMolecule   molecule
 

Gets the identity from the molecule.

Parameters:
molecule  the rnamlMolecule structure.
Returns:
the molecule identity is NULL or if molecule is NULL or not an rnamlMolecule.

xmlcpgList* rnamlgetMoleculeSequences rnamlMolecule   molecule
 

Gets the molecule's sequence list.

Parameters:
molecule  the rnamlMolecule structure.
Returns:
the molecule's sequence xmlcpgList or NULL if something goes wrong.

rnamlStructure* rnamlgetMoleculeStructure rnamlMolecule   molecule
 

Gets the structure from the molecule.

Parameters:
molecule  the rnamlMolecule structure.
Returns:
the molecule structure is NULL or if molecule is NULL or not an rnamlMolecule.

const char* rnamlgetMoleculeType const rnamlMolecule   molecule
 

Gets the molecule type.

Parameters:
molecule  the rnamlMolecule structure.
Returns:
the molecule type string or NULL if molecule is NULL or not an rnamlMolecule.

int rnamlisMolecule const rnamlObject   obj
 

Tells wheter the object is a rnamlMolecule.

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

rnamlMolecule* rnamlnewMolecule  
 

Creates a new rnamlMolecule structure.

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

void rnamlsetMoleculeId rnamlMolecule   molecule,
const char *    id
 

Sets the molecule id.

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

Parameters:
molecule  the rnamlMolecule structure.
id  the molecule id.

void rnamlsetMoleculeIdentity rnamlMolecule   molecule,
rnamlIdentity   identity
 

Sets the molecule identity.

The previous identity info is freed

Parameters:
molecule  the rnamlMolecule structure.
molecule  the molecule identity.

void rnamlsetMoleculeStructure rnamlMolecule   molecule,
rnamlStructure   structure
 

Sets the molecule structure.

The previous structure info is freed

Parameters:
molecule  the rnamlMolecule structure.
molecule  the molecule structure.

void rnamlsetMoleculeType rnamlMolecule   molecule,
const char *    type
 

Sets the molecule type.

Parameters:
molecule  the rnamlMolecule structure.
type  the molecule type.

xmlcpgObject* rnamltoXMLMolecule const rnamlMolecule   molecule
 

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

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


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