The property value class.
More...
#include <JProperties.hh>
The property value class.
This class consists of a pointer to the JPropertiesElementInterface. This class implements the assignment and type conversion operators.
Definition at line 293 of file JProperties.hh.
template<class JClass_t, template< class > class JMemory_t = JNew>
template<class JClass_t, template< class > class JMemory_t = JNew>
template<class JClass_t, template< class > class JMemory_t = JNew>
JEEP::JPropertiesElement::JPropertiesElement |
( |
| ) |
|
|
inline |
template<class T >
JEEP::JPropertiesElement::JPropertiesElement |
( |
T & |
value | ) |
|
|
inline |
Constructor.
- Parameters
-
value | reference to template object |
Definition at line 311 of file JProperties.hh.
Template class for I/O of properties element.
virtual void reset()
Reset pointer.
Equality between property elements.
- Parameters
-
element | properties element |
- Returns
- true if equal; else false
Definition at line 324 of file JProperties.hh.
bool equals(const JPropertiesElement &element) const
Equality between property elements.
virtual JClass_t * get() const
Get pointer.
Assignment operator.
- Parameters
-
value | reference to template object |
- Returns
- this JPropertiesElement
Definition at line 337 of file JProperties.hh.
Template class for I/O of properties element.
virtual void reset()
Reset pointer.
template<class T >
const T& JEEP::JPropertiesElement::getValue |
( |
| ) |
const |
|
inline |
Get value.
- Returns
- value of this JPropertiesElement
Definition at line 351 of file JProperties.hh.
358 THROW(JPropertiesException,
"Inconsistent data type.");
#define THROW(JException_t, A)
Marco for throwing exception with std::ostream compatible message.
Template class for I/O of properties element.
template<class T >
T& JEEP::JPropertiesElement::getValue |
( |
| ) |
|
|
inline |
Get value.
- Returns
- value of this JPropertiesElement
Definition at line 368 of file JProperties.hh.
375 THROW(JPropertiesException,
"Inconsistent data type.");
#define THROW(JException_t, A)
Marco for throwing exception with std::ostream compatible message.
Template class for I/O of properties element.
template<class T >
void JEEP::JPropertiesElement::setValue |
( |
const T & |
value | ) |
|
|
inline |
Set value of this JPropertiesElement.
- Parameters
-
Definition at line 386 of file JProperties.hh.
393 THROW(JPropertiesException,
"Inconsistent data type.");
#define THROW(JException_t, A)
Marco for throwing exception with std::ostream compatible message.
Template class for I/O of properties element.
std::string JEEP::JPropertiesElement::toString |
( |
| ) |
const |
|
inline |
Convert to string.
- Returns
- value of this JPropertiesElement
Definition at line 402 of file JProperties.hh.
404 std::ostringstream os;
406 get()->
write(os,
"",
'\0');
bool write(const Vec &v, std::ostream &os)
Write a Vec(tor) to a stream.
template<class T >
T JEEP::JPropertiesElement::toValue |
( |
| ) |
const |
|
inline |
Convert to template type.
- Returns
- value of this JPropertiesElement
Definition at line 418 of file JProperties.hh.
esac print_variable DETECTOR INPUT_FILE OUTPUT_FILE CDF for TYPE in
do set_variable OUTPUT_DIRECTORY $WORKDIR T
std::string toString() const
Convert to string.
template<class T >
JEEP::JPropertiesElement::operator const T & |
( |
| ) |
const |
|
inline |
bool JEEP::JPropertiesElement::getEndMarker |
( |
| ) |
const |
|
inline |
void JEEP::JPropertiesElement::setEndMarker |
( |
const bool |
marker | ) |
|
|
inline |
Set end marker.
- Parameters
-
marker | if true stop reading after this properties element, else continue |
Definition at line 458 of file JProperties.hh.
template<class JClass_t, template< class > class JMemory_t = JNew>
Get shared pointer.
- Returns
- this shared pointer
Definition at line 95 of file JSharedPointer.hh.
The template JSharedPointer class can be used to share a pointer to an object.
template<class JClass_t, template< class > class JMemory_t = JNew>
Get shared pointer.
- Returns
- this shared pointer
Definition at line 106 of file JSharedPointer.hh.
The template JSharedPointer class can be used to share a pointer to an object.
template<class JClass_t, template< class > class JMemory_t = JNew>
Set shared pointer.
- Parameters
-
Definition at line 117 of file JSharedPointer.hh.
119 if (this->
get() !=
object.
get()) {
void set(const JSharedPointer &object)
Set pointer.
bool is_valid() const
Check validity of pointer.
virtual void reset()
Reset pointer.
template<class JClass_t, template< class > class JMemory_t = JNew>
Reset pointer.
The reference counter is decremented by one and the object pointed to previously is deleted when its reference counter is zero.
Reimplemented from JLANG::JStorage< JClass_t, JMemory_t >.
Definition at line 171 of file JSharedPointer.hh.
virtual void reset()
Reset pointer.
virtual void reset()
Reset pointer.
template<class JClass_t>
template<class T >
Reset pointer.
- Parameters
-
Definition at line 108 of file JPointer.hh.
virtual void reset()
Reset pointer.
virtual JClass_t * get() const
Get pointer.
Reset pointer.
- Parameters
-
Definition at line 94 of file JAbstractPointer.hh.
96 if (this->
get() != p) {
virtual void reset()=0
Reset pointer.
virtual void set(JClass_t *p)=0
Set pointer.
template<class JClass_t, template< class > class JMemory_t = JNew>
Set pointer.
The reference counter of the shared object pointed to is incremented by one.
- Parameters
-
Definition at line 188 of file JSharedPointer.hh.
void attach(const JSharedCounter &object)
Attach this counter to given shared counter object.
virtual void set(JClass_t *p)
Set pointer.
template<class JClass_t, template< class > class JMemory_t = JNew>
|
inlineprotectedvirtualinherited |
Set pointer.
The reference counter of the shared object pointed to is initialised to one.
- Parameters
-
p | pointer to derived class object |
Reimplemented from JLANG::JPointer< JClass_t >.
Definition at line 202 of file JSharedPointer.hh.
void initialise()
Initialise counter.
virtual void set(JClass_t *p)
Set pointer.
template<class JClass_t>
template<class T >
Set pointer.
- Parameters
-
Definition at line 96 of file JPointer.hh.
virtual JClass_t * get() const
Get pointer.
virtual void set(JClass_t *p)
Set pointer.
void JLANG::JSharedCounter::initialise |
( |
| ) |
|
|
inlineinherited |
Attach this counter to given shared counter object.
- Parameters
-
Definition at line 46 of file JSharedCounter.hh.
bool JLANG::JSharedCounter::detach |
( |
| ) |
|
|
inlineinherited |
Detach.
- Returns
- true if counter at zero; else false
Definition at line 63 of file JSharedCounter.hh.
template<class JClass_t, template< class > class JMemory_t = JNew>
Recreate object in memory.
A new object is created if no memory is allocated yet, else the previously created object is maintained.
Definition at line 57 of file JStorage.hh.
60 this->
set(memory_type::create());
bool is_valid() const
Check validity of pointer.
virtual void set(JClass_t *p)
Set pointer.
template<class JClass_t, template< class > class JMemory_t = JNew>
Create object in memory.
The memory allocated by a previously created object will be released.
Definition at line 69 of file JStorage.hh.
71 this->
reset(memory_type::create());
virtual void reset()
Reset pointer.
template<class JClass_t, template< class > class JMemory_t = JNew>
void JLANG::JStorage< JClass_t, JMemory_t >::create |
( |
const unsigned int |
size | ) |
|
|
inlineinherited |
Create array of objects in memory.
The memory allocated by previously created objects will be released.
- Parameters
-
Definition at line 81 of file JStorage.hh.
83 this->
reset(memory_type::create(size));
virtual void reset()
Reset pointer.
template<class JClass_t, template< class > class JMemory_t = JNew>
Release memory.
Definition at line 91 of file JStorage.hh.
93 memory_type::release(this->
get());
Get rereference to internal pointer.
- Returns
- reference to internal pointer
Definition at line 119 of file JPointer.hh.
JClass_t * __p
pointer to object
Get rereference to internal pointer.
- Returns
- reference to internal pointer
Definition at line 130 of file JPointer.hh.
JClass_t * __p
pointer to object
Equals.
The equality is evaluated by comparison of the internal pointers.
- Parameters
-
- Returns
- true if equals; else false
Definition at line 50 of file JAbstractPointer.hh.
52 return this->
get() ==
object.
get();
Check validity of pointer.
- Returns
- true if pointer not null; else false
Definition at line 83 of file JAbstractPointer.hh.
85 return this->
get() != NULL;
Smart pointer operator.
- Returns
- pointer to object
Definition at line 112 of file JAbstractPointer.hh.
bool is_valid() const
Check validity of pointer.
Exception for null pointer operation.
bool JEEP::JPropertiesElement::end_marker |
|
private |
int* JLANG::JSharedCounter::counter |
|
protectedinherited |
The documentation for this class was generated from the following file: