Xalan-C++ API Reference
1.12.0
xalanc
XSLT
ElemTextLiteral.hpp
Go to the documentation of this file.
1
/*
2
* Licensed to the Apache Software Foundation (ASF) under one
3
* or more contributor license agreements. See the NOTICE file
4
* distributed with this work for additional information
5
* regarding copyright ownership. The ASF licenses this file
6
* to you under the Apache License, Version 2.0 (the "License");
7
* you may not use this file except in compliance with the License.
8
* You may obtain a copy of the License at
9
*
10
* http://www.apache.org/licenses/LICENSE-2.0
11
*
12
* Unless required by applicable law or agreed to in writing, software
13
* distributed under the License is distributed on an "AS IS" BASIS,
14
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
15
* See the License for the specific language governing permissions and
16
* limitations under the License.
17
*/
18
#if !defined(XALAN_ELEMTEXTLITERAL_HEADER_GUARD)
19
#define XALAN_ELEMTEXTLITERAL_HEADER_GUARD
20
21
22
// Base include file. Must be first.
23
#include "
XSLTDefinitions.hpp
"
24
25
26
27
#include <
xalanc/XalanDOM/XalanDOMString.hpp
>
28
29
30
31
// Base class header file.
32
#include "
ElemTemplateElement.hpp
"
33
34
35
36
namespace
XALAN_CPP_NAMESPACE
{
37
38
39
40
class
ElemTextLiteral
:
public
ElemTemplateElement
41
{
42
public
:
43
44
/**
45
* Construct an object corresponding to literal text element
46
*
47
* @param constructionContext context for construction of object
48
* @param stylesheetTree stylesheet containing element
49
* @param lineNumber line number in document
50
* @param columnNumber column number in document
51
* @param ch pointer to character string for element
52
* @param start starting offset of element
53
* @param length number of characters in element
54
* @param fPreserveSpace true is space should be preserved
55
* @param fDisableOutputEscaping true if output escaping should be disabled
56
*/
57
ElemTextLiteral
(
58
StylesheetConstructionContext
& constructionContext,
59
Stylesheet
& stylesheetTree,
60
XalanFileLoc lineNumber,
61
XalanFileLoc columnNumber,
62
const
XalanDOMChar* ch,
63
XalanDOMString::size_type
start,
64
XalanDOMString::size_type
length
,
65
bool
fPreserveSpace,
66
bool
fDisableOutputEscaping);
67
68
virtual
69
~
ElemTextLiteral
();
70
71
/**
72
* Determine if whitespace should be preserved within the element
73
*
74
* @return true if whitespace should be preserved
75
*/
76
bool
77
isPreserveSpace
()
const
78
{
79
return
preserveSpace();
80
}
81
82
const
XalanDOMChar*
83
getText
()
const
84
{
85
return
m_ch;
86
}
87
88
XalanDOMString::size_type
89
getLength
()
const
90
{
91
return
m_length;
92
}
93
94
virtual
bool
95
isWhitespace()
const
;
96
97
// These methods are inherited from ElemTemplateElement ...
98
99
virtual
const
XalanDOMString
&
100
getElementName()
const
;
101
102
#if !defined(XALAN_RECURSIVE_STYLESHEET_EXECUTION)
103
virtual
const
ElemTemplateElement
*
104
startElement(
StylesheetExecutionContext
& executionContext)
const
;
105
#else
106
virtual
void
107
execute(
StylesheetExecutionContext
& executionContext)
const
;
108
#endif
109
110
private
:
111
112
// not implemented
113
ElemTextLiteral
(
const
ElemTextLiteral
&);
114
115
ElemTextLiteral
&
116
operator=(
const
ElemTextLiteral
&);
117
118
const
bool
m_isWhitespace;
119
120
const
XalanDOMChar*
const
m_ch;
121
const
XalanDOMString::size_type
m_length;
122
};
123
124
125
126
}
127
128
129
130
#endif // XALAN_ELEMTEXTLITERAL_HEADER_GUARD
xalanc::ElemTextLiteral::getText
const XalanDOMChar * getText() const
Definition:
ElemTextLiteral.hpp:83
XALAN_CPP_NAMESPACE
#define XALAN_CPP_NAMESPACE
Xalan-C++ namespace, including major and minor version.
Definition:
XalanVersion.hpp:76
xalanc::ElemTextLiteral
Definition:
ElemTextLiteral.hpp:40
xalanc::StylesheetExecutionContext
Definition:
StylesheetExecutionContext.hpp:106
XalanDOMString.hpp
xalanc::ElemTextLiteral::isPreserveSpace
bool isPreserveSpace() const
Determine if whitespace should be preserved within the element.
Definition:
ElemTextLiteral.hpp:77
xalanc::ElemTemplateElement
Definition:
ElemTemplateElement.hpp:79
xalanc::ElemTextLiteral::getLength
XalanDOMString::size_type getLength() const
Definition:
ElemTextLiteral.hpp:89
xalanc::length
XalanDOMString::size_type length(const XalanDOMString &theString)
Get the length of a XalanDOMString.
Definition:
DOMStringHelper.hpp:235
xalanc::StylesheetConstructionContext
Definition:
StylesheetConstructionContext.hpp:83
ElemTemplateElement.hpp
XSLTDefinitions.hpp
xalanc::Stylesheet
This class represents the base stylesheet or an "import" stylesheet.
Definition:
Stylesheet.hpp:86
xalanc::XalanDOMString::size_type
XalanSize_t size_type
Definition:
XalanDOMString.hpp:57
xalanc::XalanDOMString
Definition:
XalanDOMString.hpp:45
Copyright © 1999-2020 The Apache Software Foundation. All Rights Reserved.
Generated on Sun May 31 2020 10:37:21 for Xalan-C++ API Reference by
1.8.17