eq::server::Config Class Reference

The config. More...

#include <config.h>

Inheritance diagram for eq::server::Config:

Inheritance graph
[legend]
Collaboration diagram for eq::server::Config:

Collaboration graph
[legend]

List of all members.

Public Member Functions

 Config ()
 Constructs a new Config.
 Config (const Config &from)
 Constructs a new deep copy of a config.
void setLatency (const uint32_t latency)
 Set the maximum accepted latency for this config.
uint32_t getLatency () const
uint32_t getFinishedFrame () const
void setApplicationName (const std::string &name)
 Set the name of the application.
void addApplicationNode (Node *node)
 Add the config node running the application thread.
NodegetApplicationNode ()
bool isApplicationNode (const Node *node) const
void setApplicationNetNode (net::NodePtr node)
 Set the network node running the application thread.
void setRenderClient (const std::string &rc)
 Set the name of the render client executable.
void setWorkDir (const std::string &workDir)
 Set the working directory for render client.
void notifyNodeFrameFinished (const uint32_t frameNumber)
 Notify that a node of this config has finished a frame.
bool exit ()
void unmap ()
 Unmap all shared objects of the session, called before session teardown.
uint32_t getDistributorID ()
 Used by server during appNode initialization.
uint32_t getInitID ()
 Return the initID for late initialization.
Data Access.
ServergetServer ()
ChannelgetChannel (const ChannelPath &path)
CanvasgetCanvas (const CanvasPath &path)
SegmentgetSegment (const SegmentPath &path)
LayoutgetLayout (const LayoutPath &path)
ObservergetObserver (const ObserverPath &path)
ViewgetView (const ViewPath &path)
bool isRunning () const
net::CommandQueuegetServerThreadQueue ()
void setName (const std::string &name)
const std::string & getName () const
void addNode (Node *node)
 Adds a new node to this config.
bool removeNode (Node *node)
 Removes a node from this config.
const NodeVector & getNodes () const
void addObserver (Observer *observer)
 Adds a new observer to this config.
bool removeObserver (Observer *observer)
 Removes a observer from this config.
const ObserverVector & getObservers () const
ObserverfindObserver (const std::string &name)
 Find the first observer of a given name.
const ObserverfindObserver (const std::string &name) const
ObserverfindObserver (const uint32_t id)
void addLayout (Layout *layout)
 Adds a new layout to this config.
bool removeLayout (Layout *layout)
 Removes a layout from this config.
const LayoutVector & getLayouts () const
LayoutfindLayout (const std::string &name)
 Find the first layout of a given name.
const LayoutfindLayout (const std::string &name) const
LayoutfindLayout (const uint32_t id)
ViewfindView (const std::string &name)
 Find the first view of a given name.
const ViewfindView (const std::string &name) const
void addCanvas (Canvas *canvas)
 Adds a new canvas to this config.
bool removeCanvas (Canvas *canvas)
 Removes a canvas from this config.
const CanvasVector & getCanvases () const
CanvasfindCanvas (const std::string &name)
 Find the first canvas of a given name.
const CanvasfindCanvas (const std::string &name) const
SegmentfindSegment (const std::string &name)
 Find the first segment of a given name.
const SegmentfindSegment (const std::string &name) const
void addCompound (Compound *compound)
 Adds a new compound to this config.
bool removeCompound (Compound *compound)
 Removes a compound from this config.
const CompoundVector & getCompounds () const
ChannelfindChannel (const std::string &name)
 Find the first channel of a given name.
const ChannelfindChannel (const std::string &name) const
ChannelfindChannel (const Segment *segment, const View *view)
 Find the channel for the given view/segment intersection.
VisitorResult accept (ConfigVisitor &visitor)
 Traverse this config and all children using a config visitor.
VisitorResult accept (ConstConfigVisitor &visitor) const
Error information.
const std::string & getErrorMessage () const

Protected Member Functions

virtual void notifyMapped (net::NodePtr node)

Friends

class Server

Attributes

enum  FAttribute {
  FATTR_EYE_BASE, FATTR_VERSION, FATTR_FILL1, FATTR_FILL2,
  FATTR_ALL
}
void setFAttribute (const FAttribute attr, const float value)
float getFAttribute (const FAttribute attr) const
static const std::string & getFAttributeString (const FAttribute attr)


Detailed Description

The config.

Definition at line 48 of file server/config.h.


Member Function Documentation

Server* eq::server::Config::getServer (  )  [inline]

Returns:
the server hosting this session, or 0 if the session is not mapped..

Reimplemented from eq::net::Session.

Definition at line 66 of file server/config.h.

void eq::server::Config::addNode ( Node node  ) 

Adds a new node to this config.

Parameters:
node the node.

Definition at line 224 of file server/config.cpp.

References eq::server::Node::_config.

Referenced by addApplicationNode(), and eq::server::Node::Node().

Here is the caller graph for this function:

bool eq::server::Config::removeNode ( Node node  ) 

Removes a node from this config.

Parameters:
node the node
Returns:
true if the node was removed, false otherwise.

