ATLAS Offline Software
Classes
TProperty.h File Reference
#include <string>
#include <vector>
#include "AsgTools/ToolHandle.h"
#include "AsgTools/ToolHandleArray.h"
#include "AsgTools/Property.h"
#include "AsgTools/TProperty.icc"
Include dependency graph for TProperty.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Classes

class  TProperty< T >
 Templated wrapper around user properties. More...
 

Functions

Property creator helper function(s)

Special handling for strings to get casts right

PropertycreateProperty (const bool &rval)
 Create a boolean propert. More...
 
PropertycreateProperty (const int &rval)
 Create an integer property. More...
 
PropertycreateProperty (const float &rval)
 Create a float property. More...
 
PropertycreateProperty (const double &rval)
 Create a double property. More...
 
PropertycreateProperty (const std::string &rval)
 Create a string property. More...
 
PropertycreateProperty (const std::vector< int > &rval)
 Create an integer vector property. More...
 
PropertycreateProperty (const std::vector< float > &rval)
 Create a floating point vector property. More...
 
PropertycreateProperty (const std::vector< std::string > &rval)
 Create a string vector property. More...
 
template<typename T >
PropertycreateProperty (const T &rval)
 Create a property for a default, unknown type. More...
 

Function Documentation

◆ createProperty() [1/9]

Property* createProperty ( const bool &  rval)

Create a boolean propert.

Definition at line 589 of file TProperty.cxx.

589  {
590  return new TProperty< bool >( const_cast< bool& >( rval ), Property::BOOL );
591 }

◆ createProperty() [2/9]

Property* createProperty ( const double &  rval)

Create a double property.

Definition at line 602 of file TProperty.cxx.

602  {
603  return new TProperty< double >( const_cast< double& >( rval ),
605 }

◆ createProperty() [3/9]

Property* createProperty ( const float &  rval)

Create a float property.

Definition at line 597 of file TProperty.cxx.

597  {
598  return new TProperty< float >( const_cast< float& >( rval ),
599  Property::FLOAT );
600 }

◆ createProperty() [4/9]

Property* createProperty ( const int &  rval)

Create an integer property.

Definition at line 593 of file TProperty.cxx.

593  {
594  return new TProperty< int >( const_cast< int& >( rval ), Property::INT );
595 }

◆ createProperty() [5/9]

Property* createProperty ( const std::string &  rval)

Create a string property.

Definition at line 607 of file TProperty.cxx.

607  {
608  return new TProperty< std::string >( const_cast< std::string& >( rval ),
610 }

◆ createProperty() [6/9]

Property* createProperty ( const std::vector< float > &  rval)

Create a floating point vector property.

Definition at line 618 of file TProperty.cxx.

618  {
619  typedef Property::FloatVector vecFloat_t;
620  return new TProperty< vecFloat_t >( const_cast< vecFloat_t& >( rval ),
622 }

◆ createProperty() [7/9]

Property* createProperty ( const std::vector< int > &  rval)

Create an integer vector property.

Definition at line 612 of file TProperty.cxx.

612  {
613  typedef Property::IntVector vecInt_t;
614  return new TProperty< vecInt_t >( const_cast< vecInt_t& >( rval ),
616 }

◆ createProperty() [8/9]

Property* createProperty ( const std::vector< std::string > &  rval)

Create a string vector property.

Definition at line 624 of file TProperty.cxx.

624  {
625  typedef Property::StringVector vecString_t;
626  return new TProperty< vecString_t >( const_cast< vecString_t& >( rval ),
628 }

◆ createProperty() [9/9]

template<typename T >
Property* createProperty ( const T &  rval)

Create a property for a default, unknown type.

Property::StringVector
std::vector< std::string > StringVector
Convenience type declaration for a string vector.
Definition: Property.h:46
Property::BOOL
@ BOOL
Definition: Property.h:29
Property::STRING
@ STRING
Definition: Property.h:33
Property::FloatVector
std::vector< float > FloatVector
Convenience type declaration for a float vector.
Definition: Property.h:44
Property::INTVECTOR
@ INTVECTOR
Definition: Property.h:34
Property::STRINGVECTOR
@ STRINGVECTOR
Definition: Property.h:36
Property::DOUBLE
@ DOUBLE
Definition: Property.h:32
TProperty
Templated wrapper around user properties.
Definition: TProperty.h:28
Property::INT
@ INT
Definition: Property.h:30
Property::IntVector
std::vector< int > IntVector
Convenience type declaration for an integer vector.
Definition: Property.h:42
Property::FLOAT
@ FLOAT
Definition: Property.h:31
Property::FLOATVECTOR
@ FLOATVECTOR
Definition: Property.h:35