1 /*************************************************************************
3 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
5 * Copyright 2008 by Sun Microsystems, Inc.
7 * OpenOffice.org - a multi-platform office productivity suite
9 * $RCSfile: libxmlutil.hxx,v $
12 * This file is part of OpenOffice.org.
14 * OpenOffice.org is free software: you can redistribute it and/or modify
15 * it under the terms of the GNU Lesser General Public License version 3
16 * only, as published by the Free Software Foundation.
18 * OpenOffice.org is distributed in the hope that it will be useful,
19 * but WITHOUT ANY WARRANTY; without even the implied warranty of
20 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
21 * GNU Lesser General Public License version 3 for more details
22 * (a copy is included in the LICENSE file that accompanied this code).
24 * You should have received a copy of the GNU Lesser General Public License
25 * version 3 along with OpenOffice.org. If not, see
26 * <http://www.openoffice.org/license.html>
27 * for a copy of the LGPLv3 License.
29 ************************************************************************/
30 #if !defined INCLUDED_JVMFWK_LIBXMLUTIL_HXX
31 #define INCLUDED_JVMFWK_LIBXMLUTIL_HXX
34 #include "libxml/parser.h"
35 #include "libxml/xpath.h"
36 //#include "libxml/xpathinternals.h"
37 #include "rtl/ustring.hxx"
42 xmlXPathObject
* _object
;
43 CXPathObjectPtr
& operator = (const CXPathObjectPtr
&);
44 CXPathObjectPtr(const CXPathObjectPtr
&);
47 /** Takes ownership of xmlXPathObject
49 CXPathObjectPtr(xmlXPathObject
* aObject
);
51 /** Takes ownership of xmlXPathObject
53 CXPathObjectPtr
& operator = (xmlXPathObject
* pObj
);
54 xmlXPathObject
* operator -> ();
55 operator xmlXPathObject
* ();
58 //===========================================================
59 class CXPathContextPtr
61 xmlXPathContext
* _object
;
63 CXPathContextPtr(const jfw::CXPathContextPtr
&);
64 CXPathContextPtr
& operator = (const CXPathContextPtr
&);
67 CXPathContextPtr(xmlXPathContextPtr aContext
);
68 CXPathContextPtr
& operator = (xmlXPathContextPtr pObj
);
70 xmlXPathContext
* operator -> ();
71 operator xmlXPathContext
* ();
74 //===========================================================
79 CXmlDocPtr(const CXmlDocPtr
&);
82 CXmlDocPtr
& operator = (const CXmlDocPtr
&);
84 CXmlDocPtr(xmlDoc
* aDoc
);
85 /** Takes ownership of xmlDoc
87 CXmlDocPtr
& operator = (xmlDoc
* pObj
);
89 xmlDoc
* operator -> ();
93 //===========================================================
98 // CXmlNsPtr(const CXmlNsPtr&);
99 // CXmlNsPtr & operator = (const CXmlNsPtr&);
102 // CXmlNsPtr(xmlNs* aDoc);
103 // /** Takes ownership of xmlDoc
105 // CXmlNsPtr & operator = (xmlNs* pObj);
107 // xmlNs* operator -> ();
108 // operator xmlNs* ();
111 //===========================================================
116 CXmlCharPtr(const CXmlCharPtr
&);
117 CXmlCharPtr
& operator = (const CXmlCharPtr
&);
120 CXmlCharPtr(xmlChar
* aDoc
);
121 CXmlCharPtr(const ::rtl::OUString
&);
123 CXmlCharPtr
& operator = (xmlChar
* pObj
);
124 // xmlChar* operator -> ();
125 operator xmlChar
* ();
126 operator ::rtl::OUString ();
127 operator ::rtl::OString ();