![]() |
AppEasy Core SDK
1.5.0
Cross platform mobile and desktop app and game development SDK - The easy way to make apps
|
00001 // 00002 // 00003 // AppEasy SDK - Cross Platform Multi-purpose Game and App Engine 00004 // 00005 // Developed by Matthew Hopwood of Pocketeers Limited - www.pocketeers.co.uk 00006 // 00007 // For updates, tutorials and more details check out www.appeasymobile.com 00008 // 00009 // This code is provided free of charge and without any warranty whatsoever. You must ensure that this whole notice is present in all files and derivatives, so the reader knows its origin. 00010 // If you use this SDK in your product then please ensure that you credit AppEasy's usage appropriately. Please see www.appeasymobile.com for licensing details and support 00011 // 00012 // 00013 00014 #if !defined(_CCZ_PLATFORM_COMMS_H_) 00015 #define _CCZ_PLATFORM_COMMS_H_ 00016 00017 #include "IzPlatformComms.h" 00018 #include "IwHTTP.h" 00019 00020 class CzPlatformComms : public IzPlatformComms 00021 { 00022 // Properties 00023 protected: 00024 public: 00025 // Properties end 00026 public: 00027 int Init(); 00028 void Release(); 00029 00030 CzHttpObject HttpCreate(); 00031 void HttpDestroy(CzHttpObject http_object); 00032 void HttpUpdate(CzHttpObject http_object); 00033 00034 void HttpCancel(CzHttpObject http_object); 00035 bool HttpGetHeader(CzHttpObject http_object, const char* header_name, CzString& header_data); 00036 void HttpSetRequestHeader(CzHttpObject http_object, const char* header_name, const char* header_data); 00037 bool HttpProcessRequest(CzHttpObject http_object, CzHttpRequest* request); 00038 00039 CzString HttpDetermineUserAgent(); 00040 00041 // Internal 00042 static int HttpReadContent(CzHttpObject http_object, char *buf, int max_bytes, s3eCallback callback = NULL, void *cb_data = NULL); 00043 static bool HttpGetSuccess(CzHttpObject http_object); 00044 static int HttpGetContentReceived(CzHttpObject http_object); 00045 static int HttpGetContentLength(CzHttpObject http_object); 00046 static int HttpGetContentExpected(CzHttpObject http_object); 00047 }; 00048 00049 00050 #endif // _CCZ_PLATFORM_COMMS_H_