Main Page | Modules | Class List | Directories | File List | Class Members | File Members | Examples

axis2_base64_binary.h

Go to the documentation of this file.
00001 /*
00002  * Copyright 2004,2005 The Apache Software Foundation.
00003  *
00004  * Licensed under the Apache License, Version 2.0 (the "License");
00005  * you may not use this file except in compliance with the License.
00006  * You may obtain a copy of the License at
00007  *
00008  *      http://www.apache.org/licenses/LICENSE-2.0
00009  *
00010  * Unless required by applicable law or agreed to in writing, software
00011  * distributed under the License is distributed on an "AS IS" BASIS,
00012  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
00013  * See the License for the specific language governing permissions and
00014  * limitations under the License.
00015  */
00016   
00017 #ifndef AXIS2_BASE64_BINARY_H
00018 #define AXIS2_BASE64_BINARY_H
00019 
00020 #include <axis2_base64.h>
00021 #include <axis2_utils_defines.h>
00022 #include <axis2_env.h>
00023 
00029 #ifdef __cplusplus
00030 extern "C"
00031 {
00032 #endif
00033    
00041 typedef struct axis2_base64_binary_ops axis2_base64_binary_ops_t;   
00042 typedef struct axis2_base64_binary axis2_base64_binary_t;
00043 
00044 AXIS2_DECLARE_DATA struct axis2_base64_binary_ops
00045 {
00052     axis2_status_t (AXIS2_CALL * 
00053     free)(axis2_base64_binary_t *base64_binary,
00054             const axis2_env_t *env);
00055     
00064     axis2_status_t (AXIS2_CALL *
00065     set_plain_binary) (axis2_base64_binary_t *base64_binary,
00066                         const axis2_env_t *env,
00067                         const unsigned char* plain_binary,
00068                         int plain_binary_len);
00069     
00078     unsigned char* (AXIS2_CALL *
00079     get_plain_binary) (axis2_base64_binary_t *base64_binary,
00080                         const axis2_env_t *env,
00081                         int* plain_binary_len );
00082   
00090     axis2_status_t (AXIS2_CALL *
00091     set_encoded_binary) (axis2_base64_binary_t *base64_binary,
00092                         const axis2_env_t *env,
00093                         const char* encoded_binary );
00094     
00101     char* (AXIS2_CALL *
00102     get_encoded_binary) (axis2_base64_binary_t *base64_binary,
00103                         const axis2_env_t *env );
00104  
00111     int (AXIS2_CALL *
00112     get_encoded_binary_len) (axis2_base64_binary_t *base64_binary,
00113                             const axis2_env_t *env );
00114  
00121     int (AXIS2_CALL *
00122     get_decoded_binary_len) (axis2_base64_binary_t *base64_binary,
00123                                 const axis2_env_t *env );
00124 
00125 
00126 };
00127 
00128 AXIS2_DECLARE_DATA struct axis2_base64_binary 
00129 {
00130     axis2_base64_binary_ops_t *ops;
00131 };
00132 
00138 AXIS2_EXTERN axis2_base64_binary_t* AXIS2_CALL
00139 axis2_base64_binary_create(const axis2_env_t *env );
00140 
00147 AXIS2_EXTERN axis2_base64_binary_t* AXIS2_CALL
00148 axis2_base64_binary_create_with_plain_binary(const axis2_env_t *env,
00149                                         const unsigned char *plain_binary,
00150                                         int plain_binary_len);
00151 
00158 AXIS2_EXTERN axis2_base64_binary_t* AXIS2_CALL
00159 axis2_base64_binary_create_with_encoded_binary(const axis2_env_t *env,
00160                                        const char *encoded_binary );
00161 
00162 /*************************** Function macros **********************************/
00163 
00164 #define AXIS2_BASE64_BINARY_FREE(base64_binary, env) \
00165      ((base64_binary)->ops->free(base64_binary, env))
00166 
00167 #define AXIS2_BASE64_BINARY_SET_PLAIN_BINARY(base64_binary, env, plain_binary) \
00168      ((base64_binary)->ops->set_plain_binary(base64_binary, env, plain_binary))
00169 
00170 #define AXIS2_BASE64_BINARY_GET_PLAIN_BINARY(base64_binary, env ) \
00171      ((base64_binary)->ops->get_plain_binary(base64_binary, env))
00172 
00173 #define AXIS2_BASE64_BINARY_SET_ENCODED_BINARY(base64_binary, env, encoded_binary) \
00174      ((base64_binary)->ops->set_encoded_binary(base64_binary, env, encoded_binary))
00175 
00176 #define AXIS2_BASE64_BINARY_GET_ENCODED_BINARY(base64_binary, env ) \
00177      ((base64_binary)->ops->get_encoded_binary(base64_binary, env))
00178 
00179 #define AXIS2_BASE64_BINARY_GET_ENCODED_BINARY_LEN(base64_binary, env ) \
00180      ((base64_binary)->ops->get_encoded_binary_len(base64_binary, env))
00181 
00182 #define AXIS2_BASE64_BINARY_GET_DECODED_BINARY_LEN(base64_binary, env ) \
00183      ((base64_binary)->ops->get_decoded_binary_len(base64_binary, env))
00184 
00186 #ifdef __cplusplus
00187 }
00188 #endif
00189 
00190 #endif /* AXIS2_BASE64_BINARY_H */

Generated on Fri Jun 16 18:02:30 2006 for Axis2/C by  doxygen 1.4.2