Definition at line 231 of file server/config.cpp.

References eq::server::Node::_config.

const NodeVector& eq::server::Config::getNodes (  )  const [inline]

Returns:
the vector of nodes.

Definition at line 100 of file server/config.h.

Referenced by Config(), and eq::server::Node::getPath().

Here is the caller graph for this function:

void eq::server::Config::addObserver ( Observer observer  ) 

Adds a new observer to this config.

Parameters:
observer the observer.

Definition at line 243 of file server/config.cpp.

References eq::server::Observer::_config.

Referenced by eq::server::Observer::Observer().

Here is the caller graph for this function:

bool eq::server::Config::removeObserver ( Observer observer  ) 

Removes a observer from this config.

Parameters:
observer the observer
Returns:
true if the observer was removed, false otherwise.

Definition at line 249 of file server/config.cpp.

References eq::server::Observer::_config.

const ObserverVector& eq::server::Config::getObservers (  )  const [inline]

Returns:
the vecotr of observers.

Definition at line 119 of file server/config.h.

Referenced by Config(), and eq::server::Observer::getPath().

Here is the caller graph for this function:

Observer * eq::server::Config::findObserver ( const std::string &  name  ) 

Find the first observer of a given name.

Parameters:
name the name of the observer to find
Returns:
the first observer with the name, or 0 if no observer with the name exists.

Definition at line 261 of file server/config.cpp.

References accept().

Here is the call graph for this function:

Observer * eq::server::Config::findObserver ( const uint32_t  id  ) 

Returns:
the observer mapped to the given identifier, or 0.

Definition at line 273 of file server/config.cpp.

References accept().

Here is the call graph for this function:

void eq::server::Config::addLayout ( Layout layout  ) 

Adds a new layout to this config.

Parameters:
layout the layout.

Definition at line 281 of file server/config.cpp.

References eq::server::Layout::_config.

Referenced by eq::server::Layout::Layout().

Here is the caller graph for this function:

bool eq::server::Config::removeLayout ( Layout layout  ) 

Removes a layout from this config.

Parameters:
layout the layout
Returns:
true if the layout was removed, false otherwise.

Definition at line 287 of file server/config.cpp.

References eq::server::Layout::_config.

const LayoutVector& eq::server::Config::getLayouts (  )  const [inline]

Returns:
the vecotr of layouts.

Definition at line 151 of file server/config.h.

Referenced by Config(), and eq::server::Layout::getPath().

Here is the caller graph for this function:

Layout * eq::server::Config::findLayout ( const std::string &  name  ) 

Find the first layout of a given name.

Parameters:
name the name of the layout to find
Returns:
the first layout with the name, or 0 if no layout with the name exists.

Definition at line 300 of file server/config.cpp.

References accept().

Here is the call graph for this function:

Layout * eq::server::Config::findLayout ( const uint32_t  id  ) 

Returns:
the layout mapped to the given identifier, or 0.

Definition at line 312 of file server/config.cpp.

References accept().

Here is the call graph for this function:

View * eq::server::Config::findView ( const std::string &  name  ) 

Find the first view of a given name.

Parameters:
name the name of the view to find
Returns:
the first view with the name, or 0 if no view with the name exists.

Definition at line 319 of file server/config.cpp.

References accept().

Here is the call graph for this function:

void eq::server::Config::addCanvas ( Canvas canvas  ) 

bool eq::server::Config::removeCanvas ( Canvas canvas  ) 

Removes a canvas from this config.

Parameters:
canvas the canvas
Returns:
true if the canvas was removed, false otherwise.

Definition at line 451 of file server/config.cpp.

References eq::server::Canvas::_config.

Referenced by eq::server::Canvas::~Canvas().

Here is the caller graph for this function:

const CanvasVector& eq::server::Config::getCanvases (  )  const [inline]

Returns:
the vecotr of canvases.

Definition at line 193 of file server/config.h.

Referenced by Config(), and eq::server::Canvas::getPath().

Here is the caller graph for this function:

Canvas * eq::server::Config::findCanvas ( const std::string &  name  ) 

Find the first canvas of a given name.

Parameters:
name the name of the canvas to find
Returns:
the first canvas with the name, or 0 if no canvas with the name exists.

Definition at line 463 of file server/config.cpp.

References accept().

Here is the call graph for this function:

Segment * eq::server::Config::findSegment ( const std::string &  name  ) 

Find the first segment of a given name.

Parameters:
name the name of the segment to find
Returns:
the first segment with the name, or 0 if no segment with the name exists.

Definition at line 477 of file server/config.cpp.

References accept().

Here is the call graph for this function:

void eq::server::Config::addCompound ( Compound compound  ) 

Adds a new compound to this config.

Parameters:
compound the compound.

Definition at line 491 of file server/config.cpp.

References eq::server::Compound::_config.

Referenced by eq::server::Loader::addOutputCompounds(), and eq::server::Compound::Compound().

Here is the caller graph for this function:

bool eq::server::Config::removeCompound ( Compound compound  ) 

Removes a compound from this config.

