Geant4 9.6.0
Toolkit for the simulation of the passage of particles through matter
Loading...
Searching...
No Matches
HEPREP::HepRep Class Referenceabstract

#include <HepRep.h>

+ Inheritance diagram for HEPREP::HepRep:

Public Member Functions

virtual ~HepRep ()
 Destructor.
 
virtual void addLayer (std::string layer)=0
 
virtual std::vector< std::string > getLayerOrder ()=0
 
virtual void addTypeTree (HepRepTypeTree *typeTree)=0
 
virtual void removeTypeTree (HepRepTypeTree *typeTree)=0
 
virtual std::vector< HepRepTypeTree * > getTypeTreeList ()=0
 
virtual HepRepTypeTreegetTypeTree (std::string name, std::string version)=0
 
virtual void addInstanceTree (HepRepInstanceTree *instanceTree)=0
 
virtual void overlayInstanceTree (HepRepInstanceTree *instanceTree)=0
 
virtual void removeInstanceTree (HepRepInstanceTree *instanceTree)=0
 
virtual std::vector< HepRepInstanceTree * > getInstanceTreeList ()=0
 
virtual HepRepInstanceTreegetInstanceTreeTop (std::string name, std::string version)=0
 
virtual HepRepInstanceTreegetInstances (std::string name, std::string version, std::vector< std::string > typeNames)=0
 
virtual HepRepInstanceTreegetInstancesAfterAction (std::string name, std::string version, std::vector< std::string > typeNames, std::vector< HepRepAction * > actions, bool getPoints, bool getDrawAtts, bool getNonDrawAtts, std::vector< std::string > invertAtts)=0
 
virtual std::string checkForException ()=0
 
virtual HepRepcopy (HepRepSelectFilter *filter=NULL)=0
 

Detailed Description

The HepRep interface.

Any of these methods may throw a UnsupportedOperationException in Java.

This interface is NOT final yet.

Author
Mark Donszelmann

Definition at line 52 of file HepRep.h.

Constructor & Destructor Documentation

◆ ~HepRep()

virtual HEPREP::HepRep::~HepRep ( )
inlinevirtual

Destructor.

Definition at line 56 of file HepRep.h.

56{ /* nop */; }

Member Function Documentation

◆ addInstanceTree()

virtual void HEPREP::HepRep::addInstanceTree ( HepRepInstanceTree instanceTree)
pure virtual

Searches for a named type in any of the typetrees. The first occurrence found is returned.

Parameters
namename of type.
Returns
named HepRepType. Adds an instancetree to this heprep.
Parameters
instanceTreeto be added.

Implemented in cheprep::DefaultHepRep.

◆ addLayer()

virtual void HEPREP::HepRep::addLayer ( std::string  layer)
pure virtual

Add a layer to the list of layers in this heprep. The layer is added to the back of the list.

Parameters
layername of layer to be added to the back of the list.

Implemented in cheprep::DefaultHepRep.

◆ addTypeTree()

virtual void HEPREP::HepRep::addTypeTree ( HepRepTypeTree typeTree)
pure virtual

Add a typetree to this heprep.

Parameters
typeTreeto be added.

Implemented in cheprep::DefaultHepRep.

◆ checkForException()

virtual std::string HEPREP::HepRep::checkForException ( )
pure virtual

Returns last exception thrown and clears it. Useful for implementations without exception handling.

Returns
last exception and clears it.

Implemented in cheprep::DefaultHepRep.

◆ copy()

virtual HepRep * HEPREP::HepRep::copy ( HepRepSelectFilter filter = NULL)
pure virtual

Returns a deep copy of the heprep, with all its attached trees, where instances are filtered using a HepRepSelectFilter.

Parameters
filterto be used for filtering instances.
Returns
copy of heprep.

Implemented in cheprep::DefaultHepRep.

◆ getInstances()

virtual HepRepInstanceTree * HEPREP::HepRep::getInstances ( std::string  name,
std::string  version,
std::vector< std::string >  typeNames 
)
pure virtual

Returns a named and versioned instancetree for a list of typenames.

This tree needs to be added to the heprep afterwards.

Parameters
namename of the instancetree.
versionversion of the instancetree.
typeNamesa list of typenames for which we need instancetrees.
Returns
HepRepIntanceTree

Implemented in cheprep::DefaultHepRep.

◆ getInstancesAfterAction()

