29 #ifndef GENAPI_CHUNKPORT_H 30 #define GENAPI_CHUNKPORT_H 37 # pragma warning(push) 38 # pragma warning(disable: 4251) // GenApi::CChunkPort::m_ptrPort' : class 'GenApi::CPointer<T>' needs to have dll-interface 73 virtual void Read(
void *pBuffer, int64_t Address, int64_t Length);
76 virtual void Write(
const void *pBuffer, int64_t Address, int64_t Length);
108 void AttachChunk(uint8_t *pBaseAddress, int64_t ChunkOffset, int64_t Length,
bool Cache);
116 return m_ChunkIDLength;
120 bool CheckChunkID(uint8_t* pChunkIDBuffer,
int ChunkIDLength);
123 bool CheckChunkID(uint64_t ChunkID);
126 void UpdateBuffer(uint8_t *pBaseAddress);
134 if (!m_ptrPort.IsValid())
137 return m_ptrPort->GetNodeMap()->GetLock();
181 # pragma warning(pop) 184 #endif // GENAPI_CHUNKPORT_H uint8_t * m_pChunkIDBuffer
Binary version of the chunk ID.
Definition: ChunkPort.h:160
int64_t m_ChunkOffset
The chunk's offset within the buffer.
Definition: ChunkPort.h:148
uint64_t m_ChunkIDNumber
Chunk ID stored as a number (for more straightforward access)
Definition: ChunkPort.h:172
enum GENAPI_NAMESPACE::_EYesNo EYesNo
GENICAM_INTERFACE GENAPI_DECL_ABSTRACT IPortConstruct
Interface for ports.
Definition: IPortConstruct.h:50
int64_t m_LengthAlloc
Space allocated for the chunk.
Definition: ChunkPort.h:154
int m_ChunkIDLength
Length of the chunk ID buffer.
Definition: ChunkPort.h:163
no
Definition: Types.h:141
uint8_t * m_pBaseAddress
Pointer to the begin of the buffer.
Definition: ChunkPort.h:145
#define RUNTIME_EXCEPTION
Fires a runtime exception, e.g. throw RUNTIME_EXCEPTION("buh!")
Definition: GCException.h:246
CNodePtr m_ptrPort
Pointer to the node holding a reference to this implementation.
Definition: ChunkPort.h:157
virtual EYesNo GetSwapEndianess()
Determines if the port adapter must perform an endianess swap.
Definition: ChunkPort.h:85
enum GENAPI_NAMESPACE::_EAccessMode EAccessMode
GENICAM_INTERFACE GENAPI_DECL_ABSTRACT IPort
Interface for ports.
Definition: IPort.h:55
Definition of interface INodeMap.
bool m_ChunkIDNumberValid
indicates if the m_ChunkIDNumber is valid (could be invalid eg. if the ID does not fit in 64-bit rang...
Definition: ChunkPort.h:175
virtual EInterfaceType GetPrincipalInterfaceType() const =0
Get the type of the main interface of a node.
virtual void InvalidateNode()=0
Indicates that the node's value may have changed.
Definition of interface IPortConstruct.
enum GENAPI_NAMESPACE::_EInterfaceType EInterfaceType
uint8_t * m_pChunkData
cache for the chunk data
Definition: ChunkPort.h:166
GENICAM_INTERFACE GENAPI_DECL_ABSTRACT IPortStacked
Interface for ports.
Definition: IPortStacked.h:62
virtual CLock & GetLock() const =0
Returns the lock which guards the node map.
bool m_CacheData
indicates if the data needs to be cached
Definition: ChunkPort.h:169
int GetChunkIDLength()
Gets the ChunkID length.
Definition: ChunkPort.h:114
Definition of template CPointer.
int64_t m_Length
Length of the chunk.
Definition: ChunkPort.h:151
Port attachable to a chunk in a buffer.
Definition: ChunkPort.h:48
virtual void Write(const void *pBuffer, int64_t Address, int64_t Length)=0
Writes a chunk of bytes to the port.
Definition: ChunkAdapter.h:37
A lock class.
Definition: Synch.h:61