Go to the documentation of this file. 1 #ifndef __JLANG__JSINGLEPOINTER__
2 #define __JLANG__JSINGLEPOINTER__
12 namespace JPP {
using namespace JLANG; }
23 template<
class JClass_t,
template<
class>
class JMemory_t =
JNew>
46 const_cast<JSinglePointer&>(
object).set(NULL);
80 if (this->
get() !=
object.
get()) {
88 const_cast<JSinglePointer&>(
object).set(NULL);
103 template<
class JDerived_t>
virtual void set(JClass_t *p)
Set pointer.
~JSinglePointer()
Destructor.
The template JSinglePointer class can be used to hold a pointer to an object.
virtual JClass_t * get() const
Get pointer.
Memory management class for create/release policy based on new/delete.
JSinglePointer()
Default constructor.
JSinglePointer & operator=(const JSinglePointer &object)
Assignment operator.
This name space includes all other name spaces (except KM3NETDAQ, KM3NET and ANTARES).
JSinglePointer(const JSinglePointer &object)
Copy constructor.
JSinglePointer & operator=(JDerived_t *p)
Assignment operator.
Auxiliary classes and methods for language specific functionality.
virtual void reset()
Reset pointer.
JSinglePointer(JClass_t *p)
Constructor.
bool is_valid() const
Check validity of pointer.