Xerces-C++ 3.2.4

URLInputSource.hpp
Go to the documentation of this file.
1/*
2 * Licensed to the Apache Software Foundation (ASF) under one or more
3 * contributor license agreements. See the NOTICE file distributed with
4 * this work for additional information regarding copyright ownership.
5 * The ASF licenses this file to You under the Apache License, Version 2.0
6 * (the "License"); you may not use this file except in compliance with
7 * the License. You may obtain a copy of the License at
8 *
9 * http://www.apache.org/licenses/LICENSE-2.0
10 *
11 * Unless required by applicable law or agreed to in writing, software
12 * distributed under the License is distributed on an "AS IS" BASIS,
13 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 * See the License for the specific language governing permissions and
15 * limitations under the License.
16 */
17
18/*
19 * $Id$
20 */
21
22#if !defined(XERCESC_INCLUDE_GUARD_URLINPUTSOURCE_HPP)
23#define XERCESC_INCLUDE_GUARD_URLINPUTSOURCE_HPP
24
25#include <xercesc/util/XMLURL.hpp>
26#include <xercesc/sax/InputSource.hpp>
27
28 XERCES_CPP_NAMESPACE_BEGIN
29
30 class BinInputStream;
31
47 class XMLPARSER_EXPORT URLInputSource : public InputSource
48{
49public :
50 // -----------------------------------------------------------------------
51 // Constructors and Destructor
52 // -----------------------------------------------------------------------
53
56
68 URLInputSource
69 (
70 const XMLURL& urlId
71 , MemoryManager* const manager = XMLPlatformUtils::fgMemoryManager
72 );
73
74
89 URLInputSource
90 (
91 const XMLCh* const baseId
92 , const XMLCh* const systemId
93 , MemoryManager* const manager = XMLPlatformUtils::fgMemoryManager
94 );
95
112 URLInputSource
113 (
114 const XMLCh* const baseId
115 , const XMLCh* const systemId
116 , const XMLCh* const publicId
117 , MemoryManager* const manager = XMLPlatformUtils::fgMemoryManager
118 );
119
120
135 URLInputSource
136 (
137 const XMLCh* const baseId
138 , const char* const systemId
139 , MemoryManager* const manager = XMLPlatformUtils::fgMemoryManager
140 );
141
160 URLInputSource
161 (
162 const XMLCh* const baseId
163 , const char* const systemId
164 , const char* const publicId
165 , MemoryManager* const manager = XMLPlatformUtils::fgMemoryManager
166 );
167
169
172 ~URLInputSource();
174
175
176 // -----------------------------------------------------------------------
177 // Virtual input source interface
178 // -----------------------------------------------------------------------
179
182
187 BinInputStream* makeStream() const;
188
190
191
192 // -----------------------------------------------------------------------
193 // Getter methods
194 // -----------------------------------------------------------------------
195
198
207 const XMLURL& urlSrc() const;
208
210
211
212private :
213 // -----------------------------------------------------------------------
214 // Unimplemented constructors and operators
215 // -----------------------------------------------------------------------
216 URLInputSource(const URLInputSource&);
217 URLInputSource& operator=(const URLInputSource&);
218
219 // -----------------------------------------------------------------------
220 // Private data members
221 //
222 // fURL
223 // This is the URL created from the passed ids.
224 // -----------------------------------------------------------------------
225 XMLURL fURL;
226};
227
228
229 inline const XMLURL& URLInputSource::urlSrc() const
230{
231 return fURL;
232}
233
234 XERCES_CPP_NAMESPACE_END
235
236#endif
InputSource.hpp
XMLURL.hpp
XMLPARSER_EXPORT
#define XMLPARSER_EXPORT
Definition: XercesDefs.hpp:163
XERCES_CPP_NAMESPACE_BEGIN
#define XERCES_CPP_NAMESPACE_BEGIN
Definition: XercesDefs.hpp:112
XERCES_CPP_NAMESPACE_END
#define XERCES_CPP_NAMESPACE_END
Definition: XercesDefs.hpp:113
XMLCh
uint16_t XMLCh
Definition: Xerces_autoconf_config.hpp:120
BinInputStream
Definition: BinInputStream.hpp:30
InputSource
A single input source for an XML entity.
Definition: InputSource.hpp:63
MemoryManager
Configurable memory manager.
Definition: MemoryManager.hpp:40
URLInputSource
This class is a derivative of the standard InputSource class.
Definition: URLInputSource.hpp:48
URLInputSource::URLInputSource
URLInputSource(const XMLCh *const baseId, const char *const systemId, const char *const publicId, MemoryManager *const manager=XMLPlatformUtils::fgMemoryManager)
This constructor is identical to the third constructor above, except that it accepts the relative and...
URLInputSource::URLInputSource
URLInputSource(const XMLCh *const baseId, const char *const systemId, MemoryManager *const manager=XMLPlatformUtils::fgMemoryManager)
This constructor is identical to the second constructor above, except that it accepts the relative sy...
URLInputSource::URLInputSource
URLInputSource(const XMLCh *const baseId, const XMLCh *const systemId, MemoryManager *const manager=XMLPlatformUtils::fgMemoryManager)
This constructor takes a base system id URL and a possibly relative system id.
URLInputSource::~URLInputSource
~URLInputSource()
URLInputSource::URLInputSource
URLInputSource(const XMLCh *const baseId, const XMLCh *const systemId, const XMLCh *const publicId, MemoryManager *const manager=XMLPlatformUtils::fgMemoryManager)
This constructor is identical to the previous one, except that it also allows you to set a public id ...
URLInputSource::makeStream
BinInputStream * makeStream() const
This method will return a binary input stream derivative that will parse from the source referred to ...
URLInputSource::urlSrc
const XMLURL & urlSrc() const
This method will return a const reference to the URL member which contains the system id in pre-parse...
Definition: URLInputSource.hpp:229
URLInputSource::URLInputSource
URLInputSource(const XMLURL &urlId, MemoryManager *const manager=XMLPlatformUtils::fgMemoryManager)
This constructor accepts an already built URL.
XMLPlatformUtils::fgMemoryManager
static MemoryManager * fgMemoryManager
The configurable memory manager.
Definition: PlatformUtils.hpp:121
XMLURL
Definition: XMLURL.hpp:36