1/************************************************************************* 2 * 3 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 4 * 5 * Copyright 2000, 2010 Oracle and/or its affiliates. 6 * 7 * OpenOffice.org - a multi-platform office productivity suite 8 * 9 * This file is part of OpenOffice.org. 10 * 11 * OpenOffice.org is free software: you can redistribute it and/or modify 12 * it under the terms of the GNU Lesser General Public License version 3 13 * only, as published by the Free Software Foundation. 14 * 15 * OpenOffice.org is distributed in the hope that it will be useful, 16 * but WITHOUT ANY WARRANTY; without even the implied warranty of 17 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 18 * GNU Lesser General Public License version 3 for more details 19 * (a copy is included in the LICENSE file that accompanied this code). 20 * 21 * You should have received a copy of the GNU Lesser General Public License 22 * version 3 along with OpenOffice.org. If not, see 23 * <http://www.openoffice.org/license.html> 24 * for a copy of the LGPLv3 License. 25 * 26 ************************************************************************/ 27 28#ifndef __com_sun_star_xml_XPath_XXPathAPI_idl__ 29#define __com_sun_star_xml_XPath_XXPathAPI_idl__ 30 31#ifndef __com_sun_star_uno_XInterface_idl__ 32#include <com/sun/star/uno/XInterface.idl> 33#endif 34#ifndef __com_sun_star_xml_dom_XNode_idl__ 35#include <com/sun/star/xml/dom/XNode.idl> 36#endif 37#ifndef __com_sun_star_xml_dom_XNodeList_idl__ 38#include <com/sun/star/xml/dom/XNodeList.idl> 39#endif 40#ifndef __com_sun_star_xml_xpath_XXPathObject_idl__ 41#include <com/sun/star/xml/xpath/XXPathObject.idl> 42#endif 43#ifndef __com_sun_star_xml_xpath_XXPathExtension_idl__ 44#include <com/sun/star/xml/xpath/XXPathExtension.idl> 45#endif 46#ifndef __com_sun_star_xml_XPath_XPathException_idl__ 47#include <com/sun/star/xml/xpath/XPathException.idl> 48#endif 49 50 51module com { module sun { module star { module xml { module xpath { 52 53 54interface XXPathAPI : com::sun::star::uno::XInterface 55{ 56 57 void registerNS( 58 [in] string prefix, 59 [in] string url); 60 61 void unregisterNS( 62 [in] string prefix, 63 [in] string url); 64 65 void registerExtension( [in] string serviceName ); 66 void registerExtensionInstance( 67 [in] com::sun::star::xml::xpath::XXPathExtension aExtension); 68 69 /** Eval XPath Expression. 70 71 @param contextNode 72 the context node (expression is relative to this node) 73 74 @param expr 75 the XPath expression 76 77 @throws XPathException 78 if the expression is malformed, or evaluation fails 79 80 @returns 81 an object representing the result of the XPath evaluation 82 83 @see XXPathObject 84 */ 85 XXPathObject eval( 86 [in] com::sun::star::xml::dom::XNode contextNode, 87 [in] string expr) 88 raises( com::sun::star::xml::xpath::XPathException ); 89 90 /** Eval XPath Expression. 91 92 @param contextNode 93 the context node (expression is relative to this node) 94 95 @param expr 96 the XPath expression 97 98 @param namespaceNode 99 all namespaces declared on this node will be registered 100 101 @throws XPathException 102 if the expression is malformed, or evaluation fails 103 104 @returns 105 an object representing the result of the XPath evaluation 106 107 @see XXPathObject 108 */ 109 XXPathObject evalNS( 110 [in] com::sun::star::xml::dom::XNode contextNode, 111 [in] string expr, 112 [in] com::sun::star::xml::dom::XNode namespaceNode) 113 raises( com::sun::star::xml::xpath::XPathException ); 114 115 /** Evaluate an XPath expression to select a list of nodes. 116 117 @param contextNode 118 the context node (expression is relative to this node) 119 120 @param expr 121 the XPath expression 122 123 @throws XPathException 124 if the expression is malformed, or evaluation fails 125 126 @returns 127 result of the XPath evaluation: a list of nodes 128 129 @see XNodeList 130 */ 131 com::sun::star::xml::dom::XNodeList selectNodeList( 132 [in] com::sun::star::xml::dom::XNode contextNode, 133 [in] string expr) 134 raises( com::sun::star::xml::xpath::XPathException ); 135 136 /** Evaluate an XPath expression to select a list of nodes. 137 138 @param contextNode 139 the context node (expression is relative to this node) 140 141 @param expr 142 the XPath expression 143 144 @param namespaceNode 145 all namespaces declared on this node will be registered 146 147 @throws XPathException 148 if the expression is malformed, or evaluation fails 149 150 @returns 151 result of the XPath evaluation: a list of nodes 152 153 @see XNodeList 154 */ 155 com::sun::star::xml::dom::XNodeList selectNodeListNS( 156 [in] com::sun::star::xml::dom::XNode contextNode, 157 [in] string str, 158 [in] com::sun::star::xml::dom::XNode namespaceNode) 159 raises( com::sun::star::xml::xpath::XPathException ); 160 161 /** Evaluate an XPath expression to select a single node. 162 163 @param contextNode 164 the context node (expression is relative to this node) 165 166 @param expr 167 the XPath expression 168 169 @throws XPathException 170 if the expression is malformed, or evaluation fails 171 172 @returns 173 result of the XPath evaluation: a single node 174 */ 175 com::sun::star::xml::dom::XNode selectSingleNode( 176 [in] com::sun::star::xml::dom::XNode contextNode, 177 [in] string expr) 178 raises( com::sun::star::xml::xpath::XPathException ); 179 180 /** Evaluate an XPath expression to select a single node. 181 182 @param contextNode 183 the context node (expression is relative to this node) 184 185 @param expr 186 the XPath expression 187 188 @param namespaceNode 189 all namespaces declared on this node will be registered 190 191 @throws XPathException 192 if the expression is malformed, or evaluation fails 193 194 @returns 195 result of the XPath evaluation: a single node 196 */ 197 com::sun::star::xml::dom::XNode selectSingleNodeNS( 198 [in] com::sun::star::xml::dom::XNode contextNode, 199 [in] string str, 200 [in] com::sun::star::xml::dom::XNode namespaceNode) 201 raises( com::sun::star::xml::xpath::XPathException ); 202 203}; 204 205}; }; }; }; }; 206 207#endif 208