31 #ifndef GENAPI_POINTER_H 32 #define GENAPI_POINTER_H 50 template <
class T,
class B = IBase>
63 :
m_pT( dynamic_cast<T*>(pB) )
74 m_pT =
dynamic_cast<T*
>(pB);
78 operator T*(void)
const 116 operator bool(
void)
const throw()
136 if (0 != nMustBeNull)
242 return dynamic_cast<IInteger*
>(
m_pT->GetNode()->GetCastAlias());
266 # pragma warning (push) // icc -W4 complains: controlling expression is constant 267 # pragma warning (disable : 279) 269 assert(pBase &&
"don't call this with a NULL pointer");
271 # pragma warning (pop) 273 CNodePtr ptrNode(pBase);
274 switch(ptrNode->GetPrincipalInterfaceType())
307 template <
class T,
class B>
314 template <
class T,
class B>
321 template <
class T,
class B>
328 template <
class T,
class B>
340 #endif // ifndef GENAPI_POINTER_H bool operator==(int nMustBeNull) const
pointer equal
CPointer(void)
Default constructor.
CPointer< ISelector > CSelectorPtr
SmartPointer for ISelector interface pointer.
CPointer< IPortReplay > CPortReplayPtr
SmartPointer for IPortReplay interface pointer.
CPointer< IChunkPort > CChunkPortPtr
SmartPointer for IChunkPort interface pointer.
CPointer< IString > CStringPtr
SmartPointer for IString interface pointer.
CPointer< IUserData, INodeMap > CNodeMapUserDataPtr
SmartPointer for IUserData interface pointer.
bool operator==(T *pT) const
pointer equal
CFloatPtr()
Default constructor.
CPointer< IValue > CValuePtr
SmartPointer for IValue interface pointer.
CFloatPtr(IBase *pB)
Constructor from IBase pointer type.
bool operator==(const CPointer< T, B > &rT) const
pointer equal
T * operator->(void) const
Dereferencing.
CPointer< IDeviceInfo, INodeMap > CDeviceInfoPtr
SmartPointer for IDeviceInfo interface pointer.
CPointer< IPortRecorder > CPortRecorderPtr
SmartPointer for IPortRecorder interface pointer.
interface GENAPI_DECL_ABSTRACT IEnumeration
Interface for enumeration properties.
T & operator()(void) const
Dereferencing.
CPointer< IPort > CPortPtr
SmartPointer for IPort interface pointer.
bool IsReadable(EAccessMode AccessMode)
Tests if readable.
interface GENAPI_DECL_ABSTRACT IInteger
Interface for integer properties.
T & operator*(void) const
Dereferencing.
interface GENAPI_DECL_ABSTRACT IFloat
Interface for float properties.
T * m_pT
Underlying raw pointer.
GENICAM_NAMESPACE::gcstring GetInterfaceName(IBase *pBase)
Returns the name of the main interface as string DEPRECATED, use IBase::GetPrincipalInterfaceType() i...
Definition of the IFloat interface.
IEnumeration * GetEnumAlias()
gets the interface of an enum alias node.
interface GENAPI_DECL_ABSTRACT IBase
Base interface common to all nodes.
CPointer< IUserData > CNodeUserDataPtr
SmartPointer for IUserData interface pointer.
bool IsAvailable(EAccessMode AccessMode)
Tests if available.
CPointer< IBoolean > CBooleanPtr
SmartPointer for IBoolean interface pointer.
Encapsulates a GenApi pointer dealing with the dynamic_cast automatically.
CPointer< INode > CNodePtr
SmartPointer for INode interface pointer.
CPointer< IEnumEntry > CEnumEntryPtr
SmartPointer for IEnumEntry interface pointer.
CPointer< INodeMap, INodeMap > CNodeMapPtr
SmartPointer for INodeMap interface pointer.
void operator=(IBase *pB)
Assign IBase Pointer.
#define LOGICAL_ERROR_EXCEPTION
Fires a logical error exception, e.g. throw LOGICAL_ERROR_EXCEPTION("Should never reach this point") ...
bool IsImplemented(EAccessMode AccessMode)
Tests if implemented.
CPointer< IBase > CBasePtr
SmartPointer for IBase interface pointer.
IInteger * GetIntAlias()
gets the interface of an integer alias node.
Forward declarations for GenICam types.
Definition of the interface IInteger.
CPointer< IInteger > CIntegerPtr
SmartPointer for IInteger interface pointer.
A string class which is a clone of std::string.
CPointer< IRegister > CRegisterPtr
SmartPointer for IRegister interface pointer.
bool IsValid() const
true if the pointer is valid
CPointer< IPortWriteList, IPortWriteList > CPortWriteListPtr
SmartPointer for IPortWriteList interface pointer.
CPointer< IPortConstruct > CPortConstructPtr
SmartPointer for IPortConstruct interface pointer.
bool IsWritable(EAccessMode AccessMode)
Tests if writable.
Definition of interface IEnumeration.
CPointer< IEnumeration > CEnumerationPtr
SmartPointer for IEnumeration interface pointer.
CPointer< ICommand > CCommandPtr
SmartPointer for ICommand interface pointer.
Part of the generic device API.
CPointer< ICategory > CCategoryPtr
SmartPointer for ICategory interface pointer.
void operator=(B *pB)
Assign INode Pointer.
SmartPointer for IFloat interface pointer.
CPointer(B *pB)
Constructor from INode pointer type.