AGX Dynamics 2.42.3.0
Loading...
Searching...
No Matches
agxPowerLine::SubGraph Class Referenceabstract

#include <SubGraph.h>

+ Inheritance diagram for agxPowerLine::SubGraph:

Public Member Functions

 SubGraph ()
 
virtual bool addNotification (agxSDK::Simulation *simulation)=0
 
 AGXSTREAM_DECLARE_ABSTRACT_SERIALIZABLE (agxPowerLine::SubGraph)
 
virtual void getConnectorsRecursive (ConnectorPtrVector &connectors)
 Fill the given vector with the Connectors that are held by this SubGraph.
 
Connector * getEnclosingConnector ()
 
const Connector * getEnclosingConnector () const
 
SubGraph * getEnclosingGraph ()
 
const SubGraph * getEnclosingGraph () const
 
Unit * getEnclosingUnit ()
 
const Unit * getEnclosingUnit () const
 
const agxPowerLine::ConnectorRefVector & getInternalConnectors () const
 
const agxPowerLine::UnitRefVector & getInternalUnits () const
 
const agx::Name & getName () const
 
SubGraph * getRootEnclosingGraph ()
 
const SubGraph * getRootEnclosingGraph () const
 
virtual void getUnitsRecursive (UnitPtrVector &units)
 Fill the given vector with the Units that are held by this SubGraph.
 
bool isEnclosedWithin (const SubGraph *component) const
 
virtual bool postUpdate (agx::Real timeStep)
 
virtual void prepareForRestore ()
 
virtual void prepareForStore ()
 
virtual bool preUpdate (agx::Real timeStep)
 
virtual bool removeNotification (agxUtil::ConstraintHolder *holder, agxSDK::Simulation *simulation)=0
 
virtual void restore (agxStream::InputArchive &in) override
 
virtual bool restore (agxStream::StorageStream &str)
 Restores internal data from stream.
 
void setName (const agx::Name &name)
 Set the name of this power line component.
 
void spreadPowerLineToGraph ()
 
virtual void store (agxStream::OutputArchive &out) const override
 
virtual bool store (agxStream::StorageStream &str) const
 Stores internal data into stream.
 
- Public Member Functions inherited from agx::Referenced
 Referenced ()
 Default constructor.
 
 Referenced (const Referenced &)
 
template<typename T >
T * as ()
 Subclass casting.
 
template<typename T >
const T * as () const
 
template<typename T >
T * asSafe ()
 Safe subclass casting, return nullptr if template type does not match.
 
template<typename T >
const T * asSafe () const
 
int getReferenceCount () const
 
template<typename T >
bool is () const
 Subclass test.
 
Referenced & operator= (const Referenced &)
 Assignment operator. Will increment the number of references to the referenced object.
 
void reference (void *ptr=nullptr) const
 Explicitly increment the reference count by one, indicating that this object has another pointer which is referencing it.
 
void unreference (void *ptr=nullptr) const
 Decrement the reference count by one, indicating that a pointer to this object is referencing it.
 
void unreference_nodelete () const
 Decrement the reference count by one, indicating that a pointer to this object is referencing it.
 
- Public Member Functions inherited from agxStream::Serializable
virtual ~Serializable ()
 Destructor for normal C++ use but hidden from SWIG bindings.
 
virtual const char * getClassName () const
 
bool getEnableSerialization () const
 
bool getEnableUuidGeneration ()
 
agx::UInt32 getIndex () const
 This index is given at creation of this object.
 
virtual StorageAgent * getStorageAgent () const =0
 
agx::Uuid getUuid () const
 
bool isFinished () const
 
void setEnableSerialization (bool flag)
 Set to false to disable serialization of this object.
 
void setFinished ()
 Tells this class that it is restored correctly and should not be deleted during destruction of an Archive.
 
void setUuid (const agx::Uuid &uuid)
 Explicitly set a Uuid on a serializable object.
 

Protected Member Functions

virtual ~SubGraph ()
 
void addInternalConnector (agxPowerLine::Connector *connector)
 
void addInternalUnit (agxPowerLine::Unit *unit)
 
void removeInternalConnector (agxPowerLine::Connector *connector)
 
void removeInternalUnit (agxPowerLine::Unit *unit)
 
agx::Bool replaceInternalUnit (agxPowerLine::Unit *oldUnit, agxPowerLine::Unit *newUnit)
 
- Protected Member Functions inherited from agx::Referenced
virtual ~Referenced ()
 Destructor.
 
void allocateObserverVector () const
 
void deleteUsingDeleteHandler () const
 
- Protected Member Functions inherited from agxStream::Serializable
 Serializable ()
 Default constructor.
 
 Serializable (const Serializable &other)
 Copy constructor.
 
void generateUuid ()
 

Protected Attributes

SubGraphObserver m_enclosingGraph
 
ConnectorRefVector m_internalConnectors
 
UnitRefVector m_internalUnits
 
agx::Name m_name
 
PowerLine * m_powerLine
 
- Protected Attributes inherited from agx::Referenced
Mutex m_mutex
 
ObserverContainer m_observers
 
AtomicValue m_refCount
 

Additional Inherited Members

- Static Public Member Functions inherited from agx::Referenced
template<typename T >
static bool ValidateCast (const Referenced *object)
 
- Static Public Member Functions inherited from agxStream::Serializable
static void setEnableUuidGeneration (bool flag)
 Specify if there should be UUID:s generated for each new Serializable object. By default it is enabled.
 
- Static Protected Member Functions inherited from agx::Referenced
static DeleteHandler * getDeleteHandler ()
 
static void setDeleteHandler (DeleteHandler *handler)
 Internal: Set a DeleteHandler to which deletion of all referenced counted objects will be delegated to.
 

Detailed Description

Definition at line 58 of file SubGraph.h.

Constructor & Destructor Documentation

◆ SubGraph()

agxPowerLine::SubGraph::SubGraph ( )

◆ ~SubGraph()

virtual agxPowerLine::SubGraph::~SubGraph ( )
protectedvirtual

Member Function Documentation

◆ addInternalConnector()

void agxPowerLine::SubGraph::addInternalConnector ( agxPowerLine::Connector *  connector)
protected

◆ addInternalUnit()

void agxPowerLine::SubGraph::addInternalUnit ( agxPowerLine::Unit *  unit)
protected

◆ addNotification()

virtual bool agxPowerLine::SubGraph::addNotification ( agxSDK::Simulation *  simulation)
pure virtual

◆ AGXSTREAM_DECLARE_ABSTRACT_SERIALIZABLE()

agxPowerLine::SubGraph::AGXSTREAM_DECLARE_ABSTRACT_SERIALIZABLE ( agxPowerLine::SubGraph  )

◆ getConnectorsRecursive()

virtual void agxPowerLine::SubGraph::getConnectorsRecursive ( ConnectorPtrVector &  connectors)
virtual

Fill the given vector with the Connectors that are held by this SubGraph.

The collection is recursive, so internal Connectors will be collected.

Reimplemented in agxDriveTrain::deprecated::DriveTrainComponent, and agxDriveTrain::Differential.

◆ getEnclosingConnector() [1/2]

Connector * agxPowerLine::SubGraph::getEnclosingConnector ( )

◆ getEnclosingConnector() [2/2]

const Connector * agxPowerLine::SubGraph::getEnclosingConnector ( ) const

◆ getEnclosingGraph() [1/2]

SubGraph * agxPowerLine::SubGraph::getEnclosingGraph ( )

◆ getEnclosingGraph() [2/2]

const SubGraph * agxPowerLine::SubGraph::getEnclosingGraph ( ) const

◆ getEnclosingUnit() [1/2]

Unit * agxPowerLine::SubGraph::getEnclosingUnit ( )

◆ getEnclosingUnit() [2/2]

const Unit * agxPowerLine::SubGraph::getEnclosingUnit ( ) const

◆ getInternalConnectors()

const agxPowerLine::ConnectorRefVector & agxPowerLine::SubGraph::getInternalConnectors ( ) const

◆ getInternalUnits()

const agxPowerLine::UnitRefVector & agxPowerLine::SubGraph::getInternalUnits ( ) const

◆ getName()

const agx::Name & agxPowerLine::SubGraph::getName ( ) const
Returns
The name of this power line component.

◆ getRootEnclosingGraph() [1/2]

SubGraph * agxPowerLine::SubGraph::getRootEnclosingGraph ( )
Returns
The top-most Enclosing Graph. May return 'this'.

◆ getRootEnclosingGraph() [2/2]

const SubGraph * agxPowerLine::SubGraph::getRootEnclosingGraph ( ) const
Returns
The top-most Enclosing Graph. May return 'this'.

◆ getUnitsRecursive()

virtual void agxPowerLine::SubGraph::getUnitsRecursive ( UnitPtrVector &  units)
virtual

Fill the given vector with the Units that are held by this SubGraph.

The collection is recursive, so internal Units will be collected.

Reimplemented in agxDriveTrain::deprecated::DriveTrainComponent.

◆ isEnclosedWithin()

bool agxPowerLine::SubGraph::isEnclosedWithin ( const SubGraph *  component) const
Returns
True if this component is enclosed within the given component.

◆ postUpdate()

◆ prepareForRestore()

virtual void agxPowerLine::SubGraph::prepareForRestore ( )
virtual

◆ prepareForStore()

virtual void agxPowerLine::SubGraph::prepareForStore ( )
virtual

◆ preUpdate()

◆ removeInternalConnector()

void agxPowerLine::SubGraph::removeInternalConnector ( agxPowerLine::Connector *  connector)
protected

◆ removeInternalUnit()

void agxPowerLine::SubGraph::removeInternalUnit ( agxPowerLine::Unit *  unit)
protected

◆ removeNotification()

virtual bool agxPowerLine::SubGraph::removeNotification ( agxUtil::ConstraintHolder *  holder,
agxSDK::Simulation *  simulation 
)
pure virtual

◆ replaceInternalUnit()

agx::Bool agxPowerLine::SubGraph::replaceInternalUnit ( agxPowerLine::Unit *  oldUnit,
agxPowerLine::Unit *  newUnit 
)
protected

◆ restore() [1/2]

◆ restore() [2/2]

virtual bool agxPowerLine::SubGraph::restore ( agxStream::StorageStream &  str)
virtual

◆ setName()

void agxPowerLine::SubGraph::setName ( const agx::Name &  name)

Set the name of this power line component.

Parameters
name- The new name.

◆ spreadPowerLineToGraph()

void agxPowerLine::SubGraph::spreadPowerLineToGraph ( )

◆ store() [1/2]

◆ store() [2/2]

virtual bool agxPowerLine::SubGraph::store ( agxStream::StorageStream &  str) const
virtual

Member Data Documentation

◆ m_enclosingGraph

SubGraphObserver agxPowerLine::SubGraph::m_enclosingGraph
protected

Definition at line 167 of file SubGraph.h.

◆ m_internalConnectors

ConnectorRefVector agxPowerLine::SubGraph::m_internalConnectors
protected

Definition at line 169 of file SubGraph.h.

◆ m_internalUnits

UnitRefVector agxPowerLine::SubGraph::m_internalUnits
protected

Definition at line 168 of file SubGraph.h.

◆ m_name

agx::Name agxPowerLine::SubGraph::m_name
protected

Definition at line 171 of file SubGraph.h.

◆ m_powerLine

PowerLine* agxPowerLine::SubGraph::m_powerLine
protected

Definition at line 170 of file SubGraph.h.


The documentation for this class was generated from the following file: