| Top |
| void | xmlSecBufferSetDefaultAllocMode () |
| xmlSecBufferPtr | xmlSecBufferCreate () |
| void | xmlSecBufferDestroy () |
| int | xmlSecBufferInitialize () |
| void | xmlSecBufferFinalize () |
| xmlSecByte * | xmlSecBufferGetData () |
| int | xmlSecBufferSetData () |
| xmlSecSize | xmlSecBufferGetSize () |
| int | xmlSecBufferSetSize () |
| xmlSecSize | xmlSecBufferGetMaxSize () |
| int | xmlSecBufferSetMaxSize () |
| void | xmlSecBufferEmpty () |
| int | xmlSecBufferAppend () |
| int | xmlSecBufferPrepend () |
| int | xmlSecBufferRemoveHead () |
| int | xmlSecBufferRemoveTail () |
| int | xmlSecBufferReverse () |
| int | xmlSecBufferReadFile () |
| int | xmlSecBufferBase64NodeContentRead () |
| int | xmlSecBufferBase64NodeContentWrite () |
| xmlOutputBufferPtr | xmlSecBufferCreateOutputBuffer () |
void xmlSecBufferSetDefaultAllocMode (xmlSecAllocMode defAllocMode,xmlSecSize defInitialSize);
Sets new global default allocation mode and minimal intial size.
xmlSecBufferPtr
xmlSecBufferCreate (xmlSecSize size);
Allocates and initializes new memory buffer with given size. Caller is responsible for calling xmlSecBufferDestroy function to free the buffer.
void
xmlSecBufferDestroy (xmlSecBufferPtr buf);
Destroys buffer object created with xmlSecBufferCreate function.
int xmlSecBufferInitialize (xmlSecBufferPtr buf,xmlSecSize size);
Initializes buffer object buf
. Caller is responsible for calling
xmlSecBufferFinalize function to free allocated resources.
void
xmlSecBufferFinalize (xmlSecBufferPtr buf);
Frees allocated resource for a buffer initialized with xmlSecBufferInitialize function.
xmlSecByte *
xmlSecBufferGetData (xmlSecBufferPtr buf);
Gets pointer to buffer's data.
int xmlSecBufferSetData (xmlSecBufferPtr buf,const xmlSecByte *data,xmlSecSize size);
Sets the value of the buffer to data
.
xmlSecSize
xmlSecBufferGetSize (xmlSecBufferPtr buf);
Gets the current buffer data size.
int xmlSecBufferSetSize (xmlSecBufferPtr buf,xmlSecSize size);
Sets new buffer data size. If necessary, buffer grows to
have at least size
bytes.
xmlSecSize
xmlSecBufferGetMaxSize (xmlSecBufferPtr buf);
Gets the maximum (allocated) buffer size.
int xmlSecBufferSetMaxSize (xmlSecBufferPtr buf,xmlSecSize size);
Sets new buffer maximum size. If necessary, buffer grows to
have at least size
bytes.
int xmlSecBufferAppend (xmlSecBufferPtr buf,const xmlSecByte *data,xmlSecSize size);
Appends the data
after the current data stored in the buffer.
int xmlSecBufferPrepend (xmlSecBufferPtr buf,const xmlSecByte *data,xmlSecSize size);
Prepends the data
before the current data stored in the buffer.
int xmlSecBufferRemoveHead (xmlSecBufferPtr buf,xmlSecSize size);
Removes size
bytes from the beginning of the current buffer.
int xmlSecBufferRemoveTail (xmlSecBufferPtr buf,xmlSecSize size);
Removes size
bytes from the end of current buffer.
int
xmlSecBufferReverse (xmlSecBufferPtr buf);
Reverses order of bytes in the buffer buf
.
int xmlSecBufferReadFile (xmlSecBufferPtr buf,const char *filename);
Reads the content of the file filename
in the buffer.
int xmlSecBufferBase64NodeContentRead (xmlSecBufferPtr buf,xmlNodePtr node);
Reads the content of the node
, base64 decodes it and stores the
result in the buffer.
int xmlSecBufferBase64NodeContentWrite (xmlSecBufferPtr buf,xmlNodePtr node,int columns);
Sets the content of the node
to the base64 encoded buffer data.
xmlOutputBufferPtr
xmlSecBufferCreateOutputBuffer (xmlSecBufferPtr buf);
Creates new LibXML output buffer to store data in the buf
. Caller is
responsible for destroying buf
when processing is done.
struct xmlSecBuffer {
xmlSecByte* data;
xmlSecSize size;
xmlSecSize maxSize;
xmlSecAllocMode allocMode;
};
Binary data buffer.
xmlSecByte * |
the pointer to buffer data. |
|
xmlSecSize |
the current data size. |
|
xmlSecSize |
the max data size (allocated buffer size). |
|
xmlSecAllocMode |
the buffer memory allocation mode. |