acp_in.c File : acp_in.c
Description : ACP Input Handling
Category : ACP Scripting
Author : Charles Yates
ACPIN_Init ACPIN DLLEXP ACPIN_Init()
Function : ACPIN_Init
Description : Initialise an input stream
Input : void
Output : void
Returns : An initialised ACPIN
ACPIN_ReadLine char *ACPIN_ReadLine( ACPIN in, char *line, int max )
Function : ACPIN_ReadLine
Description : Read a line of text from the input stream
Input : ACPIN in - input structure
char *line - output
int max - maximum length of a string
Output : line contains a LF or CR/LF terminated string if successful
Returns : char * - NULL if no input was obtained or line
ACPIN_ReadChomp char *ACPIN_ReadChomp( ACPIN in, char *line, int max )
Function : ACPIN_ReadChomp
Description : Read a line of text from the input stream
Input : ACPIN in - input structure
char *line - output
int max - maximum length of a string
Output : line will contain a NUL terminated string if successful
Returns : char * - NULL if no input was obtained or line
ACPIN_ReadBuffer int ACPIN_ReadBuffer( ACPIN in, char *buffer, int max )
Function : ACPIN_ReadBuffer
Description : Read a block of data from the input stream
Input : ACPIN in - input structure
char *buffer - output
int max - maximum length of buffer
Output : buffer will contain up to max bytes
Returns : int - the number of bytes returned (0 indicates end of stream)
ACPIN_GetLine int ACPIN_GetLine( ACPIN in, char **line )
Function : ACPIN_GetLine
Description : Read a dynamic line of text from the input
Input : ACPIN in - input structure
char **line - output
Output : line will contain an LF or CR/LF terminated string
Returns : int - the number of bytes returned (0 indicates end of stream)
ACPIN_Parse ACPENV ACPIN_Parse( ACPIN in )
Function : ACPIN_Parse
Description : Parse the URL encoded posted data on the stream
Input : ACPIN in - input structure
Output : void
Returns : an ACPENV cotaining the name/value pairs received
ACPIN_GetHeaders ACPENV DLLEXP ACPIN_GetHeaders( ACPIN in )
Function : ACPIN_GetHeaders
Description : Return the original headers received from the http request
Input : ACPIN in - input structure
Output : void
Returns : ACPENV containing the request headers
ACPIN_Close void DLLEXP ACPIN_Close( ACPIN in )
Function : ACPIN_Close
Description : Close the input structure
Input : ACPIN in - input structure
Output : void
Returns : void
|