19 #ifndef EQFABRIC_NODE_H 20 #define EQFABRIC_NODE_H 22 #include <eq/fabric/object.h> 23 #include <eq/fabric/types.h> 31 template <
class C,
class N,
class P,
class V>
45 const Pipes&
getPipes()
const {
return _pipes; }
51 bool isApplicationNode()
const {
return _isAppNode; }
53 EQFABRIC_INL
void setApplicationNode(
const bool isAppNode);
56 EQFABRIC_INL NodePath getPath()
const;
57 P* findPipe(
const uint128_t&
id);
66 EQFABRIC_INL VisitorResult
accept(V& visitor);
69 EQFABRIC_INL VisitorResult
accept(V& visitor)
const;
85 IATTR_ALL = IATTR_LAST + 5
89 EQFABRIC_INL
void setIAttribute(
const IAttribute attr,
const int32_t value);
95 static const std::string& getIAttributeString(
const IAttribute attr);
100 EQFABRIC_INL
virtual void backup();
101 EQFABRIC_INL
virtual void restore();
102 void create(P** pipe);
103 void release(P* pipe);
104 virtual void output(std::ostream&)
const {}
105 EQFABRIC_INL
virtual uint128_t commit(
106 const uint32_t incarnation = CO_COMMIT_NEXT);
111 explicit Node(C* parent);
114 EQFABRIC_INL
virtual ~
Node();
117 EQFABRIC_INL
virtual void serialize(co::DataOStream& os,
118 const uint64_t dirtyBits);
120 EQFABRIC_INL
virtual void deserialize(co::DataIStream& is,
121 const uint64_t dirtyBits);
123 EQFABRIC_INL
virtual void notifyDetach();
126 EQFABRIC_INL
virtual void setDirty(
const uint64_t bits);
129 virtual ChangeType getChangeType()
const {
return UNBUFFERED; }
132 DIRTY_ATTRIBUTES = Object::DIRTY_CUSTOM << 0,
133 DIRTY_PIPES = Object::DIRTY_CUSTOM << 1,
134 DIRTY_MEMBER = Object::DIRTY_CUSTOM << 2,
136 DIRTY_ATTRIBUTES | DIRTY_PIPES | DIRTY_MEMBER | DIRTY_OBJECT_BITS
140 virtual uint64_t getRedistributableBits()
const {
return DIRTY_NODE_BITS; }
152 int32_t iAttributes[IATTR_ALL];
157 template <
class,
class,
class,
class>
159 void _addPipe(P* pipe);
160 bool _removePipe(P* pipe);
163 bool _mapNodeObjects() {
return _config->mapNodeObjects(); }
166 template <
class C,
class N,
class P,
class V>
167 EQFABRIC_INL std::ostream& operator<<(std::ostream&, const Node<C, N, P, V>&);
171 #endif // EQFABRIC_NODE_H const Pipes & getPipes() const
EQFABRIC_INL int32_t getIAttribute(const IAttribute attr) const
IAttribute
Integer attributes.
DirtyBits
The changed parts of the object since the last pack().
Base data transport class for pipes.
const C * getConfig() const
Base data transport class for nodes.
EQFABRIC_INL VisitorResult accept(V &visitor)
Perform a depth-first traversal of this node.
virtual EQFABRIC_INL void setDirty(const uint64_t bits)
The Equalizer client library.
std::vector< P * > Pipes
A vector of pointers to pipes.
Timeout when auto-launching the node.
Internal base class for all distributed, inheritable Equalizer objects.