axl main logo
 All Data Structures Functions Variables Typedefs Enumerations Enumerator Modules Pages
Enumerations | Functions
Axl Stream Document: Abstract stream where a xml document is expected (also provided string functions)

Enumerations

enum  NullifyItem { LAST_CHUNK, LAST_NEAR_TO, LAST_GET_FOLLOWING }
 Enum value that allows to configure which item to nullify inside the provided axlStream reference. More...
 

Functions

void axl_stream_accept (axlStream *stream)
 Accept previous inspected chunk to be consumed and moves current stream current the size equal to the chunk inspected. More...
 
axl_bool axl_stream_casecmp (const char *chunk1, const char *chunk2, int size)
 Provides the same function like axl_stream_cmp but ignoring the case of the characters (case insensitive manner). More...
 
void axl_stream_consume_white_spaces (axlStream *stream)
 Support function which consumes white spaces in the W3C sense. More...
 
void axl_stream_free (axlStream *stream)
 Allows to deallocate memory used by the axlStream received. More...
 
const char * axl_stream_get_following (axlStream *stream, int count)
 Allows to get the following count bytes read from the stream. More...
 
int axl_stream_get_global_index (axlStream *stream)
 Returns current global index for the device being streamed. More...
 
int axl_stream_get_index (axlStream *stream)
 Returns current index status for the given stream. More...
 
const char * axl_stream_get_near_to (axlStream *stream, int count)
 Allows to get current status of the given stream, taking the current index, getting an amount of count bytes before and after the given index. More...
 
int axl_stream_get_size (axlStream *stream)
 Allows to get current stream size. More...
 
char * axl_stream_get_until (axlStream *stream, char *valid_chars, int *chunk_matched, axl_bool accept_terminator, int chunk_num,...)
 Returns the next chunk available on the stream. More...
 
char * axl_stream_get_until_ref (axlStream *stream, char *valid_chars, int *chunk_matched, axl_bool accept_terminator, int *result_size, int chunk_num,...)
 Works the same way like axl_strteam_get_until but wihtout allocating the memory returned, and filling the size for the chunk returned in result_size reference. More...
 
char * axl_stream_get_until_zero (axlStream *stream, char *valid_chars, int *chunk_matched, axl_bool accept_terminator, int chunk_num,...)
 Allows to get the next string until the separators provided are found or the end of the stream memory is reached. More...
 
char * axl_stream_get_untilv (axlStream *stream, char *valid_chars, int *chunk_matched, axl_bool accept_terminator, int *result_size, int chunk_num, va_list args)
 Allows to perform the same operation like axl_stream_get_untilv but providing an already initialized and opened std arg. More...
 
int axl_stream_inspect (axlStream *stream, const char *chunk, int inspected_size)
 Allows to perform an inspection of the given chunk on the given stream. More...
 
axl_bool axl_stream_inspect_code (axlStream *stream, char value, int offset)
 Allows to check the provide char code at the given axlStream, using optionally an offset to perform the check. More...
 
int axl_stream_inspect_several (axlStream *stream, int chunk_num,...)
 Allows to perform several, not excluyen inspect operations, over the given stream. More...
 
axl_bool axl_stream_is_white_space (char *chunk)
 Allows to check if the given chunk is a white space in the same of the XML 1.0 Third edition. More...
 
void axl_stream_link (axlStream *stream, axlPointer element, axlDestroyFunc func)
 Associates the given axlPointer with the given stream to be life-time dependant. More...
 
void axl_stream_link_full (axlStream *stream, axlPointer element, axlDestroyFunc func, axl_bool free_on_finish)
 Allows to associate data references with a destroy function, like axl_stream_link, but ensuring the object reference will be released once finished the axl stream, no mather if the application code calls to axl_stream_unlink. More...
 
void axl_stream_move (axlStream *stream, int index)
 Allows to configure current index to be accepted by the stream. More...
 
axlStreamaxl_stream_new (const char *stream_source, int stream_size, const char *file_path, int fd_handler, axlError **error)
 Creates a new byte stream using as data the string pointer and the size. More...
 
void axl_stream_nullify (axlStream *stream, NullifyItem item)
 Allows to nullify the internal reference of the stream, making that reference to be not deallocated once the stream is moving. More...
 
int axl_stream_peek (axlStream *stream, const char *chunk, int inspected_size)
 Allows to perform a stream inspection without automatically accept content properly inspected. More...
 
void axl_stream_push (axlStream *stream, const char *content, int size)
 Push new content at the begin of the stream. More...
 
axl_bool axl_stream_remains (axlStream *stream)
 Allows to get current status of the stream. More...
 
void axl_stream_set_buffer_alloc (axlStream *stream, axlStreamAlloc handler, axlPointer data)
 Allows to configure the handler to be executed to alloc memory for the axl_stream_get_until* API. More...
 
void axl_stream_step (axlStream *stream, int bytes)
 Makes the current index to be moved the amount of bytes signaled by the parameter bytes. More...
 
void axl_stream_unlink (axlStream *stream)
 Unlinks the associated axlDoc instance. More...
 

Detailed Description