axutil_env.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 AXUTIL_ENV_H
00019 #define AXUTIL_ENV_H
00020 
00027 #include <axutil_allocator.h>
00028 #include <axutil_error.h>
00029 #include <axutil_log.h>
00030 #include <axutil_thread_pool.h>
00031 
00032 #ifdef __cplusplus
00033 extern "C"
00034 {
00035 #endif
00036 
00044     struct axutil_env;
00045     struct axutil_env_ops;
00046 
00059     typedef struct axutil_env
00060     {
00062         axutil_allocator_t *allocator;
00064         axutil_error_t *error;
00066         axutil_log_t *log;
00068         axis2_bool_t log_enabled;
00070         axutil_thread_pool_t *thread_pool;
00071     }
00072     axutil_env_t;
00073 
00081     AXIS2_EXTERN axutil_env_t * AXIS2_CALL 
00082     axutil_env_create_all(const axis2_char_t *log_file,
00083         const axutil_log_levels_t log_level);
00084 
00091     AXIS2_EXTERN axutil_env_t * AXIS2_CALL 
00092     axutil_env_create(axutil_allocator_t *allocator);
00093 
00101     AXIS2_EXTERN axutil_env_t * AXIS2_CALL 
00102     axutil_env_create_with_error(axutil_allocator_t *allocator, 
00103         axutil_error_t *error);
00104 
00113     AXIS2_EXTERN axutil_env_t * AXIS2_CALL 
00114     axutil_env_create_with_error_log(axutil_allocator_t *allocator, 
00115         axutil_error_t *error, 
00116         axutil_log_t *log);
00117 
00127     AXIS2_EXTERN axutil_env_t * AXIS2_CALL 
00128     axutil_env_create_with_error_log_thread_pool(axutil_allocator_t *allocator, 
00129         axutil_error_t *error, 
00130         axutil_log_t *log, 
00131         axutil_thread_pool_t *pool);
00132 
00144     AXIS2_EXTERN void AXIS2_CALL 
00145     axutil_env_free(axutil_env_t *env);
00146 
00159     AXIS2_EXTERN void AXIS2_CALL 
00160     axutil_env_free_masked(axutil_env_t *env, 
00161         char mask);
00165     AXIS2_EXTERN axis2_status_t AXIS2_CALL 
00166     axutil_env_enable_log(axutil_env_t *env, 
00167         axis2_bool_t enable);
00168 
00172     AXIS2_EXTERN axis2_status_t AXIS2_CALL 
00173     axutil_env_check_status(const axutil_env_t *env);
00174 
00175 /*#define AXIS2_ENV_CHECK(env, error_return) \
00176     if(!env) \
00177     { \
00178         return error_return; \
00179     }*/
00180 
00181 #define AXIS2_ENV_CHECK(env, error_return) 
00182 
00185 #ifdef __cplusplus
00186 }
00187 #endif
00188 
00189 #endif                          /* AXIS2_ENV_H */
00190 
00191 

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