18 #ifndef AGXPOWERLINE_SUB_GRAPH_ROUTER_H
19 #define AGXPOWERLINE_SUB_GRAPH_ROUTER_H
32 class PhysicalDimension;
47 class ConstraintHolder;
#define AGX_DECLARE_POINTER_TYPES(type)
#define AGX_DECLARE_VECTOR_TYPES(type)
Links two connections together.
PowerLine is the base class for a system of power transfer integrated into the rigid body simulation.
virtual void prepareForStore()
bool isEnclosedWithin(const SubGraph *component) const
AGXSTREAM_DECLARE_ABSTRACT_SERIALIZABLE(agxPowerLine::SubGraph)
void addInternalUnit(agxPowerLine::Unit *unit)
SubGraphObserver m_enclosingGraph
const agxPowerLine::UnitRefVector & getInternalUnits() const
virtual bool preUpdate(agx::Real timeStep)
virtual void store(agxStream::OutputArchive &out) const override
virtual bool restore(agxStream::StorageStream &str)
Restores internal data from stream.
SubGraph * getRootEnclosingGraph()
Unit * getEnclosingUnit()
Connector * getEnclosingConnector()
virtual void getUnitsRecursive(UnitPtrVector &units)
Fill the given vector with the Units that are held by this SubGraph.
ConnectorRefVector m_internalConnectors
const agx::Name & getName() const
const SubGraph * getEnclosingGraph() const
void setName(const agx::Name &name)
Set the name of this power line component.
const Connector * getEnclosingConnector() const
virtual void restore(agxStream::InputArchive &in) override
virtual void getConnectorsRecursive(ConnectorPtrVector &connectors)
Fill the given vector with the Connectors that are held by this SubGraph.
void removeInternalConnector(agxPowerLine::Connector *connector)
virtual bool removeNotification(agxUtil::ConstraintHolder *holder, agxSDK::Simulation *simulation)=0
const agxPowerLine::ConnectorRefVector & getInternalConnectors() const
virtual bool postUpdate(agx::Real timeStep)
const SubGraph * getRootEnclosingGraph() const
void addInternalConnector(agxPowerLine::Connector *connector)
UnitRefVector m_internalUnits
void removeInternalUnit(agxPowerLine::Unit *unit)
void spreadPowerLineToGraph()
agx::Bool replaceInternalUnit(agxPowerLine::Unit *oldUnit, agxPowerLine::Unit *newUnit)
const Unit * getEnclosingUnit() const
virtual bool store(agxStream::StorageStream &str) const
Stores internal data into stream.
virtual void prepareForRestore()
virtual bool addNotification(agxSDK::Simulation *simulation)=0
SubGraph * getEnclosingGraph()
Simulation is a class that bridges the collision space agxCollide::Space and the dynamic simulation s...
Class for writing serialized data in binary format to a stream.
This class is an abstract base class for all classes that can be stored and retrieved from an Archive...
Abstract base class for storing/restoring a line/drums with version control.
Utility class to hold custom implementations of constraints.
Representation of a name string.
Base class providing referencing counted objects.
agxPowerLine contains a collection of connected components that transport power across a system.
agx::Vector< UnitRef > UnitRefVector
agx::Vector< ConnectorRef > ConnectorRefVector
agx::ref_ptr< Unit > UnitRef
agx::Vector< Connector * > ConnectorPtrVector
agx::ref_ptr< Connector > ConnectorRef
agx::Vector< Unit * > UnitPtrVector
InputRef< T > in(const char *name, T &obj)
Create an object with a name and a reference to the object that should be restored (usually a pointer...
OutputRef< Serializable > out(const char *name, const Serializable *obj)
Return an object that contain the name and the object that should be serialized to an archive.
The agxUtil namespace contain classes and methods for utility functionality.
The agx namespace contains the dynamics/math part of the AGX Dynamics API.