Functions | |
int | kate_decode_is_idheader (const kate_packet *kp) |
int | kate_decode_headerin (kate_info *ki, kate_comment *kc, kate_packet *kp) |
int | kate_decode_init (kate_state *k, kate_info *ki) |
int | kate_decode_packetin (kate_state *k, kate_packet *kp) |
int | kate_decode_eventout (kate_state *k, kate_const kate_event **event) |
int kate_decode_eventout | ( | kate_state * | k, | |
kate_const kate_event ** | event | |||
) |
Requests a pointer to the event decoded by the last packet, if there is one.
k | the kate_state to get the event from | |
event | a pointer to where to place the pointer to the event, if any |
1 success, but there was no event to return
KATE_E_* error
int kate_decode_headerin | ( | kate_info * | ki, | |
kate_comment * | kc, | |||
kate_packet * | kp | |||
) |
Decodes a header packet, and updates the kate_info and kate_comment structures from the decoded data.
ki | the kate_info structure to update | |
kc | the kate_comment structure to update | |
kp | the packet to decode |
KATE_E_* error
int kate_decode_init | ( | kate_state * | k, | |
kate_info * | ki | |||
) |
Initializes a kate_state structure for decoding using the supplied kate_info structure. When done, the kate_state should be cleared using kate_clear.
k | the kate_state to initialize for decoding | |
ki | the kate_info structure initialized from the decoded headers |
KATE_E_* error
int kate_decode_is_idheader | ( | const kate_packet * | kp | ) |
Checks if a packet is a Kate ID header
kp | the packet to inspect |
!=0 the packet is an ID header
int kate_decode_packetin | ( | kate_state * | k, | |
kate_packet * | kp | |||
) |
Decodes a data packet.
k | the kate_state to decode to | |
kp | the packet to decode |
1 success, and we're at end of stream
KATE_E_* error