eq::server::Node Class Reference

The node. More...

#include <node.h>

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

List of all members.

Public Types

enum  State {
  STATE_STOPPED = 0, STATE_INITIALIZING, STATE_INIT_SUCCESS, STATE_INIT_FAILED,
  STATE_RUNNING, STATE_EXITING, STATE_EXIT_SUCCESS, STATE_EXIT_FAILED
}

Public Member Functions

 Node ()
 Constructs a new Node.
 Node (const Node &from, Config *config)
 Constructs a new deep copy of a node.
void send (net::SessionPacket &packet)
void send (net::SessionPacket &packet, const std::string &string)
template<typename T >
void send (net::SessionPacket &packet, const std::vector< T > &data)
void flushSendBuffer ()
void addConnectionDescription (ConnectionDescriptionPtr desc)
 Add a new description how this node can be reached.
bool removeConnectionDescription (ConnectionDescriptionPtr cd)
 Remove a connection description.
const ConnectionDescriptionVector & getConnectionDescriptions () const
Data Access.



ConfiggetConfig () const
ServergetServer () const
net::NodePtr getNode () const
void setNode (net::NodePtr node)
bool isApplicationNode () const
NodePath getPath () const
ChannelgetChannel (const ChannelPath &path)
State getState () const
net::CommandQueuegetServerThreadQueue ()
net::CommandQueuegetCommandThreadQueue ()
uint32_t getFinishedFrame () const
void addPipe (Pipe *pipe)
 Adds a new pipe to this node.
bool removePipe (Pipe *pipe)
 Removes a pipe from this node.
const PipeVector & getPipes () const
VisitorResult accept (NodeVisitor &visitor)
 Traverse this node and all children using a node visitor.
VisitorResult accept (NodeVisitor &visitor) const
void activate ()
 Increase node activition count.
void deactivate ()
 Decrease node activition count.
bool isActive () const
void addTasks (const uint32_t tasks)
 Add additional tasks this node might potentially execute.
void setName (const std::string &name)
const std::string & getName () const
void setLastDrawPipe (const Pipe *pipe)
 The last drawing channel for this entity.
const PipegetLastDrawPipe () const
Operations



void updateRunning (const uint32_t initID, const uint32_t frameNumber)
 Update (init and exit) this node and its children as needed.
bool syncRunning ()
 Finalize the last updateRunning changes.
void update (const uint32_t frameID, const uint32_t frameNumber)
 Trigger the rendering of a new frame for this node.
void flushFrames (const uint32_t frameNumber)
 Flush the processing of frames, including frameNumber.
void finishFrame (const uint32_t frame)
 Synchronize the completion of the rendering of a frame.
Barrier Cache

Caches barriers for which this node is the master.



net::BarriergetBarrier ()
 Get a new barrier of height 0.
void releaseBarrier (net::Barrier *barrier)
 Release a barrier server by this node.
Error information.



const std::string & getErrorMessage () const

Protected Member Functions

virtual void attachToSession (const uint32_t id, const uint32_t instanceID, net::Session *session)

Protected Attributes

base::RequestHandler _requestHandler
 Registers request packets waiting for a return value.

Friends

class Config

Attributes



enum  SAttribute { SATTR_LAUNCH_COMMAND, SATTR_FILL1, SATTR_FILL2, SATTR_ALL }
enum  CAttribute { CATTR_LAUNCH_COMMAND_QUOTE, CATTR_FILL1, CATTR_FILL2, CATTR_ALL }
void setSAttribute (const SAttribute attr, const std::string &value)
const std::string & getSAttribute (const SAttribute attr) const
void setCAttribute (const CAttribute attr, const char value)
char getCAttribute (const CAttribute attr) const
void setIAttribute (const eq::Node::IAttribute attr, const int32_t value)
int32_t getIAttribute (const eq::Node::IAttribute attr) const
static const std::string & getSAttributeString (const SAttribute attr)
static const std::string & getCAttributeString (const CAttribute attr)

Detailed Description

The node.

Definition at line 43 of file server/node.h.


Member Function Documentation

NodePath eq::server::Node::getPath (  )  const
Returns:
the index path to this node.

Definition at line 162 of file server/node.cpp.

References eq::server::Config::getNodes().

Referenced by eq::server::Pipe::getPath().

Here is the call graph for this function:

Here is the caller graph for this function:

State eq::server::Node::getState (  )  const [inline]
Returns:
the state of this node.

Definition at line 85 of file server/node.h.

References eq::base::Monitor< T >::get().

Here is the call graph for this function:

uint32_t eq::server::Node::getFinishedFrame (  )  const [inline]
Returns:
the number of the last finished frame.

Definition at line 93 of file server/node.h.

Referenced by eq::server::Config::notifyNodeFrameFinished().

Here is the caller graph for this function:

void eq::server::Node::addPipe ( Pipe pipe  ) 

Adds a new pipe to this node.

Parameters:
pipe the pipe.

Definition at line 140 of file server/node.cpp.

References eq::server::Pipe::getWindows().

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

Here is the call graph for this function:

Here is the caller graph for this function:

bool eq::server::Node::removePipe ( Pipe pipe  ) 

Removes a pipe from this node.

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

Definition at line 148 of file server/node.cpp.

