113 lines
1.2 KiB
C
113 lines
1.2 KiB
C
/*
|
|
* This file is automaticaly generated, Please dont edit this file!
|
|
*/
|
|
#include <request.h>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
void request_constructor( request * this ) {
|
|
|
|
|
|
}
|
|
|
|
void request_free( request * this ) {
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
free( this );
|
|
|
|
|
|
}
|
|
|
|
request request_new() {
|
|
|
|
request instance;
|
|
|
|
instance.connection = malloc( BUFFER_SIZE );
|
|
|
|
instance.address = malloc( BUFFER_SIZE );
|
|
|
|
instance.url = malloc( BUFFER_SIZE );
|
|
|
|
instance.method = malloc( BUFFER_SIZE );
|
|
|
|
instance.version = malloc( BUFFER_SIZE );
|
|
|
|
instance.mimeType = malloc( BUFFER_SIZE );
|
|
|
|
instance.extension = malloc( BUFFER_SIZE );
|
|
|
|
instance.headers = headerManager_newPointer();
|
|
|
|
request_constructor( &instance);
|
|
|
|
return instance;
|
|
|
|
}
|
|
|
|
request * request_newPointer() {
|
|
|
|
struct request * pointer = malloc( sizeof ( struct request ) );
|
|
|
|
pointer->connection = malloc( BUFFER_SIZE );
|
|
|
|
pointer->address = malloc( BUFFER_SIZE );
|
|
|
|
pointer->url = malloc( BUFFER_SIZE );
|
|
|
|
pointer->method = malloc( BUFFER_SIZE );
|
|
|
|
pointer->version = malloc( BUFFER_SIZE );
|
|
|
|
pointer->mimeType = malloc( BUFFER_SIZE );
|
|
|
|
pointer->extension = malloc( BUFFER_SIZE );
|
|
|
|
pointer->headers = headerManager_newPointer();
|
|
|
|
request_constructor( pointer );
|
|
|
|
return pointer;
|
|
|
|
}
|
|
|