axutil_uri.h

Go to the documentation of this file.
00001 
00002 /*
00003  * Licensed to the Apache Software Foundation (ASF) under one or more
00004  * contributor license agreements.  See the NOTICE file distributed with
00005  * this work for additional information regarding copyright ownership.
00006  * The ASF licenses this file to You under the Apache License, Version 2.0
00007  * (the "License"); you may not use this file except in compliance with
00008  * the License.  You may obtain a copy of the License at
00009  *
00010  *      http://www.apache.org/licenses/LICENSE-2.0
00011  *
00012  * Unless required by applicable law or agreed to in writing, software
00013  * distributed under the License is distributed on an "AS IS" BASIS,
00014  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
00015  * See the License for the specific language governing permissions and
00016  * limitations under the License.
00017  */
00018 
00019 #ifndef AXUTIL_URI_H
00020 #define AXUTIL_URI_H
00021 
00028 #include <axutil_string.h>
00029 #include <axutil_utils.h>
00030 #include <axutil_utils_defines.h>
00031 #include <axutil_env.h>
00032 
00033 #ifdef __cplusplus
00034 extern "C"
00035 {
00036 #endif
00037 
00044 #define AXIS2_URI_FTP_DEFAULT_PORT         21 
00046 #define AXIS2_URI_SSH_DEFAULT_PORT         22 
00048 #define AXIS2_URI_TELNET_DEFAULT_PORT      23 
00050 #define AXIS2_URI_GOPHER_DEFAULT_PORT      70 
00052 #define AXIS2_URI_HTTP_DEFAULT_PORT        80 
00054 #define AXIS2_URI_POP_DEFAULT_PORT        110 
00056 #define AXIS2_URI_NNTP_DEFAULT_PORT       119 
00058 #define AXIS2_URI_IMAP_DEFAULT_PORT       143 
00060 #define AXIS2_URI_PROSPERO_DEFAULT_PORT   191 
00062 #define AXIS2_URI_WAIS_DEFAULT_PORT       210 
00064 #define AXIS2_URI_LDAP_DEFAULT_PORT       389 
00066 #define AXIS2_URI_HTTPS_DEFAULT_PORT      443 
00068 #define AXIS2_URI_RTSP_DEFAULT_PORT       554 
00070 #define AXIS2_URI_SNEWS_DEFAULT_PORT      563 
00072 #define AXIS2_URI_ACAP_DEFAULT_PORT       674 
00074 #define AXIS2_URI_NFS_DEFAULT_PORT       2049 
00076 #define AXIS2_URI_TIP_DEFAULT_PORT       3372 
00078 #define AXIS2_URI_SIP_DEFAULT_PORT       5060 
00083 #define AXIS2_URI_UNP_OMITSITEPART    (1U<<0)
00084 
00086 #define AXIS2_URI_UNP_OMITUSER        (1U<<1)
00087 
00089 #define AXIS2_URI_UNP_OMITPASSWORD    (1U<<2)
00090 
00092 #define AXIS2_URI_UNP_OMITUSERINFO    (AXIS2_URI_UNP_OMITUSER | \
00093                                      AXIS2_URI_UNP_OMITPASSWORD)
00094 
00096 #define AXIS2_URI_UNP_REVEALPASSWORD  (1U<<3)
00097 
00099 #define AXIS2_URI_UNP_OMITPATHINFO    (1U<<4)
00100 
00102 #define AXIS2_URI_UNP_OMITQUERY       (1U<<5)
00103 
00105     typedef unsigned short axis2_port_t;
00106     /* axutil_uri.c */
00107 
00108     typedef struct axutil_uri axutil_uri_t;
00109 
00116     AXIS2_EXTERN axis2_port_t AXIS2_CALL
00117     axutil_uri_port_of_scheme(
00118         const axis2_char_t * scheme_str);
00119 
00128     AXIS2_EXTERN axutil_uri_t *AXIS2_CALL
00129     axutil_uri_parse_string(
00130         const axutil_env_t * env,
00131         const axis2_char_t * uri);
00132 
00139     AXIS2_EXTERN axutil_uri_t *AXIS2_CALL
00140     axutil_uri_parse_hostinfo(
00141         const axutil_env_t * env,
00142         const axis2_char_t * hostinfo);
00143 
00145     AXIS2_EXTERN axutil_uri_t *AXIS2_CALL
00146     axutil_uri_resolve_relative(
00147         const axutil_env_t * env,
00148         const axutil_uri_t * base,
00149         axutil_uri_t * uptr);
00150 
00163     AXIS2_EXTERN axutil_uri_t *AXIS2_CALL
00164     axutil_uri_parse_relative(
00165         const axutil_env_t * env,
00166         const axutil_uri_t * base,
00167         const char *uri);
00168 
00169     AXIS2_EXTERN void AXIS2_CALL
00170     axutil_uri_free(
00171         axutil_uri_t * uri,
00172         const axutil_env_t * env);
00173 
00190     AXIS2_EXTERN axis2_char_t *AXIS2_CALL
00191     axutil_uri_to_string(
00192         const axutil_uri_t * uri,
00193         const axutil_env_t * env,
00194         unsigned flags);
00195 
00196     AXIS2_EXTERN axis2_char_t *AXIS2_CALL
00197     axutil_uri_get_protocol(
00198         axutil_uri_t * uri,
00199         const axutil_env_t * env);
00200 
00201     AXIS2_EXTERN axis2_char_t *AXIS2_CALL
00202     axutil_uri_get_server(
00203         axutil_uri_t * uri,
00204         const axutil_env_t * env);
00205 
00206     AXIS2_EXTERN axis2_port_t AXIS2_CALL
00207     axutil_uri_get_port(
00208         axutil_uri_t * uri,
00209         const axutil_env_t * env);
00210 
00211     AXIS2_EXTERN axis2_char_t *AXIS2_CALL
00212     axutil_uri_get_path(
00213         axutil_uri_t * uri,
00214         const axutil_env_t * env);
00215 
00216     AXIS2_EXTERN axutil_uri_t *AXIS2_CALL
00217     axutil_uri_clone(
00218         const axutil_uri_t * uri,
00219         const axutil_env_t * env);
00220 
00222 #ifdef __cplusplus
00223 }
00224 #endif
00225 
00226 #endif                          /* AXIS2_URI_H */

Generated on Wed Jan 2 17:42:50 2008 for Axis2/C by  doxygen 1.5.1