1/**************************************************************
2 *
3 * Licensed to the Apache Software Foundation (ASF) under one
4 * or more contributor license agreements.  See the NOTICE file
5 * distributed with this work for additional information
6 * regarding copyright ownership.  The ASF licenses this file
7 * to you under the Apache License, Version 2.0 (the
8 * "License"); you may not use this file except in compliance
9 * with the License.  You may obtain a copy of the License at
10 *
11 *   http://www.apache.org/licenses/LICENSE-2.0
12 *
13 * Unless required by applicable law or agreed to in writing,
14 * software distributed under the License is distributed on an
15 * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
16 * KIND, either express or implied.  See the License for the
17 * specific language governing permissions and limitations
18 * under the License.
19 *
20 *************************************************************/
21
22
23
24#ifndef __com_sun_star_xml_dom_XDOMImplementation_idl__
25#define __com_sun_star_xml_dom_XDOMImplementation_idl__
26
27#ifndef __com_sun_star_uno__XInterface_idl__
28#include <com/sun/star/uno/XInterface.idl>
29#endif
30#ifndef __com_sun_star_xml_dom_DOMException_idl__
31#include <com/sun/star/xml/dom/DOMException.idl>
32#endif
33
34
35module com { module sun { module star { module xml { module dom {
36
37interface XDocument;
38interface XDocumentType;
39
40interface XDOMImplementation : com::sun::star::uno::XInterface
41{
42    /**
43    Creates a DOM Document object of the specified type with its document element.
44    Throws:
45    DOMException - INVALID_CHARACTER_ERR: Raised if the specified qualified name contains an illegal character.
46                   NAMESPACE_ERR: Raised if the qualifiedName is malformed, if the qualifiedName has a prefix
47                      and the namespaceURI is null, or if the qualifiedName has a prefix that is "xml" and
48                      the namespaceURI is different from " http://www.w3.org/XML/1998/namespace" , or if the
49                      DOM implementation does not support the "XML" feature but a non-null namespace URI was
50                      provided, since namespaces were defined by XML.
51                   WRONG_DOCUMENT_ERR: Raised if doctype has already been used with a different document or
52                      was created from a different implementation.
53                   NOT_SUPPORTED_ERR: May be raised by DOM implementations which do not support the
54                      "XML" feature, if they choose not to support this method. Other features introduced
55                      in the future, by the DOM WG or in extensions defined by other groups, may also
56                      demand support for this method; please consult the definition of the feature to see
57                      if it requires this method.
58    */
59    XDocument createDocument([in] string namespaceURI, [in] string qualifiedName, [in] XDocumentType doctype)
60        raises (DOMException);
61
62    /**
63    Creates an empty DocumentType node.
64    Throws:
65    DOMException - INVALID_CHARACTER_ERR: Raised if the specified qualified name contains an illegal character.
66                   NAMESPACE_ERR: Raised if the qualifiedName is malformed.
67                   NOT_SUPPORTED_ERR: May be raised by DOM implementations which do not support the
68                      "XML" feature, if they choose not to support this method. Other features introduced
69                      in the future, by the DOM WG or in extensions defined by other groups, may also demand
70                      support for this method; please consult the definition of the feature to see if it
71                      requires this method.
72    */
73    XDocumentType createDocumentType([in] string qualifiedName, [in] string publicId, [in] string systemId)
74        raises (DOMException);
75
76    /**
77    Test if the DOM implementation implements a specific feature.
78    */
79    boolean hasFeature([in] string feature, [in] string ver);
80};
81
82}; }; }; }; };
83
84#endif
85