Zorba
The XQuery Processor
Documentation
Live Demo
Modules
Download
Tools
Blog
Code
Main Page
Related Pages
Classes
Files
Examples
File List
File Members
swig
XmlDataManager.h
Go to the documentation of this file.
1
/*
2
* Copyright 2006-2012 The FLWOR Foundation.
3
*
4
* Licensed under the Apache License, Version 2.0 (the "License");
5
* you may not use this file except in compliance with the License.
6
* You may obtain a copy of the License at
7
*
8
* http://www.apache.org/licenses/LICENSE-2.0
9
*
10
* Unless required by applicable law or agreed to in writing, software
11
* distributed under the License is distributed on an "AS IS" BASIS,
12
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13
* See the License for the specific language governing permissions and
14
* limitations under the License.
15
*/
16
#ifndef API_XML_DATA_MANAGER_H
17
#define API_XML_DATA_MANAGER_H
18
19
/** \brief Using the XmlDataManager one can manage documents and collections.
20
*
21
* The XmlDataManager is a singleton instance. The Zorba object is reponsible
22
* for maintaining its lifetime. The instance can be accessed by calling
23
* getXmlDataManager() on the Zorba object. It may not be accessed anymore
24
* after Zorba::shutdown() has been called.
25
*
26
* XmlDataManager is a thread-safe class.
27
*/
28
class
XmlDataManager
29
{
30
private
:
31
zorba::XmlDataManager* theManager;
32
33
public
:
34
XmlDataManager
(
const
XmlDataManager
& aMgr) : theManager(aMgr.theManager) {}
35
XmlDataManager
(zorba::XmlDataManager* aMgr) : theManager(aMgr) {}
36
37
/** \brief Returns a DocumentManager
38
*
39
* @return The document manager.
40
*
41
*/
42
DocumentManager
getDocumentManager
();
43
44
/** \brief Returns a CollectionManager responsible for all collections.
45
*
46
* The collection manager provides a set of functions for managing
47
* collections identified by a QName and their contents.
48
*
49
* Please note that the resulting manager is only responsible for
50
* dynamic collections identified by a QName, i.e. those that are
51
* not declared in the prolog of a module or identified by a URI.
52
*
53
* @return The collection manager responsible for managing
54
* collections.
55
*
56
*/
57
CollectionManager
getCollectionManager
();
58
59
/** \brief Returns a CollectionManager responsible for collections
60
* identified by a URI.
61
*
62
* The collection manager provides a set of functions for managing
63
* collections identified by a URI and their contents.
64
*
65
* Please note that the resulting manager is only responsible for
66
* dynamic collections identified by a URI, i.e. those that are
67
* not declared in the prolog of a module or identified by a QName.
68
*
69
* @return The collection manager responsible for managing collections.
70
*
71
*/
72
CollectionManager
getW3CCollectionManager
();
73
74
/** \brief Parse an XML document and return an Iterator.
75
*
76
* @param aDoc the input string whose content should be parsed
77
*/
78
Iterator
parseXML
(
const
std::string& aDoc);
79
80
/** \brief Parse an XML document and return an Item.
81
*
82
* @param aDoc the input string whose content should be parsed
83
*/
84
Item
parseXMLtoItem
(
const
std::string& aDoc);
85
86
/** \brief Parse an XML stream and return an Item.
87
*
88
* @param aStream the input string whose content should be parsed
89
*/
90
Item
parseXMLtoItem
(
ZorbaIOStream
& aStream);
91
92
};
93
#endif
Please enable JavaScript to view the
comments powered by Disqus.
blog comments powered by
Disqus