Developer's Guide
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Groups Pages
virtual P6R::P6ERR P6R::p6ICryptoKey::serializeToBuffer ( P6VOID pBuffer,
P6UINT32  cBuffer,
P6UINT32 pcBytesWritten 
)
pure virtual

Write the key in this component to the provided buffer.

Note, that the pcBytesWritten parameter can be set to NULL if the caller is not interested in the number of bytes written into the buffer. However, this parameter is also used to return the bytes required to copy the key into when pBuffer is set to NULL.

Parameters
pBuffer[ in ] Block of memory to write the key into, when NULL the required size of this buffer is returned in pcBytesWritten
cBuffer[ in ] Size (in bytes) of the memory block pointed to by pBuffer.
pcBytesWritten[ out ] Returns the number of bytes written into pBuffer representing the key. This parameter cannot be NULL when pBuffer is also NULL.
Returns
SuccessP6R::eOk 
FailureP6R::eNotInitializedObject is in an incorrect state.
P6R::eInvalidArgpBuffer and pcBytesWritten cannot both be NULL.
P6R::eFailAndExceptionWritting to the buffer failed.
P6R::eTooSmallpBuffer is too small to copy the key into.