fix baseline build (old cairo) - 'cairo_rectangle_int_t' does not name a type
[LibreOffice.git] / udkapi / com / sun / star / uri / XUriReference.idl
blob147eaba79f2ebec9765f649a29c6b6c65a033437
1 /* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
2 /*
3 * This file is part of the LibreOffice project.
5 * This Source Code Form is subject to the terms of the Mozilla Public
6 * License, v. 2.0. If a copy of the MPL was not distributed with this
7 * file, You can obtain one at http://mozilla.org/MPL/2.0/.
9 * This file incorporates work covered by the following license notice:
11 * Licensed to the Apache Software Foundation (ASF) under one or more
12 * contributor license agreements. See the NOTICE file distributed
13 * with this work for additional information regarding copyright
14 * ownership. The ASF licenses this file to you under the Apache
15 * License, Version 2.0 (the "License"); you may not use this file
16 * except in compliance with the License. You may obtain a copy of
17 * the License at http://www.apache.org/licenses/LICENSE-2.0 .
20 #ifndef __com_sun_star_uri_XUriReference_idl__
21 #define __com_sun_star_uri_XUriReference_idl__
23 #include <com/sun/star/uno/XInterface.idl>
25 module com { module sun { module star { module uri {
27 /**
28 represents generic, mutable URI references.
30 <p>See <a href="http://www.ietf.org/rfc/rfc2396.txt">RFC&nbsp;2396</a> for a
31 description of URI references and related terms.</p>
33 <p>This interface only handles generic URI references (both absolute and
34 relative). For specific URI schemes, there will be additional interfaces
35 that offer extra, scheme-specific functionality.</p>
37 @see com::sun::star::uri::UriReferenceFactory
38 which allows to create URI reference objects that support
39 com::sun::star::uri::XUriReference and additional,
40 scheme-specific interfaces.
42 @since OOo 2.0
44 published interface XUriReference: com::sun::star::uno::XInterface {
45 /**
46 returns the textual representation of the complete URI reference.
48 @returns
49 the textual representation of the complete URI reference. The exact
50 spelling of the URI reference is retained.
52 string getUriReference();
54 /**
55 returns whether this URI reference is absolute or relative.
57 @returns
58 `TRUE` if this URI reference is absolute, `FALSE` if it is relative.
60 boolean isAbsolute();
62 /**
63 returns the scheme part of this (absolute) URI reference.
65 @returns
66 the textual representation of the scheme part (with the exact spelling
67 retained; without the delimiting &ldquo;<code>:</code>&rdquo;), if this
68 is an absolute URI reference; otherwise, an empty `string` is
69 returned.
71 string getScheme();
73 /**
74 returns the scheme-specific part of this URI reference.
76 <p>For an absolute URI reference, the scheme-specific part is everything
77 after the scheme part and the delimiting &ldquo;<code>:</code>&rdquo;,
78 and before the optional &ldquo;<code>#</code>&rdquo; and fragment part.
79 For a relative URI reference, the scheme-specific part is everything
80 before the optional &ldquo;<code>#</code>&rdquo; and fragment part.</p>
82 @returns
83 the textual representation of the scheme-specific part (with the exact
84 spelling retained).
86 string getSchemeSpecificPart();
88 /**
89 returns whether this URI reference is hierarchical or opaque.
91 <p>An absolute URI reference is hierarchical if its scheme-specific part
92 starts with &ldquo;<code>/</code>&rdquo;. A relative URI reference is
93 always hierarchical.</p>
95 @returns
96 `TRUE` if this URI reference is hierarchical, `FALSE` if it is opaque.
98 boolean isHierarchical();
101 returns whether this (hierarchical) URI reference has an authority part.
103 @returns
104 `TRUE` if this URI reference is hierarchical and has an authority part.
106 boolean hasAuthority();
109 returns the authority part of this (hierarchical) URI reference.
111 @returns
112 the textual representation of the authority part (with the exact spelling
113 retained), if this is a hierarchical URI reference that has an authority
114 part; otherwise, an empty `string` is returned.
116 string getAuthority();
119 returns the path part of this URI reference.
121 @returns
122 the textual representation of the path part (with the exact spelling
123 retained), if this is a hierarchical URI reference; for an opaque URI
124 reference, the scheme-specific part (with the exact spelling retained) is
125 returned.
127 string getPath();
130 returns whether this (relative) URI reference has a relative path.
132 @returns
133 `TRUE` if this URI reference is relative and has a relative path.
135 boolean hasRelativePath();
138 returns the number of path segments of this (hierarchical) URI reference.
140 <p>For an opaque URI reference, and for a hierarchical URI reference with
141 an empty path, the number of path segments is zero. For a hierarchical
142 URI reference with an absolute, non-empty path, the number of path
143 segments equals the number of &ldquo;<code>/</code>&rdquo; delimiters.
144 For a hierarchical URI reference with a relative, non-empty path, the
145 number of path segments equals the number of &ldquo;<code>/</code>&rdquo;
146 delimiters, plus one.</p>
148 @returns
149 the number of path segments.
151 long getPathSegmentCount();
154 returns a given path segment of this (hierarchical) URI reference.
156 @param index
157 the index of the path segment, starting at zero.
159 @returns
160 the textual representation of the given path segment (with the exact
161 spelling retained, without any delimiting &ldquo;<code>/</code>&rdquo;),
162 if this URI reference is hierarchical and has that many path segments;
163 otherwise, and in particular if <code>index</code> is negative, an empty
164 `string` is returned.
166 string getPathSegment([in] long index);
169 returns whether this (hierarchical) URI reference has a query part.
171 @returns
172 `TRUE` if this URI reference is hierarchical and has a query part.
174 boolean hasQuery();
177 returns the query part of this (hierarchical) URI reference.
179 @returns
180 the textual representation of the query part (with the exact spelling
181 retained; without the delimiting &ldquo;<code>?</code>&rdquo;), if this
182 is a hierarchical URI reference that has a query part; otherwise, an
183 empty `string` is returned.
185 string getQuery();
188 returns whether this URI reference has a fragment part.
190 @returns
191 `TRUE` if this URI reference has a fragment part.
193 boolean hasFragment();
196 returns the fragment part of this URI reference.
198 @returns
199 the textual representation of the fragment part (with the exact spelling
200 retained; without the delimiting &ldquo;<code>#</code>&rdquo;), if this
201 is a URI reference that has a fragment part; otherwise, an empty
202 `string` is returned.
204 string getFragment();
207 sets the fragment part of this URI reference.
209 @param fragment
210 the textual representation of the new fragment part. The exact spelling
211 will be preserved, and no escaping is performed.
213 void setFragment([in] string fragment);
216 clears the fragment part of this URI reference.
218 void clearFragment();
221 }; }; }; };
223 #endif
225 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */