copasi API  0.1
Public Member Functions | Protected Attributes | Friends
CLGraphicalObject Class Reference

#include <CLGraphicalObject.h>

Inheritance diagram for CLGraphicalObject:
CLBase CCopasiContainer CCopasiObject CLCompartmentGlyph CLMetabGlyph CLMetabReferenceGlyph CLReactionGlyph CLTextGlyph CCompartmentGraphNode CGraphNode CLabel

List of all members.

Public Member Functions

 CLGraphicalObject (const std::string &name="GraphicalObject", const CCopasiContainer *pParent=NULL)
 CLGraphicalObject (const CLGraphicalObject &src, const CCopasiContainer *pParent=NULL)
 CLGraphicalObject (const GraphicalObject &sbml, std::map< std::string, std::string > &layoutmap, const CCopasiContainer *pParent=NULL)
 ~CLGraphicalObject ()
CLGraphicalObjectoperator= (const CLGraphicalObject &rhs)
virtual const std::string & getKey () const
const CLBoundingBoxgetBoundingBox () const
CLBoundingBoxgetBoundingBox ()
void setBoundingBox (const CLBoundingBox &bb)
const CLPointgetPosition () const
void setPosition (const CLPoint &p)
const C_FLOAT64 & getX () const
void setX (const C_FLOAT64 &x)
const C_FLOAT64 & getY () const
void setY (const C_FLOAT64 &y)
const CLDimensionsgetDimensions () const
void setDimensions (const CLDimensions &d)
const C_FLOAT64 & getWidth () const
void setWidth (const C_FLOAT64 &w)
const C_FLOAT64 & getHeight () const
void setHeight (const C_FLOAT64 &h)
const std::string & getModelObjectKey () const
void setModelObjectKey (const std::string &k)
CCopasiObjectgetModelObject () const
std::string getModelObjectName () const
std::string getModelObjectDisplayName (bool regular=true, bool richtext=false) const
virtual void exportToSBML (GraphicalObject *sbmlobject, const std::map< CCopasiObject *, SBase * > &copasimodelmap, std::map< std::string, const SBase * > &sbmlIDs) const
void print (std::ostream *ostream) const

Protected Attributes

CLBoundingBox mBBox

Friends

std::ostream & operator<< (std::ostream &os, const CLGraphicalObject &g)

Detailed Description

This is the base class for the layout objects in copasi. It is a CCopasiObject. It also has a key (which is used if one layout object refers to another one) It provides the mechanism for refering to a copasi model object by key. This needs to be specialized in the derived classes


Constructor & Destructor Documentation

CLGraphicalObject::CLGraphicalObject ( const std::string &  name = "GraphicalObject",
const CCopasiContainer pParent = NULL 
)
CLGraphicalObject::CLGraphicalObject ( const CLGraphicalObject src,
const CCopasiContainer pParent = NULL 
)
CLGraphicalObject::CLGraphicalObject ( const GraphicalObject &  sbml,
std::map< std::string, std::string > &  layoutmap,
const CCopasiContainer pParent = NULL 
)

constructor from libsbml object

CLGraphicalObject::~CLGraphicalObject ( )

Member Function Documentation

void CLGraphicalObject::exportToSBML ( GraphicalObject *  sbmlobject,
const std::map< CCopasiObject *, SBase * > &  copasimodelmap,
std::map< std::string, const SBase * > &  sbmlIDs 
) const [virtual]

This method writes the information of the copasi layout object into the corresponding sbml object

const CLBoundingBox& CLGraphicalObject::getBoundingBox ( ) const [inline]
CLBoundingBox& CLGraphicalObject::getBoundingBox ( ) [inline]
const CLDimensions& CLGraphicalObject::getDimensions ( ) const [inline]
const C_FLOAT64& CLGraphicalObject::getHeight ( ) const [inline]
virtual const std::string& CLGraphicalObject::getKey ( ) const [inline, virtual]

Retrieves the key of the layout object

Reimplemented from CCopasiObject.

CCopasiObject * CLGraphicalObject::getModelObject ( ) const
std::string CLGraphicalObject::getModelObjectDisplayName ( bool  regular = true,
bool  richtext = false 
) const

if the graphical object refers to a model object this method will return the display name of that object.

const std::string& CLGraphicalObject::getModelObjectKey ( ) const [inline]
std::string CLGraphicalObject::getModelObjectName ( ) const

if the graphical object refers to a model object this method will return the name of that object.

const CLPoint& CLGraphicalObject::getPosition ( ) const [inline]
const C_FLOAT64& CLGraphicalObject::getWidth ( ) const [inline]
const C_FLOAT64& CLGraphicalObject::getX ( ) const [inline]
const C_FLOAT64& CLGraphicalObject::getY ( ) const [inline]
CLGraphicalObject & CLGraphicalObject::operator= ( const CLGraphicalObject rhs)

The assignment operator does not copy the key.

void CLGraphicalObject::print ( std::ostream *  ostream) const [virtual]

This is the output method for any object. The default implementation provided with CCopasiObject uses the ostream operator<< of the object to print the object.To override this default behavior one needs to reimplement the virtual print function.

Parameters:
std::ostream* ostream

Reimplemented from CCopasiObject.

Reimplemented in CLReactionGlyph, CLTextGlyph, CLMetabReferenceGlyph, CLCompartmentGlyph, and CLMetabGlyph.

void CLGraphicalObject::setBoundingBox ( const CLBoundingBox bb) [inline]
void CLGraphicalObject::setDimensions ( const CLDimensions d) [inline]
void CLGraphicalObject::setHeight ( const C_FLOAT64 &  h) [inline]
void CLGraphicalObject::setModelObjectKey ( const std::string &  k) [inline]
void CLGraphicalObject::setPosition ( const CLPoint p) [inline]
void CLGraphicalObject::setWidth ( const C_FLOAT64 &  w) [inline]
void CLGraphicalObject::setX ( const C_FLOAT64 &  x) [inline]
void CLGraphicalObject::setY ( const C_FLOAT64 &  y) [inline]

Friends And Related Function Documentation

std::ostream& operator<< ( std::ostream &  os,
const CLGraphicalObject g 
) [friend]

insert operator


Member Data Documentation


The documentation for this class was generated from the following files:
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Defines