DCMTK Version 3.6.8
OFFIS DICOM Toolkit
Public Member Functions | Private Attributes | List of all members
UserIdentityNegotiationSubItemAC Class Reference

Class representing a User Identity Negotiation acknowledgement sub item. More...

+ Inheritance diagram for UserIdentityNegotiationSubItemAC:

Public Member Functions

 UserIdentityNegotiationSubItemAC ()
 Constructor, creates an empty user identity response structure.
 
unsigned char pduType () const
 Denotes that instance is part of a request (DUL_TYPEASSOCIATEAC) More...
 
virtual void clear ()
 Clears member variables and frees memory.
 
void setServerResponse (const char *rsp, const Uint16 &rspLen)
 Sets server response value. More...
 
Uint16 getServerResponse (char *&targetBuffer, Uint16 &resultLen) const
 Returns content of server response field Memory is allocated by this function and must be freed by the caller. More...
 
OFCondition streamedLength (unsigned long &length) const
 Computes total length of item if streamed into buffer. More...
 
OFCondition stream (unsigned char *targetBuffer, unsigned long &lengthWritten) const
 Stream the package into a byte stream for network transmission. More...
 
OFCondition parseFromBuffer (unsigned char *readBuffer, unsigned long &bytesRead, unsigned long availData)
 Parse sub item from buffer. More...
 
void dump (STD_NAMESPACE ostream &outstream) const
 Dump content of this user identity sub item to output stream. More...
 
UserIdentityNegotiationSubItemACoperator= (const UserIdentityNegotiationSubItemAC &rhs)
 Assignment operator, does a deep copy of a class instance. More...
 
 UserIdentityNegotiationSubItemAC (const UserIdentityNegotiationSubItemAC &rhs)
 Copy constructor, does a deep copy of a class instance. More...
 
 ~UserIdentityNegotiationSubItemAC ()
 Destructor, frees memory.
 
- Public Member Functions inherited from UserIdentityNegotiationSubItem
 UserIdentityNegotiationSubItem (const unsigned char itemType)
 Constructor. More...
 
 UserIdentityNegotiationSubItem (const UserIdentityNegotiationSubItem &src)
 Copy constructor. More...
 
virtual unsigned char pduType () const =0
 Denotes whether instance is part of a request (DUL_TYPEASSOCIATERQ) or acknowledgement PDU (DUL_TYPEASSOCIATEAC) More...
 
virtual unsigned char getItemType () const
 Returns item type, which is 0x58 for requests, and 0x58 for acknowledgements. More...
 
virtual unsigned char getReserved () const
 Returns reserved field, which is 0 in this implementation (see DICOM standard) More...
 
virtual OFCondition streamedLength (unsigned long &length) const =0
 Computes total length of item if streamed to a buffer. More...
 
virtual OFCondition parseFromBuffer (unsigned char *readBuffer, unsigned long &bytesRead, unsigned long availData)=0
 Parse item from buffer. More...
 
virtual OFCondition stream (unsigned char *targetBuffer, unsigned long &lengthWritten) const =0
 Stream the package into a byte stream for network transmission. More...
 
virtual void clear ()=0
 Clears member variables and frees memory.
 
virtual void dump (STD_NAMESPACE ostream &outstream) const =0
 Dump content of this user identity sub item to output stream. More...
 
virtual ~UserIdentityNegotiationSubItem ()
 Destructor, nothing to clean up.
 

Private Attributes

char * m_serverRsp
 Buffer for server response.
 
Uint16 m_rspLength
 Length of server response in bytes.
 

Detailed Description

Class representing a User Identity Negotiation acknowledgement sub item.

Constructor & Destructor Documentation

◆ UserIdentityNegotiationSubItemAC()

UserIdentityNegotiationSubItemAC::UserIdentityNegotiationSubItemAC ( const UserIdentityNegotiationSubItemAC rhs)

Copy constructor, does a deep copy of a class instance.

Parameters
rhsThe class instance to copy from

Member Function Documentation

◆ dump()

void UserIdentityNegotiationSubItemAC::dump ( STD_NAMESPACE ostream &  outstream) const
virtual

Dump content of this user identity sub item to output stream.

Parameters
outstreamThe stream to dump to

Implements UserIdentityNegotiationSubItem.

◆ getServerResponse()

Uint16 UserIdentityNegotiationSubItemAC::getServerResponse ( char *&  targetBuffer,
Uint16 &  resultLen 
) const

Returns content of server response field Memory is allocated by this function and must be freed by the caller.

Parameters
targetBufferContent of server response field. NULL if not set. Memory of buffer must be freed by the caller.
resultLenLength of returned buffer
Returns
Length of returned buffer

◆ operator=()

UserIdentityNegotiationSubItemAC & UserIdentityNegotiationSubItemAC::operator= ( const UserIdentityNegotiationSubItemAC rhs)

Assignment operator, does a deep copy of a class instance.

Parameters
rhsRight hand side of assignment
Returns
Reference to "this" object

◆ parseFromBuffer()

OFCondition UserIdentityNegotiationSubItemAC::parseFromBuffer ( unsigned char *  readBuffer,
unsigned long &  bytesRead,
unsigned long  availData 
)
virtual

Parse sub item from buffer.

The buffer has to start with the correct user item type.

Parameters
readBufferThe buffer to read from. The pointer to the buffer gets incremented by "bytesRead" bytes.
bytesReadReturns number of bytes read by this function
availDataSize of the read buffer
Returns
EC_Normal if successful, error code otherwise

Implements UserIdentityNegotiationSubItem.

◆ pduType()

unsigned char UserIdentityNegotiationSubItemAC::pduType ( ) const
virtual

Denotes that instance is part of a request (DUL_TYPEASSOCIATEAC)

Returns
DUL_TYPEASSOCIATEAC

Implements UserIdentityNegotiationSubItem.

◆ setServerResponse()

void UserIdentityNegotiationSubItemAC::setServerResponse ( const char *  rsp,
const Uint16 &  rspLen 
)

Sets server response value.

Parameters
rspContent of server response value (copied by function)
rspLenLength of buffer

◆ stream()

OFCondition UserIdentityNegotiationSubItemAC::stream ( unsigned char *  targetBuffer,
unsigned long &  lengthWritten 
) const
virtual

Stream the package into a byte stream for network transmission.

Parameters
targetBufferThe buffer to stream to
lengthWrittenReturns number of bytes written to buffer
Returns
EC_Normal, if successful, error code otherwise

Implements UserIdentityNegotiationSubItem.

◆ streamedLength()

OFCondition UserIdentityNegotiationSubItemAC::streamedLength ( unsigned long &  length) const
virtual

Computes total length of item if streamed into buffer.

Parameters
lengthReturns length of the item if streamed
Returns
EC_Normal if successful, error code otherwise

Implements UserIdentityNegotiationSubItem.


The documentation for this class was generated from the following file:


Generated on Tue Dec 19 2023 for DCMTK Version 3.6.8 by Doxygen 1.9.4