Axis2/C: axutil_uri.h Source File

- Main Page
- Modules
- Classes
- Files
- Directories
- Related Pages
- Examples

- Search for |

# 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_ONLY    (1U<<5)
    00103
    00105 #define AXIS2_URI_UNP_OMITFRAGMENT_ONLY (1U<<6)
    00106
    00108 #define AXIS2_URI_UNP_OMITQUERY         (AXIS2_URI_UNP_OMITQUERY_ONLY | \
    00109                                        AXIS2_URI_UNP_OMITFRAGMENT_ONLY)
    00110
    00112     typedef unsigned short axis2_port_t;
    00113     /* axutil_uri.c */
    00114
    00115     typedef struct axutil_uri axutil_uri_t;
    00116
    00122     AXIS2_EXTERN axutil_uri_t *AXIS2_CALL
    00123     axutil_uri_create(
    00124         const axutil_env_t * env);
    00125
    00132     AXIS2_EXTERN axis2_port_t AXIS2_CALL
    00133     axutil_uri_port_of_scheme(
    00134         const axis2_char_t * scheme_str);
    00135
    00144     AXIS2_EXTERN axutil_uri_t *AXIS2_CALL
    00145     axutil_uri_parse_string(
    00146         const axutil_env_t * env,
    00147         const axis2_char_t * uri);
    00148
    00155     AXIS2_EXTERN axutil_uri_t *AXIS2_CALL
    00156     axutil_uri_parse_hostinfo(
    00157         const axutil_env_t * env,
    00158         const axis2_char_t * hostinfo);
    00159
    00161     AXIS2_EXTERN axutil_uri_t *AXIS2_CALL
    00162     axutil_uri_resolve_relative(
    00163         const axutil_env_t * env,
    00164         const axutil_uri_t * base,
    00165         axutil_uri_t * uptr);
    00166
    00179     AXIS2_EXTERN axutil_uri_t *AXIS2_CALL
    00180     axutil_uri_parse_relative(
    00181         const axutil_env_t * env,
    00182         const axutil_uri_t * base,
    00183         const char *uri);
    00184
    00185     AXIS2_EXTERN void AXIS2_CALL
    00186     axutil_uri_free(
    00187         axutil_uri_t * uri,
    00188         const axutil_env_t * env);
    00189
    00206     AXIS2_EXTERN axis2_char_t *AXIS2_CALL
    00207     axutil_uri_to_string(
    00208         const axutil_uri_t * uri,
    00209         const axutil_env_t * env,
    00210         unsigned flags);
    00211
    00215     AXIS2_EXTERN axis2_char_t *AXIS2_CALL
    00216     axutil_uri_get_protocol(
    00217         axutil_uri_t * uri,
    00218         const axutil_env_t * env);
    00219
    00223     AXIS2_EXTERN axis2_char_t *AXIS2_CALL
    00224     axutil_uri_get_server(
    00225         axutil_uri_t * uri,
    00226         const axutil_env_t * env);
    00227
    00233     AXIS2_EXTERN axis2_char_t *AXIS2_CALL
    00234     axutil_uri_get_host(
    00235         axutil_uri_t * uri,
    00236         const axutil_env_t * env);
    00237
    00238     AXIS2_EXTERN axis2_port_t AXIS2_CALL
    00239     axutil_uri_get_port(
    00240         axutil_uri_t * uri,
    00241         const axutil_env_t * env);
    00242
    00246     AXIS2_EXTERN axis2_char_t *AXIS2_CALL
    00247     axutil_uri_get_path(
    00248         axutil_uri_t * uri,
    00249         const axutil_env_t * env);
    00250
    00251     AXIS2_EXTERN axutil_uri_t *AXIS2_CALL
    00252     axutil_uri_clone(
    00253         const axutil_uri_t * uri,
    00254         const axutil_env_t * env);
    00255
    00259     AXIS2_EXTERN axis2_char_t *AXIS2_CALL
    00260     axutil_uri_get_query(
    00261         axutil_uri_t * uri,
    00262         const axutil_env_t * env);
    00263
    00267     AXIS2_EXTERN axis2_char_t *AXIS2_CALL
    00268     axutil_uri_get_fragment(
    00269         axutil_uri_t * uri,
    00270         const axutil_env_t * env);
    00271
    00273 #ifdef __cplusplus
    00274 }
    00275 #endif
    00276
    00277 #endif                          /* AXIS2_URI_H */