|
ACTS
Experiment-independent tracking
|
PortalLinkBase is the abstract base class for all portal links. More...
#include <Acts/Geometry/PortalLinkBase.hpp>
Public Member Functions | |
| virtual | ~PortalLinkBase ()=default |
| Virtual destructor in case the object is held as a derived. | |
| virtual Result< const TrackingVolume * > | resolveVolume (const GeometryContext &gctx, const Vector2 &position, double tolerance=s_onSurfaceTolerance) const =0 |
| Resolve a volume given a local position. | |
| virtual Result< const TrackingVolume * > | resolveVolume (const GeometryContext &gctx, const Vector3 &position, double tolerance=s_onSurfaceTolerance) const =0 |
| Resolve a volume given a global position. | |
| void | setSurface (std::shared_ptr< RegularSurface > surface) |
| Setter for the surface. | |
| const RegularSurface & | surface () const |
| Getter for the associated surface. | |
| const std::shared_ptr< RegularSurface > & | surfacePtr () const |
| Getter for the underlying shared pointer. | |
| virtual void | toStream (std::ostream &os) const =0 |
| Stream output function. | |
Static Public Member Functions | |
| static std::unique_ptr< PortalLinkBase > | merge (std::unique_ptr< PortalLinkBase > a, std::unique_ptr< PortalLinkBase > b, AxisDirection direction, const Logger &logger=getDummyLogger()) |
| Merge two portal link into a single one. | |
Protected Member Functions | |
| PortalLinkBase (std::shared_ptr< RegularSurface > surface) | |
| Constructor from a surface. | |
Static Protected Member Functions | |
| static void | checkMergePreconditions (const PortalLinkBase &a, const PortalLinkBase &b, AxisDirection direction) |
| Helper function to check a number of preconditions before merging is executed. | |
Protected Attributes | |
| std::shared_ptr< RegularSurface > | m_surface |
| Surface associated with this portal link. | |
PortalLinkBase is the abstract base class for all portal links.
A portal link is a mapping between a surface and a point on the surface and a destination tracking volume. The derived classes implement different ways to resolve a volume
|
explicitprotected |
Constructor from a surface.
This constructor is only called from derived classes
| surface | The surface |
|
virtualdefault |
Virtual destructor in case the object is held as a derived.
|
staticprotected |
Helper function to check a number of preconditions before merging is executed.
| a | The first portal link |
| b | The second portal link |
| direction | The axis direction for merging |
|
static |
Merge two portal link into a single one.
The merge can resolve combinations of difference derived classes, and will try to flatten and deep merge given links if possible.
| a | The first portal link |
| b | The second portal link |
| direction | The binning direction in which to merge. Valid values are depend on the surface types associated with the links. |
| logger | The logger to use for messages |
|
pure virtual |
Resolve a volume given a local position.
The local position is assumed to be on surface.
| gctx | The geometry context |
| position | The local position |
| tolerance | The tolerance for the lookup |
Implemented in Acts::CompositePortalLink, Acts::GridPortalLinkT< Axes >, and Acts::TrivialPortalLink.
|
pure virtual |
Resolve a volume given a global position.
Depending on the derived class, the global position might be converted to a local position before lookup.
| gctx | The geometry context |
| position | The global position |
| tolerance | The tolerance for the lookup |
Implemented in Acts::CompositePortalLink, Acts::GridPortalLinkT< Axes >, and Acts::TrivialPortalLink.
| void Acts::PortalLinkBase::setSurface | ( | std::shared_ptr< RegularSurface > | surface | ) |
Setter for the surface.
| surface | The surface |
| const RegularSurface & Acts::PortalLinkBase::surface | ( | ) | const |
Getter for the associated surface.
| const std::shared_ptr< RegularSurface > & Acts::PortalLinkBase::surfacePtr | ( | ) | const |
Getter for the underlying shared pointer.
|
pure virtual |
Stream output function.
| os | The output stream |
Implemented in Acts::CompositePortalLink, Acts::GridPortalLinkT< Axes >, and Acts::TrivialPortalLink.
|
protected |
Surface associated with this portal link.