1 /* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
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 module com
{ module sun
{ module star
{ module uri
{
22 published
interface XUriReferenceFactory
;
25 creates URI references.
27 <p>See <a href="http://www.ietf.org/rfc/rfc3986.txt">RFC 3986</a> for a
28 description of URI references and related terms.</p>
30 <p>For parsing absolute URI references, this service tries to use a
31 scheme-specific parser. Such a scheme-specific parser will typically enforce
32 additional restrictions during parsing, and will typically return objects
33 that support extra, scheme-specific interfaces in addition to
34 com::sun::star::uri::XUriReference. If no such parser
35 is found, and for relative URI references, a generic parser is used, which
36 returns objects that only support
37 com::sun::star::uri::XUriReference.</p>
39 <p>Locating a scheme-specific parser works as follows: A scheme consists of
41 “<code>A</code>”–“<code>Z</code>”, Latin small
42 letters “<code>a</code>”–“<code>z</code>”,
43 digits “<code>0</code>”–“<code>9</code>”,
44 “<code>+</code>”, “<code>-</code>”, and
45 “<code>.</code>”. A scheme <var>s</var> is transformed into
46 a string <var>s</var>′ character-by-character, by translating
47 Latin capital letters to their small counterparts, translating
48 “<code>+</code>” to “<code>PLUS</code>”,
49 “<code>-</code>” to “<code>HYPHEN</code>”,
50 “<code>.</code>” to “<code>DOT</code>”, and copying
51 Latin small letters and digits unchanged. If the component context used
52 while creating this <code>UriReferenceFactory</code> instance offers a
53 service manager, and there is a service available at that service manager
54 whose name is the concatenation of
55 “<code>com.sun.star.uri.UriSchemeParser_</code>” and
56 <var>s</var>′, then that service is used. It is an error if that
57 service does not support
58 com::sun::star::uri::XUriSchemeParser.</p>
62 published service UriReferenceFactory
: XUriReferenceFactory
;
66 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */