axutil_uri.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_URI_H
00019 #define AXUTIL_URI_H
00020 
00027 #include <axutil_string.h>
00028 #include <axutil_utils.h>
00029 #include <axutil_utils_defines.h>
00030 #include <axutil_env.h>
00031 
00032 #ifdef __cplusplus
00033 extern "C"
00034 {
00035 #endif
00036 
00043 #define AXIS2_URI_FTP_DEFAULT_PORT         21 
00044 #define AXIS2_URI_SSH_DEFAULT_PORT         22 
00045 #define AXIS2_URI_TELNET_DEFAULT_PORT      23 
00046 #define AXIS2_URI_GOPHER_DEFAULT_PORT      70 
00047 #define AXIS2_URI_HTTP_DEFAULT_PORT        80 
00048 #define AXIS2_URI_POP_DEFAULT_PORT        110 
00049 #define AXIS2_URI_NNTP_DEFAULT_PORT       119 
00050 #define AXIS2_URI_IMAP_DEFAULT_PORT       143 
00051 #define AXIS2_URI_PROSPERO_DEFAULT_PORT   191 
00052 #define AXIS2_URI_WAIS_DEFAULT_PORT       210 
00053 #define AXIS2_URI_LDAP_DEFAULT_PORT       389 
00054 #define AXIS2_URI_HTTPS_DEFAULT_PORT      443 
00055 #define AXIS2_URI_RTSP_DEFAULT_PORT       554 
00056 #define AXIS2_URI_SNEWS_DEFAULT_PORT      563 
00057 #define AXIS2_URI_ACAP_DEFAULT_PORT       674 
00058 #define AXIS2_URI_NFS_DEFAULT_PORT       2049 
00059 #define AXIS2_URI_TIP_DEFAULT_PORT       3372 
00060 #define AXIS2_URI_SIP_DEFAULT_PORT       5060 
00064 #define AXIS2_URI_UNP_OMITSITEPART    (1U<<0)
00065 
00066 #define AXIS2_URI_UNP_OMITUSER        (1U<<1)
00067 
00068 #define AXIS2_URI_UNP_OMITPASSWORD    (1U<<2)
00069 
00070 #define AXIS2_URI_UNP_OMITUSERINFO    (AXIS2_URI_UNP_OMITUSER | \
00071                                      AXIS2_URI_UNP_OMITPASSWORD)
00072 
00073 #define AXIS2_URI_UNP_REVEALPASSWORD  (1U<<3)
00074 
00075 #define AXIS2_URI_UNP_OMITPATHINFO    (1U<<4)
00076 
00077 #define AXIS2_URI_UNP_OMITQUERY       (1U<<5)
00078 
00080     typedef  unsigned short  axis2_port_t;
00081     /* axutil_uri.c */
00082 
00083     typedef struct axutil_uri axutil_uri_t;
00084 
00091     AXIS2_EXTERN axis2_port_t AXIS2_CALL
00092     axutil_uri_port_of_scheme(
00093         const axis2_char_t *scheme_str);
00094 
00103     AXIS2_EXTERN axutil_uri_t *AXIS2_CALL
00104     axutil_uri_parse_string(
00105         const axutil_env_t *env,
00106         const axis2_char_t *uri);
00107 
00114     AXIS2_EXTERN axutil_uri_t *AXIS2_CALL
00115     axutil_uri_parse_hostinfo(
00116         const axutil_env_t *env,
00117         const axis2_char_t *hostinfo);
00118 
00120     AXIS2_EXTERN axutil_uri_t *AXIS2_CALL
00121     axutil_uri_resolve_relative(
00122         const axutil_env_t *env,
00123         const axutil_uri_t* base,
00124         axutil_uri_t* uptr);
00125 
00138     AXIS2_EXTERN axutil_uri_t *AXIS2_CALL
00139     axutil_uri_parse_relative(
00140         const axutil_env_t *env,
00141         const axutil_uri_t* base,
00142         const char* uri);
00143 
00144     AXIS2_EXTERN void AXIS2_CALL
00145     axutil_uri_free(axutil_uri_t *uri,
00146             const axutil_env_t *env);
00147 
00164     AXIS2_EXTERN axis2_char_t* AXIS2_CALL
00165     axutil_uri_to_string(const axutil_uri_t *uri,
00166             const axutil_env_t *env,
00167             unsigned flags);
00168 
00169     AXIS2_EXTERN axis2_char_t* AXIS2_CALL
00170     axutil_uri_get_protocol(axutil_uri_t *uri,
00171             const axutil_env_t *env);
00172 
00173     AXIS2_EXTERN axis2_char_t* AXIS2_CALL
00174     axutil_uri_get_server(axutil_uri_t *uri,
00175             const axutil_env_t *env);
00176 
00177     AXIS2_EXTERN axis2_port_t AXIS2_CALL
00178     axutil_uri_get_port(axutil_uri_t *uri,
00179             const axutil_env_t *env);
00180 
00181     AXIS2_EXTERN axis2_char_t* AXIS2_CALL
00182     axutil_uri_get_path(axutil_uri_t *uri,
00183             const axutil_env_t *env);
00184 
00185     AXIS2_EXTERN axutil_uri_t* AXIS2_CALL
00186     axutil_uri_clone(const axutil_uri_t *uri,
00187             const axutil_env_t *env);
00188 
00189 
00191 #ifdef __cplusplus
00192 }
00193 #endif
00194 
00195 #endif /* AXIS2_URI_H */

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