Main Page | File List | File Members

ByteArray.h

Go to the documentation of this file.
00001 /* -*- mode: c++; -*-
00002  *-----------------------------------------------------------------------------
00003  * $RCSfile: ByteArray.h,v $
00004  *
00005  * See Copyright for the status of this software.
00006  *
00007  * The OpenSOAP Project
00008  * http://opensoap.jp/
00009  *-----------------------------------------------------------------------------
00010  */
00011 #ifndef OpenSOAP_ByteArray_H
00012 #define OpenSOAP_ByteArray_H
00013 
00014 #include <stdlib.h>
00015 #include <sys/types.h>
00016 
00017 #include <OpenSOAP/Defines.h>
00018 #include <OpenSOAP/ErrorCode.h>
00019 
00026 #ifdef __cplusplus
00027 extern "C" {
00028 #endif /* __cplusplus */
00029 
00034     typedef struct tagOpenSOAPByteArray OpenSOAPByteArray;
00035 
00040     typedef OpenSOAPByteArray    *OpenSOAPByteArrayPtr;
00041 
00050     int
00051     OPENSOAP_API
00052     OpenSOAPByteArrayCreate(OpenSOAPByteArrayPtr * /* [out] */ b_ary);
00053 
00066     int
00067     OPENSOAP_API
00068     OpenSOAPByteArrayCreateWithData(const unsigned char * /* [in] */ data,
00069                                     size_t /* [in] */ sz,
00070                                     OpenSOAPByteArrayPtr * /* [out] */ b_ary);
00071 
00076     #define OpenSOAPByteArrayCreateWithSize(sz, b_ary) OpenSOAPByteArrayCreateWithData(0, (sz), (b_ary))
00077 
00086     int
00087     OPENSOAP_API
00088     OpenSOAPByteArrayAppendRef(OpenSOAPByteArrayPtr /* [in] */ b_ary);
00089 
00098     int
00099     OPENSOAP_API
00100     OpenSOAPByteArrayRelease(OpenSOAPByteArrayPtr /* [in] */ b_ary);
00101 
00112     int
00113     OPENSOAP_API
00114     OpenSOAPByteArrayGetSize(OpenSOAPByteArrayPtr /* [in] */ b_ary,
00115                              size_t * /* [out] */ sz);
00116 
00127     int
00128     OPENSOAP_API
00129     OpenSOAPByteArrayBeginConst(OpenSOAPByteArrayPtr /* [in] */ b_ary,
00130                                 const unsigned char ** /* [out] */beg);
00131     
00142     int
00143     OPENSOAP_API
00144     OpenSOAPByteArrayEndConst(OpenSOAPByteArrayPtr /* [in] */ b_ary,
00145                               const unsigned char ** /* [out] */ed);
00146     
00159     int
00160     OPENSOAP_API
00161     OpenSOAPByteArrayGetBeginSizeConst(OpenSOAPByteArrayPtr /* [in] */ b_ary,
00162                                        const unsigned char ** /* [out] */ beg,
00163                                        size_t * /* [out] */ sz);
00164 
00177     int
00178     OPENSOAP_API
00179     OpenSOAPByteArrayGetBeginEndConst(OpenSOAPByteArrayPtr /* [in] */ b_ary,
00180                                       const unsigned char ** /* [out] */ beg,
00181                                       const unsigned char ** /* [out] */ ed);
00182     
00193     int
00194     OPENSOAP_API
00195     OpenSOAPByteArrayBegin(OpenSOAPByteArrayPtr /* [in] */ b_ary,
00196                            unsigned char ** /* [out] */beg);
00197     
00208     int
00209     OPENSOAP_API
00210     OpenSOAPByteArrayEnd(OpenSOAPByteArrayPtr /* [in] */ b_ary,
00211                          unsigned char ** /* [out] */ed);
00212 
00225     int
00226     OPENSOAP_API
00227     OpenSOAPByteArrayGetBeginSize(OpenSOAPByteArrayPtr /* [in] */ b_ary,
00228                                   unsigned char ** /* [out] */ beg,
00229                                   size_t * /* [out] */ sz);
00230 
00243     int
00244     OPENSOAP_API
00245     OpenSOAPByteArrayGetBeginEnd(OpenSOAPByteArrayPtr /* [in] */ b_ary,
00246                                  unsigned char ** /* [out] */ beg,
00247                                  unsigned char ** /* [out] */ ed);
00248     
00257     int
00258     OPENSOAP_API
00259     OpenSOAPByteArrayClear(OpenSOAPByteArrayPtr /* [in] */ b_ary);
00260 
00273     int
00274     OPENSOAP_API
00275     OpenSOAPByteArraySetData(OpenSOAPByteArrayPtr /* [in, out] */ b_ary,
00276                              const unsigned char * /* [in] */ data,
00277                              size_t /* [in] */ sz);
00278     
00291     int
00292     OPENSOAP_API
00293     OpenSOAPByteArrayAppend(OpenSOAPByteArrayPtr /* [in] */ b_ary,
00294                             const unsigned char *dat,
00295                             size_t       dat_len);
00296 
00307     int
00308     OPENSOAP_API
00309     OpenSOAPByteArrayResize(OpenSOAPByteArrayPtr /* [in, out] */ b_ary,
00310                             size_t       /* [in] */ new_size);
00311 
00322     int
00323     OPENSOAP_API
00324     OpenSOAPByteArrayDuplicate(OpenSOAPByteArrayPtr /* [in] */ b_ary,
00325                                OpenSOAPByteArrayPtr * /* [out] */ dup_b_ary);
00326 
00327 #ifdef __cplusplus
00328 }
00329 #endif /* __cplusplus */
00330 
00331 #endif /* OpenSOAP_ByteArray_H */

Generated on Mon Oct 18 18:29:43 2004 for OpenSOAP by doxygen 1.3.6