Advanced Strategic Command
Public Member Functions | Public Attributes | List of all members
ASC_PBEM_FileUploadControl Class Reference

file: ASC_PBEM.h author: Jade Rogalski license: GPL warranty: none More...

#include <pbem-server-interaction.h>

Public Member Functions

 ASC_PBEM_FileUploadControl (const Uint8 *dataParam, const int sizeParam)
 

Public Attributes

int step
 
int sent_step
 
const int size
 
const Uint8 * data
 
ASCString fileName
 
ASCString boundary
 
std::vector< ASCStringparameters
 

Detailed Description

file: ASC_PBEM.h author: Jade Rogalski license: GPL warranty: none

interface between the game asc by Marting Bickel, and the asc pbem server by Jade Rogalski

example usages:

*** account erstellen

ASC_PBEM asc_pbem( "http://localhost:8080/ascServer/" ); if( asc_pbem.isUsable() && asc_pbem.createAccount( "user", "password", "a@b.c" ) ) { std::cout << "account erstellt, mail unterwegs\n"; }else { std::cout << "account erstellung fehlgeschlagen\n"; }

*** upload eines spielstandes;

char* daten = "miau"; int size = strlen( "miau" ) * sizeof( char ); ASCString fileName = "duell-A-1.ascpbm"; int gameID = 1;

ASC_PBEM asc_pbem( "http://localhost:8080/ascServer/" ); if( asc_pbem.isUsable() && asc_pbem.login( "user", "pw" ) ) { if( asc_pbem.uploadFile( fileName, daten, size, gameID ) ) std::cout << "uploadFile erfolgreich\n"; else std::cout << "uploadFile fehlgeschlagen\n"; }

??? TODO:

Definition at line 65 of file pbem-server-interaction.h.

Constructor & Destructor Documentation

ASC_PBEM_FileUploadControl::ASC_PBEM_FileUploadControl ( const Uint8 *  dataParam,
const int  sizeParam 
)
inline

Definition at line 77 of file pbem-server-interaction.h.

Member Data Documentation

ASCString ASC_PBEM_FileUploadControl::boundary
const Uint8* ASC_PBEM_FileUploadControl::data

Definition at line 71 of file pbem-server-interaction.h.

Referenced by ASC_PBEM_readInternal().

ASCString ASC_PBEM_FileUploadControl::fileName
std::vector<ASCString> ASC_PBEM_FileUploadControl::parameters
int ASC_PBEM_FileUploadControl::sent_step
const int ASC_PBEM_FileUploadControl::size

Definition at line 70 of file pbem-server-interaction.h.

Referenced by ASC_PBEM_readInternal().

int ASC_PBEM_FileUploadControl::step

The documentation for this class was generated from the following file: