FIAP (IEEE1888) library
Dependents: Fetch_IEEE1888_Storage IEEE1888_MULTI_SENSOR_GW
Fork of FiapV2 by
Diff: fiap.h
- Revision:
- 13:13cceccf6bfb
- Parent:
- 12:f4e59ab2bab0
- Child:
- 14:a9ec0e6e22c8
diff -r f4e59ab2bab0 -r 13cceccf6bfb fiap.h --- a/fiap.h Fri Feb 22 16:41:51 2013 +0000 +++ b/fiap.h Sun Feb 24 05:53:20 2013 +0000 @@ -2,6 +2,7 @@ // // 2011/09/19 ver.1 H.Inoue & H.Ochiai // 2011/12/31 Ver.1 for mbed Y.Tauchi +// 2013/02 inherited repository by S.Yoshida // --------- FIAP.h --------- #ifndef MBED_FIAP_H @@ -17,7 +18,10 @@ #define FIAP_UPLOAD_HTTPERR 3 // HTTP Server error (The response was not "200 OK") #define FIAP_UPLOAD_FIAPERR 4 // FIAP Server error -// fetch_last_data(struct fiap_element* v) seems to be broken +// use fetch_last_data(struct fiap_element* v, unsigned int esize) if true +#define USE_FETCH_MULTI false + +// use fetch_last_data(struct fiap_element* v) if true, but it seems to be broken #define USE_FETCH_ONLY_1 false /** fiap_element @@ -46,13 +50,16 @@ /** FIAP Class */ class FIAP { public: - /** Create fiap object */ + /** Create fiap object + * @param Storage FIAP Storage Addrees + * @param _use_fetch use fetch mode if true, write mode if false + */ + FIAP(char Storage[], bool _use_fetch); + FIAP(char Storage[]); FIAP(); - FIAP(char Storage[]); - FIAP(char Storage[], bool _use_fetch); /** Set Storage URL - * @param Storage FIAP Storage Addrees (ie. "http://fiap.org/axis2/services/FIAPStorage") + * @param Storage FIAP Storage Addrees */ void setStorage(char Storage[]); @@ -69,6 +76,7 @@ * @return network_error */ int fetch_last_data(struct fiap_element* v, unsigned int esize); + int fetch_last_data(struct fiap_element* v) /** debug_mode * Output XML and Error @@ -76,8 +84,8 @@ bool debug_mode; private: - bool _use_fetch; - char _fiap_storage[100]; + bool _use_fetch;//use fetch mode if true, write mode if false + char _fiap_storage[100];//FIAP Storage Addrees //char _fiap_id_prefix[100]; char _soap_header[256]; char _soap_footer[256];