virtual HepRepInstanceTree * HEPREP::HepRep::getInstancesAfterAction ( std::string  name,
std::string  version,
std::vector< std::string >  typeNames,
std::vector< HepRepAction * >  actions,
bool  getPoints,
bool  getDrawAtts,
bool  getNonDrawAtts,
std::vector< std::string >  invertAtts 
)
pure virtual

Returns a named and versioned instancetree for a list of typenames after executing some action and for specific filters.

This tree needs to be added to the heprep afterwards.

The inversion effect of invertAtts depends on the values of GetDrawAtts and GetNonDrawAtts as follows:

  • GetDrawAtts GetNonDrawAtts effect of InvertAtts
  • FALSE FALSE all Attributes specified will be downloaded
  • TRUE FALSE Draw Attributes specified will be omitted, NonDraw Attributes specified will be included
  • FALSE TRUE Draw Attributes specified will be included, NonDraw Attributes specified will be omitted
  • TRUE TRUE all Attributes specified will be omitted
Parameters
namename of the instancetree.
versionversion of the instancetree.
typeNamesa list of typenames for which we need instancetrees.
actionsexecute this list of actions before returning.
getPointsinclude the HepRepPoints in the instance tree.
getDrawAttsinclude the Draw attributes in the instance tree.
getNonDrawAttsinclude the Non-Draw attributes in the instance tree.
invertAttslist of attributes to be included or not depending on getDrawAtts and getNonDrawAtts.
Returns
HepRepIntanceTree

Implemented in cheprep::DefaultHepRep.

◆ getInstanceTreeList()

virtual std::vector< HepRepInstanceTree * > HEPREP::HepRep::getInstanceTreeList ( )
pure virtual

Returns a collection of instancetrees.

Returns
collection of HepRepInstanceTrees.

Implemented in cheprep::DefaultHepRep.

Referenced by cheprep::XMLHepRepWriter::write().

◆ getInstanceTreeTop()

virtual HepRepInstanceTree * HEPREP::HepRep::getInstanceTreeTop ( std::string  name,
std::string  version 
)
pure virtual

Returns a named and versioned instancetree. FIXME: doc is incorrect here, should only return TOP of the tree. Filling in should be done by getInstances calls.

This tree needs to be added to the heprep afterwards.

Parameters
namename of the instancetree.
versionversion of the instancetree.
Returns
HepRepIntanceTree

Implemented in cheprep::DefaultHepRep.

◆ getLayerOrder()

virtual std::vector< std::string > HEPREP::HepRep::getLayerOrder ( )
pure virtual

Returns the list of layers.

Returns
the known layer names, in the order back-to-front.

Implemented in cheprep::DefaultHepRep.

Referenced by cheprep::XMLHepRepWriter::write().

◆ getTypeTree()

virtual HepRepTypeTree * HEPREP::HepRep::getTypeTree ( std::string  name,
std::string  version 
)
pure virtual

Returns a named and versioned typetree.

Parameters
namename of the typetree.
versionversion of the typetree.
Returns
named and versioned HepRepTypeTree.

Implemented in cheprep::DefaultHepRep.

◆ getTypeTreeList()

virtual std::vector< HepRepTypeTree * > HEPREP::HepRep::getTypeTreeList ( )
pure virtual

Returns the collection of all typetrees of this heprep.

Returns
collection of HepRepTypeTrees.

Implemented in cheprep::DefaultHepRep.

Referenced by cheprep::XMLHepRepWriter::write().

◆ overlayInstanceTree()

virtual void HEPREP::HepRep::overlayInstanceTree ( HepRepInstanceTree instanceTree)
pure virtual

Overlays an instancetree to this heprep, overriding attributes and adding children.

Parameters
instanceTreeto be overlaid.

Implemented in cheprep::DefaultHepRep.

◆ removeInstanceTree()

virtual void HEPREP::HepRep::removeInstanceTree ( HepRepInstanceTree instanceTree)
pure virtual

Remove an instanectree from this heprep.

Parameters
instanceTreeto be removed.

Implemented in cheprep::DefaultHepRep.

◆ removeTypeTree()

virtual void HEPREP::HepRep::removeTypeTree ( HepRepTypeTree typeTree)
pure virtual

Remove a typetree from this heprep.

Parameters
typeTreeto be removed.

Implemented in cheprep::DefaultHepRep.


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