1 | // |
---|---|
2 | // InputSource.cpp |
3 | // |
4 | // Library: XML |
5 | // Package: SAX |
6 | // Module: SAX |
7 | // |
8 | // Copyright (c) 2004-2006, Applied Informatics Software Engineering GmbH. |
9 | // and Contributors. |
10 | // |
11 | // SPDX-License-Identifier: BSL-1.0 |
12 | // |
13 | |
14 | |
15 | #include "Poco/SAX/InputSource.h" |
16 | |
17 | |
18 | namespace Poco { |
19 | namespace XML { |
20 | |
21 | |
22 | InputSource::InputSource(): |
23 | _bistr(0), |
24 | _cistr(0) |
25 | { |
26 | } |
27 | |
28 | |
29 | InputSource::InputSource(const XMLString& systemId): |
30 | _systemId(systemId), |
31 | _bistr(0), |
32 | _cistr(0) |
33 | { |
34 | } |
35 | |
36 | |
37 | InputSource::InputSource(XMLByteInputStream& bistr): |
38 | _bistr(&bistr), |
39 | _cistr(0) |
40 | { |
41 | } |
42 | |
43 | |
44 | InputSource::~InputSource() |
45 | { |
46 | } |
47 | |
48 | |
49 | void InputSource::setPublicId(const XMLString& publicId) |
50 | { |
51 | _publicId = publicId; |
52 | } |
53 | |
54 | |
55 | void InputSource::setSystemId(const XMLString& systemId) |
56 | { |
57 | _systemId = systemId; |
58 | } |
59 | |
60 | |
61 | void InputSource::setEncoding(const XMLString& encoding) |
62 | { |
63 | _encoding = encoding; |
64 | } |
65 | |
66 | |
67 | void InputSource::setByteStream(XMLByteInputStream& bistr) |
68 | { |
69 | _bistr = &bistr; |
70 | } |
71 | |
72 | |
73 | void InputSource::setCharacterStream(XMLCharInputStream& cistr) |
74 | { |
75 | _cistr = &cistr; |
76 | } |
77 | |
78 | |
79 | } } // namespace Poco::XML |
80 | |
81 |