xref: /aoo41x/main/offapi/com/sun/star/rdf/XRepository.idl (revision cdf0e10c)
1*cdf0e10cSrcweir/*************************************************************************
2*cdf0e10cSrcweir *
3*cdf0e10cSrcweir * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
4*cdf0e10cSrcweir *
5*cdf0e10cSrcweir * Copyright 2000, 2010 Oracle and/or its affiliates.
6*cdf0e10cSrcweir *
7*cdf0e10cSrcweir * OpenOffice.org - a multi-platform office productivity suite
8*cdf0e10cSrcweir *
9*cdf0e10cSrcweir * This file is part of OpenOffice.org.
10*cdf0e10cSrcweir *
11*cdf0e10cSrcweir * OpenOffice.org is free software: you can redistribute it and/or modify
12*cdf0e10cSrcweir * it under the terms of the GNU Lesser General Public License version 3
13*cdf0e10cSrcweir * only, as published by the Free Software Foundation.
14*cdf0e10cSrcweir *
15*cdf0e10cSrcweir * OpenOffice.org is distributed in the hope that it will be useful,
16*cdf0e10cSrcweir * but WITHOUT ANY WARRANTY; without even the implied warranty of
17*cdf0e10cSrcweir * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
18*cdf0e10cSrcweir * GNU Lesser General Public License version 3 for more details
19*cdf0e10cSrcweir * (a copy is included in the LICENSE file that accompanied this code).
20*cdf0e10cSrcweir *
21*cdf0e10cSrcweir * You should have received a copy of the GNU Lesser General Public License
22*cdf0e10cSrcweir * version 3 along with OpenOffice.org.  If not, see
23*cdf0e10cSrcweir * <http://www.openoffice.org/license.html>
24*cdf0e10cSrcweir * for a copy of the LGPLv3 License.
25*cdf0e10cSrcweir *
26*cdf0e10cSrcweir ************************************************************************/
27*cdf0e10cSrcweir
28*cdf0e10cSrcweir#ifndef __com_sun_star_rdf_XRepository_idl__
29*cdf0e10cSrcweir#define __com_sun_star_rdf_XRepository_idl__
30*cdf0e10cSrcweir
31*cdf0e10cSrcweir#ifndef __com_sun_star_lang_IllegalArgumentException_idl__
32*cdf0e10cSrcweir#include <com/sun/star/lang/IllegalArgumentException.idl>
33*cdf0e10cSrcweir#endif
34*cdf0e10cSrcweir
35*cdf0e10cSrcweir#ifndef __com_sun_star_container_ElementExistException_idl__
36*cdf0e10cSrcweir#include <com/sun/star/container/ElementExistException.idl>
37*cdf0e10cSrcweir#endif
38*cdf0e10cSrcweir
39*cdf0e10cSrcweir#ifndef __com_sun_star_container_NoSuchElementException_idl__
40*cdf0e10cSrcweir#include <com/sun/star/container/NoSuchElementException.idl>
41*cdf0e10cSrcweir#endif
42*cdf0e10cSrcweir
43*cdf0e10cSrcweir#ifndef __com_sun_star_container_XEnumeration_idl__
44*cdf0e10cSrcweir#include <com/sun/star/container/XEnumeration.idl>
45*cdf0e10cSrcweir#endif
46*cdf0e10cSrcweir
47*cdf0e10cSrcweir#ifndef __com_sun_star_io_IOException_idl__
48*cdf0e10cSrcweir#include <com/sun/star/io/IOException.idl>
49*cdf0e10cSrcweir#endif
50*cdf0e10cSrcweir
51*cdf0e10cSrcweir#ifndef __com_sun_star_io_XInputStream_idl__
52*cdf0e10cSrcweir#include <com/sun/star/io/XInputStream.idl>
53*cdf0e10cSrcweir#endif
54*cdf0e10cSrcweir
55*cdf0e10cSrcweir#ifndef __com_sun_star_io_XOutputStream_idl__
56*cdf0e10cSrcweir#include <com/sun/star/io/XOutputStream.idl>
57*cdf0e10cSrcweir#endif
58*cdf0e10cSrcweir
59*cdf0e10cSrcweir#ifndef __com_sun_star_datatransfer_UnsupportedFlavorException_idl__
60*cdf0e10cSrcweir#include <com/sun/star/datatransfer/UnsupportedFlavorException.idl>
61*cdf0e10cSrcweir#endif
62*cdf0e10cSrcweir
63*cdf0e10cSrcweir#ifndef __com_sun_star_rdf_FileFormat_idl__
64*cdf0e10cSrcweir#include <com/sun/star/rdf/FileFormat.idl>
65*cdf0e10cSrcweir#endif
66*cdf0e10cSrcweir
67*cdf0e10cSrcweir#ifndef __com_sun_star_rdf_ParseException_idl__
68*cdf0e10cSrcweir#include <com/sun/star/rdf/ParseException.idl>
69*cdf0e10cSrcweir#endif
70*cdf0e10cSrcweir
71*cdf0e10cSrcweir#ifndef __com_sun_star_rdf_QueryException_idl__
72*cdf0e10cSrcweir#include <com/sun/star/rdf/QueryException.idl>
73*cdf0e10cSrcweir#endif
74*cdf0e10cSrcweir
75*cdf0e10cSrcweir#ifndef __com_sun_star_rdf_RepositoryException_idl__
76*cdf0e10cSrcweir#include <com/sun/star/rdf/RepositoryException.idl>
77*cdf0e10cSrcweir#endif
78*cdf0e10cSrcweir
79*cdf0e10cSrcweir#ifndef __com_sun_star_rdf_XBlankNode_idl__
80*cdf0e10cSrcweir#include <com/sun/star/rdf/XBlankNode.idl>
81*cdf0e10cSrcweir#endif
82*cdf0e10cSrcweir
83*cdf0e10cSrcweir#ifndef __com_sun_star_rdf_XURI_idl__
84*cdf0e10cSrcweir#include <com/sun/star/rdf/XURI.idl>
85*cdf0e10cSrcweir#endif
86*cdf0e10cSrcweir
87*cdf0e10cSrcweir#ifndef __com_sun_star_rdf_Statement_idl__
88*cdf0e10cSrcweir#include <com/sun/star/rdf/Statement.idl>
89*cdf0e10cSrcweir#endif
90*cdf0e10cSrcweir
91*cdf0e10cSrcweir#ifndef __com_sun_star_rdf_XQuerySelectResult_idl__
92*cdf0e10cSrcweir#include <com/sun/star/rdf/XQuerySelectResult.idl>
93*cdf0e10cSrcweir#endif
94*cdf0e10cSrcweir
95*cdf0e10cSrcweir#ifndef __com_sun_star_rdf_XNamedGraph_idl__
96*cdf0e10cSrcweir#include <com/sun/star/rdf/XNamedGraph.idl>
97*cdf0e10cSrcweir#endif
98*cdf0e10cSrcweir
99*cdf0e10cSrcweir
100*cdf0e10cSrcweir//=============================================================================
101*cdf0e10cSrcweir
102*cdf0e10cSrcweirmodule com {   module sun {   module star {   module rdf {
103*cdf0e10cSrcweir
104*cdf0e10cSrcweir//=============================================================================
105*cdf0e10cSrcweir/** provides access to a set of named RDF graphs.
106*cdf0e10cSrcweir
107*cdf0e10cSrcweir    <p>
108*cdf0e10cSrcweir    A repository for storing information according to the data model of the
109*cdf0e10cSrcweir    <a href="http://www.w3.org/RDF/">Resource Description Framework</a>.
110*cdf0e10cSrcweir    This interface may be used e.g. for repositories that correspond to a
111*cdf0e10cSrcweir    loaded ODF document, or for repositories that are backed by some kind of
112*cdf0e10cSrcweir    database.
113*cdf0e10cSrcweir    </p>
114*cdf0e10cSrcweir    <p>
115*cdf0e10cSrcweir    The RDF triples are stored as a set of named RDF graphs.
116*cdf0e10cSrcweir    Importing and exporting files in the
117*cdf0e10cSrcweir    <a href="http://www.w3.org/TR/rdf-syntax-grammar/">RDF/XML</a>
118*cdf0e10cSrcweir    format is supported.
119*cdf0e10cSrcweir    Support for other file formats is optional.
120*cdf0e10cSrcweir    Support for querying the repository with the
121*cdf0e10cSrcweir    <a href="http://www.w3.org/TR/rdf-sparql-query/">SPARQL</a>
122*cdf0e10cSrcweir    query language is provided.
123*cdf0e10cSrcweir    </p>
124*cdf0e10cSrcweir
125*cdf0e10cSrcweir
126*cdf0e10cSrcweir    @since OOo 3.2
127*cdf0e10cSrcweir
128*cdf0e10cSrcweir    @see XRepositorySupplier
129*cdf0e10cSrcweir    @see XDocumentRepository
130*cdf0e10cSrcweir */
131*cdf0e10cSrcweirinterface XRepository
132*cdf0e10cSrcweir{
133*cdf0e10cSrcweir
134*cdf0e10cSrcweir    //-------------------------------------------------------------------------
135*cdf0e10cSrcweir    /** creates a fresh unique blank node.
136*cdf0e10cSrcweir
137*cdf0e10cSrcweir        @returns
138*cdf0e10cSrcweir            a newly generated blank node which is unique in this repository
139*cdf0e10cSrcweir     */
140*cdf0e10cSrcweir    XBlankNode createBlankNode();
141*cdf0e10cSrcweir
142*cdf0e10cSrcweir
143*cdf0e10cSrcweir    //-------------------------------------------------------------------------
144*cdf0e10cSrcweir    /** imports a named graph into the repository.
145*cdf0e10cSrcweir
146*cdf0e10cSrcweir        <p>
147*cdf0e10cSrcweir        Implementations must support RDF/XML format.
148*cdf0e10cSrcweir        Support for other RDF formats is optional.
149*cdf0e10cSrcweir        If the format is not supported by the implementation, an
150*cdf0e10cSrcweir        <type scope="com::sun::star::datatransfer">UnsupportedFlavorException
151*cdf0e10cSrcweir        </type> is raised.
152*cdf0e10cSrcweir        If the format requires use of a BaseURI, but none is given, an
153*cdf0e10cSrcweir        <type scope="com::sun::star::lang">IllegalArgumentException</type>
154*cdf0e10cSrcweir        is raised.
155*cdf0e10cSrcweir        </p>
156*cdf0e10cSrcweir
157*cdf0e10cSrcweir        @param Format
158*cdf0e10cSrcweir            the format of the input file
159*cdf0e10cSrcweir
160*cdf0e10cSrcweir        @param InStream
161*cdf0e10cSrcweir            the input stream, containing an RDF file in the specified format
162*cdf0e10cSrcweir
163*cdf0e10cSrcweir        @param GraphName
164*cdf0e10cSrcweir            the name of the graph that is imported
165*cdf0e10cSrcweir
166*cdf0e10cSrcweir        @param BaseURI
167*cdf0e10cSrcweir            a base URI to resolve relative URI references
168*cdf0e10cSrcweir
169*cdf0e10cSrcweir        @returns
170*cdf0e10cSrcweir            the imported graph
171*cdf0e10cSrcweir
172*cdf0e10cSrcweir        @throws com::sun::star::lang::IllegalArgumentException
173*cdf0e10cSrcweir            if the given stream or the GraphName is <NULL/>,
174*cdf0e10cSrcweir            or BaseURI is <NULL/> and the format requires use of a base URI
175*cdf0e10cSrcweir
176*cdf0e10cSrcweir        @throws com::sun::star::datatransfer::UnsupportedFlavorException
177*cdf0e10cSrcweir            if the format requested is unknown or not supported
178*cdf0e10cSrcweir
179*cdf0e10cSrcweir        @throws com::sun::star::container::ElementExistException
180*cdf0e10cSrcweir            if a graph with the given GraphName already exists in the
181*cdf0e10cSrcweir            repository
182*cdf0e10cSrcweir
183*cdf0e10cSrcweir        @throws ParseException
184*cdf0e10cSrcweir            if the input does not conform to the specified file format.
185*cdf0e10cSrcweir
186*cdf0e10cSrcweir        @throws RepositoryException
187*cdf0e10cSrcweir            if an error occurs when accessing the repository.
188*cdf0e10cSrcweir
189*cdf0e10cSrcweir        @throws com::sun::star::io::IOException
190*cdf0e10cSrcweir            if an I/O error occurs.
191*cdf0e10cSrcweir
192*cdf0e10cSrcweir        @see FileFormat
193*cdf0e10cSrcweir     */
194*cdf0e10cSrcweir    XNamedGraph importGraph([in] /*FileFormat*/ short Format,
195*cdf0e10cSrcweir                [in] com::sun::star::io::XInputStream InStream,
196*cdf0e10cSrcweir                [in] XURI GraphName, [in] XURI BaseURI)
197*cdf0e10cSrcweir        raises( com::sun::star::lang::IllegalArgumentException,
198*cdf0e10cSrcweir                com::sun::star::datatransfer::UnsupportedFlavorException,
199*cdf0e10cSrcweir                com::sun::star::container::ElementExistException,
200*cdf0e10cSrcweir                ParseException,
201*cdf0e10cSrcweir                RepositoryException,
202*cdf0e10cSrcweir                com::sun::star::io::IOException );
203*cdf0e10cSrcweir
204*cdf0e10cSrcweir    //-------------------------------------------------------------------------
205*cdf0e10cSrcweir    /** exports a named graph from the repository.
206*cdf0e10cSrcweir
207*cdf0e10cSrcweir        <p>
208*cdf0e10cSrcweir        Implementations must support RDF/XML format.
209*cdf0e10cSrcweir        Support for other RDF formats is optional.
210*cdf0e10cSrcweir        If the format is not supported by the implementation, an
211*cdf0e10cSrcweir        <type scope="com::sun::star::datatransfer">UnsupportedFlavorException
212*cdf0e10cSrcweir        </type> is raised.
213*cdf0e10cSrcweir        </p>
214*cdf0e10cSrcweir
215*cdf0e10cSrcweir        @param Format
216*cdf0e10cSrcweir            the format of the output file
217*cdf0e10cSrcweir
218*cdf0e10cSrcweir        @param OutStream
219*cdf0e10cSrcweir            the target output stream
220*cdf0e10cSrcweir
221*cdf0e10cSrcweir        @param GraphName
222*cdf0e10cSrcweir            the name of the graph that is to be exported
223*cdf0e10cSrcweir
224*cdf0e10cSrcweir        @param BaseURI
225*cdf0e10cSrcweir            a base URI to resolve relative URI references
226*cdf0e10cSrcweir
227*cdf0e10cSrcweir        @throws com::sun::star::lang::IllegalArgumentException
228*cdf0e10cSrcweir            if the given stream or the GraphName is <NULL/>,
229*cdf0e10cSrcweir            or BaseURI is <NULL/> and the format requires use of a base URI
230*cdf0e10cSrcweir
231*cdf0e10cSrcweir        @throws com::sun::star::datatransfer::UnsupportedFlavorException
232*cdf0e10cSrcweir            if the format requested is unknown or not supported
233*cdf0e10cSrcweir
234*cdf0e10cSrcweir        @throws com::sun::star::container::NoSuchElementException
235*cdf0e10cSrcweir            if a graph with the given GraphName does not exist
236*cdf0e10cSrcweir
237*cdf0e10cSrcweir        @throws RepositoryException
238*cdf0e10cSrcweir            if an error occurs when accessing the repository.
239*cdf0e10cSrcweir
240*cdf0e10cSrcweir        @throws com::sun::star::io::IOException
241*cdf0e10cSrcweir            if an I/O error occurs.
242*cdf0e10cSrcweir
243*cdf0e10cSrcweir        @see FileFormat
244*cdf0e10cSrcweir     */
245*cdf0e10cSrcweir    void exportGraph([in] /*FileFormat*/ short Format,
246*cdf0e10cSrcweir                [in] com::sun::star::io::XOutputStream OutStream,
247*cdf0e10cSrcweir                [in] XURI GraphName, [in] XURI BaseURI)
248*cdf0e10cSrcweir        raises( com::sun::star::lang::IllegalArgumentException,
249*cdf0e10cSrcweir                com::sun::star::datatransfer::UnsupportedFlavorException,
250*cdf0e10cSrcweir                com::sun::star::container::NoSuchElementException,
251*cdf0e10cSrcweir                RepositoryException,
252*cdf0e10cSrcweir                com::sun::star::io::IOException );
253*cdf0e10cSrcweir
254*cdf0e10cSrcweir    //-------------------------------------------------------------------------
255*cdf0e10cSrcweir    /** gets the names of all the graphs in the repository.
256*cdf0e10cSrcweir
257*cdf0e10cSrcweir        @returns
258*cdf0e10cSrcweir            a list containing the names of the graphs in the repository
259*cdf0e10cSrcweir
260*cdf0e10cSrcweir        @throws RepositoryException
261*cdf0e10cSrcweir            if an error occurs when accessing the repository.
262*cdf0e10cSrcweir     */
263*cdf0e10cSrcweir    sequence<XURI> getGraphNames()
264*cdf0e10cSrcweir        raises( RepositoryException );
265*cdf0e10cSrcweir
266*cdf0e10cSrcweir    //-------------------------------------------------------------------------
267*cdf0e10cSrcweir    /** gets a graph by its name.
268*cdf0e10cSrcweir
269*cdf0e10cSrcweir        @param GraphName
270*cdf0e10cSrcweir            the name of the graph that is to be returned
271*cdf0e10cSrcweir
272*cdf0e10cSrcweir        @returns
273*cdf0e10cSrcweir            the graph with the given name if it exists, else <NULL/>
274*cdf0e10cSrcweir
275*cdf0e10cSrcweir        @throws com::sun::star::lang::IllegalArgumentException
276*cdf0e10cSrcweir            if the given GraphName is invalid
277*cdf0e10cSrcweir
278*cdf0e10cSrcweir        @throws RepositoryException
279*cdf0e10cSrcweir            if an error occurs when accessing the repository.
280*cdf0e10cSrcweir     */
281*cdf0e10cSrcweir    XNamedGraph getGraph([in] XURI GraphName)
282*cdf0e10cSrcweir        raises( com::sun::star::lang::IllegalArgumentException,
283*cdf0e10cSrcweir                RepositoryException );
284*cdf0e10cSrcweir
285*cdf0e10cSrcweir    //-------------------------------------------------------------------------
286*cdf0e10cSrcweir    /** creates a graph with the given name.
287*cdf0e10cSrcweir
288*cdf0e10cSrcweir        <p>
289*cdf0e10cSrcweir        The name must be unique within the repository.
290*cdf0e10cSrcweir        </p>
291*cdf0e10cSrcweir
292*cdf0e10cSrcweir        @param GraphName
293*cdf0e10cSrcweir            the name of the graph that is to be created
294*cdf0e10cSrcweir
295*cdf0e10cSrcweir        @returns
296*cdf0e10cSrcweir            the graph with the given name
297*cdf0e10cSrcweir
298*cdf0e10cSrcweir        @throws com::sun::star::lang::IllegalArgumentException
299*cdf0e10cSrcweir            if the given GraphName is invalid
300*cdf0e10cSrcweir
301*cdf0e10cSrcweir        @throws com::sun::star::container::ElementExistException
302*cdf0e10cSrcweir            if a graph with the given GraphName already exists
303*cdf0e10cSrcweir
304*cdf0e10cSrcweir        @throws RepositoryException
305*cdf0e10cSrcweir            if an error occurs when accessing the repository.
306*cdf0e10cSrcweir     */
307*cdf0e10cSrcweir    XNamedGraph createGraph([in] XURI GraphName)
308*cdf0e10cSrcweir        raises( com::sun::star::lang::IllegalArgumentException,
309*cdf0e10cSrcweir                com::sun::star::container::ElementExistException,
310*cdf0e10cSrcweir                RepositoryException );
311*cdf0e10cSrcweir
312*cdf0e10cSrcweir    //-------------------------------------------------------------------------
313*cdf0e10cSrcweir    /** destroys the graph with the given name, and removes it from the
314*cdf0e10cSrcweir        repository.
315*cdf0e10cSrcweir
316*cdf0e10cSrcweir        <p>
317*cdf0e10cSrcweir        This invalidates any instances of <type>XNamedGraph</type>
318*cdf0e10cSrcweir        for the argument.
319*cdf0e10cSrcweir        </p>
320*cdf0e10cSrcweir
321*cdf0e10cSrcweir        @param GraphName
322*cdf0e10cSrcweir            the name of the graph that is to be destroyed
323*cdf0e10cSrcweir
324*cdf0e10cSrcweir        @throws com::sun::star::lang::IllegalArgumentException
325*cdf0e10cSrcweir            if the given GraphName is invalid
326*cdf0e10cSrcweir
327*cdf0e10cSrcweir        @throws com::sun::star::container::NoSuchElementException
328*cdf0e10cSrcweir            if a graph with the given GraphName does not exist
329*cdf0e10cSrcweir
330*cdf0e10cSrcweir        @throws RepositoryException
331*cdf0e10cSrcweir            if an error occurs when accessing the repository.
332*cdf0e10cSrcweir     */
333*cdf0e10cSrcweir    void destroyGraph([in] XURI GraphName)
334*cdf0e10cSrcweir        raises( com::sun::star::lang::IllegalArgumentException,
335*cdf0e10cSrcweir                com::sun::star::container::NoSuchElementException,
336*cdf0e10cSrcweir                RepositoryException );
337*cdf0e10cSrcweir
338*cdf0e10cSrcweir    //-------------------------------------------------------------------------
339*cdf0e10cSrcweir    /** gets matching RDF statements from the repository.
340*cdf0e10cSrcweir
341*cdf0e10cSrcweir        <p>
342*cdf0e10cSrcweir        Any parameter may be <NULL/>, which acts as a wildcard.
343*cdf0e10cSrcweir        For example, to get all statements about myURI:
344*cdf0e10cSrcweir        <code>getStatements(myURI, null, null)</code>
345*cdf0e10cSrcweir        </p>
346*cdf0e10cSrcweir
347*cdf0e10cSrcweir        @param Subject
348*cdf0e10cSrcweir            the subject of the RDF triple.
349*cdf0e10cSrcweir
350*cdf0e10cSrcweir        @param Predicate
351*cdf0e10cSrcweir            the predicate of the RDF triple.
352*cdf0e10cSrcweir
353*cdf0e10cSrcweir        @param Object
354*cdf0e10cSrcweir            the object of the RDF triple.
355*cdf0e10cSrcweir
356*cdf0e10cSrcweir        @returns
357*cdf0e10cSrcweir            an iterator over all RDF statements in the repository that match
358*cdf0e10cSrcweir            the parameters, represented as an
359*cdf0e10cSrcweir            enumeration of <type>Statement</type>
360*cdf0e10cSrcweir
361*cdf0e10cSrcweir        @throws RepositoryException
362*cdf0e10cSrcweir            if an error occurs when accessing the repository.
363*cdf0e10cSrcweir
364*cdf0e10cSrcweir        @see Statement
365*cdf0e10cSrcweir        @see XNamedGraph::getStatements
366*cdf0e10cSrcweir     */
367*cdf0e10cSrcweir    com::sun::star::container::XEnumeration/*<Statement>*/ getStatements(
368*cdf0e10cSrcweir            [in] XResource Subject,
369*cdf0e10cSrcweir            [in] XURI Predicate,
370*cdf0e10cSrcweir            [in] XNode Object)
371*cdf0e10cSrcweir        raises( RepositoryException );
372*cdf0e10cSrcweir
373*cdf0e10cSrcweir
374*cdf0e10cSrcweir    //-------------------------------------------------------------------------
375*cdf0e10cSrcweir    /** executes a SPARQL "SELECT" query.
376*cdf0e10cSrcweir
377*cdf0e10cSrcweir        <p>
378*cdf0e10cSrcweir        This method runs a SPARQL query that returns a list of variable
379*cdf0e10cSrcweir        bindings, i.e., a query beginning with "SELECT".
380*cdf0e10cSrcweir        The result is basically a (rectangular) table with labeled columns,
381*cdf0e10cSrcweir        where individual cells may be <NULL/>.
382*cdf0e10cSrcweir        </p>
383*cdf0e10cSrcweir
384*cdf0e10cSrcweir        @param Query
385*cdf0e10cSrcweir            the SPARQL query <atom>string</atom>
386*cdf0e10cSrcweir
387*cdf0e10cSrcweir        @returns
388*cdf0e10cSrcweir            an enumeration, containing
389*cdf0e10cSrcweir            <ol>
390*cdf0e10cSrcweir            <li>a list of query variable names (column labels)</li>
391*cdf0e10cSrcweir            <li>the query results (rows),
392*cdf0e10cSrcweir                each being a list of bindings for the above variables</li>
393*cdf0e10cSrcweir            </ol>
394*cdf0e10cSrcweir
395*cdf0e10cSrcweir        @throws QueryException
396*cdf0e10cSrcweir            if the query is malformed, or evaluation fails
397*cdf0e10cSrcweir
398*cdf0e10cSrcweir        @throws RepositoryException
399*cdf0e10cSrcweir            if an error occurs when accessing the repository.
400*cdf0e10cSrcweir
401*cdf0e10cSrcweir        @see XQuerySelectResult
402*cdf0e10cSrcweir     */
403*cdf0e10cSrcweir    XQuerySelectResult querySelect([in] string Query)
404*cdf0e10cSrcweir        raises( QueryException,
405*cdf0e10cSrcweir                RepositoryException );
406*cdf0e10cSrcweir
407*cdf0e10cSrcweir    //-------------------------------------------------------------------------
408*cdf0e10cSrcweir    /** executes a SPARQL "CONSTRUCT" query.
409*cdf0e10cSrcweir
410*cdf0e10cSrcweir        <p>
411*cdf0e10cSrcweir        This method runs a SPARQL query that constructs a result graph,
412*cdf0e10cSrcweir        i.e., a query beginning with "CONSTRUCT".
413*cdf0e10cSrcweir        </p>
414*cdf0e10cSrcweir
415*cdf0e10cSrcweir        @param Query
416*cdf0e10cSrcweir            the SPARQL query <atom>string</atom>
417*cdf0e10cSrcweir
418*cdf0e10cSrcweir        @returns
419*cdf0e10cSrcweir            an iterator over the query result graph, represented as an
420*cdf0e10cSrcweir            enumeration of <type>Statement</type>
421*cdf0e10cSrcweir
422*cdf0e10cSrcweir        @throws QueryException
423*cdf0e10cSrcweir            if the query is malformed, or evaluation fails
424*cdf0e10cSrcweir
425*cdf0e10cSrcweir        @throws RepositoryException
426*cdf0e10cSrcweir            if an error occurs when accessing the repository.
427*cdf0e10cSrcweir
428*cdf0e10cSrcweir        @see Statement
429*cdf0e10cSrcweir     */
430*cdf0e10cSrcweir    com::sun::star::container::XEnumeration/*<Statement>*/ queryConstruct(
431*cdf0e10cSrcweir            [in] string Query)
432*cdf0e10cSrcweir        raises( QueryException,
433*cdf0e10cSrcweir                RepositoryException );
434*cdf0e10cSrcweir
435*cdf0e10cSrcweir    //-------------------------------------------------------------------------
436*cdf0e10cSrcweir    /** executes a SPARQL "ASK" query.
437*cdf0e10cSrcweir
438*cdf0e10cSrcweir        <p>
439*cdf0e10cSrcweir        This method runs a SPARQL query that computes a boolean,
440*cdf0e10cSrcweir        i.e., a query beginning with "ASK".
441*cdf0e10cSrcweir        </p>
442*cdf0e10cSrcweir
443*cdf0e10cSrcweir        @param Query
444*cdf0e10cSrcweir            the SPARQL query <atom>string</atom>
445*cdf0e10cSrcweir
446*cdf0e10cSrcweir        @returns
447*cdf0e10cSrcweir            the boolean query result
448*cdf0e10cSrcweir
449*cdf0e10cSrcweir        @throws QueryException
450*cdf0e10cSrcweir            if the query is malformed, or evaluation fails
451*cdf0e10cSrcweir
452*cdf0e10cSrcweir        @throws RepositoryException
453*cdf0e10cSrcweir            if an error occurs when accessing the repository.
454*cdf0e10cSrcweir     */
455*cdf0e10cSrcweir    boolean queryAsk([in] string Query)
456*cdf0e10cSrcweir        raises( QueryException,
457*cdf0e10cSrcweir                RepositoryException );
458*cdf0e10cSrcweir
459*cdf0e10cSrcweir};
460*cdf0e10cSrcweir
461*cdf0e10cSrcweir//=============================================================================
462*cdf0e10cSrcweir
463*cdf0e10cSrcweir}; }; }; };
464*cdf0e10cSrcweir
465*cdf0e10cSrcweir#endif
466