Parameters:
compound the compound
Returns:
true if the compound was removed, false otherwise.

Definition at line 497 of file server/config.cpp.

References eq::server::Compound::_config.

Referenced by eq::server::Compound::~Compound().

Here is the caller graph for this function:

const CompoundVector& eq::server::Config::getCompounds (  )  const [inline]

Returns:
the vecotr of compounds.

Definition at line 232 of file server/config.h.

Referenced by Config().

Here is the caller graph for this function:

Channel * eq::server::Config::findChannel ( const std::string &  name  ) 

Find the first channel of a given name.

Parameters:
name the name of the channel to find
Returns:
the first channel with the name, or 0 if no channel with the name exists.

Definition at line 509 of file server/config.cpp.

References accept().

Referenced by addCanvas().

Here is the call graph for this function:

Here is the caller graph for this function:

Channel * eq::server::Config::findChannel ( const Segment segment,
const View view 
)

Find the channel for the given view/segment intersection.

Parameters:
segment the segment.
view the view.
Returns:
the channel for updating the view/segment intersection.

Definition at line 364 of file server/config.cpp.

References accept().

Here is the call graph for this function:

VisitorResult eq::server::Config::accept ( ConfigVisitor visitor  ) 

Traverse this config and all children using a config visitor.

Parameters:
visitor the visitor.
Returns:
the result of the visitor traversal.

Definition at line 727 of file server/config.cpp.

Referenced by eq::server::Loader::addOutputCompounds(), eq::server::View::deserialize(), findCanvas(), findChannel(), findLayout(), findObserver(), findSegment(), findView(), eq::server::ConfigSerializer::getInstanceData(), and unmap().

Here is the caller graph for this function:

void eq::server::Config::setLatency ( const uint32_t  latency  )  [inline]

Set the maximum accepted latency for this config.

The latency is defined as the maximum number of frames between the start of a frame and the finish of the last rendering task for that frame.

Parameters:
latency the latency.

Definition at line 272 of file server/config.h.

uint32_t eq::server::Config::getLatency (  )  const [inline]

Returns:
the latency for this config.

Definition at line 275 of file server/config.h.

Referenced by eq::server::ConfigSerializer::getInstanceData(), and eq::server::CompoundInitVisitor::visit().

Here is the caller graph for this function:

uint32_t eq::server::Config::getFinishedFrame (  )  const [inline]

Returns:
the last finished frame.

Definition at line 278 of file server/config.h.

void eq::server::Config::setApplicationName ( const std::string &  name  )  [inline]

Set the name of the application.

Parameters:
name the name of the application.

Definition at line 284 of file server/config.h.

void eq::server::Config::addApplicationNode ( Node node  ) 

Add the config node running the application thread.

Parameters:
node the application node.

Definition at line 523 of file server/config.cpp.

References addNode().

Here is the call graph for this function:

Node* eq::server::Config::getApplicationNode (  )  [inline]

Returns:
the application node, or 0 if it was not set.

Definition at line 294 of file server/config.h.

bool eq::server::Config::isApplicationNode ( const Node node  )  const [inline]

Returns:
true if the node is the application node.

Definition at line 297 of file server/config.h.

void eq::server::Config::setApplicationNetNode ( net::NodePtr  node  ) 

Set the network node running the application thread.

Parameters:
node the application node.

Definition at line 532 of file server/config.cpp.

void eq::server::Config::setRenderClient ( const std::string &  rc  )  [inline]

Set the name of the render client executable.

Parameters:
rc the name of the render client executable.

Definition at line 312 of file server/config.h.

void eq::server::Config::setWorkDir ( const std::string &  workDir  )  [inline]

Set the working directory for render client.

Parameters:
workDir the working directory for the render client.

Definition at line 319 of file server/config.h.

void eq::server::Config::notifyNodeFrameFinished ( const uint32_t  frameNumber  ) 

Notify that a node of this config has finished a frame.

Definition at line 1162 of file server/config.cpp.

References EQLOG, eq::server::Node::getFinishedFrame(), eq::net::Session::getID(), eq::server::Node::isActive(), and eq::LOG_TASKS.

Here is the call graph for this function:

const std::string& eq::server::Config::getErrorMessage (  )  const [inline]

Returns:
the error message from the last operation.

Definition at line 356 of file server/config.h.

uint32_t eq::server::Config::getDistributorID (  ) 

Used by server during appNode initialization.

Definition at line 742 of file server/config.cpp.

References eq::net::Object::getID(), and eq::net::Session::registerObject().

Here is the call graph for this function:

void eq::server::Config::notifyMapped ( net::NodePtr  node  )  [protected, virtual]

See also:
net::Session::notifyMapped.

Reimplemented from eq::net::Session.

Definition at line 197 of file server/config.cpp.

References eq::net::Session::getCommandThreadQueue(), and eq::net::Dispatcher::registerCommand().

Here is the call graph for this function:


The documentation for this class was generated from the following files:
Generated on Mon Aug 10 18:58:45 2009 for Equalizer 0.9 by  doxygen 1.5.8