Main Page | Namespace List | Class Hierarchy | Class List | Directories | File List | Namespace Members | Class Members

FD::UINetwork Class Reference

#include <UINetwork.h>

Inheritance diagram for FD::UINetwork:

Inheritance graph
[legend]
Collaboration diagram for FD::UINetwork:

Collaboration graph
[legend]
List of all members.

Public Types

enum  Type { subnet = 0, iterator = 1, threaded = 2 }

Public Member Functions

 UINetwork (UIDocument *_doc, std::string _name, Type _type)
 UINetwork (UIDocument *_doc, xmlNodePtr net, bool init=true)
void load (xmlNodePtr net)
virtual ~UINetwork ()
void setModified ()
UINodeloadNode (xmlNodePtr node)
UINodegetNodeNamed (std::string n)
void addNode (UINode *node)
void removeNode (UINode *node)
void addLink (UILink *link)
void removeLink (UILink *link)
const std::string & getName ()
std::string getDescription ()
void setDescription (const std::string &_description)
Type getType ()
UIDocumentgetDocument ()
bool isIter ()
void saveXML (xmlNode *root)
virtual void newNetNotify (const std::string &cat, const std::string &type)
void addTerminal (UINetTerminal *term)
void removeTerminal (UINetTerminal *term)
std::vector< std::string > getTerminals (UINetTerminal::NetTermType termType)
void insertNetParams (std::vector< ItemInfo * > &params)
virtual UINodenewNode (UINetwork *_net, xmlNodePtr def)
virtual UINodenewNode (UINetwork *_net, std::string _name, std::string _type, double _x, double _y, bool doInit)
virtual UILink * newLink (UITerminal *_from, UITerminal *_to, char *str=NULL)
virtual UINotenewNote (const std::string &text, double x, double y, bool visible)
virtual UINetTerminal * newNetTerminal (UITerminal *_terminal, UINetTerminal::NetTermType _type, const std::string &_name, const std::string &_objType="any", const std::string &_description="No description available")
Networkbuild (const std::string &netName, const ParameterSet &params)
void genCode (std::ostream &out, int &id, std::set< std::string > &nodeList)
std::vector< UINode * > getNodes ()
std::vector< UILink * > getLinks ()
std::vector< UINetTerminal * > getTerminals ()
std::vector< UINote * > getNotes ()
 Direct access to the note vector.
void addNote (UINote *note)
void removeNote (UINote *note)
virtual void rename (std::string newName)
void interfaceChangeNotify ()
virtual void updateAllSubnetTerminals (const std::string _nettype, const std::string _terminalname, UINetTerminal::NetTermType _terminaltype, bool _remove)
virtual void updateAllSubnetParameters (const std::string _nettype, NodeInfo *_info)

Protected Attributes

bool destroyed
UIDocumentdoc
std::string name
std::string m_description
Type type
std::vector< UINode * > nodes
std::vector< UILink * > links
std::vector< UINetTerminal * > terminals
std::vector< UINote * > m_notes

Detailed Description

UINetwork is the represantation used to store data for any network, either in the GUI or in batch mode. A UINetwork cannot perform any operation but can be used to build a real Network.
Author:
Jean-Marc Valin


Member Enumeration Documentation

enum FD::UINetwork::Type
 

Available network types


Constructor & Destructor Documentation

FD::UINetwork::UINetwork UIDocument _doc,
std::string  _name,
Type  _type
 

Basic constructor, allows building the UINetwork gradually

FD::UINetwork::UINetwork UIDocument _doc,
xmlNodePtr  net,
bool  init = true
 

Construct a UINetwork from a parsed XML file

virtual FD::UINetwork::~UINetwork  )  [virtual]
 

Destructor


Member Function Documentation

void FD::UINetwork::genCode std::ostream &  out,
int &  id,
std::set< std::string > &  nodeList
 

Generate C++ code for building the document, instead of using XML

void FD::UINetwork::load xmlNodePtr  net  ) 
 

Loads the info from the XML parse tree

virtual UINote* FD::UINetwork::newNote const std::string &  text,
double  x,
double  y,
bool  visible
[virtual]
 

Create a new UINote

Parameters:
text the text of the note
x the x position of the note (useful for GUINote)
y the y position of the note (usfeul for GUINote)
visible true if the note is visible (useful for GUINote)
Returns:
UINote *the pointer to the newly created note

void FD::UINetwork::setModified  ) 
 

Informs that some part of the network has been changed. To be called anytime one modifies something in the network, a node, a link, ...


Member Data Documentation

bool FD::UINetwork::destroyed [protected]
 

Has the network been destroyed? Not too sure what I was thinking...

UIDocument* FD::UINetwork::doc [protected]
 

Document (.n file) to which the network belongs

std::vector<UILink *> FD::UINetwork::links [protected]
 

All the links included in the network

std::string FD::UINetwork::m_description [protected]
 

Description of the network

std::vector<UINote*> FD::UINetwork::m_notes [protected]
 

All the notes in the network

std::string FD::UINetwork::name [protected]
 

Name of the network

std::vector<UINode *> FD::UINetwork::nodes [protected]
 

All the links included in the network

std::vector<UINetTerminal *> FD::UINetwork::terminals [protected]
 

Pointer to all the network terminals

Type FD::UINetwork::type [protected]
 

Network type (subnet, iterator, threaded iterator


The documentation for this class was generated from the following file:
Generated on Wed Oct 5 14:30:06 2005 for FlowDesigner by  doxygen 1.4.4