axis2_transport_sender.h

Go to the documentation of this file.
00001 /*
00002 * Licensed to the Apache Software Foundation (ASF) under one or more
00003 * contributor license agreements.  See the NOTICE file distributed with
00004 * this work for additional information regarding copyright ownership.
00005 * The ASF licenses this file to You under the Apache License, Version 2.0
00006 * (the "License"); you may not use this file except in compliance with
00007 * the License.  You may obtain a copy of the License at
00008 *
00009 *      http://www.apache.org/licenses/LICENSE-2.0
00010 *
00011 * Unless required by applicable law or agreed to in writing, software
00012 * distributed under the License is distributed on an "AS IS" BASIS,
00013 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
00014 * See the License for the specific language governing permissions and
00015 * limitations under the License.
00016 */
00017 
00018 #ifndef AXIS2_TRANSPORT_SENDER_H
00019 #define AXIS2_TRANSPORT_SENDER_H
00020 
00032 #include <axis2_const.h>
00033 #include <axutil_error.h>
00034 #include <axis2_defines.h>
00035 #include <axutil_env.h>
00036 #include <axutil_allocator.h>
00037 #include <axis2_transport_out_desc.h>
00038 #include <axis2_ctx.h>
00039 #include <axis2_msg_ctx.h>
00040 
00041 #ifdef __cplusplus
00042 extern "C"
00043 {
00044 #endif
00045 
00046     struct axis2_transport_out_desc;
00047     struct axis2_ctx;
00048     struct axis2_msg_ctx;
00049     struct axis2_handler;
00051     typedef struct axis2_transport_sender axis2_transport_sender_t;
00053     typedef struct axis2_transport_sender_ops axis2_transport_sender_ops_t;
00054 
00059     struct axis2_transport_sender_ops
00060     {
00069         axis2_status_t (AXIS2_CALL *
00070                 init)(
00071                     axis2_transport_sender_t *transport_sender,
00072                     const axutil_env_t *env,
00073                     struct axis2_conf_ctx *conf_ctx,
00074                     struct axis2_transport_out_desc *transport_out);
00082         axis2_status_t (AXIS2_CALL *
00083                 invoke)(
00084                     axis2_transport_sender_t *transport_sender,
00085                     const axutil_env_t *env,
00086                     struct axis2_msg_ctx *msg_ctx);
00087 
00095         axis2_status_t (AXIS2_CALL *
00096                 cleanup)(
00097                     axis2_transport_sender_t *transport_sender,
00098                     const axutil_env_t *env,
00099                     struct axis2_msg_ctx *msg_ctx);
00100 
00101 
00107         void (AXIS2_CALL *
00108                 free)(
00109                     axis2_transport_sender_t *transport_sender,
00110                     const axutil_env_t *env);
00111 
00112     };
00113 
00119      struct axis2_transport_sender
00120     {
00122         const axis2_transport_sender_ops_t *ops;
00123     };
00124 
00130     AXIS2_EXTERN axis2_transport_sender_t * AXIS2_CALL
00131     axis2_transport_sender_create (
00132         const axutil_env_t *env);
00133 
00134 /*************************** Function macros **********************************/
00135 
00138 #define AXIS2_TRANSPORT_SENDER_FREE(transport_sender, env) \
00139       ((transport_sender->ops)->free (transport_sender, env))
00140 
00143 #define AXIS2_TRANSPORT_SENDER_INIT(transport_sender, env, conf_context, transport_out) \
00144       ((transport_sender->ops)->init (transport_sender, env, conf_context, transport_out))
00145 
00148 #define AXIS2_TRANSPORT_SENDER_INVOKE(transport_sender, env, msg_ctx) \
00149       ((transport_sender->ops)->invoke (transport_sender, env, msg_ctx))
00150 
00153 #define AXIS2_TRANSPORT_SENDER_CLEANUP(transport_sender, env, msg_ctx) \
00154       ((transport_sender->ops)->cleanup (transport_sender, env, msg_ctx))
00155 
00156 /*************************** End of function macros ***************************/
00157 
00160 #ifdef __cplusplus
00161 }
00162 #endif
00163 #endif  /* AXIS2_TRANSPORT_SENDER_H */

Generated on Thu May 3 12:31:01 2007 for Axis2/C by  doxygen 1.4.6