References eq::server::Pipe::getWindows().

Here is the call graph for this function:

const PipeVector& eq::server::Node::getPipes (  )  const [inline]
Returns:
vector of pipes

Definition at line 112 of file server/node.h.

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

Here is the caller graph for this function:

VisitorResult eq::server::Node::accept ( NodeVisitor visitor  ) 

Traverse this node and all children using a node visitor.

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

Definition at line 230 of file server/node.cpp.

void eq::server::Node::activate (  ) 

Increase node activition count.

Definition at line 240 of file server/node.cpp.

References EQLOG.

Referenced by eq::server::Pipe::activate().

Here is the caller graph for this function:

void eq::server::Node::deactivate (  ) 

Decrease node activition count.

Definition at line 246 of file server/node.cpp.

References EQLOG.

Referenced by eq::server::Pipe::deactivate().

Here is the caller graph for this function:

bool eq::server::Node::isActive (  )  const [inline]
Returns:
if this pipe is actively used for rendering.

Definition at line 130 of file server/node.h.

Referenced by eq::server::Config::notifyNodeFrameFinished(), syncRunning(), and updateRunning().

Here is the caller graph for this function:

void eq::server::Node::addTasks ( const uint32_t  tasks  )  [inline]

Add additional tasks this node might potentially execute.

Definition at line 133 of file server/node.h.

Referenced by eq::server::Pipe::addTasks().

Here is the caller graph for this function:

void eq::server::Node::setLastDrawPipe ( const Pipe pipe  )  [inline]

The last drawing channel for this entity.

Definition at line 139 of file server/node.h.

Referenced by eq::server::ConfigUpdateDataVisitor::visitPost().

Here is the caller graph for this function:

void eq::server::Node::updateRunning ( const uint32_t  initID,
const uint32_t  frameNumber 
)

Update (init and exit) this node and its children as needed.

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

References isActive().

Here is the call graph for this function:

bool eq::server::Node::syncRunning (  ) 

Finalize the last updateRunning changes.

Definition at line 285 of file server/node.cpp.

References eq::server::Pipe::getErrorMessage(), isActive(), and eq::server::Pipe::syncRunning().

Here is the call graph for this function:

void eq::server::Node::update ( const uint32_t  frameID,
const uint32_t  frameNumber 
)

Trigger the rendering of a new frame for this node.

Parameters:
frameID a per-frame identifier passed to all rendering methods.
frameNumber the number of the frame.

Definition at line 406 of file server/node.cpp.

References EQLOG, EQVERB, eq::server::Pipe::isActive(), eq::LOG_TASKS, and eq::server::Pipe::update().

Here is the call graph for this function:

void eq::server::Node::flushFrames ( const uint32_t  frameNumber  ) 

Flush the processing of frames, including frameNumber.

Parameters:
frameNumber the number of the frame.

Definition at line 490 of file server/node.cpp.

References EQVERB.

void eq::server::Node::finishFrame ( const uint32_t  frame  ) 

Synchronize the completion of the rendering of a frame.

net::Barrier * eq::server::Node::getBarrier (  ) 

Get a new barrier of height 0.

Returns:
the barrier.

Definition at line 520 of file server/node.cpp.

References eq::net::Session::registerObject(), eq::net::Object::setAutoObsolete(), and eq::net::Barrier::setHeight().

Referenced by eq::server::Window::joinNVSwapBarrier(), and eq::server::Window::joinSwapBarrier().

Here is the call graph for this function:

Here is the caller graph for this function:

void eq::server::Node::releaseBarrier ( net::Barrier barrier  ) 

Release a barrier server by this node.

Parameters:
barrier the barrier.

Definition at line 538 of file server/node.cpp.

void eq::server::Node::addConnectionDescription ( ConnectionDescriptionPtr  desc  )  [inline]

Add a new description how this node can be reached.

Parameters:
desc the connection description.

Definition at line 261 of file server/node.h.

Referenced by Node().

Here is the caller graph for this function:

bool eq::server::Node::removeConnectionDescription ( ConnectionDescriptionPtr  cd  ) 

Remove a connection description.

Parameters:
cd the connection description.
Returns:
true if the connection description was removed, false otherwise.

Definition at line 555 of file server/node.cpp.

const ConnectionDescriptionVector& eq::server::Node::getConnectionDescriptions (  )  const [inline]
Returns:
the vector of connection descriptions.

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

Referenced by Node().

Here is the caller graph for this function:

const std::string& eq::server::Node::getErrorMessage (  )  const [inline]
Returns:
the error message from the last operation.

Definition at line 281 of file server/node.h.

void eq::server::Node::attachToSession ( const uint32_t  id,
const uint32_t  instanceID,
net::Session session 
) [protected, virtual]
See also:
net::Object::attachToSession.

Reimplemented from eq::net::Object.

Definition at line 125 of file server/node.cpp.

References eq::net::Dispatcher::registerCommand().

Here is the call graph for this function:


Member Data Documentation

Registers request packets waiting for a return value.

Definition at line 288 of file server/node.h.


The documentation for this class was generated from the following files:
Generated on Sat Feb 6 13:14:08 2010 for Equalizer 0.9.1 by  doxygen 1.6.1