Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
View | Details | Raw Unified | Return to bug 242218 | Differences between
and this patch

Collapse All | Expand All

(-)src/xalanc/PlatformSupport/AttributesImpl.cpp (-12 / +57 lines)
Lines 109-115 Link Here
109
		// until we're done.
109
		// until we're done.
110
		AttributesVectorType		tempVector(getMemoryManager());
110
		AttributesVectorType		tempVector(getMemoryManager());
111
111
112
		const unsigned int	theLength = theRHS.getLength();
112
		const XalanSize_t	theLength = theRHS.getLength();
113
113
114
		if (theLength > 0)
114
		if (theLength > 0)
115
		{
115
		{
Lines 167-178 Link Here
167
		// safe and don't need any try blocks.
167
		// safe and don't need any try blocks.
168
		AttributesImpl	theTempList(getMemoryManager());
168
		AttributesImpl	theTempList(getMemoryManager());
169
169
170
		const unsigned int	theLength = theRHS.getLength();
170
		const XalanSize_t	theLength = theRHS.getLength();
171
171
172
		theTempList.reserve(theLength);
172
		theTempList.reserve(theLength);
173
173
174
		// Add each attribute.
174
		// Add each attribute.
175
		for(unsigned int i = 0; i < theLength; i++)
175
		for(XalanSize_t i = 0; i < theLength; i++)
176
		{
176
		{
177
			theTempList.addAttribute(
177
			theTempList.addAttribute(
178
					theRHS.getURI(i),
178
					theRHS.getURI(i),
Lines 192-198 Link Here
192
192
193
193
194
194
195
unsigned int
195
XalanSize_t
196
AttributesImpl::getLength() const
196
AttributesImpl::getLength() const
197
{
197
{
198
	return unsigned(m_attributesVector.size());
198
	return unsigned(m_attributesVector.size());
Lines 201-207 Link Here
201
201
202
202
203
const XMLCh*
203
const XMLCh*
204
AttributesImpl::getURI(const unsigned int index) const
204
AttributesImpl::getURI(const XalanSize_t    index) const
205
{
205
{
206
	assert(index < getLength());
206
	assert(index < getLength());
207
207
Lines 211-217 Link Here
211
211
212
212
213
const XMLCh*
213
const XMLCh*
214
AttributesImpl::getLocalName(const unsigned int index) const
214
AttributesImpl::getLocalName(const XalanSize_t  index) const
215
{
215
{
216
	assert(index < getLength());
216
	assert(index < getLength());
217
217
Lines 221-227 Link Here
221
221
222
222
223
const XMLCh*
223
const XMLCh*
224
AttributesImpl::getQName(const unsigned int		index) const
224
AttributesImpl::getQName(const XalanSize_t  index) const
225
{
225
{
226
	assert(index < getLength());
226
	assert(index < getLength());
227
227
Lines 231-237 Link Here
231
231
232
232
233
const XMLCh*
233
const XMLCh*
234
AttributesImpl::getType(const unsigned int	index) const
234
AttributesImpl::getType(const XalanSize_t   index) const
235
{
235
{
236
	assert(index < getLength());
236
	assert(index < getLength());
237
237
Lines 241-247 Link Here
241
241
242
242
243
const XMLCh*
243
const XMLCh*
244
AttributesImpl::getValue(const unsigned int		index) const
244
AttributesImpl::getValue(const XalanSize_t  index) const
245
{
245
{
246
	assert(index < getLength());
246
	assert(index < getLength());
247
247
Lines 380-397 Link Here
380
380
381
381
382
382
383
bool
384
AttributesImpl::getIndex(
385
            const XMLCh* const  uri,
386
            const XMLCh* const  localPart,
387
            XalanSize_t&        index) const
388
{
389
    const int   tempIndex =
390
        getIndex(uri, localPart);
391
392
    if (tempIndex == -1)
393
    {
394
        return false;
395
    }
396
    else
397
    {
398
        index = tempIndex;
399
400
        return true;
401
    }
402
}
403
404
405
383
int
406
int
384
AttributesImpl::getIndex(
407
AttributesImpl::getIndex(
385
			const XMLCh* const	uri,
408
			const XMLCh* const	uri,
386
			const XMLCh* const	localName) const
409
			const XMLCh* const	localPart) const
387
{
410
{
388
	assert(uri != 0 && localName != 0);
411
	assert(uri != 0 && localPart != 0);
389
412
390
	const AttributesVectorType::const_iterator	i =
413
	const AttributesVectorType::const_iterator	i =
391
		XALAN_STD_QUALIFIER find_if(
414
		XALAN_STD_QUALIFIER find_if(
392
			m_attributesVector.begin(),
415
			m_attributesVector.begin(),
393
			m_attributesVector.end(),
416
			m_attributesVector.end(),
394
			URIAndLocalNameCompareFunctor(uri, localName));
417
			URIAndLocalNameCompareFunctor(uri, localPart));
395
418
396
	if (i != m_attributesVector.end())
419
	if (i != m_attributesVector.end())
397
	{
420
	{
Lines 407-412 Link Here
407
430
408
431
409
432
433
bool
434
AttributesImpl::getIndex(
435
            const XMLCh* const  qName,
436
            XalanSize_t&        index) const
437
{
438
    const int   tempIndex =
439
        getIndex(qName);
440
441
    if (tempIndex == -1)
442
    {
443
        return false;
444
    }
445
    else
446
    {
447
        index = tempIndex;
448
449
        return true;
450
    }
451
}
452
453
454
410
int
455
int
411
AttributesImpl::getIndex(const XMLCh* const		qname) const
456
AttributesImpl::getIndex(const XMLCh* const		qname) const
412
{
457
{
(-)src/xalanc/PlatformSupport/NamedNodeMapAttributeList.cpp (-8 / +12 lines)
Lines 43-55 Link Here
43
43
44
44
45
45
46
NamedNodeMapAttributeList::NamedNodeMapAttributeList(const XalanNamedNodeMap&	theMap,
46
NamedNodeMapAttributeList::NamedNodeMapAttributeList(
47
                                                     MemoryManagerType&         theManager) :
47
            const XalanNamedNodeMap&    theMap,
48
            MemoryManagerType&          theManager) :
48
	ParentType(),
49
	ParentType(),
49
	m_nodeMap(theMap),
50
	m_nodeMap(theMap),
50
	m_lastIndex(theMap.getLength() - 1),
51
	m_lastIndex(theMap.getLength() - 1),
51
    m_memoryManager(theManager)
52
    m_memoryManager(theManager)
52
{
53
{
54
    assert(theMap.getLength() != 0);
53
}
55
}
54
56
55
57
Lines 60-66 Link Here
60
62
61
63
62
64
63
unsigned int
65
XalanSize_t
64
NamedNodeMapAttributeList::getLength() const
66
NamedNodeMapAttributeList::getLength() const
65
{
67
{
66
	return m_nodeMap.getLength();
68
	return m_nodeMap.getLength();
Lines 69-75 Link Here
69
71
70
72
71
const XMLCh*
73
const XMLCh*
72
NamedNodeMapAttributeList::getName(const unsigned int index) const
74
NamedNodeMapAttributeList::getName(const XalanSize_t    index) const
73
{
75
{
74
	const XalanNode* const	theAttribute = m_nodeMap.item(m_lastIndex - index);
76
	const XalanNode* const	theAttribute = m_nodeMap.item(m_lastIndex - index);
75
	assert(theAttribute != 0);
77
	assert(theAttribute != 0);
Lines 80-86 Link Here
80
82
81
83
82
const XMLCh*
84
const XMLCh*
83
NamedNodeMapAttributeList::getType(const unsigned int /* index */) const
85
NamedNodeMapAttributeList::getType(const XalanSize_t    /* index */) const
84
{
86
{
85
	assert(length(s_typeString) > 0);
87
	assert(length(s_typeString) > 0);
86
88
Lines 90-98 Link Here
90
92
91
93
92
const XMLCh*
94
const XMLCh*
93
NamedNodeMapAttributeList::getValue(const unsigned int index) const
95
NamedNodeMapAttributeList::getValue(const XalanSize_t   index) const
94
{
96
{
95
	const XalanNode* const	theAttribute = m_nodeMap.item(m_lastIndex - index);
97
    assert(index <= m_lastIndex);
98
99
    const XalanNode* const	theAttribute = m_nodeMap.item(m_lastIndex - index);
96
	assert(theAttribute != 0);
100
	assert(theAttribute != 0);
97
101
98
	return c_wstr(theAttribute->getNodeValue());
102
	return c_wstr(theAttribute->getNodeValue());
Lines 111-117 Link Here
111
115
112
116
113
const XMLCh*
117
const XMLCh*
114
NamedNodeMapAttributeList::getValue(const XMLCh* const      name) const
118
NamedNodeMapAttributeList::getValue(const XMLCh* const  name) const
115
{
119
{
116
	const XalanNode*	theNode = m_nodeMap.getNamedItem(XalanDOMString(name, m_memoryManager));
120
	const XalanNode*	theNode = m_nodeMap.getNamedItem(XalanDOMString(name, m_memoryManager));
117
121
(-)src/xalanc/PlatformSupport/StdBinInputStream.cpp (-3 / +11 lines)
Lines 43-49 Link Here
43
43
44
44
45
45
46
unsigned int
46
XalanFilePos
47
StdBinInputStream::curPos() const
47
StdBinInputStream::curPos() const
48
{
48
{
49
	return m_stream.tellg();
49
	return m_stream.tellg();
Lines 51-60 Link Here
51
51
52
52
53
53
54
unsigned int
54
XalanSize_t
55
StdBinInputStream::readBytes(
55
StdBinInputStream::readBytes(
56
			XMLByte* const      toFill,
56
			XMLByte* const      toFill,
57
			const unsigned int	maxToRead)
57
			const XalanSize_t	maxToRead)
58
{
58
{
59
	assert(sizeof(XMLByte) == sizeof(char));
59
	assert(sizeof(XMLByte) == sizeof(char));
60
60
Lines 80-83 Link Here
80
80
81
81
82
82
83
const XalanDOMChar*
84
StdBinInputStream::getContentType() const
85
{
86
    return 0;
87
}
88
89
90
83
XALAN_CPP_NAMESPACE_END
91
XALAN_CPP_NAMESPACE_END
(-)src/xalanc/PlatformSupport/AttributeListImpl.hpp (-5 / +5 lines)
Lines 73-89 Link Here
73
    }
73
    }
74
74
75
	// These are inherited from AttributeList
75
	// These are inherited from AttributeList
76
    virtual unsigned int
76
    virtual XalanSize_t
77
	getLength() const;
77
	getLength() const;
78
78
79
    virtual const XMLCh*
79
    virtual const XMLCh*
80
	getName(const unsigned int index) const;
80
	getName(const XalanSize_t index) const;
81
81
82
    virtual const XMLCh*
82
    virtual const XMLCh*
83
	getType(const unsigned int index) const;
83
	getType(const XalanSize_t index) const;
84
84
85
    virtual const XMLCh*
85
    virtual const XMLCh*
86
	getValue(const unsigned int index) const;
86
	getValue(const XalanSize_t index) const;
87
87
88
    virtual const XMLCh*
88
    virtual const XMLCh*
89
	getType(const XMLCh* const name) const;
89
	getType(const XMLCh* const name) const;
Lines 141-147 Link Here
141
	 * @param theCount The number to reserve
141
	 * @param theCount The number to reserve
142
	 */
142
	 */
143
	void
143
	void
144
	reserve(unsigned int	theCount)
144
	reserve(XalanSize_t     theCount)
145
	{
145
	{
146
		m_AttributeVector.reserve(theCount);
146
		m_AttributeVector.reserve(theCount);
147
	}
147
	}
(-)src/xalanc/PlatformSupport/XSLException.hpp (-5 / +2 lines)
Lines 40-47 Link Here
40
{
40
{
41
public:
41
public:
42
42
43
	typedef XalanLocator::size_type					size_type;
44
45
	/**
43
	/**
46
	 * Constructor
44
	 * Constructor
47
	 * 
45
	 * 
Lines 119-125 Link Here
119
	 * 
117
	 * 
120
	 * @return the line number
118
	 * @return the line number
121
	 */
119
	 */
122
	size_type
120
	XalanFileLoc
123
	getLineNumber() const
121
	getLineNumber() const
124
	{
122
	{
125
		return m_lineNumber;
123
		return m_lineNumber;
Lines 130-142 Link Here
130
	 * 
128
	 * 
131
	 * @return the column number
129
	 * @return the column number
132
	 */
130
	 */
133
	size_type
131
	XalanFileLoc
134
	getColumnNumber() const
132
	getColumnNumber() const
135
	{
133
	{
136
		return m_columnNumber;
134
		return m_columnNumber;
137
	}
135
	}
138
136
139
140
    MemoryManagerType& 
137
    MemoryManagerType& 
141
    getMemoryManager()const
138
    getMemoryManager()const
142
    {
139
    {
(-)src/xalanc/PlatformSupport/XalanLocator.hpp (-10 / +8 lines)
Lines 45-52 Link Here
45
45
46
    typedef Locator     ParentType;
46
    typedef Locator     ParentType;
47
47
48
    typedef XMLSSize_t  size_type;
49
50
    XalanLocator() {}
48
    XalanLocator() {}
51
49
52
    virtual
50
    virtual
Lines 58-85 Link Here
58
    virtual const XMLCh*
56
    virtual const XMLCh*
59
    getSystemId() const = 0;
57
    getSystemId() const = 0;
60
58
61
    virtual size_type
59
    virtual XalanFileLoc
62
    getLineNumber() const = 0;
60
    getLineNumber() const = 0;
63
61
64
    virtual size_type
62
    virtual XalanFileLoc
65
    getColumnNumber() const = 0;
63
    getColumnNumber() const = 0;
66
64
67
    static size_type
65
    static XalanFileLoc
68
    getLineNumber(const ParentType*     theLocator)
66
    getLineNumber(const ParentType*     theLocator)
69
    {
67
    {
70
        return theLocator == 0 ? size_type(-1) : theLocator->getLineNumber();
68
        return theLocator == 0 ? getUnknownValue() : theLocator->getLineNumber();
71
    }
69
    }
72
70
73
    static size_type
71
    static XalanFileLoc
74
    getColumnNumber(const ParentType*   theLocator)
72
    getColumnNumber(const ParentType*   theLocator)
75
    {
73
    {
76
        return theLocator == 0 ? size_type(-1) : theLocator->getColumnNumber();
74
        return theLocator == 0 ? getUnknownValue() : theLocator->getColumnNumber();
77
    }
75
    }
78
76
79
    static size_type
77
    static XalanFileLoc
80
    getUnknownValue()
78
    getUnknownValue()
81
    {
79
    {
82
        return size_type(-1);
80
        return XalanFileLoc(-1);
83
    }
81
    }
84
82
85
private:
83
private:
(-)src/xalanc/PlatformSupport/XalanMemoryManagerDefault.cpp (+8 lines)
Lines 74-77 Link Here
74
74
75
75
76
76
77
MemoryManager*
78
XalanMemoryManagerDefault::getExceptionMemoryManager()
79
{
80
    return this;
81
}
82
83
84
77
XALAN_CPP_NAMESPACE_END
85
XALAN_CPP_NAMESPACE_END
(-)src/xalanc/PlatformSupport/FormatterListener.hpp (-1 / +1 lines)
Lines 66-72 Link Here
66
	typedef XERCES_CPP_NAMESPACE_QUALIFIER DocumentHandler	ParentType;
66
	typedef XERCES_CPP_NAMESPACE_QUALIFIER DocumentHandler	ParentType;
67
67
68
	// A handy typedef...  Must match DocumentHandler's type for characters(), etc...
68
	// A handy typedef...  Must match DocumentHandler's type for characters(), etc...
69
	typedef unsigned int	size_type;
69
	typedef XalanSize_t     size_type;
70
70
71
	enum eFormat
71
	enum eFormat
72
	{
72
	{
(-)src/xalanc/PlatformSupport/DOMStringHelper.hpp (-1 / +1 lines)
Lines 705-711 Link Here
705
{
705
{
706
public:
706
public:
707
707
708
    typedef void (FormatterListener::*MemberFunctionPtr)(const XMLCh* const, const unsigned int);
708
    typedef void (FormatterListener::*MemberFunctionPtr)(const XMLCh* const, const FormatterListener::size_type);
709
709
710
    static void
710
    static void
711
    DoubleToCharacters(
711
    DoubleToCharacters(
(-)src/xalanc/PlatformSupport/NamedNodeMapAttributeList.hpp (-9 / +10 lines)
Lines 43-66 Link Here
43
	typedef XERCES_CPP_NAMESPACE_QUALIFIER AttributeList	ParentType;
43
	typedef XERCES_CPP_NAMESPACE_QUALIFIER AttributeList	ParentType;
44
44
45
	explicit
45
	explicit
46
	NamedNodeMapAttributeList(const XalanNamedNodeMap&	theMap,
46
	NamedNodeMapAttributeList(
47
                                MemoryManagerType& theManager);
47
                const XalanNamedNodeMap&	theMap,
48
                MemoryManagerType&          theManager);
48
49
49
	virtual
50
	virtual
50
	~NamedNodeMapAttributeList();
51
	~NamedNodeMapAttributeList();
51
52
52
	// These are inherited from AttributeList
53
	// These are inherited from AttributeList
53
    virtual unsigned int
54
    virtual XalanSize_t
54
	getLength() const;
55
	getLength() const;
55
56
56
    virtual const XalanDOMChar*
57
    virtual const XalanDOMChar*
57
	getName(const unsigned int index) const;
58
	getName(const XalanSize_t   index) const;
58
59
59
    virtual const XalanDOMChar*
60
    virtual const XalanDOMChar*
60
	getType(const unsigned int index) const;
61
	getType(const XalanSize_t   index) const;
61
62
62
    virtual const XalanDOMChar*
63
    virtual const XalanDOMChar*
63
	getValue(const unsigned int index) const;
64
	getValue(const XalanSize_t  index) const;
64
65
65
    virtual const XalanDOMChar*
66
    virtual const XalanDOMChar*
66
	getType(const XalanDOMChar* const name) const;
67
	getType(const XalanDOMChar* const name) const;
Lines 83-93 Link Here
83
	// Data members...
84
	// Data members...
84
	const XalanNamedNodeMap&	m_nodeMap;
85
	const XalanNamedNodeMap&	m_nodeMap;
85
86
86
	const unsigned int			m_lastIndex;
87
	const XalanSize_t			m_lastIndex;
87
88
89
    MemoryManagerType&          m_memoryManager;
90
88
	static const XalanDOMChar	s_typeString[];
91
	static const XalanDOMChar	s_typeString[];
89
90
    	MemoryManagerType&  m_memoryManager;
91
};
92
};
92
93
93
94
(-)src/xalanc/PlatformSupport/AttributesImpl.hpp (-11 / +22 lines)
Lines 65-95 Link Here
65
	AttributesImpl&
65
	AttributesImpl&
66
	operator=(const AttributesType&		theRHS);
66
	operator=(const AttributesType&		theRHS);
67
67
68
	// These are inherited from AttributeList
68
	// These are inherited from Attributes
69
    virtual unsigned int
69
    virtual XalanSize_t
70
	getLength() const;
70
	getLength() const;
71
71
72
	virtual const XMLCh*
72
	virtual const XMLCh*
73
	getURI(const unsigned int index) const;
73
	getURI(const XalanSize_t    index) const;
74
74
75
	virtual const XMLCh*
75
	virtual const XMLCh*
76
	getLocalName(const unsigned int index) const;
76
	getLocalName(const XalanSize_t  index) const;
77
77
78
    virtual const XMLCh*
78
    virtual const XMLCh*
79
	getQName(const unsigned int index) const;
79
	getQName(const XalanSize_t  index) const;
80
80
81
    virtual const XMLCh*
81
    virtual const XMLCh*
82
	getType(const unsigned int index) const;
82
	getType(const XalanSize_t   index) const;
83
83
84
    virtual const XMLCh*
84
    virtual const XMLCh*
85
	getValue(const unsigned int index) const;
85
	getValue(const XalanSize_t  index) const;
86
86
87
	virtual int
87
    virtual bool
88
    getIndex(
89
            const XMLCh* const  uri,
90
            const XMLCh* const  localPart,
91
            XalanSize_t&        index) const;
92
93
    virtual int
88
	getIndex(
94
	getIndex(
89
			const XMLCh* const	uri,
95
			const XMLCh* const	uri,
90
			const XMLCh* const	localName) const;
96
			const XMLCh* const	localPart) const;
91
97
92
	virtual int
98
    virtual bool
99
    getIndex(
100
            const XMLCh* const  qName,
101
            XalanSize_t&        index) const;
102
103
    virtual int
93
	getIndex(const XMLCh* const		qname) const;
104
	getIndex(const XMLCh* const		qname) const;
94
105
95
    virtual const XMLCh*
106
    virtual const XMLCh*
Lines 186-192 Link Here
186
	 * @param theCount The number to reserve
197
	 * @param theCount The number to reserve
187
	 */
198
	 */
188
	void
199
	void
189
	reserve(unsigned int	theCount)
200
	reserve(XalanSize_t     theCount)
190
	{
201
	{
191
		m_attributesVector.reserve(theCount);
202
		m_attributesVector.reserve(theCount);
192
	}
203
	}
(-)src/xalanc/PlatformSupport/AttributeListImpl.cpp (-7 / +7 lines)
Lines 110-116 Link Here
110
		// until we're done.
110
		// until we're done.
111
		AttributeVectorType		tempVector(getMemoryManager());
111
		AttributeVectorType		tempVector(getMemoryManager());
112
112
113
		const unsigned int	theLength = theRHS.getLength();
113
		const XalanSize_t	theLength = theRHS.getLength();
114
114
115
		if (theLength > 0)
115
		if (theLength > 0)
116
		{
116
		{
Lines 166-177 Link Here
166
		// safe and don't need any try blocks.
166
		// safe and don't need any try blocks.
167
		AttributeListImpl	theTempList(getMemoryManager());
167
		AttributeListImpl	theTempList(getMemoryManager());
168
168
169
		const unsigned int	theLength = theRHS.getLength();
169
		const XalanSize_t	theLength = theRHS.getLength();
170
170
171
		theTempList.reserve(theLength);
171
		theTempList.reserve(theLength);
172
172
173
		// Add each attribute.
173
		// Add each attribute.
174
		for(unsigned int i = 0; i < theLength; i++)
174
		for(XalanSize_t i = 0; i < theLength; i++)
175
		{
175
		{
176
			theTempList.addAttribute(
176
			theTempList.addAttribute(
177
					theRHS.getName(i),
177
					theRHS.getName(i),
Lines 189-195 Link Here
189
189
190
190
191
191
192
unsigned int
192
XalanSize_t
193
AttributeListImpl::getLength() const
193
AttributeListImpl::getLength() const
194
{
194
{
195
	// Make sure the mismatch between Xerces and vector<> doesn't cause a problem...
195
	// Make sure the mismatch between Xerces and vector<> doesn't cause a problem...
Lines 201-207 Link Here
201
201
202
202
203
const XMLCh*
203
const XMLCh*
204
AttributeListImpl::getName(const unsigned int index) const
204
AttributeListImpl::getName(const XalanSize_t    index) const
205
{
205
{
206
	assert(index < getLength());
206
	assert(index < getLength());
207
207
Lines 211-217 Link Here
211
211
212
212
213
const XMLCh*
213
const XMLCh*
214
AttributeListImpl::getType(const unsigned int index) const
214
AttributeListImpl::getType(const XalanSize_t    index) const
215
{
215
{
216
	assert(index < getLength());
216
	assert(index < getLength());
217
217
Lines 221-227 Link Here
221
221
222
222
223
const XMLCh*
223
const XMLCh*
224
AttributeListImpl::getValue(const unsigned int index) const
224
AttributeListImpl::getValue(const XalanSize_t   index) const
225
{
225
{
226
	assert(index < getLength());
226
	assert(index < getLength());
227
227
(-)src/xalanc/PlatformSupport/StdBinInputStream.hpp (-3 / +6 lines)
Lines 58-71 Link Here
58
	virtual
58
	virtual
59
	~StdBinInputStream();
59
	~StdBinInputStream();
60
60
61
	virtual unsigned int
61
	virtual XalanFilePos
62
	curPos() const;
62
	curPos() const;
63
63
64
	virtual unsigned int
64
	virtual XalanSize_t
65
	readBytes(
65
	readBytes(
66
			XMLByte* const      toFill,
66
			XMLByte* const      toFill,
67
			const unsigned int	maxToRead);
67
			const XalanSize_t   maxToRead);
68
68
69
    virtual const XalanDOMChar*
70
    getContentType() const;
71
69
private:
72
private:
70
73
71
	// Unimplemented...
74
	// Unimplemented...
(-)src/xalanc/PlatformSupport/XalanMemoryManagerDefault.hpp (+3 lines)
Lines 52-57 Link Here
52
    virtual void
52
    virtual void
53
    deallocate(void*    pointer);
53
    deallocate(void*    pointer);
54
54
55
    virtual MemoryManager*
56
    getExceptionMemoryManager();
57
55
private:
58
private:
56
59
57
    // These are not implemented.
60
    // These are not implemented.
(-)src/xalanc/PlatformSupport/XalanTranscodingServices.hpp (-2 / +2 lines)
Lines 56-63 Link Here
56
	static void
56
	static void
57
	terminate();
57
	terminate();
58
58
59
	typedef unsigned char	XalanXMLByte;
59
    typedef unsigned char   XalanXMLByte;
60
    typedef unsigned int    size_type;
60
    typedef XalanSize_t     size_type;
61
    typedef unsigned int    UnicodeCharType;
61
    typedef unsigned int    UnicodeCharType;
62
62
63
	static size_type
63
	static size_type
(-)src/xalanc/PlatformSupport/XalanMemoryManagement.cpp (-3 / +8 lines)
Lines 40-46 Link Here
40
		
40
		
41
		return 0;
41
		return 0;
42
	}	
42
	}	
43
	virtual void
43
44
    virtual void
44
	deallocate(  void* 	/*	pDataPointer */ )
45
	deallocate(  void* 	/*	pDataPointer */ )
45
	{
46
	{
46
		XALAN_USING_STD(bad_alloc)
47
		XALAN_USING_STD(bad_alloc)
Lines 48-55 Link Here
48
		throw bad_alloc();		
49
		throw bad_alloc();		
49
		
50
		
50
	}
51
	}
51
	
52
52
	
53
    MemoryManager*
54
    getExceptionMemoryManager()
55
    {
56
        return this;
57
    }
53
};
58
};
54
59
55
60
(-)src/xalanc/Include/VCPPDefinitions.hpp (-1 / +1 lines)
Lines 17-23 Link Here
17
#define VCPPDEFINITIONS_HEADER_GUARD_1357924680
17
#define VCPPDEFINITIONS_HEADER_GUARD_1357924680
18
18
19
19
20
#pragma warning(disable: 4127 4251 4511 4512 4514 4702 4710 4711 4786 4097 4503 4786; error: 4150 4172 4238 4239 4715)
20
#pragma warning(disable: 4127 4251 4345 4351 4511 4512 4514 4521 4702 4710 4711 4786 4097 4503 4786; error: 4150 4172 4238 4239 4715)
21
21
22
22
23
// ---------------------------------------------------------------------------
23
// ---------------------------------------------------------------------------
(-)src/xalanc/Include/PlatformDefinitions.hpp (+10 lines)
Lines 120-125 Link Here
120
typedef unsigned short	XalanDOMChar;
120
typedef unsigned short	XalanDOMChar;
121
#endif
121
#endif
122
122
123
#if XERCES_VERSION_MAJOR < 3
124
typedef unsigned int    XalanSize_t;
125
typedef unsigned int    XalanFilePos;
126
typedef unsigned int    XalanFileLoc;
127
#else
128
typedef XMLSize_t       XalanSize_t;
129
typedef XMLFilePos      XalanFilePos;
130
typedef XMLFileLoc      XalanFileLoc;
131
#endif
132
123
template<bool value>
133
template<bool value>
124
struct XalanCompileErrorBoolean
134
struct XalanCompileErrorBoolean
125
{
135
{
(-)src/xalanc/XPath/XPathProcessorImpl.hpp (-4 / +6 lines)
Lines 70-75 Link Here
70
70
71
    typedef XalanVector<bool>               BoolVectorType;
71
    typedef XalanVector<bool>               BoolVectorType;
72
72
73
    typedef XalanDOMString::size_type   t_size_type;
74
73
    XPathProcessorImpl(MemoryManagerType& theManager XALAN_DEFAULT_MEMMGR);
75
    XPathProcessorImpl(MemoryManagerType& theManager XALAN_DEFAULT_MEMMGR);
74
76
75
    virtual
77
    virtual
Lines 121-132 Link Here
121
     * When a separator token is found, see if there's a element name or the
123
     * When a separator token is found, see if there's a element name or the
122
     * like to map.
124
     * like to map.
123
     */
125
     */
124
    int
126
    t_size_type
125
    mapNSTokens(
127
    mapNSTokens(
126
            const XalanDOMString&   pat,
128
            const XalanDOMString&   pat,
127
            int                     startSubstring,
129
            t_size_type             startSubstring,
128
            int                     posOfNSSep,
130
            t_size_type             posOfNSSep,
129
            int                     posOfScan);
131
            t_size_type             posOfScan);
130
132
131
    /**
133
    /**
132
     * Check if m_token==s. If m_token is null, this won't throw
134
     * Check if m_token==s. If m_token is null, this won't throw
(-)src/xalanc/XPath/XPathExecutionContextDefault.cpp (-6 / +6 lines)
Lines 492-499 Link Here
492
{
492
{
493
    assert(m_xpathEnvSupport != 0);
493
    assert(m_xpathEnvSupport != 0);
494
494
495
    XalanLocator::size_type     lineNumber = XalanLocator::getUnknownValue();
495
    XalanFileLoc     lineNumber = XalanLocator::getUnknownValue();
496
    XalanLocator::size_type     columnNumber = XalanLocator::getUnknownValue();
496
    XalanFileLoc     columnNumber = XalanLocator::getUnknownValue();
497
497
498
    MemoryManagerType& theManager =  const_cast<XPathExecutionContextDefault*>(this)->getMemoryManager();
498
    MemoryManagerType& theManager =  const_cast<XPathExecutionContextDefault*>(this)->getMemoryManager();
499
499
Lines 546-553 Link Here
546
{
546
{
547
    assert(m_xpathEnvSupport != 0);
547
    assert(m_xpathEnvSupport != 0);
548
548
549
    XalanLocator::size_type     lineNumber = XalanLocator::getUnknownValue();
549
    XalanFileLoc    lineNumber = XalanLocator::getUnknownValue();
550
    XalanLocator::size_type     columnNumber = XalanLocator::getUnknownValue();
550
    XalanFileLoc    columnNumber = XalanLocator::getUnknownValue();
551
551
552
    MemoryManagerType& theManager =  const_cast<XPathExecutionContextDefault*>(this)->getMemoryManager();
552
    MemoryManagerType& theManager =  const_cast<XPathExecutionContextDefault*>(this)->getMemoryManager();
553
553
Lines 600-607 Link Here
600
{
600
{
601
    assert(m_xpathEnvSupport != 0);
601
    assert(m_xpathEnvSupport != 0);
602
602
603
    XalanLocator::size_type     lineNumber = XalanLocator::getUnknownValue();
603
    XalanFileLoc    lineNumber = XalanLocator::getUnknownValue();
604
    XalanLocator::size_type     columnNumber = XalanLocator::getUnknownValue();
604
    XalanFileLoc    columnNumber = XalanLocator::getUnknownValue();
605
605
606
   MemoryManagerType& theManager =  const_cast<XPathExecutionContextDefault*>(this)->getMemoryManager();
606
   MemoryManagerType& theManager =  const_cast<XPathExecutionContextDefault*>(this)->getMemoryManager();
607
607
(-)src/xalanc/XPath/XPathExecutionContextDefault.hpp (-4 / +5 lines)
Lines 32-40 Link Here
32
32
33
33
34
34
35
/**
36
 * @author <a href="mailto:david_n_bertoni@lotus.com">David N. Bertoni</a>
37
 */
38
// Base class include file.
35
// Base class include file.
39
#include <xalanc/XPath/XPathExecutionContext.hpp>
36
#include <xalanc/XPath/XPathExecutionContext.hpp>
40
37
Lines 346-352 Link Here
346
343
347
protected:
344
protected:
348
345
349
	typedef XalanObjectCache<MutableNodeRefList, DefaultCacheCreateFunctorMemMgr<MutableNodeRefList>, DeleteFunctor<MutableNodeRefList>, ClearCacheResetFunctor<MutableNodeRefList> >	NodeListCacheType;
346
	typedef XalanObjectCache<
347
                MutableNodeRefList,
348
                DefaultCacheCreateFunctorMemMgr<MutableNodeRefList>,
349
                DeleteFunctor<MutableNodeRefList>,
350
                ClearCacheResetFunctor<MutableNodeRefList> >	NodeListCacheType;
350
351
351
	enum { eNodeListCacheListSize = 50 };
352
	enum { eNodeListCacheListSize = 50 };
352
353
(-)src/xalanc/XPath/FormatterStringLengthCounter.cpp (-8 / +8 lines)
Lines 76-83 Link Here
76
76
77
void
77
void
78
FormatterStringLengthCounter::characters(
78
FormatterStringLengthCounter::characters(
79
			const XMLCh* const	/* chars */,
79
			const XMLCh* const  /* chars */,
80
			const unsigned int	length)
80
			const size_type     length)
81
{
81
{
82
	m_count += length;
82
	m_count += length;
83
}
83
}
Lines 86-93 Link Here
86
86
87
void
87
void
88
FormatterStringLengthCounter::charactersRaw(
88
FormatterStringLengthCounter::charactersRaw(
89
		const XMLCh* const	/* chars */,
89
		const XMLCh* const  /* chars */,
90
		const unsigned int	/*length */)
90
		const size_type	    /*length */)
91
{
91
{
92
}
92
}
93
93
Lines 101-108 Link Here
101
101
102
void
102
void
103
FormatterStringLengthCounter::ignorableWhitespace(
103
FormatterStringLengthCounter::ignorableWhitespace(
104
			const XMLCh* const	/* chars */,
104
			const XMLCh* const  /* chars */,
105
			const unsigned int	/* length */)
105
			const size_type	    /* length */)
106
{
106
{
107
}
107
}
108
108
Lines 133-140 Link Here
133
133
134
void
134
void
135
FormatterStringLengthCounter::cdata(
135
FormatterStringLengthCounter::cdata(
136
			const XMLCh* const	 /* ch */,
136
			const XMLCh* const  /* ch */,
137
			const unsigned int 	/* length */)
137
			const size_type     /* length */)
138
{
138
{
139
}
139
}
140
140
(-)src/xalanc/XPath/XPathConstructionContext.hpp (-13 / +9 lines)
Lines 123-142 Link Here
123
        {
123
        {
124
        }
124
        }
125
125
126
        // Note non-const copy semantics...
127
        GetAndReleaseCachedString(GetAndReleaseCachedString&    theSource) :
128
            m_constructionContext(theSource.m_constructionContext),
129
            m_string(theSource.m_string)
130
        {
131
            theSource.m_string = 0;
132
        }
133
134
        ~GetAndReleaseCachedString()
126
        ~GetAndReleaseCachedString()
135
        {
127
        {
136
            if (m_string != 0)
128
            assert(m_string != 0);
137
            {
129
138
                m_constructionContext->releaseCachedString(*m_string);
130
            m_constructionContext->releaseCachedString(*m_string);
139
            }
140
        }
131
        }
141
132
142
        XalanDOMString&
133
        XalanDOMString&
Lines 150-162 Link Here
150
        XPathConstructionContext&
141
        XPathConstructionContext&
151
        getConstructionContext() const
142
        getConstructionContext() const
152
        {
143
        {
144
            assert(m_constructionContext != 0);
145
153
            return *m_constructionContext;
146
            return *m_constructionContext;
154
        }
147
        }
155
148
156
157
    private:
149
    private:
158
150
159
        // Not implemented...
151
        // Not implemented...
152
        GetAndReleaseCachedString();
153
154
        GetAndReleaseCachedString(const GetAndReleaseCachedString&);
155
160
        GetAndReleaseCachedString&
156
        GetAndReleaseCachedString&
161
        operator=(const GetAndReleaseCachedString&);
157
        operator=(const GetAndReleaseCachedString&);
162
158
(-)src/xalanc/XPath/XPathExecutionContext.hpp (-3 / +4 lines)
Lines 35-43 Link Here
35
35
36
36
37
37
38
/**
39
 * @author <a href="mailto:david_n_bertoni@lotus.com">David N. Bertoni</a>
40
 */
41
// Base class header file...
38
// Base class header file...
42
#include <xalanc/PlatformSupport/ExecutionContext.hpp>
39
#include <xalanc/PlatformSupport/ExecutionContext.hpp>
43
40
Lines 470-475 Link Here
470
    private:
467
    private:
471
468
472
        // Not implemented...
469
        // Not implemented...
470
        GetAndReleaseCachedString();
471
472
        GetAndReleaseCachedString(const GetAndReleaseCachedString&);
473
473
        GetAndReleaseCachedString&
474
        GetAndReleaseCachedString&
474
        operator=(const GetAndReleaseCachedString&);
475
        operator=(const GetAndReleaseCachedString&);
475
476
(-)src/xalanc/XPath/XObject.hpp (-1 / +1 lines)
Lines 141-147 Link Here
141
	virtual const XalanDOMString&
141
	virtual const XalanDOMString&
142
	str() const;
142
	str() const;
143
143
144
	typedef void (FormatterListener::*MemberFunctionPtr)(const XMLCh* const, const unsigned int);
144
    typedef void (FormatterListener::*MemberFunctionPtr)(const XMLCh* const, const FormatterListener::size_type);
145
145
146
	/**
146
	/**
147
	 * Send the string value to a FormatterListener instance.
147
	 * Send the string value to a FormatterListener instance.
(-)src/xalanc/XPath/FormatterStringLengthCounter.hpp (-6 / +4 lines)
Lines 41-48 Link Here
41
{
41
{
42
public:
42
public:
43
43
44
	typedef unsigned long	size_type;
45
46
	/**
44
	/**
47
	 * FormatterStringLengthCounter instance constructor.
45
	 * FormatterStringLengthCounter instance constructor.
48
	 */
46
	 */
Lines 81-92 Link Here
81
    virtual void
79
    virtual void
82
	characters(
80
	characters(
83
			const XMLCh* const	chars,
81
			const XMLCh* const	chars,
84
			const unsigned int	length);
82
			const size_type	    length);
85
83
86
    virtual void
84
    virtual void
87
	charactersRaw(
85
	charactersRaw(
88
			const XMLCh* const	chars,
86
			const XMLCh* const	chars,
89
			const unsigned int	length);
87
			const size_type	    length);
90
88
91
	virtual void
89
	virtual void
92
	entityReference(const XMLCh* const	name);
90
	entityReference(const XMLCh* const	name);
Lines 94-100 Link Here
94
	virtual void
92
	virtual void
95
	ignorableWhitespace(
93
	ignorableWhitespace(
96
			const XMLCh* const	chars,
94
			const XMLCh* const	chars,
97
			const unsigned int	length);
95
			const size_type	    length);
98
96
99
	virtual void
97
	virtual void
100
	processingInstruction(
98
	processingInstruction(
Lines 110-116 Link Here
110
	virtual void
108
	virtual void
111
	cdata(
109
	cdata(
112
			const XMLCh* const	ch,
110
			const XMLCh* const	ch,
113
			const unsigned int 	length);
111
			const size_type     length);
114
112
115
private:
113
private:
116
114
(-)src/xalanc/XPath/XPathProcessorImpl.cpp (-31 / +33 lines)
Lines 212-227 Link Here
212
212
213
    m_expression->setCurrentPattern(m_constructionContext->getPooledString(pat));
213
    m_expression->setCurrentPattern(m_constructionContext->getPooledString(pat));
214
214
215
    const int   nChars = length(pat);
215
    const t_size_type   nChars = length(pat);
216
216
217
    int         startSubstring = -1;
217
    t_size_type     startSubstring = XalanDOMString::npos;
218
    int         posOfNSSep = -1;
218
    t_size_type     posOfNSSep = XalanDOMString::npos;
219
219
220
    const XPathConstructionContext::GetAndReleaseCachedString   theGuard(*m_constructionContext);
220
    const XPathConstructionContext::GetAndReleaseCachedString   theGuard(*m_constructionContext);
221
221
222
    XalanDOMString&     theToken = theGuard.get();
222
    XalanDOMString&     theToken = theGuard.get();
223
223
224
    for(int i = 0; i < nChars; i++)
224
    for(t_size_type i = 0; i < nChars; i++)
225
    {
225
    {
226
        XalanDOMChar    c = charAt(pat, i);
226
        XalanDOMChar    c = charAt(pat, i);
227
227
Lines 229-237 Link Here
229
        {
229
        {
230
        case XalanUnicode::charQuoteMark: 
230
        case XalanUnicode::charQuoteMark: 
231
            {
231
            {
232
                if(startSubstring != -1)
232
                if(startSubstring != XalanDOMString::npos)
233
                {
233
                {
234
                    if(-1 != posOfNSSep)
234
                    if(XalanDOMString::npos != posOfNSSep)
235
                    {      
235
                    {      
236
                        posOfNSSep = mapNSTokens(pat, startSubstring, posOfNSSep, i);
236
                        posOfNSSep = mapNSTokens(pat, startSubstring, posOfNSSep, i);
237
                    }
237
                    }
Lines 253-259 Link Here
253
253
254
                    addToTokenQueue(theToken);
254
                    addToTokenQueue(theToken);
255
255
256
                    startSubstring = -1;
256
                    startSubstring = XalanDOMString::npos;
257
                }
257
                }
258
                else
258
                else
259
                {
259
                {
Lines 264-272 Link Here
264
264
265
        case XalanUnicode::charApostrophe:
265
        case XalanUnicode::charApostrophe:
266
            {
266
            {
267
                if(startSubstring != -1)
267
                if(startSubstring != XalanDOMString::npos)
268
                {
268
                {
269
                    if(-1 != posOfNSSep)
269
                    if(XalanDOMString::npos != posOfNSSep)
270
                    {    
270
                    {    
271
                        posOfNSSep = mapNSTokens(pat, startSubstring, posOfNSSep, i);
271
                        posOfNSSep = mapNSTokens(pat, startSubstring, posOfNSSep, i);
272
                    }
272
                    }
Lines 288-294 Link Here
288
288
289
                    addToTokenQueue(theToken);
289
                    addToTokenQueue(theToken);
290
290
291
                    startSubstring = -1;
291
                    startSubstring = XalanDOMString::npos;
292
                }
292
                }
293
                else
293
                else
294
                {
294
                {
Lines 302-310 Link Here
302
        case XalanUnicode::charSpace:
302
        case XalanUnicode::charSpace:
303
        case XalanUnicode::charHTab:
303
        case XalanUnicode::charHTab:
304
            {
304
            {
305
                if(startSubstring != -1)
305
                if(startSubstring != XalanDOMString::npos)
306
                {
306
                {
307
                    if(-1 != posOfNSSep)
307
                    if(XalanDOMString::npos != posOfNSSep)
308
                    {    
308
                    {    
309
                        posOfNSSep = mapNSTokens(pat, startSubstring, posOfNSSep, i);
309
                        posOfNSSep = mapNSTokens(pat, startSubstring, posOfNSSep, i);
310
                    }
310
                    }
Lines 315-328 Link Here
315
                        addToTokenQueue(theToken);
315
                        addToTokenQueue(theToken);
316
                    }
316
                    }
317
317
318
                    startSubstring = -1;
318
                    startSubstring = XalanDOMString::npos;
319
                }
319
                }
320
            }
320
            }
321
            break;
321
            break;
322
        
322
        
323
        case XalanUnicode::charHyphenMinus:
323
        case XalanUnicode::charHyphenMinus:
324
            {
324
            {
325
                if(!(startSubstring == -1))
325
                if(!(startSubstring == XalanDOMString::npos))
326
                {
326
                {
327
                    break;
327
                    break;
328
                }
328
                }
Lines 347-355 Link Here
347
        case XalanUnicode::charLessThanSign:
347
        case XalanUnicode::charLessThanSign:
348
        case XalanUnicode::charGreaterThanSign:
348
        case XalanUnicode::charGreaterThanSign:
349
            {
349
            {
350
                if(startSubstring != -1)
350
                if(startSubstring != XalanDOMString::npos)
351
                {
351
                {
352
                    if(-1 != posOfNSSep)
352
                    if(XalanDOMString::npos != posOfNSSep)
353
                    {    
353
                    {    
354
                        posOfNSSep = mapNSTokens(pat, startSubstring, posOfNSSep, i);
354
                        posOfNSSep = mapNSTokens(pat, startSubstring, posOfNSSep, i);
355
                    }
355
                    }
Lines 360-366 Link Here
360
                        addToTokenQueue(theToken);
360
                        addToTokenQueue(theToken);
361
                    }
361
                    }
362
362
363
                    startSubstring = -1;
363
                    startSubstring = XalanDOMString::npos;
364
                }
364
                }
365
365
366
                substring(pat, theToken, i, i + 1);
366
                substring(pat, theToken, i, i + 1);
Lines 373-379 Link Here
373
            {
373
            {
374
                if(posOfNSSep == i - 1 && i > 0)
374
                if(posOfNSSep == i - 1 && i > 0)
375
                { 
375
                { 
376
                    if(startSubstring != -1)
376
                    if(startSubstring != XalanDOMString::npos)
377
                    {
377
                    {
378
                        if (startSubstring < i - 1)
378
                        if (startSubstring < i - 1)
379
                        {
379
                        {
Lines 383-390 Link Here
383
                        }
383
                        }
384
                    }
384
                    }
385
385
386
                    startSubstring = -1;
386
                    startSubstring = XalanDOMString::npos;
387
                    posOfNSSep = -1;
387
                    posOfNSSep = XalanDOMString::npos;
388
388
389
                    substring(pat, theToken, i - 1, i + 1);
389
                    substring(pat, theToken, i - 1, i + 1);
390
390
Lines 401-407 Link Here
401
        
401
        
402
        default:
402
        default:
403
            {
403
            {
404
                if(-1 == startSubstring)
404
                if(XalanDOMString::npos == startSubstring)
405
                {
405
                {
406
                    startSubstring = i;
406
                    startSubstring = i;
407
407
Lines 440-455 Link Here
440
440
441
                        addToTokenQueue(theToken);
441
                        addToTokenQueue(theToken);
442
442
443
                        startSubstring = -1;
443
                        startSubstring = XalanDOMString::npos;
444
                    }
444
                    }
445
                }
445
                }
446
            }
446
            }
447
        }
447
        }
448
    }
448
    }
449
449
450
    if(startSubstring != -1)
450
    if(startSubstring != XalanDOMString::npos)
451
    {
451
    {
452
        if(-1 != posOfNSSep)
452
        if(XalanDOMString::npos != posOfNSSep)
453
        {    
453
        {    
454
            posOfNSSep = mapNSTokens(pat, startSubstring, posOfNSSep, nChars);
454
            posOfNSSep = mapNSTokens(pat, startSubstring, posOfNSSep, nChars);
455
        }
455
        }
Lines 504-515 Link Here
504
504
505
505
506
506
507
int
507
XPathProcessorImpl::t_size_type
508
XPathProcessorImpl::mapNSTokens(
508
XPathProcessorImpl::mapNSTokens(
509
            const XalanDOMString&   pat,
509
            const XalanDOMString&   pat,
510
            int                     startSubstring,
510
            t_size_type             startSubstring,
511
            int                     posOfNSSep,
511
            t_size_type             posOfNSSep,
512
            int                     posOfScan)
512
            t_size_type             posOfScan)
513
{
513
{
514
    assert(m_prefixResolver != 0);
514
    assert(m_prefixResolver != 0);
515
515
Lines 575-581 Link Here
575
        }
575
        }
576
    }
576
    }
577
577
578
    return -1;
578
    return XalanDOMString::npos;
579
}
579
}
580
580
581
581
Lines 2938-2951 Link Here
2938
bool
2938
bool
2939
XPathProcessorImpl::isCurrentLiteral() const
2939
XPathProcessorImpl::isCurrentLiteral() const
2940
{
2940
{
2941
    const int last = length(m_token) - 1;
2941
    const t_size_type   theLength = m_token.length();
2942
2942
2943
    if (last <= 0)
2943
    if (theLength <= 1)
2944
    {
2944
    {
2945
        return false;
2945
        return false;
2946
    }
2946
    }
2947
    else
2947
    else
2948
    {
2948
    {
2949
        const t_size_type   last = theLength - 1;
2950
2949
        const XalanDOMChar  c0 = m_tokenChar;
2951
        const XalanDOMChar  c0 = m_tokenChar;
2950
        const XalanDOMChar  cX = charAt(m_token, last);
2952
        const XalanDOMChar  cX = charAt(m_token, last);
2951
2953
(-)src/xalanc/XPath/XPath.hpp (-1 / +1 lines)
Lines 241-247 Link Here
241
			XPathExecutionContext&	executionContext,
241
			XPathExecutionContext&	executionContext,
242
			XalanDOMString&			result) const;
242
			XalanDOMString&			result) const;
243
243
244
	typedef void (FormatterListener::*MemberFunctionPtr)(const XMLCh* const, const unsigned int);
244
    typedef void (FormatterListener::*MemberFunctionPtr)(const XMLCh* const, const FormatterListener::size_type);
245
245
246
	/**
246
	/**
247
	 * Execute the XPath from the provided context.
247
	 * Execute the XPath from the provided context.
(-)src/xalanc/XercesParserLiaison/XercesDOMWrapperException.hpp (+6 lines)
Lines 83-88 Link Here
83
83
84
	static ExceptionCode
84
	static ExceptionCode
85
	translateErrorCode(DOMExceptionType::ExceptionCode	theCode);
85
	translateErrorCode(DOMExceptionType::ExceptionCode	theCode);
86
87
	static ExceptionCode
88
	translateErrorCode(short    theCode)
89
    {
90
        return translateErrorCode(static_cast<DOMExceptionType::ExceptionCode>(theCode));
91
    }
86
};
92
};
87
93
88
94
(-)src/xalanc/XercesParserLiaison/XercesParserLiaison.cpp (+9 lines)
Lines 741-747 Link Here
741
    DOMParserType* const    theParser =
741
    DOMParserType* const    theParser =
742
        new (&theMemoryManager) DOMParserType(0, &theMemoryManager);
742
        new (&theMemoryManager) DOMParserType(0, &theMemoryManager);
743
743
744
#if XERCES_VERSION_MAJOR < 3
744
    theParser->setExpandEntityReferences(true);
745
    theParser->setExpandEntityReferences(true);
746
#else
747
    theParser->setCreateEntityReferenceNodes(false);
748
#endif
749
745
    theParser->setDoNamespaces(m_doNamespaces);
750
    theParser->setDoNamespaces(m_doNamespaces);
746
    theParser->setEntityResolver(m_entityResolver);
751
    theParser->setEntityResolver(m_entityResolver);
747
752
Lines 759-765 Link Here
759
    SAXParserType* const    theParser =
764
    SAXParserType* const    theParser =
760
        new (&theMemoryManager) SAXParserType(0, &theMemoryManager);
765
        new (&theMemoryManager) SAXParserType(0, &theMemoryManager);
761
766
767
#if XERCES_VERSION_MAJOR < 3
762
    theParser->setDoValidation(false);
768
    theParser->setDoValidation(false);
769
#else
770
    theParser->setValidationScheme(SAXParserType::Val_Never);
771
#endif
763
772
764
    theParser->setDoNamespaces(false);
773
    theParser->setDoNamespaces(false);
765
774
(-)src/xalanc/XercesParserLiaison/XercesNamedNodeMapAttributeList.hpp (-5 / +5 lines)
Lines 48-64 Link Here
48
	~XercesNamedNodeMapAttributeList();
48
	~XercesNamedNodeMapAttributeList();
49
49
50
	// These are inherited from AttributeList
50
	// These are inherited from AttributeList
51
    virtual unsigned int
51
    virtual XalanSize_t
52
	getLength() const;
52
	getLength() const;
53
53
54
    virtual const XMLCh*
54
    virtual const XMLCh*
55
	getName(const unsigned int index) const;
55
	getName(const XalanSize_t   index) const;
56
56
57
    virtual const XMLCh*
57
    virtual const XMLCh*
58
	getType(const unsigned int index) const;
58
	getType(const XalanSize_t   index) const;
59
59
60
    virtual const XMLCh*
60
    virtual const XMLCh*
61
	getValue(const unsigned int index) const;
61
	getValue(const XalanSize_t  index) const;
62
62
63
    virtual const XMLCh*
63
    virtual const XMLCh*
64
	getType(const XMLCh* const name) const;
64
	getType(const XMLCh* const name) const;
Lines 81-87 Link Here
81
	// Data members...
81
	// Data members...
82
	const DOMNamedNodeMapType* const	m_nodeMap;
82
	const DOMNamedNodeMapType* const	m_nodeMap;
83
83
84
	const XMLSizeType					m_lastIndex;
84
	const XalanSize_t					m_lastIndex;
85
85
86
	static const XMLCh	s_typeString[];
86
	static const XMLCh	s_typeString[];
87
};
87
};
(-)src/xalanc/XercesParserLiaison/FormatterToXercesDOM.cpp (-4 / +4 lines)
Lines 191-197 Link Here
191
void
191
void
192
FormatterToXercesDOM::characters(
192
FormatterToXercesDOM::characters(
193
			const XMLCh* const	chars,
193
			const XMLCh* const	chars,
194
			const unsigned int	length)
194
			const size_type	    length)
195
{
195
{
196
	m_textBuffer.append(chars, length);
196
	m_textBuffer.append(chars, length);
197
}
197
}
Lines 201-207 Link Here
201
void
201
void
202
FormatterToXercesDOM::charactersRaw(
202
FormatterToXercesDOM::charactersRaw(
203
		const XMLCh* const	chars,
203
		const XMLCh* const	chars,
204
		const unsigned int	length)
204
		const size_type	    length)
205
{
205
{
206
	try
206
	try
207
	{
207
	{
Lines 237-243 Link Here
237
void
237
void
238
FormatterToXercesDOM::ignorableWhitespace(
238
FormatterToXercesDOM::ignorableWhitespace(
239
			const XMLCh* const	chars,
239
			const XMLCh* const	chars,
240
			const unsigned int	length)
240
			const size_type	    length)
241
{
241
{
242
	try
242
	try
243
	{
243
	{
Lines 301-307 Link Here
301
void
301
void
302
FormatterToXercesDOM::cdata(
302
FormatterToXercesDOM::cdata(
303
			const XMLCh* const	ch,
303
			const XMLCh* const	ch,
304
			const unsigned int 	length)
304
			const size_type	    length)
305
{
305
{
306
	try
306
	try
307
	{
307
	{
(-)src/xalanc/XercesParserLiaison/XercesNamedNodeMapAttributeList.cpp (-5 / +6 lines)
Lines 48-53 Link Here
48
	m_nodeMap(theMap),
48
	m_nodeMap(theMap),
49
	m_lastIndex(theMap->getLength() - 1)
49
	m_lastIndex(theMap->getLength() - 1)
50
{
50
{
51
    assert(theMap->getLength() != 0);
51
}
52
}
52
53
53
54
Lines 58-64 Link Here
58
59
59
60
60
61
61
unsigned int
62
XalanSize_t
62
XercesNamedNodeMapAttributeList::getLength() const
63
XercesNamedNodeMapAttributeList::getLength() const
63
{
64
{
64
	return m_lastIndex + 1;
65
	return m_lastIndex + 1;
Lines 67-73 Link Here
67
68
68
69
69
const XMLCh*
70
const XMLCh*
70
XercesNamedNodeMapAttributeList::getName(const unsigned int index) const
71
XercesNamedNodeMapAttributeList::getName(const XalanSize_t  index) const
71
{
72
{
72
	const DOMNodeType* const	theAttribute = m_nodeMap->item(m_lastIndex - index);
73
	const DOMNodeType* const	theAttribute = m_nodeMap->item(m_lastIndex - index);
73
	assert(theAttribute != 0);
74
	assert(theAttribute != 0);
Lines 78-84 Link Here
78
79
79
80
80
const XMLCh*
81
const XMLCh*
81
XercesNamedNodeMapAttributeList::getType(const unsigned int /* index */) const
82
XercesNamedNodeMapAttributeList::getType(const XalanSize_t  /* index */) const
82
{
83
{
83
	assert(length(s_typeString) > 0);
84
	assert(length(s_typeString) > 0);
84
85
Lines 88-94 Link Here
88
89
89
90
90
const XMLCh*
91
const XMLCh*
91
XercesNamedNodeMapAttributeList::getValue(const unsigned int index) const
92
XercesNamedNodeMapAttributeList::getValue(const XalanSize_t     index) const
92
{
93
{
93
	const DOMNodeType* const	theAttribute = m_nodeMap->item(m_lastIndex - index);
94
	const DOMNodeType* const	theAttribute = m_nodeMap->item(m_lastIndex - index);
94
	assert(theAttribute != 0);
95
	assert(theAttribute != 0);
Lines 126-132 Link Here
126
const XMLCh* 
127
const XMLCh* 
127
XercesNamedNodeMapAttributeList::getValue(const char* const /*name*/) const
128
XercesNamedNodeMapAttributeList::getValue(const char* const /*name*/) const
128
{
129
{
129
    assert( 0 );
130
    assert(false);
130
131
131
    return 0;
132
    return 0;
132
}
133
}
(-)src/xalanc/XercesParserLiaison/FormatterToXercesDOM.hpp (-5 / +5 lines)
Lines 82-93 Link Here
82
	~FormatterToXercesDOM();
82
	~FormatterToXercesDOM();
83
83
84
84
85
	// These methods are inherited from DocumentHandler ...
85
	// These methods are inherited from FormatterListener...
86
86
87
	virtual void
87
	virtual void
88
	charactersRaw(
88
	charactersRaw(
89
			const XMLCh* const	chars,
89
			const XMLCh* const	chars,
90
			const unsigned int	length);
90
			const size_type	    length);
91
91
92
	virtual void
92
	virtual void
93
	comment(const XMLCh* const	data);
93
	comment(const XMLCh* const	data);
Lines 95-101 Link Here
95
	virtual void
95
	virtual void
96
	cdata(
96
	cdata(
97
			const XMLCh* const	ch,
97
			const XMLCh* const	ch,
98
			const unsigned int 	length);
98
			const size_type 	length);
99
99
100
	virtual void
100
	virtual void
101
	entityReference(const XMLCh* const	name);
101
	entityReference(const XMLCh* const	name);
Lines 120-131 Link Here
120
	virtual void
120
	virtual void
121
	characters(
121
	characters(
122
				const XMLCh* const	chars,
122
				const XMLCh* const	chars,
123
				const unsigned int	length);
123
				const size_type	    length);
124
124
125
	virtual void
125
	virtual void
126
	ignorableWhitespace(
126
	ignorableWhitespace(
127
				const XMLCh* const	chars,
127
				const XMLCh* const	chars,
128
				const unsigned int	length);
128
				const size_type	    length);
129
129
130
	virtual void
130
	virtual void
131
	processingInstruction(
131
	processingInstruction(
(-)src/xalanc/XSLT/XSLTProcessor.hpp (-1 / +1 lines)
Lines 80-86 Link Here
80
{
80
{
81
public:
81
public:
82
82
83
	typedef size_t	size_type;
83
    typedef XalanSize_t     size_type;
84
84
85
	XSLTProcessor();
85
	XSLTProcessor();
86
86
(-)src/xalanc/XSLT/ElemCopyOf.cpp (-11 / +11 lines)
Lines 49-56 Link Here
49
            StylesheetConstructionContext&  constructionContext,
49
            StylesheetConstructionContext&  constructionContext,
50
            Stylesheet&                     stylesheetTree,
50
            Stylesheet&                     stylesheetTree,
51
            const AttributeListType&        atts,
51
            const AttributeListType&        atts,
52
            int                             lineNumber,
52
            XalanFileLoc                    lineNumber,
53
            int                             columnNumber) :
53
            XalanFileLoc                    columnNumber) :
54
    ElemTemplateElement(constructionContext,
54
    ElemTemplateElement(constructionContext,
55
                        stylesheetTree,
55
                        stylesheetTree,
56
                        lineNumber,
56
                        lineNumber,
Lines 60-72 Link Here
60
{
60
{
61
    bool    isSelectCurrentNode = false;
61
    bool    isSelectCurrentNode = false;
62
62
63
    const unsigned int  nAttrs = atts.getLength();
63
    const XalanSize_t   nAttrs = atts.getLength();
64
    
64
    
65
    for(unsigned int i = 0; i < nAttrs; ++i)
65
    for (XalanSize_t i = 0; i < nAttrs; ++i)
66
    {
66
    {
67
        const XalanDOMChar* const   aname = atts.getName(i);
67
        const XalanDOMChar* const   aname = atts.getName(i);
68
68
69
        if(equals(aname, Constants::ATTRNAME_SELECT))
69
        if (equals(aname, Constants::ATTRNAME_SELECT))
70
        {
70
        {
71
            const XalanDOMChar* const   avalue = atts.getValue(i);
71
            const XalanDOMChar* const   avalue = atts.getValue(i);
72
            assert(avalue != 0);
72
            assert(avalue != 0);
Lines 80-86 Link Here
80
                m_selectPattern = constructionContext.createXPath(getLocator(), avalue, *this);
80
                m_selectPattern = constructionContext.createXPath(getLocator(), avalue, *this);
81
            }
81
            }
82
        }
82
        }
83
        else if(isAttrOK(
83
        else if (isAttrOK(
84
                    aname,
84
                    aname,
85
                    atts,
85
                    atts,
86
                    i,
86
                    i,
Lines 124-130 Link Here
124
124
125
    if (m_selectPattern == 0)
125
    if (m_selectPattern == 0)
126
    {
126
    {
127
        if(0 != executionContext.getTraceListeners())
127
        if (0 != executionContext.getTraceListeners())
128
        {
128
        {
129
            StylesheetExecutionContext::BorrowReturnMutableNodeRefList  theNodeList(executionContext);
129
            StylesheetExecutionContext::BorrowReturnMutableNodeRefList  theNodeList(executionContext);
130
130
Lines 147-153 Link Here
147
        const XObjectPtr    value(m_selectPattern->execute(*this, executionContext));
147
        const XObjectPtr    value(m_selectPattern->execute(*this, executionContext));
148
        assert(value.null() == false);
148
        assert(value.null() == false);
149
149
150
        if(0 != executionContext.getTraceListeners())
150
        if (0 != executionContext.getTraceListeners())
151
        {
151
        {
152
            executionContext.fireSelectEvent(
152
            executionContext.fireSelectEvent(
153
                SelectionEvent(
153
                SelectionEvent(
Lines 209-215 Link Here
209
209
210
    if (m_selectPattern == 0)
210
    if (m_selectPattern == 0)
211
    {
211
    {
212
        if(0 != executionContext.getTraceListeners())
212
        if (0 != executionContext.getTraceListeners())
213
        {
213
        {
214
            StylesheetExecutionContext::BorrowReturnMutableNodeRefList  theNodeList(executionContext);
214
            StylesheetExecutionContext::BorrowReturnMutableNodeRefList  theNodeList(executionContext);
215
215
Lines 232-238 Link Here
232
        const XObjectPtr    value(m_selectPattern->execute(*this, executionContext));
232
        const XObjectPtr    value(m_selectPattern->execute(*this, executionContext));
233
        assert(value.null() == false);
233
        assert(value.null() == false);
234
234
235
        if(0 != executionContext.getTraceListeners())
235
        if (0 != executionContext.getTraceListeners())
236
        {
236
        {
237
            executionContext.fireSelectEvent(
237
            executionContext.fireSelectEvent(
238
                SelectionEvent(
238
                SelectionEvent(
Lines 283-289 Link Here
283
283
284
284
285
const XPath*
285
const XPath*
286
ElemCopyOf::getXPath(unsigned int   index) const
286
ElemCopyOf::getXPath(XalanSize_t    index) const
287
{
287
{
288
    return index == 0 ? m_selectPattern : 0;
288
    return index == 0 ? m_selectPattern : 0;
289
}
289
}
(-)src/xalanc/XSLT/XalanElemAttributeSetAllocator.cpp (-3 / +5 lines)
Lines 23-29 Link Here
23
23
24
24
25
25
26
XalanElemAttributeSetAllocator::XalanElemAttributeSetAllocator(MemoryManagerType&  theManager, size_type	theBlockCount) :
26
XalanElemAttributeSetAllocator::XalanElemAttributeSetAllocator(
27
            MemoryManagerType&  theManager,
28
            size_type	        theBlockCount) :
27
	m_allocator(theManager, theBlockCount)
29
	m_allocator(theManager, theBlockCount)
28
{
30
{
29
}
31
}
Lines 41-48 Link Here
41
			StylesheetConstructionContext&	constructionContext,
43
			StylesheetConstructionContext&	constructionContext,
42
			Stylesheet&						stylesheetTree,
44
			Stylesheet&						stylesheetTree,
43
			const AttributeListType&		atts,
45
			const AttributeListType&		atts,
44
			int								lineNumber,
46
			XalanFileLoc					lineNumber,
45
			int								columnNumber)
47
			XalanFileLoc					columnNumber)
46
{
48
{
47
	data_type* const	theBlock = m_allocator.allocateBlock();
49
	data_type* const	theBlock = m_allocator.allocateBlock();
48
	assert(theBlock != 0);
50
	assert(theBlock != 0);
(-)src/xalanc/XSLT/ElemAttribute.hpp (-2 / +2 lines)
Lines 52-59 Link Here
52
			StylesheetConstructionContext&	constructionContext,
52
			StylesheetConstructionContext&	constructionContext,
53
			Stylesheet&						stylesheetTree,
53
			Stylesheet&						stylesheetTree,
54
			const AttributeListType&		atts,
54
			const AttributeListType&		atts,
55
			int								lineNumber,
55
			XalanFileLoc				    lineNumber,
56
			int								columnNumber);
56
			XalanFileLoc					columnNumber);
57
57
58
	virtual
58
	virtual
59
	~ElemAttribute();
59
	~ElemAttribute();
(-)src/xalanc/XSLT/XalanElemElementAllocator.hpp (-3 / +5 lines)
Lines 57-63 Link Here
57
	 *
57
	 *
58
	 * @param theBlockSize The block size.
58
	 * @param theBlockSize The block size.
59
	 */
59
	 */
60
	XalanElemElementAllocator(MemoryManagerType&  theManager, size_type		theBlockCount);
60
	XalanElemElementAllocator(
61
            MemoryManagerType&  theManager,
62
            size_type		    theBlockCount);
61
63
62
	~XalanElemElementAllocator();
64
	~XalanElemElementAllocator();
63
65
Lines 77-84 Link Here
77
			StylesheetConstructionContext&	constructionContext,
79
			StylesheetConstructionContext&	constructionContext,
78
			Stylesheet&						stylesheetTree,
80
			Stylesheet&						stylesheetTree,
79
			const AttributeListType&		atts,
81
			const AttributeListType&		atts,
80
			int								lineNumber,
82
			XalanFileLoc					lineNumber,
81
			int								columnNumber);
83
			XalanFileLoc					columnNumber);
82
84
83
	/**
85
	/**
84
	 * Determine if an object is owned by the allocator...
86
	 * Determine if an object is owned by the allocator...
(-)src/xalanc/XSLT/XalanElemAttributeAllocator.hpp (-3 / +5 lines)
Lines 57-63 Link Here
57
	 *
57
	 *
58
	 * @param theBlockSize The block size.
58
	 * @param theBlockSize The block size.
59
	 */
59
	 */
60
	XalanElemAttributeAllocator(MemoryManagerType&  theManager, size_type		theBlockCount);
60
	XalanElemAttributeAllocator(
61
                MemoryManagerType&  theManager,
62
                size_type		    theBlockCount);
61
63
62
	~XalanElemAttributeAllocator();
64
	~XalanElemAttributeAllocator();
63
	
65
	
Lines 77-84 Link Here
77
			StylesheetConstructionContext&	constructionContext,
79
			StylesheetConstructionContext&	constructionContext,
78
			Stylesheet&						stylesheetTree,
80
			Stylesheet&						stylesheetTree,
79
			const AttributeListType&		atts,
81
			const AttributeListType&		atts,
80
			int								lineNumber,
82
			XalanFileLoc					lineNumber,
81
			int								columnNumber);
83
			XalanFileLoc					columnNumber);
82
84
83
	/**
85
	/**
84
	 * Determine if an object is owned by the allocator...
86
	 * Determine if an object is owned by the allocator...
(-)src/xalanc/XSLT/StylesheetConstructionContextDefault.cpp (-17 / +17 lines)
Lines 631-638 Link Here
631
        StylesheetConstructionContext&  constructionContext,
631
        StylesheetConstructionContext&  constructionContext,
632
        Stylesheet&                     stylesheetTree,
632
        Stylesheet&                     stylesheetTree,
633
        const AttributeListType&        atts,
633
        const AttributeListType&        atts,
634
        int                             lineNumber,
634
        XalanFileLoc                    lineNumber,
635
        int                             columnNumber)
635
        XalanFileLoc                    columnNumber)
636
    {
636
    {
637
        Type*   theResult;
637
        Type*   theResult;
638
638
Lines 656-664 Link Here
656
            const AttributeListType&    atts,
656
            const AttributeListType&    atts,
657
            const LocatorType*          locator)
657
            const LocatorType*          locator)
658
{
658
{
659
    const XalanLocator::size_type   lineNumber = XalanLocator::getLineNumber(locator);
659
    const XalanFileLoc  lineNumber =
660
    const XalanLocator::size_type   columnNumber = XalanLocator::getColumnNumber(locator);
660
        XalanLocator::getLineNumber(locator);
661
661
662
    const XalanFileLoc  columnNumber =
663
        XalanLocator::getColumnNumber(locator);
664
662
    ElemTemplateElement*    theElement = 0;
665
    ElemTemplateElement*    theElement = 0;
663
666
664
    switch(token)
667
    switch(token)
Lines 975-983 Link Here
975
            const AttributeListType&    atts,
978
            const AttributeListType&    atts,
976
            const LocatorType*          locator)
979
            const LocatorType*          locator)
977
{
980
{
978
    const XalanLocator::size_type   lineNumber = XalanLocator::getLineNumber(locator);
981
    const XalanFileLoc  lineNumber =
979
    const XalanLocator::size_type   columnNumber = XalanLocator::getColumnNumber(locator);
982
        XalanLocator::getLineNumber(locator);
980
983
984
    const XalanFileLoc  columnNumber =
985
        XalanLocator::getColumnNumber(locator);
986
981
    ElemTemplateElement*    theElement = 0;
987
    ElemTemplateElement*    theElement = 0;
982
988
983
    if (token == ELEMNAME_LITERAL_RESULT)
989
    if (token == ELEMNAME_LITERAL_RESULT)
Lines 1032-1040 Link Here
1032
            ExtensionNSHandler&         handler,
1038
            ExtensionNSHandler&         handler,
1033
            const LocatorType*          locator)
1039
            const LocatorType*          locator)
1034
{
1040
{
1035
    const XalanLocator::size_type   lineNumber = XalanLocator::getLineNumber(locator);
1036
    const XalanLocator::size_type   columnNumber = XalanLocator::getColumnNumber(locator);
1037
1038
    m_allocatedElements.push_back(0);
1041
    m_allocatedElements.push_back(0);
1039
1042
1040
    m_allocatedElements.back() = ElemExtensionCall::create(
1043
    m_allocatedElements.back() = ElemExtensionCall::create(
Lines 1043-1050 Link Here
1043
            stylesheetTree,
1046
            stylesheetTree,
1044
            name,
1047
            name,
1045
            atts,
1048
            atts,
1046
            lineNumber,
1049
            XalanLocator::getLineNumber(locator),
1047
            columnNumber,
1050
            XalanLocator::getColumnNumber(locator),
1048
            handler);
1051
            handler);
1049
1052
1050
    return m_allocatedElements.back();
1053
    return m_allocatedElements.back();
Lines 1061-1074 Link Here
1061
            bool                        disableOutputEscaping,
1064
            bool                        disableOutputEscaping,
1062
            const LocatorType*          locator)
1065
            const LocatorType*          locator)
1063
{
1066
{
1064
    const XalanLocator::size_type   lineNumber = XalanLocator::getLineNumber(locator);
1065
    const XalanLocator::size_type   columnNumber = XalanLocator::getColumnNumber(locator);
1066
1067
    return m_elemTextLiteralAllocator.create(
1067
    return m_elemTextLiteralAllocator.create(
1068
            *this,
1068
            *this,
1069
            stylesheetTree,
1069
            stylesheetTree,
1070
            lineNumber,
1070
            XalanLocator::getLineNumber(locator),
1071
            columnNumber,
1071
            XalanLocator::getColumnNumber(locator),
1072
            chars,
1072
            chars,
1073
            0,
1073
            0,
1074
            length,
1074
            length,
Lines 1992-1998 Link Here
1992
    }
1992
    }
1993
};
1993
};
1994
1994
1995
const unsigned int  StylesheetConstructionContextDefault::s_elementTokenTableSize =
1995
const XalanSize_t  StylesheetConstructionContextDefault::s_elementTokenTableSize =
1996
        sizeof(s_elementTokenTable) / sizeof(s_elementTokenTable[0]);
1996
        sizeof(s_elementTokenTable) / sizeof(s_elementTokenTable[0]);
1997
1997
1998
const StylesheetConstructionContextDefault::ElementTokenTableEntry&     StylesheetConstructionContextDefault::s_elementTokenTableLast =
1998
const StylesheetConstructionContextDefault::ElementTokenTableEntry&     StylesheetConstructionContextDefault::s_elementTokenTableLast =
(-)src/xalanc/XSLT/StylesheetConstructionContext.hpp (-6 lines)
Lines 76-87 Link Here
76
76
77
	typedef XalanQName::NamespacesStackType		NamespacesStackType;
77
	typedef XalanQName::NamespacesStackType		NamespacesStackType;
78
78
79
#if defined(XALAN_STRICT_ANSI_HEADERS)
80
	typedef std::size_t		size_type;
81
#else
82
	typedef size_t			size_type;
83
#endif
84
85
	/**
79
	/**
86
	 * IDs for XSL element types. These are the values
80
	 * IDs for XSL element types. These are the values
87
	 * that must be returned by getElementToken().
81
	 * that must be returned by getElementToken().
(-)src/xalanc/XSLT/ElemDecimalFormat.hpp (-3 / +3 lines)
Lines 57-64 Link Here
57
			StylesheetConstructionContext&	constructionContext,
57
			StylesheetConstructionContext&	constructionContext,
58
			Stylesheet&						stylesheetTree,
58
			Stylesheet&						stylesheetTree,
59
			const AttributeListType&		atts,
59
			const AttributeListType&		atts,
60
			int								lineNumber,
60
			XalanFileLoc					lineNumber,
61
			int								columnNumber);
61
			XalanFileLoc					columnNumber);
62
62
63
63
64
	~ElemDecimalFormat();
64
	~ElemDecimalFormat();
Lines 83-89 Link Here
83
	}
83
	}
84
84
85
	virtual	const XPath*
85
	virtual	const XPath*
86
	getXPath(unsigned int	index = 0) const;
86
	getXPath(XalanSize_t    index) const;
87
87
88
private:
88
private:
89
89
(-)src/xalanc/XSLT/ElemAttributeSet.hpp (-2 / +2 lines)
Lines 49-56 Link Here
49
			StylesheetConstructionContext&	constructionContext,
49
			StylesheetConstructionContext&	constructionContext,
50
			Stylesheet&						stylesheetTree,
50
			Stylesheet&						stylesheetTree,
51
			const AttributeListType&		atts,
51
			const AttributeListType&		atts,
52
			int								lineNumber,
52
			XalanFileLoc				    lineNumber,
53
			int								columnNumber);
53
			XalanFileLoc					columnNumber);
54
54
55
	virtual
55
	virtual
56
	~ElemAttributeSet();
56
	~ElemAttributeSet();
(-)src/xalanc/XSLT/StylesheetExecutionContextDefault.cpp (-6 / +6 lines)
Lines 928-936 Link Here
928
928
929
void
929
void
930
StylesheetExecutionContextDefault::characters(
930
StylesheetExecutionContextDefault::characters(
931
            const XalanDOMChar*         ch,
931
            const XalanDOMChar*     ch,
932
            XalanDOMString::size_type   start,
932
            fl_size_type            start,
933
            XalanDOMString::size_type   length)
933
            fl_size_type            length)
934
{
934
{
935
    assert(m_xsltProcessor != 0);
935
    assert(m_xsltProcessor != 0);
936
936
Lines 941-949 Link Here
941
941
942
void
942
void
943
StylesheetExecutionContextDefault::charactersRaw(
943
StylesheetExecutionContextDefault::charactersRaw(
944
            const XalanDOMChar*         ch,
944
            const XalanDOMChar*     ch,
945
            XalanDOMString::size_type   start,
945
            fl_size_type            start,
946
            XalanDOMString::size_type   length)
946
            fl_size_type            length)
947
{
947
{
948
    assert(m_xsltProcessor != 0);
948
    assert(m_xsltProcessor != 0);
949
949
(-)src/xalanc/XSLT/ElemSort.cpp (-13 / +13 lines)
Lines 39-46 Link Here
39
            StylesheetConstructionContext&  constructionContext,
39
            StylesheetConstructionContext&  constructionContext,
40
            Stylesheet&                     stylesheetTree,
40
            Stylesheet&                     stylesheetTree,
41
            const AttributeListType&        atts,
41
            const AttributeListType&        atts,
42
            int                             lineNumber,
42
            XalanFileLoc                    lineNumber,
43
            int                             columnNumber) :
43
            XalanFileLoc                    columnNumber) :
44
    ElemTemplateElement(constructionContext,
44
    ElemTemplateElement(constructionContext,
45
                        stylesheetTree,
45
                        stylesheetTree,
46
                        lineNumber,
46
                        lineNumber,
Lines 52-89 Link Here
52
    m_orderAVT(0),
52
    m_orderAVT(0),
53
    m_caseOrderAVT(0)
53
    m_caseOrderAVT(0)
54
{
54
{
55
    const unsigned int nAttrs = atts.getLength();
55
    const XalanSize_t nAttrs = atts.getLength();
56
56
57
    for(unsigned int i = 0; i < nAttrs; i++)
57
    for (XalanSize_t i = 0; i < nAttrs; i++)
58
    {
58
    {
59
        const XalanDOMChar* const   aname = atts.getName(i);
59
        const XalanDOMChar* const   aname = atts.getName(i);
60
60
61
        if(equals(aname, Constants::ATTRNAME_SELECT))
61
        if (equals(aname, Constants::ATTRNAME_SELECT))
62
        {
62
        {
63
            m_selectPattern 
63
            m_selectPattern 
64
                = constructionContext.createXPath(getLocator(), atts.getValue(i), *this);
64
                = constructionContext.createXPath(getLocator(), atts.getValue(i), *this);
65
        }
65
        }
66
        else if(equals(aname, Constants::ATTRNAME_LANG))
66
        else if (equals(aname, Constants::ATTRNAME_LANG))
67
        {           
67
        {           
68
            m_langAVT =
68
            m_langAVT =
69
                    constructionContext.createAVT(getLocator(), aname, atts.getValue(i), *this);
69
                    constructionContext.createAVT(getLocator(), aname, atts.getValue(i), *this);
70
        }
70
        }
71
        else if(equals(aname, Constants::ATTRNAME_DATATYPE))
71
        else if (equals(aname, Constants::ATTRNAME_DATATYPE))
72
        {
72
        {
73
            m_dataTypeAVT =
73
            m_dataTypeAVT =
74
                    constructionContext.createAVT(getLocator(), aname, atts.getValue(i), *this);
74
                    constructionContext.createAVT(getLocator(), aname, atts.getValue(i), *this);
75
        }
75
        }
76
        else if(equals(aname, Constants::ATTRNAME_ORDER))
76
        else if (equals(aname, Constants::ATTRNAME_ORDER))
77
        {
77
        {
78
            m_orderAVT =
78
            m_orderAVT =
79
                    constructionContext.createAVT(getLocator(), aname, atts.getValue(i), *this);
79
                    constructionContext.createAVT(getLocator(), aname, atts.getValue(i), *this);
80
        }
80
        }
81
        else if(equals(aname, Constants::ATTRNAME_CASEORDER))
81
        else if (equals(aname, Constants::ATTRNAME_CASEORDER))
82
        {
82
        {
83
            m_caseOrderAVT =
83
            m_caseOrderAVT =
84
                    constructionContext.createAVT(getLocator(), aname, atts.getValue(i), *this);
84
                    constructionContext.createAVT(getLocator(), aname, atts.getValue(i), *this);
85
        }
85
        }
86
        else if(isAttrOK(
86
        else if (isAttrOK(
87
                    aname,
87
                    aname,
88
                    atts,
88
                    atts,
89
                    i,
89
                    i,
Lines 126-133 Link Here
126
            StylesheetConstructionContext&  constructionContext,
126
            StylesheetConstructionContext&  constructionContext,
127
            Stylesheet&                     stylesheetTree,
127
            Stylesheet&                     stylesheetTree,
128
            const AttributeListType&        atts,
128
            const AttributeListType&        atts,
129
            int                             lineNumber,
129
            XalanFileLoc                    lineNumber,
130
            int                             columnNumber)
130
            XalanFileLoc                    columnNumber)
131
{
131
{
132
    typedef ElemSort ThisType;
132
    typedef ElemSort ThisType;
133
133
Lines 163-169 Link Here
163
163
164
164
165
const XPath*
165
const XPath*
166
ElemSort::getXPath(unsigned int     index) const
166
ElemSort::getXPath(XalanSize_t  index) const
167
{
167
{
168
    return index == 0 ? m_selectPattern : 0;
168
    return index == 0 ? m_selectPattern : 0;
169
}
169
}
(-)src/xalanc/XSLT/ElemElement.hpp (-2 / +2 lines)
Lines 60-67 Link Here
60
			StylesheetConstructionContext&	constructionContext,
60
			StylesheetConstructionContext&	constructionContext,
61
			Stylesheet&						stylesheetTree,
61
			Stylesheet&						stylesheetTree,
62
			const AttributeListType&		atts,
62
			const AttributeListType&		atts,
63
			int								lineNumber,
63
			XalanFileLoc					lineNumber,
64
			int								columnNumber);
64
			XalanFileLoc					columnNumber);
65
65
66
	virtual
66
	virtual
67
	~ElemElement();
67
	~ElemElement();
(-)src/xalanc/XSLT/XalanElemApplyTemplatesAllocator.hpp (-3 / +5 lines)
Lines 57-63 Link Here
57
	 *
57
	 *
58
	 * @param theBlockSize The block size.
58
	 * @param theBlockSize The block size.
59
	 */
59
	 */
60
	XalanElemApplyTemplatesAllocator(MemoryManagerType&  theManager, size_type		theBlockCount);
60
	XalanElemApplyTemplatesAllocator(
61
            MemoryManagerType&  theManager,
62
            size_type		    theBlockCount);
61
63
62
	~XalanElemApplyTemplatesAllocator();
64
	~XalanElemApplyTemplatesAllocator();
63
	
65
	
Lines 77-84 Link Here
77
			StylesheetConstructionContext&	constructionContext,
79
			StylesheetConstructionContext&	constructionContext,
78
			Stylesheet&						stylesheetTree,
80
			Stylesheet&						stylesheetTree,
79
			const AttributeListType&		atts,
81
			const AttributeListType&		atts,
80
			int								lineNumber,
82
			XalanFileLoc					lineNumber,
81
			int								columnNumber);
83
			XalanFileLoc					columnNumber);
82
84
83
	/**
85
	/**
84
	 * Determine if an object is owned by the allocator...
86
	 * Determine if an object is owned by the allocator...
(-)src/xalanc/XSLT/ElemCopyOf.hpp (-3 / +3 lines)
Lines 57-64 Link Here
57
			StylesheetConstructionContext&	constructionContext,
57
			StylesheetConstructionContext&	constructionContext,
58
			Stylesheet&						stylesheetTree,
58
			Stylesheet&						stylesheetTree,
59
			const AttributeListType&		atts,
59
			const AttributeListType&		atts,
60
			int								lineNumber,
60
			XalanFileLoc					lineNumber,
61
			int								columnNumber);
61
			XalanFileLoc					columnNumber);
62
	
62
	
63
63
64
64
Lines 76-82 Link Here
76
	execute(StylesheetExecutionContext&		executionContext) const;
76
	execute(StylesheetExecutionContext&		executionContext) const;
77
#endif
77
#endif
78
	virtual	const XPath*
78
	virtual	const XPath*
79
	getXPath(unsigned int	index = 0) const;
79
	getXPath(XalanSize_t    index) const;
80
80
81
private:
81
private:
82
82
(-)src/xalanc/XSLT/ElemApplyTemplates.cpp (-4 / +4 lines)
Lines 50-57 Link Here
50
            StylesheetConstructionContext&  constructionContext,
50
            StylesheetConstructionContext&  constructionContext,
51
            Stylesheet&                     stylesheetTree,
51
            Stylesheet&                     stylesheetTree,
52
            const AttributeListType&        atts,
52
            const AttributeListType&        atts,
53
            int                             lineNumber,
53
            XalanFileLoc                    lineNumber,
54
            int                             columnNumber) :
54
            XalanFileLoc                    columnNumber) :
55
    ParentType(
55
    ParentType(
56
        constructionContext,
56
        constructionContext,
57
        stylesheetTree,
57
        stylesheetTree,
Lines 60-68 Link Here
60
        StylesheetConstructionContext::ELEMNAME_APPLY_TEMPLATES),
60
        StylesheetConstructionContext::ELEMNAME_APPLY_TEMPLATES),
61
    m_mode(0)
61
    m_mode(0)
62
{
62
{
63
    const unsigned  int nAttrs = atts.getLength();
63
    const XalanSize_t  nAttrs = atts.getLength();
64
64
65
    for(unsigned int i = 0; i < nAttrs; i++)
65
    for (XalanSize_t i = 0; i < nAttrs; i++)
66
    {
66
    {
67
        const XalanDOMChar* const   aname = atts.getName(i);
67
        const XalanDOMChar* const   aname = atts.getName(i);
68
68
(-)src/xalanc/XSLT/XalanElemAttributeSetAllocator.hpp (-3 / +5 lines)
Lines 57-63 Link Here
57
	 *
57
	 *
58
	 * @param theBlockSize The block size.
58
	 * @param theBlockSize The block size.
59
	 */
59
	 */
60
	XalanElemAttributeSetAllocator(MemoryManagerType&  theManager, size_type		theBlockCount);
60
	XalanElemAttributeSetAllocator(
61
            MemoryManagerType&  theManager,
62
            size_type		    theBlockCount);
61
63
62
	~XalanElemAttributeSetAllocator();
64
	~XalanElemAttributeSetAllocator();
63
	
65
	
Lines 77-84 Link Here
77
			StylesheetConstructionContext&	constructionContext,
79
			StylesheetConstructionContext&	constructionContext,
78
			Stylesheet&						stylesheetTree,
80
			Stylesheet&						stylesheetTree,
79
			const AttributeListType&		atts,
81
			const AttributeListType&		atts,
80
			int								lineNumber,
82
			XalanFileLoc					lineNumber,
81
			int								columnNumber);
83
			XalanFileLoc					columnNumber);
82
84
83
	/**
85
	/**
84
	 * Determine if an object is owned by the allocator...
86
	 * Determine if an object is owned by the allocator...
(-)src/xalanc/XSLT/StylesheetExecutionContext.hpp (-11 / +10 lines)
Lines 56-61 Link Here
56
56
57
57
58
#include <xalanc/PlatformSupport/AttributeListImpl.hpp>
58
#include <xalanc/PlatformSupport/AttributeListImpl.hpp>
59
#include <xalanc/PlatformSupport/FormatterListener.hpp>
59
#include <xalanc/PlatformSupport/XalanCollationServices.hpp>
60
#include <xalanc/PlatformSupport/XalanCollationServices.hpp>
60
61
61
62
Lines 105-116 Link Here
105
{
106
{
106
public:
107
public:
107
108
108
#if defined(XALAN_STRICT_ANSI_HEADERS)
109
    typedef XalanSize_t     tl_size_type;
109
    typedef std::size_t     tl_size_type;
110
#else
111
    typedef size_t          tl_size_type;
112
#endif
113
110
111
    typedef FormatterListener::size_type    fl_size_type;
112
114
#if defined(XALAN_NO_STD_NAMESPACE)
113
#if defined(XALAN_NO_STD_NAMESPACE)
115
    typedef ostream         StreamType;
114
    typedef ostream         StreamType;
116
#else
115
#else
Lines 1069-1077 Link Here
1069
     */
1068
     */
1070
    virtual void
1069
    virtual void
1071
    characters(
1070
    characters(
1072
            const XalanDOMChar*         ch,
1071
            const XalanDOMChar*     ch,
1073
            XalanDOMString::size_type   start,
1072
            fl_size_type            start,
1074
            XalanDOMString::size_type   length) = 0;
1073
            fl_size_type            length) = 0;
1075
1074
1076
    /**
1075
    /**
1077
     * Receive notification of character data. If available, when the
1076
     * Receive notification of character data. If available, when the
Lines 1084-1092 Link Here
1084
     */
1083
     */
1085
    virtual void
1084
    virtual void
1086
    charactersRaw(
1085
    charactersRaw(
1087
            const XalanDOMChar*         ch,
1086
            const XalanDOMChar*     ch,
1088
            XalanDOMString::size_type   start,
1087
            fl_size_type            start,
1089
            XalanDOMString::size_type   length) = 0;
1088
            fl_size_type            length) = 0;
1090
1089
1091
    /**
1090
    /**
1092
     * Called when a Comment is to be constructed.
1091
     * Called when a Comment is to be constructed.
(-)src/xalanc/XSLT/ElemTemplateElement.cpp (-11 / +12 lines)
Lines 82-89 Link Here
82
ElemTemplateElement::ElemTemplateElement(
82
ElemTemplateElement::ElemTemplateElement(
83
            StylesheetConstructionContext&  constructionContext,
83
            StylesheetConstructionContext&  constructionContext,
84
            Stylesheet&                     stylesheetTree,
84
            Stylesheet&                     stylesheetTree,
85
            int                             lineNumber,
85
            XalanFileLoc                    lineNumber,
86
            int                             columnNumber,
86
            XalanFileLoc                    columnNumber,
87
            int                             xslToken) :
87
            int                             xslToken) :
88
    PrefixResolver(),
88
    PrefixResolver(),
89
    m_stylesheet(stylesheetTree),
89
    m_stylesheet(stylesheetTree),
Lines 112-119 Link Here
112
            Stylesheet&                     stylesheetTree,
112
            Stylesheet&                     stylesheetTree,
113
            int                             xslToken,
113
            int                             xslToken,
114
            const XalanDOMString&           baseURI,
114
            const XalanDOMString&           baseURI,
115
            int                             lineNumber,
115
            XalanFileLoc                    lineNumber,
116
            int                             columnNumber) :
116
            XalanFileLoc                    columnNumber) :
117
    PrefixResolver(),
117
    PrefixResolver(),
118
    m_stylesheet(stylesheetTree),
118
    m_stylesheet(stylesheetTree),
119
    m_namespacesHandler(constructionContext.getMemoryManager()),
119
    m_namespacesHandler(constructionContext.getMemoryManager()),
Lines 158-164 Link Here
158
ElemTemplateElement::isAttrOK(
158
ElemTemplateElement::isAttrOK(
159
            const XalanDOMChar*             attrName,
159
            const XalanDOMChar*             attrName,
160
            const AttributeListType&        atts,
160
            const AttributeListType&        atts,
161
            int                             which,
161
            XalanSize_t                     which,
162
            StylesheetConstructionContext&  constructionContext) const
162
            StylesheetConstructionContext&  constructionContext) const
163
{
163
{
164
    return m_stylesheet.isAttrOK(attrName, atts, which, constructionContext);
164
    return m_stylesheet.isAttrOK(attrName, atts, which, constructionContext);
Lines 171-177 Link Here
171
            const XalanDOMChar*             elementName, 
171
            const XalanDOMChar*             elementName, 
172
            const XalanDOMChar*             aname, 
172
            const XalanDOMChar*             aname, 
173
            const AttributeListType&        atts,
173
            const AttributeListType&        atts,
174
            int                             which,
174
            XalanSize_t                     which,
175
            StylesheetConstructionContext&  constructionContext)
175
            StylesheetConstructionContext&  constructionContext)
176
{
176
{
177
    if(constructionContext.isXMLSpaceAttribute(
177
    if(constructionContext.isXMLSpaceAttribute(
Lines 1062-1073 Link Here
1062
1062
1063
1063
1064
const XPath*
1064
const XPath*
1065
ElemTemplateElement::getXPath(unsigned int  /* index */) const
1065
ElemTemplateElement::getXPath(XalanSize_t   /* index */) const
1066
{
1066
{
1067
    return 0;
1067
    return 0;
1068
}
1068
}
1069
1069
1070
1070
1071
1071
#if !defined(XALAN_RECURSIVE_STYLESHEET_EXECUTION)
1072
#if !defined(XALAN_RECURSIVE_STYLESHEET_EXECUTION)
1072
const ElemTemplateElement*
1073
const ElemTemplateElement*
1073
ElemTemplateElement::findTemplateToTransformChild(
1074
ElemTemplateElement::findTemplateToTransformChild(
Lines 1504-1511 Link Here
1504
1505
1505
1506
1506
ElemTemplateElement::LocatorProxy::LocatorProxy(
1507
ElemTemplateElement::LocatorProxy::LocatorProxy(
1507
            size_type               theLineNumber,
1508
            XMLFileLoc              theLineNumber,
1508
            size_type               theColumnNumber,
1509
            XMLFileLoc              theColumnNumber,
1509
            const XalanDOMString&   theURI) :
1510
            const XalanDOMString&   theURI) :
1510
    m_lineNumber(theLineNumber),
1511
    m_lineNumber(theLineNumber),
1511
    m_columnNumber(theColumnNumber),
1512
    m_columnNumber(theColumnNumber),
Lines 1521-1527 Link Here
1521
1522
1522
1523
1523
1524
1524
ElemTemplateElement::LocatorProxy::size_type
1525
XMLFileLoc
1525
ElemTemplateElement::LocatorProxy::getLineNumber() const
1526
ElemTemplateElement::LocatorProxy::getLineNumber() const
1526
{
1527
{
1527
    return m_lineNumber;
1528
    return m_lineNumber;
Lines 1529-1535 Link Here
1529
1530
1530
1531
1531
1532
1532
ElemTemplateElement::LocatorProxy::size_type
1533
XMLFileLoc
1533
ElemTemplateElement::LocatorProxy::getColumnNumber() const
1534
ElemTemplateElement::LocatorProxy::getColumnNumber() const
1534
{
1535
{
1535
    return m_columnNumber;
1536
    return m_columnNumber;
(-)src/xalanc/XSLT/Stylesheet.cpp (-19 / +17 lines)
Lines 252-260 Link Here
252
    XPath*                  matchAttr = 0;
252
    XPath*                  matchAttr = 0;
253
    XPath*                  useAttr = 0;
253
    XPath*                  useAttr = 0;
254
 
254
 
255
    const unsigned int  nAttrs = atts.getLength();
255
    const XalanSize_t   nAttrs = atts.getLength();
256
256
257
    for(unsigned int i = 0; i < nAttrs; i++)
257
    for(XalanSize_t i = 0; i < nAttrs; i++)
258
    {
258
    {
259
        const XalanDOMChar* const   aname = atts.getName(i);
259
        const XalanDOMChar* const   aname = atts.getName(i);
260
260
Lines 317-323 Link Here
317
        }
317
        }
318
    }
318
    }
319
319
320
    if(0 == theQName)
320
    if (0 == theQName)
321
    {
321
    {
322
        const GetAndReleaseCachedString     theGuard(constructionContext);
322
        const GetAndReleaseCachedString     theGuard(constructionContext);
323
323
Lines 331-337 Link Here
331
            locator);
331
            locator);
332
    }
332
    }
333
333
334
    if(0 == matchAttr)
334
    if (0 == matchAttr)
335
    {
335
    {
336
        const GetAndReleaseCachedString     theGuard(constructionContext);
336
        const GetAndReleaseCachedString     theGuard(constructionContext);
337
337
Lines 345-351 Link Here
345
            locator);
345
            locator);
346
    }
346
    }
347
347
348
    if(0 == useAttr)
348
    if (0 == useAttr)
349
    {
349
    {
350
        const GetAndReleaseCachedString     theGuard(constructionContext);
350
        const GetAndReleaseCachedString     theGuard(constructionContext);
351
351
Lines 374-386 Link Here
374
void
374
void
375
Stylesheet::pushNamespaces(const AttributeListType&     atts)
375
Stylesheet::pushNamespaces(const AttributeListType&     atts)
376
{
376
{
377
    const unsigned int      nAttrs = atts.getLength();
377
    const XalanSize_t       nAttrs = atts.getLength();
378
378
379
    NamespaceVectorType     namespaces(getMemoryManager());
379
    NamespaceVectorType     namespaces(getMemoryManager());
380
380
381
    XalanDOMString          prefix(getMemoryManager());
381
    XalanDOMString          prefix(getMemoryManager());
382
382
383
    for(unsigned int i = 0; i < nAttrs; i++)
383
    for(XalanSize_t i = 0; i < nAttrs; i++)
384
    {
384
    {
385
        const XalanDOMChar* const   aname = atts.getName(i);
385
        const XalanDOMChar* const   aname = atts.getName(i);
386
        const XalanDOMChar* const   value = atts.getValue(i);
386
        const XalanDOMChar* const   value = atts.getValue(i);
Lines 438-449 Link Here
438
            Stylesheet::PatternTableVectorType&     theList,
438
            Stylesheet::PatternTableVectorType&     theList,
439
            const XalanMatchPatternData*            thePattern)
439
            const XalanMatchPatternData*            thePattern)
440
{
440
{
441
442
    typedef Stylesheet::size_type   size_type;
443
    assert(thePattern != 0);
441
    assert(thePattern != 0);
444
442
445
    const double        thePatternPriority = thePattern->getPriorityOrDefault();
443
    const double        thePatternPriority = thePattern->getPriorityOrDefault();
446
    const size_type     thePatternPosition = thePattern->getPosition();
444
    const XalanSize_t   thePatternPosition = thePattern->getPosition();
447
445
448
    typedef Stylesheet::PatternTableVectorType  PatternTableListType;
446
    typedef Stylesheet::PatternTableVectorType  PatternTableListType;
449
    typedef PatternTableListType::iterator      iterator;
447
    typedef PatternTableListType::iterator      iterator;
Lines 452-458 Link Here
452
450
453
    const iterator  theEnd = theList.end();
451
    const iterator  theEnd = theList.end();
454
452
455
    while(theCurrent != theEnd)
453
    while (theCurrent != theEnd)
456
    {
454
    {
457
        const double    theCurrentPriority = (*theCurrent)->getPriorityOrDefault();
455
        const double    theCurrentPriority = (*theCurrent)->getPriorityOrDefault();
458
456
Lines 626-632 Link Here
626
Stylesheet::isAttrOK(
624
Stylesheet::isAttrOK(
627
            const XalanDOMChar*             attrName,
625
            const XalanDOMChar*             attrName,
628
            const AttributeListType&        /* atts */,
626
            const AttributeListType&        /* atts */,
629
            int                             /* which */,
627
            XalanSize_t                     /* which */,
630
            StylesheetConstructionContext&  constructionContext) const
628
            StylesheetConstructionContext&  constructionContext) const
631
{
629
{
632
    // Namespace declarations are OK by definition
630
    // Namespace declarations are OK by definition
Lines 1497-1512 Link Here
1497
            const AttributeListType&        atts,
1495
            const AttributeListType&        atts,
1498
            StylesheetConstructionContext&  constructionContext)
1496
            StylesheetConstructionContext&  constructionContext)
1499
{
1497
{
1500
    const unsigned int      nAttrs = atts.getLength();
1498
    const XalanSize_t       nAttrs = atts.getLength();
1501
1499
1502
    const XalanDOMString*   stylesheetNamespace = 0;
1500
    const XalanDOMString*   stylesheetNamespace = 0;
1503
    const XalanDOMString*   resultNamespace = 0;
1501
    const XalanDOMString*   resultNamespace = 0;
1504
1502
1505
    for(unsigned int i = 0; i < nAttrs; i++)
1503
    for (XalanSize_t i = 0; i < nAttrs; i++)
1506
    {
1504
    {
1507
        const XalanDOMChar* const   aname = atts.getName(i);
1505
        const XalanDOMChar* const   aname = atts.getName(i);
1508
1506
1509
        if(equals(aname, Constants::ATTRNAME_STYLESHEET_PREFIX) == true)
1507
        if (equals(aname, Constants::ATTRNAME_STYLESHEET_PREFIX) == true)
1510
        {
1508
        {
1511
            const XalanDOMChar* const   value = atts.getValue(i);
1509
            const XalanDOMChar* const   value = atts.getValue(i);
1512
1510
Lines 1519-1525 Link Here
1519
                stylesheetNamespace = getNamespaceForPrefix(value, constructionContext);
1517
                stylesheetNamespace = getNamespaceForPrefix(value, constructionContext);
1520
            }
1518
            }
1521
        }
1519
        }
1522
        else if(equals(aname, Constants::ATTRNAME_RESULT_PREFIX))
1520
        else if (equals(aname, Constants::ATTRNAME_RESULT_PREFIX))
1523
        {
1521
        {
1524
            const XalanDOMChar* const   value = atts.getValue(i);
1522
            const XalanDOMChar* const   value = atts.getValue(i);
1525
1523
Lines 1532-1538 Link Here
1532
                resultNamespace = getNamespaceForPrefix(value, constructionContext);
1530
                resultNamespace = getNamespaceForPrefix(value, constructionContext);
1533
            }
1531
            }
1534
        }
1532
        }
1535
        else if(!isAttrOK(aname, atts, i, constructionContext))
1533
        else if (!isAttrOK(aname, atts, i, constructionContext))
1536
        {
1534
        {
1537
            const GetAndReleaseCachedString     theGuard(constructionContext);
1535
            const GetAndReleaseCachedString     theGuard(constructionContext);
1538
1536
Lines 1588-1597 Link Here
1588
            const AttributeListType&        atts,
1586
            const AttributeListType&        atts,
1589
            const LocatorType*              locator)
1587
            const LocatorType*              locator)
1590
{
1588
{
1591
    const XalanLocator::size_type   lineNumber =
1589
    const XalanFileLoc  lineNumber =
1592
        XalanLocator::getLineNumber(locator);
1590
        XalanLocator::getLineNumber(locator);
1593
1591
1594
    const XalanLocator::size_type   columnNumber =
1592
    const XalanFileLoc  columnNumber =
1595
        XalanLocator::getColumnNumber(locator);
1593
        XalanLocator::getColumnNumber(locator);
1596
1594
1597
    m_elemDecimalFormats.reserve(m_elemDecimalFormats.size() + 1);
1595
    m_elemDecimalFormats.reserve(m_elemDecimalFormats.size() + 1);
(-)src/xalanc/XSLT/ElemUse.cpp (-3 / +3 lines)
Lines 48-55 Link Here
48
ElemUse::ElemUse(
48
ElemUse::ElemUse(
49
			StylesheetConstructionContext&	constructionContext,
49
			StylesheetConstructionContext&	constructionContext,
50
			Stylesheet&						stylesheetTree,
50
			Stylesheet&						stylesheetTree,
51
			int								lineNumber,
51
			XalanFileLoc					lineNumber,
52
			int								columnNumber,
52
			XalanFileLoc					columnNumber,
53
			int								xslToken) :
53
			int								xslToken) :
54
	ElemTemplateElement(constructionContext,
54
	ElemTemplateElement(constructionContext,
55
						stylesheetTree,
55
						stylesheetTree,
Lines 268-274 Link Here
268
			StylesheetConstructionContext&	constructionContext,
268
			StylesheetConstructionContext&	constructionContext,
269
			const XalanDOMChar*				attrName,
269
			const XalanDOMChar*				attrName,
270
			const AttributeListType&		atts,
270
			const AttributeListType&		atts,
271
			int								which)
271
			XalanSize_t						which)
272
{
272
{
273
	bool isUAS = false;
273
	bool isUAS = false;
274
274
(-)src/xalanc/XSLT/ElemValueOf.cpp (-4 / +4 lines)
Lines 185-191 Link Here
185
    void
185
    void
186
    characters(
186
    characters(
187
                const XMLCh* const  chars,
187
                const XMLCh* const  chars,
188
                const unsigned int  length)
188
                const size_type     length)
189
    {
189
    {
190
        m_executionContext.characters(chars, 0, length);
190
        m_executionContext.characters(chars, 0, length);
191
    }
191
    }
Lines 193-199 Link Here
193
    void
193
    void
194
    charactersRaw(
194
    charactersRaw(
195
            const XMLCh* const  chars,
195
            const XMLCh* const  chars,
196
            const unsigned int  length)
196
            const size_type     length)
197
    {
197
    {
198
        m_executionContext.charactersRaw(chars, 0, length);
198
        m_executionContext.charactersRaw(chars, 0, length);
199
    }
199
    }
Lines 206-212 Link Here
206
    void
206
    void
207
    ignorableWhitespace(
207
    ignorableWhitespace(
208
                const XMLCh* const  /* chars */,
208
                const XMLCh* const  /* chars */,
209
                const unsigned int  /* length */)
209
                const size_type     /* length */)
210
    {
210
    {
211
    }
211
    }
212
212
Lines 232-238 Link Here
232
    void
232
    void
233
    cdata(
233
    cdata(
234
                const XMLCh* const  /* ch */,
234
                const XMLCh* const  /* ch */,
235
                const unsigned int  /* length */)
235
                const size_type     /* length */)
236
    {
236
    {
237
    }
237
    }
238
238
(-)src/xalanc/XSLT/ElemCopy.cpp (-8 / +8 lines)
Lines 46-77 Link Here
46
            StylesheetConstructionContext&  constructionContext,
46
            StylesheetConstructionContext&  constructionContext,
47
            Stylesheet&                     stylesheetTree,
47
            Stylesheet&                     stylesheetTree,
48
            const AttributeListType&        atts,
48
            const AttributeListType&        atts,
49
            int                             lineNumber,
49
            XalanFileLoc                    lineNumber,
50
            int                             columnNumber) :
50
            XalanFileLoc                    columnNumber) :
51
    ElemUse(constructionContext,
51
    ElemUse(constructionContext,
52
            stylesheetTree,
52
            stylesheetTree,
53
            lineNumber,
53
            lineNumber,
54
            columnNumber,
54
            columnNumber,
55
            StylesheetConstructionContext::ELEMNAME_COPY)
55
            StylesheetConstructionContext::ELEMNAME_COPY)
56
{
56
{
57
    const unsigned int  nAttrs = atts.getLength();
57
    const XalanSize_t   nAttrs = atts.getLength();
58
58
59
    for(unsigned int i = 0; i < nAttrs; i++)
59
    for (XalanSize_t i = 0; i < nAttrs; i++)
60
    {
60
    {
61
        const XalanDOMChar* const   aname = atts.getName(i);
61
        const XalanDOMChar* const   aname = atts.getName(i);
62
62
63
        if(processUseAttributeSets(
63
        if (processUseAttributeSets(
64
                constructionContext,
64
                constructionContext,
65
                aname,
65
                aname,
66
                atts,
66
                atts,
67
                i) == false &&
67
                i) == false &&
68
           processSpaceAttr(
68
            processSpaceAttr(
69
                Constants::ELEMNAME_COPY_WITH_PREFIX_STRING.c_str(),
69
                Constants::ELEMNAME_COPY_WITH_PREFIX_STRING.c_str(),
70
                aname,
70
                aname,
71
                atts,
71
                atts,
72
                i,
72
                i,
73
                constructionContext) == false &&
73
                constructionContext) == false &&
74
           isAttrOK(
74
            isAttrOK(
75
                aname,
75
                aname,
76
                atts,
76
                atts,
77
                i,
77
                i,
Lines 94-99 Link Here
94
}
94
}
95
95
96
96
97
97
#if !defined(XALAN_RECURSIVE_STYLESHEET_EXECUTION)
98
#if !defined(XALAN_RECURSIVE_STYLESHEET_EXECUTION)
98
const ElemTemplateElement*
99
const ElemTemplateElement*
99
ElemCopy::startElement(StylesheetExecutionContext&  executionContext) const
100
ElemCopy::startElement(StylesheetExecutionContext&  executionContext) const
Lines 120-126 Link Here
120
            executionContext.copyNamespaceAttributes(*sourceNode);
121
            executionContext.copyNamespaceAttributes(*sourceNode);
121
122
122
            return beginExecuteChildren(executionContext);
123
            return beginExecuteChildren(executionContext);
123
124
        }
124
        }
125
        else
125
        else
126
        {
126
        {
(-)src/xalanc/XSLT/StylesheetConstructionContextDefault.hpp (-3 / +4 lines)
Lines 213-220 Link Here
213
	getURLFromString(const XalanDOMString&	urlString);
213
	getURLFromString(const XalanDOMString&	urlString);
214
214
215
	virtual XalanDOMString&
215
	virtual XalanDOMString&
216
	getURLStringFromString(const XalanDOMString&	urlString,
216
	getURLStringFromString(
217
                            XalanDOMString& theResult);
217
            const XalanDOMString&	urlString,
218
            XalanDOMString&         theResult);
218
219
219
	virtual URLAutoPtrType
220
	virtual URLAutoPtrType
220
	getURLFromString(
221
	getURLFromString(
Lines 648-654 Link Here
648
649
649
	static const ElementTokenTableEntry		s_elementTokenTable[];
650
	static const ElementTokenTableEntry		s_elementTokenTable[];
650
651
651
	static const unsigned int				s_elementTokenTableSize;
652
	static const XalanSize_t				s_elementTokenTableSize;
652
653
653
	static const ElementTokenTableEntry&	s_elementTokenTableLast;
654
	static const ElementTokenTableEntry&	s_elementTokenTableLast;
654
655
(-)src/xalanc/XSLT/StylesheetExecutionContextDefault.hpp (-8 / +7 lines)
Lines 471-485 Link Here
471
471
472
    virtual void
472
    virtual void
473
    characters(
473
    characters(
474
            const XalanDOMChar*         ch,
474
            const XalanDOMChar*     ch,
475
            XalanDOMString::size_type   start,
475
            fl_size_type            start,
476
            XalanDOMString::size_type   length);
476
            fl_size_type            length);
477
477
478
    virtual void
478
    virtual void
479
    charactersRaw(
479
    charactersRaw(
480
            const XalanDOMChar*         ch,
480
            const XalanDOMChar*     ch,
481
            XalanDOMString::size_type   start,
481
            fl_size_type            start,
482
            XalanDOMString::size_type   length);
482
            fl_size_type            length);
483
483
484
    virtual void
484
    virtual void
485
    comment(const XalanDOMChar*     data);
485
    comment(const XalanDOMChar*     data);
Lines 515-522 Link Here
515
    endCreateXResultTreeFrag();
515
    endCreateXResultTreeFrag();
516
516
517
    virtual void
517
    virtual void
518
    beginFormatToText(
518
    beginFormatToText(XalanDOMString&   theResult);
519
            XalanDOMString&             theResult);
520
519
521
    virtual void
520
    virtual void
522
    endFormatToText();
521
    endFormatToText();
(-)src/xalanc/XSLT/ElemSort.hpp (-5 / +5 lines)
Lines 59-66 Link Here
59
			StylesheetConstructionContext&	constructionContext,
59
			StylesheetConstructionContext&	constructionContext,
60
			Stylesheet&						stylesheetTree,
60
			Stylesheet&						stylesheetTree,
61
			const AttributeListType&		atts,
61
			const AttributeListType&		atts,
62
			int								lineNumber,
62
			XalanFileLoc					lineNumber,
63
			int								columnNumber);
63
			XalanFileLoc					columnNumber);
64
64
65
    static ElemSort*
65
    static ElemSort*
66
	create(
66
	create(
Lines 68-75 Link Here
68
			StylesheetConstructionContext&	constructionContext,
68
			StylesheetConstructionContext&	constructionContext,
69
			Stylesheet&						stylesheetTree,
69
			Stylesheet&						stylesheetTree,
70
			const AttributeListType&		atts,
70
			const AttributeListType&		atts,
71
			int								lineNumber,
71
			XalanFileLoc					lineNumber,
72
			int								columnNumber);
72
			XalanFileLoc					columnNumber);
73
73
74
	~ElemSort();
74
	~ElemSort();
75
75
Lines 132-138 Link Here
132
	getElementName() const;
132
	getElementName() const;
133
133
134
	virtual	const XPath*
134
	virtual	const XPath*
135
	getXPath(unsigned int	index = 0) const;
135
	getXPath(XalanSize_t	index = 0) const;
136
136
137
private:
137
private:
138
138
(-)src/xalanc/XSLT/XSLTEngineImpl.cpp (-40 / +43 lines)
Lines 692-698 Link Here
692
#if defined(XALAN_OLD_STYLE_CASTS)
692
#if defined(XALAN_OLD_STYLE_CASTS)
693
                nsNode = (const XalanElement*)&fragBase;
693
                nsNode = (const XalanElement*)&fragBase;
694
#else
694
#else
695
                nsNode = static_cast<XalanElement*>(node);
695
                nsNode = static_cast<const XalanElement*>(node);
696
#endif
696
#endif
697
            }
697
            }
698
            else
698
            else
Lines 1064-1072 Link Here
1064
1064
1065
    XalanDOMString          uri( theManager );
1065
    XalanDOMString          uri( theManager );
1066
1066
1067
    int                     lineNumber = XalanLocator::getUnknownValue();
1067
    XalanFileLoc    lineNumber =
1068
    int                     columnNumber = XalanLocator::getUnknownValue();
1068
        XalanLocator::getUnknownValue();
1069
1069
1070
    XalanFileLoc    columnNumber =
1071
        XalanLocator::getUnknownValue();
1072
1070
    const LocatorType*      locator = getLocatorFromStack();
1073
    const LocatorType*      locator = getLocatorFromStack();
1071
1074
1072
    if (locator == 0 && styleNode != 0)
1075
    if (locator == 0 && styleNode != 0)
Lines 1136-1143 Link Here
1136
        id = &theDummy;
1139
        id = &theDummy;
1137
    }
1140
    }
1138
1141
1139
    const XalanLocator::size_type   lineNumber = locator.getLineNumber();
1142
    XalanFileLoc    lineNumber = locator.getLineNumber();
1140
    const XalanLocator::size_type   columnNumber = locator.getColumnNumber();
1143
    XalanFileLoc    columnNumber = locator.getColumnNumber();
1141
1144
1142
    if (m_problemListener != 0)
1145
    if (m_problemListener != 0)
1143
    {
1146
    {
Lines 1364-1375 Link Here
1364
1367
1365
void
1368
void
1366
XSLTEngineImpl::addResultAttribute(
1369
XSLTEngineImpl::addResultAttribute(
1367
            AttributeListImpl&          attList,
1370
            AttributeListImpl&      attList,
1368
            const XalanDOMString&       aname,
1371
            const XalanDOMString&   aname,
1369
            const XalanDOMChar*         value,
1372
            const XalanDOMChar*     value,
1370
            XalanDOMString::size_type   theLength,
1373
            size_type               theLength,
1371
            bool                        fromCopy,
1374
            bool                    fromCopy,
1372
			const LocatorType*	        locator)
1375
            const LocatorType*      locator)
1373
{
1376
{
1374
    assert(value != 0);
1377
    assert(value != 0);
1375
1378
Lines 1517-1529 Link Here
1517
    const AttributeListImpl&    thePendingAttributes =
1520
    const AttributeListImpl&    thePendingAttributes =
1518
        (const AttributeListImpl&)getPendingAttributes();
1521
        (const AttributeListImpl&)getPendingAttributes();
1519
1522
1520
    const unsigned int  n = thePendingAttributes.getLength();
1523
    const XalanSize_t   n = thePendingAttributes.getLength();
1521
1524
1522
    for(unsigned int i = 0; i < n; i++)
1525
    for (XalanSize_t i = 0; i < n; i++)
1523
    {
1526
    {
1524
        if(equals(
1527
        if (equals(
1525
            thePendingAttributes.getName(i),
1528
                thePendingAttributes.getName(i),
1526
            DOMServices::s_XMLNamespace) == true)
1529
                DOMServices::s_XMLNamespace) == true)
1527
        {
1530
        {
1528
            return true;
1531
            return true;
1529
        }
1532
        }
Lines 1650-1656 Link Here
1650
1653
1651
    flushPending();
1654
    flushPending();
1652
1655
1653
    const unsigned int  nAtts = atts.getLength();
1656
    const XalanSize_t   nAtts = atts.getLength();
1654
1657
1655
    assert(m_outputContextStack.empty() == false);
1658
    assert(m_outputContextStack.empty() == false);
1656
1659
Lines 1659-1665 Link Here
1659
1662
1660
    thePendingAttributes.clear();
1663
    thePendingAttributes.clear();
1661
1664
1662
    for(unsigned int i = 0; i < nAtts; i++)
1665
    for (XalanSize_t i = 0; i < nAtts; i++)
1663
    {
1666
    {
1664
        thePendingAttributes.addAttribute(
1667
        thePendingAttributes.addAttribute(
1665
            atts.getName(i),
1668
            atts.getName(i),
Lines 1708-1715 Link Here
1708
1711
1709
void
1712
void
1710
XSLTEngineImpl::characters(
1713
XSLTEngineImpl::characters(
1711
            const XalanDOMChar*         ch,
1714
            const XalanDOMChar*     ch,
1712
            XalanDOMString::size_type   length)
1715
            size_type               length)
1713
{
1716
{
1714
    characters(
1717
    characters(
1715
        ch,
1718
        ch,
Lines 1721-1729 Link Here
1721
1724
1722
void
1725
void
1723
XSLTEngineImpl::characters(
1726
XSLTEngineImpl::characters(
1724
            const XalanDOMChar*         ch,
1727
            const XalanDOMChar*     ch,
1725
            XalanDOMString::size_type   start,
1728
            size_type               start,
1726
            XalanDOMString::size_type   length)
1729
            size_type               length)
1727
{
1730
{
1728
    assert(getFormatterListenerImpl() != 0);
1731
    assert(getFormatterListenerImpl() != 0);
1729
    assert(ch != 0);
1732
    assert(ch != 0);
Lines 1732-1742 Link Here
1732
1735
1733
    doFlushPending();
1736
    doFlushPending();
1734
1737
1735
    if(generateCDATASection() == true)
1738
    if (generateCDATASection() == true)
1736
    {
1739
    {
1737
        getFormatterListenerImpl()->cdata(ch + start, length);
1740
        getFormatterListenerImpl()->cdata(ch + start, length);
1738
1741
1739
        if(getTraceListeners() > 0)
1742
        if (getTraceListeners() > 0)
1740
        {
1743
        {
1741
            fireCharacterGenerateEvent(ch, start, length, true);
1744
            fireCharacterGenerateEvent(ch, start, length, true);
1742
        }
1745
        }
Lines 1745-1751 Link Here
1745
    {
1748
    {
1746
        getFormatterListenerImpl()->characters(ch + start, length);
1749
        getFormatterListenerImpl()->characters(ch + start, length);
1747
1750
1748
        if(getTraceListeners() > 0)
1751
        if (getTraceListeners() > 0)
1749
        {
1752
        {
1750
            fireCharacterGenerateEvent(ch, start, length, false);
1753
            fireCharacterGenerateEvent(ch, start, length, false);
1751
        }
1754
        }
Lines 1817-1825 Link Here
1817
1820
1818
void 
1821
void 
1819
XSLTEngineImpl::charactersRaw(
1822
XSLTEngineImpl::charactersRaw(
1820
            const XalanDOMChar*         ch,
1823
            const XalanDOMChar*     ch,
1821
            XalanDOMString::size_type   start,
1824
            size_type               start,
1822
            XalanDOMString::size_type   length)
1825
            size_type               length)
1823
{
1826
{
1824
    assert(ch != 0);
1827
    assert(ch != 0);
1825
    assert(length != 0);
1828
    assert(length != 0);
Lines 1880-1887 Link Here
1880
1883
1881
void
1884
void
1882
XSLTEngineImpl::ignorableWhitespace(
1885
XSLTEngineImpl::ignorableWhitespace(
1883
            const XalanDOMChar*         ch,
1886
            const XalanDOMChar*     ch,
1884
            XalanDOMString::size_type   length)
1887
            size_type               length)
1885
{
1888
{
1886
    assert(getFormatterListenerImpl() != 0);
1889
    assert(getFormatterListenerImpl() != 0);
1887
    assert(ch != 0);
1890
    assert(ch != 0);
Lines 1973-1981 Link Here
1973
1976
1974
void
1977
void
1975
XSLTEngineImpl::cdata(
1978
XSLTEngineImpl::cdata(
1976
            const XalanDOMChar*         ch,
1979
            const XalanDOMChar*     ch,
1977
            XalanDOMString::size_type   start,
1980
            size_type               start,
1978
            XalanDOMString::size_type   length)
1981
            size_type               length)
1979
{
1982
{
1980
    assert(getFormatterListenerImpl() != 0);
1983
    assert(getFormatterListenerImpl() != 0);
1981
    assert(ch != 0);
1984
    assert(ch != 0);
Lines 2716-2722 Link Here
2716
            const XalanDOMString&       thePrefix,
2719
            const XalanDOMString&       thePrefix,
2717
            XalanDOMString::size_type   thePrefixLength)
2720
            XalanDOMString::size_type   thePrefixLength)
2718
{
2721
{
2719
    const unsigned int  thePendingAttributesCount =
2722
    const XalanSize_t   thePendingAttributesCount =
2720
                thePendingAttributes.getLength();
2723
                thePendingAttributes.getLength();
2721
2724
2722
    if (thePendingAttributesCount == 0)
2725
    if (thePendingAttributesCount == 0)
Lines 2729-2735 Link Here
2729
        bool    fResult = false;
2732
        bool    fResult = false;
2730
2733
2731
        // Check each attribute...
2734
        // Check each attribute...
2732
        for (unsigned int i = 0; i < thePendingAttributesCount; ++i)
2735
        for (XalanSize_t i = 0; i < thePendingAttributesCount; ++i)
2733
        {
2736
        {
2734
            const XalanDOMChar* const   thePendingAttributeName =
2737
            const XalanDOMChar* const   thePendingAttributeName =
2735
                            thePendingAttributes.getName(i);
2738
                            thePendingAttributes.getName(i);
Lines 3141-3150 Link Here
3141
3144
3142
void
3145
void
3143
XSLTEngineImpl::fireCharacterGenerateEvent(
3146
XSLTEngineImpl::fireCharacterGenerateEvent(
3144
            const XalanDOMChar*         ch,
3147
            const XalanDOMChar*     ch,
3145
            XalanDOMString::size_type   start,
3148
            size_type               start,
3146
            XalanDOMString::size_type   length,
3149
            size_type               length,
3147
            bool                        isCDATA)
3150
            bool                    isCDATA)
3148
{
3151
{
3149
    const GenerateEvent     ge(
3152
    const GenerateEvent     ge(
3150
        isCDATA == true ? GenerateEvent::EVENTTYPE_CDATA : GenerateEvent::EVENTTYPE_CHARACTERS,
3153
        isCDATA == true ? GenerateEvent::EVENTTYPE_CDATA : GenerateEvent::EVENTTYPE_CHARACTERS,
(-)src/xalanc/XSLT/DecimalToRoman.hpp (-1 / +1 lines)
Lines 38-44 Link Here
38
{
38
{
39
	enum { eMaxLetter = 2 };
39
	enum { eMaxLetter = 2 };
40
40
41
	typedef unsigned long	ValueType;
41
	typedef XalanSize_t     ValueType;
42
42
43
	ValueType		m_postValue;
43
	ValueType		m_postValue;
44
44
(-)src/xalanc/XSLT/ElemForEach.cpp (-12 / +12 lines)
Lines 55-62 Link Here
55
            StylesheetConstructionContext&  constructionContext,
55
            StylesheetConstructionContext&  constructionContext,
56
            Stylesheet&                     stylesheetTree,
56
            Stylesheet&                     stylesheetTree,
57
            const AttributeListType&        atts,
57
            const AttributeListType&        atts,
58
            int                             lineNumber,
58
            XalanFileLoc                    lineNumber,
59
            int                             columnNumber) :
59
            XalanFileLoc                    columnNumber) :
60
    ElemTemplateElement(constructionContext,
60
    ElemTemplateElement(constructionContext,
61
                        stylesheetTree,
61
                        stylesheetTree,
62
                        lineNumber,
62
                        lineNumber,
Lines 66-82 Link Here
66
    m_sortElems(constructionContext.getMemoryManager()),
66
    m_sortElems(constructionContext.getMemoryManager()),
67
    m_sortElemsCount(0)
67
    m_sortElemsCount(0)
68
{
68
{
69
    const unsigned int  nAttrs = atts.getLength();
69
    const XalanSize_t  nAttrs = atts.getLength();
70
        
70
        
71
    for(unsigned int i = 0; i < nAttrs; i++)
71
    for (XalanSize_t i = 0; i < nAttrs; i++)
72
    {
72
    {
73
        const XalanDOMChar* const   aname = atts.getName(i);
73
        const XalanDOMChar* const   aname = atts.getName(i);
74
74
75
        if(equals(aname, Constants::ATTRNAME_SELECT))
75
        if (equals(aname, Constants::ATTRNAME_SELECT))
76
        {
76
        {
77
            m_selectPattern = constructionContext.createXPath(getLocator(), atts.getValue(i), *this);
77
            m_selectPattern = constructionContext.createXPath(getLocator(), atts.getValue(i), *this);
78
        }
78
        }
79
        else if(isAttrOK(
79
        else if (isAttrOK(
80
                    aname,
80
                    aname,
81
                    atts,
81
                    atts,
82
                    i,
82
                    i,
Lines 96-102 Link Here
96
        }
96
        }
97
    }
97
    }
98
98
99
    if(0 == m_selectPattern)
99
    if (0 == m_selectPattern)
100
    {
100
    {
101
        error(
101
        error(
102
            constructionContext,
102
            constructionContext,
Lines 111-118 Link Here
111
ElemForEach::ElemForEach(
111
ElemForEach::ElemForEach(
112
            StylesheetConstructionContext&  constructionContext,
112
            StylesheetConstructionContext&  constructionContext,
113
            Stylesheet&                     stylesheetTree,
113
            Stylesheet&                     stylesheetTree,
114
            int                             lineNumber,
114
            XalanFileLoc                    lineNumber,
115
            int                             columnNumber,
115
            XalanFileLoc                    columnNumber,
116
            int                             xslToken) :
116
            int                             xslToken) :
117
    ElemTemplateElement(constructionContext,
117
    ElemTemplateElement(constructionContext,
118
                        stylesheetTree,
118
                        stylesheetTree,
Lines 147-154 Link Here
147
            const AttributeListType&        atts,
147
            const AttributeListType&        atts,
148
            const LocatorType*              locator)
148
            const LocatorType*              locator)
149
{
149
{
150
    const int   lineNumber = XalanLocator::getLineNumber(locator);
150
    const XalanFileLoc  lineNumber = XalanLocator::getLineNumber(locator);
151
    const int   columnNumber = XalanLocator::getColumnNumber(locator);
151
    const XalanFileLoc  columnNumber = XalanLocator::getColumnNumber(locator);
152
152
153
    m_sortElems.reserve(m_sortElems.size() + 1);
153
    m_sortElems.reserve(m_sortElems.size() + 1);
154
154
Lines 826-832 Link Here
826
826
827
827
828
const XPath*
828
const XPath*
829
ElemForEach::getXPath(unsigned int  index) const
829
ElemForEach::getXPath(XalanSize_t   index) const
830
{
830
{
831
    return index == 0 ? m_selectPattern : 0;
831
    return index == 0 ? m_selectPattern : 0;
832
}
832
}
(-)src/xalanc/XSLT/ElemApplyTemplates.hpp (-5 / +5 lines)
Lines 50-60 Link Here
50
	 * @param columnNumber			column number in document
50
	 * @param columnNumber			column number in document
51
	 */
51
	 */
52
	ElemApplyTemplates(
52
	ElemApplyTemplates(
53
			StylesheetConstructionContext&	constructionContext,
53
			StylesheetConstructionContext&  constructionContext,
54
			Stylesheet&						stylesheetTree,
54
			Stylesheet&                     stylesheetTree,
55
			const AttributeListType&		atts,
55
			const AttributeListType&        atts,
56
			int								lineNumber, 
56
			XalanFileLoc                    lineNumber, 
57
			int								columnNumber);
57
			XalanFileLoc                    columnNumber);
58
58
59
    virtual
59
    virtual
60
    ~ElemApplyTemplates();
60
    ~ElemApplyTemplates();
(-)src/xalanc/XSLT/StylesheetHandler.cpp (-8 / +8 lines)
Lines 1525-1531 Link Here
1525
void
1525
void
1526
StylesheetHandler::characters(
1526
StylesheetHandler::characters(
1527
            const XMLCh* const  chars,
1527
            const XMLCh* const  chars,
1528
            const unsigned int  length)
1528
            const size_type     length)
1529
{
1529
{
1530
    if (m_inTemplate == false &&
1530
    if (m_inTemplate == false &&
1531
        inExtensionElement() == false &&
1531
        inExtensionElement() == false &&
Lines 1551-1557 Link Here
1551
void
1551
void
1552
StylesheetHandler::cdata(
1552
StylesheetHandler::cdata(
1553
            const XMLCh* const  chars,
1553
            const XMLCh* const  chars,
1554
            const unsigned int  length)
1554
            const size_type     length)
1555
{
1555
{
1556
    accumulateText(chars, length);
1556
    accumulateText(chars, length);
1557
1557
Lines 1565-1571 Link Here
1565
void
1565
void
1566
StylesheetHandler::ignorableWhitespace(
1566
StylesheetHandler::ignorableWhitespace(
1567
            const XMLCh* const  /*chars*/,
1567
            const XMLCh* const  /*chars*/,
1568
            const unsigned int  /*length*/)
1568
            const size_type     /*length*/)
1569
{
1569
{
1570
    // Ignore!
1570
    // Ignore!
1571
    m_lastPopped = 0;
1571
    m_lastPopped = 0;
Lines 1617-1623 Link Here
1617
void
1617
void
1618
StylesheetHandler::charactersRaw(
1618
StylesheetHandler::charactersRaw(
1619
            const XMLCh* const  /* chars */,
1619
            const XMLCh* const  /* chars */,
1620
            const unsigned int  /* length */)
1620
            const size_type     /* length */)
1621
{
1621
{
1622
}
1622
}
1623
1623
Lines 1625-1632 Link Here
1625
1625
1626
void
1626
void
1627
StylesheetHandler::processText(
1627
StylesheetHandler::processText(
1628
            const XMLCh*                chars,
1628
            const XMLCh*    chars,
1629
            XalanDOMString::size_type   length)
1629
            size_type       length)
1630
{
1630
{
1631
    if(m_inTemplate)
1631
    if(m_inTemplate)
1632
    {
1632
    {
Lines 1719-1726 Link Here
1719
1719
1720
void
1720
void
1721
StylesheetHandler::accumulateText(
1721
StylesheetHandler::accumulateText(
1722
            const XMLCh*                chars,
1722
            const XMLCh*    chars,
1723
            XalanDOMString::size_type   length)
1723
            size_type       length)
1724
{   
1724
{   
1725
    if(m_inTemplate)
1725
    if(m_inTemplate)
1726
    {
1726
    {
(-)src/xalanc/XSLT/ElemTemplateElement.hpp (-15 / +15 lines)
Lines 89-96 Link Here
89
    ElemTemplateElement(
89
    ElemTemplateElement(
90
            StylesheetConstructionContext&  constructionContext,
90
            StylesheetConstructionContext&  constructionContext,
91
            Stylesheet&                     stylesheetTree,
91
            Stylesheet&                     stylesheetTree,
92
            int                             lineNumber,
92
            XalanFileLoc                    lineNumber,
93
            int                             columnNumber,
93
            XalanFileLoc                    columnNumber,
94
            int                             xslToken);
94
            int                             xslToken);
95
95
96
    /**
96
    /**
Lines 110-117 Link Here
110
            Stylesheet&                     stylesheetTree,
110
            Stylesheet&                     stylesheetTree,
111
            int                             xslToken,
111
            int                             xslToken,
112
            const XalanDOMString&           baseURI = XalanDOMString(XalanMemMgrs::getDummyMemMgr()),
112
            const XalanDOMString&           baseURI = XalanDOMString(XalanMemMgrs::getDummyMemMgr()),
113
            int                             lineNumber = XalanLocator::getUnknownValue(),
113
            XalanFileLoc                    lineNumber = XalanLocator::getUnknownValue(),
114
            int                             columnNumber = XalanLocator::getUnknownValue());
114
            XalanFileLoc                    columnNumber = XalanLocator::getUnknownValue());
115
115
116
    virtual
116
    virtual
117
    ~ElemTemplateElement();
117
    ~ElemTemplateElement();
Lines 138-144 Link Here
138
    isAttrOK(
138
    isAttrOK(
139
            const XalanDOMChar*             attrName,
139
            const XalanDOMChar*             attrName,
140
            const AttributeListType&        atts,
140
            const AttributeListType&        atts,
141
            int                             which,
141
            XalanSize_t                     which,
142
            StylesheetConstructionContext&  constructionContext) const;
142
            StylesheetConstructionContext&  constructionContext) const;
143
143
144
    /** 
144
    /** 
Lines 156-162 Link Here
156
            const XalanDOMChar*             elementName,
156
            const XalanDOMChar*             elementName,
157
            const XalanDOMChar*             aname,
157
            const XalanDOMChar*             aname,
158
            const AttributeListType&        atts,
158
            const AttributeListType&        atts,
159
            int                             which,
159
            XalanSize_t                     which,
160
            StylesheetConstructionContext&  constructionContext);
160
            StylesheetConstructionContext&  constructionContext);
161
161
162
    /** 
162
    /** 
Lines 615-621 Link Here
615
     * @return pointer or null 
615
     * @return pointer or null 
616
     */
616
     */
617
    virtual const XPath*
617
    virtual const XPath*
618
    getXPath(unsigned int   index = 0) const;
618
    getXPath(XalanSize_t    index) const;
619
619
620
    // These interfaces are inherited from PrefixResolver...
620
    // These interfaces are inherited from PrefixResolver...
621
621
Lines 633-640 Link Here
633
    public:
633
    public:
634
634
635
        LocatorProxy(
635
        LocatorProxy(
636
                    size_type               theLineNumber,
636
                    XMLFileLoc              theLineNumber,
637
                    size_type               theColumnNumber,
637
                    XMLFileLoc              theColumnNumber,
638
                    const XalanDOMString&   theURI);
638
                    const XalanDOMString&   theURI);
639
639
640
        virtual
640
        virtual
Lines 646-655 Link Here
646
        virtual const XMLCh*
646
        virtual const XMLCh*
647
        getSystemId() const;
647
        getSystemId() const;
648
648
649
        virtual size_type
649
        virtual XMLFileLoc
650
        getLineNumber() const;
650
        getLineNumber() const;
651
651
652
        virtual size_type
652
        virtual XMLFileLoc
653
        getColumnNumber() const;
653
        getColumnNumber() const;
654
654
655
        const XalanDOMString&
655
        const XalanDOMString&
Lines 670-690 Link Here
670
        operator==(const LocatorProxy&) const;
670
        operator==(const LocatorProxy&) const;
671
671
672
        // data members...
672
        // data members...
673
        const size_type         m_lineNumber;
673
        const XMLFileLoc        m_lineNumber;
674
674
675
        const size_type         m_columnNumber;
675
        const XMLFileLoc        m_columnNumber;
676
676
677
        const XalanDOMString&   m_uri;
677
        const XalanDOMString&   m_uri;
678
    };
678
    };
679
679
680
680
681
    LocatorProxy::size_type
681
    XMLFileLoc
682
    getLineNumber() const
682
    getLineNumber() const
683
    {
683
    {
684
        return m_locatorProxy.getLineNumber();
684
        return m_locatorProxy.getLineNumber();
685
    }
685
    }
686
686
687
    LocatorProxy::size_type
687
    XMLFileLoc
688
    getColumnNumber() const
688
    getColumnNumber() const
689
    {
689
    {
690
        return m_locatorProxy.getColumnNumber();
690
        return m_locatorProxy.getColumnNumber();
(-)src/xalanc/XSLT/Stylesheet.hpp (-6 / +7 lines)
Lines 86-92 Link Here
86
86
87
public:
87
public:
88
88
89
    typedef StylesheetConstructionContext::size_type        size_type;
90
	typedef StylesheetExecutionContext::ParamVectorType		ParamVectorType;
89
	typedef StylesheetExecutionContext::ParamVectorType		ParamVectorType;
91
	typedef XalanQName::NamespaceVectorType					NamespaceVectorType;
90
	typedef XalanQName::NamespaceVectorType					NamespaceVectorType;
92
	typedef XalanQName::NamespacesStackType					NamespacesStackType;
91
	typedef XalanQName::NamespacesStackType					NamespacesStackType;
Lines 288-294 Link Here
288
	isAttrOK(
287
	isAttrOK(
289
			const XalanDOMChar*				attrName,
288
			const XalanDOMChar*				attrName,
290
			const AttributeListType&		atts,
289
			const AttributeListType&		atts,
291
			int 							which,
290
			XalanSize_t						which,
292
			StylesheetConstructionContext&	constructionContext) const;
291
			StylesheetConstructionContext&	constructionContext) const;
293
292
294
	/**
293
	/**
Lines 298-305 Link Here
298
	 * @return namespace string for node, or null if not found.
297
	 * @return namespace string for node, or null if not found.
299
	 */
298
	 */
300
	const XalanDOMString*
299
	const XalanDOMString*
301
	getNamespaceFromStack(const XalanDOMString& 	nodeName,
300
    getNamespaceFromStack(
302
                            XalanDOMString&         theBuffer) const
301
                const XalanDOMString&   nodeName,
302
                XalanDOMString&         theBuffer) const
303
	{
303
	{
304
		return getNamespaceFromStack(c_wstr(nodeName), theBuffer);
304
		return getNamespaceFromStack(c_wstr(nodeName), theBuffer);
305
	}
305
	}
Lines 311-318 Link Here
311
	 * @return namespace string for node, or null if not found.
311
	 * @return namespace string for node, or null if not found.
312
	 */
312
	 */
313
	const XalanDOMString*
313
	const XalanDOMString*
314
	getNamespaceFromStack(const XalanDOMChar* 	nodeName,
314
    getNamespaceFromStack(
315
                            XalanDOMString&     theBuffer) const;
315
                const XalanDOMChar*     nodeName,
316
                XalanDOMString&         theBuffer) const;
316
317
317
	/**
318
	/**
318
	 * Get the namespace from a prefix by searching the stack of namespace
319
	 * Get the namespace from a prefix by searching the stack of namespace
(-)src/xalanc/XSLT/ElemUse.hpp (-3 / +3 lines)
Lines 56-63 Link Here
56
	ElemUse(
56
	ElemUse(
57
			StylesheetConstructionContext&	constructionContext,
57
			StylesheetConstructionContext&	constructionContext,
58
			Stylesheet&						stylesheetTree,
58
			Stylesheet&						stylesheetTree,
59
			int								lineNumber,
59
			XalanFileLoc					lineNumber,
60
			int								columnNumber,
60
			XalanFileLoc					columnNumber,
61
			int								xslToken);
61
			int								xslToken);
62
62
63
	virtual
63
	virtual
Lines 77-83 Link Here
77
			StylesheetConstructionContext&	constructionContext,
77
			StylesheetConstructionContext&	constructionContext,
78
			const XalanDOMChar*				attrName,
78
			const XalanDOMChar*				attrName,
79
			const AttributeListType&		atts,
79
			const AttributeListType&		atts,
80
			int								which);
80
			XalanSize_t						which);
81
81
82
	// These methods are inherited from ElemTemplateElement ...
82
	// These methods are inherited from ElemTemplateElement ...
83
	
83
	
(-)src/xalanc/XSLT/ElemCallTemplate.cpp (-4 / +4 lines)
Lines 54-66 Link Here
54
    m_templateName(0),
54
    m_templateName(0),
55
    m_template(0)
55
    m_template(0)
56
{
56
{
57
    const unsigned int  nAttrs = atts.getLength();
57
    const XalanSize_t  nAttrs = atts.getLength();
58
58
59
    for(unsigned int i = 0; i < nAttrs; i++)
59
    for(XalanSize_t i = 0; i < nAttrs; i++)
60
    {
60
    {
61
        const XalanDOMChar* const   aname = atts.getName(i);
61
        const XalanDOMChar* const   aname = atts.getName(i);
62
62
63
        if(equals(aname, Constants::ATTRNAME_NAME))
63
        if (equals(aname, Constants::ATTRNAME_NAME))
64
        {
64
        {
65
            m_templateName = constructionContext.createXalanQName(
65
            m_templateName = constructionContext.createXalanQName(
66
                    atts.getValue(i),
66
                    atts.getValue(i),
Lines 76-82 Link Here
76
                    atts.getValue(i));
76
                    atts.getValue(i));
77
            }
77
            }
78
        }
78
        }
79
        else if(isAttrOK(
79
        else if (isAttrOK(
80
                    aname,
80
                    aname,
81
                    atts,
81
                    atts,
82
                    i,
82
                    i,
(-)src/xalanc/XSLT/CountersTable.hpp (-1 / +1 lines)
Lines 55-61 Link Here
55
 */
55
 */
56
struct Counter
56
struct Counter
57
{
57
{
58
	typedef unsigned long	CountType;
58
	typedef XalanSize_t     CountType;
59
59
60
	typedef XalanVector<XalanNode*>			NodeVectorType;
60
	typedef XalanVector<XalanNode*>			NodeVectorType;
61
61
(-)src/xalanc/XSLT/ElemCopy.hpp (-2 / +2 lines)
Lines 49-56 Link Here
49
			StylesheetConstructionContext&	constructionContext,
49
			StylesheetConstructionContext&	constructionContext,
50
			Stylesheet&						stylesheetTree,
50
			Stylesheet&						stylesheetTree,
51
			const AttributeListType&		atts,
51
			const AttributeListType&		atts,
52
			int								lineNumber,
52
			XalanFileLoc					lineNumber,
53
			int								columnNumber);
53
			XalanFileLoc					columnNumber);
54
54
55
	// These methods are inherited from ElemTemplateElement ...
55
	// These methods are inherited from ElemTemplateElement ...
56
	
56
	
(-)src/xalanc/XSLT/ElemChoose.cpp (-10 / +10 lines)
Lines 48-73 Link Here
48
            StylesheetConstructionContext&  constructionContext,
48
            StylesheetConstructionContext&  constructionContext,
49
            Stylesheet&                     stylesheetTree,
49
            Stylesheet&                     stylesheetTree,
50
            const AttributeListType&        atts,
50
            const AttributeListType&        atts,
51
            int                             lineNumber,
51
            XalanFileLoc                    lineNumber,
52
            int                             columnNumber) :
52
            XalanFileLoc                    columnNumber) :
53
    ElemTemplateElement(constructionContext,
53
    ElemTemplateElement(constructionContext,
54
                        stylesheetTree,
54
                        stylesheetTree,
55
                        lineNumber,
55
                        lineNumber,
56
                        columnNumber,
56
                        columnNumber,
57
                        StylesheetConstructionContext::ELEMNAME_CHOOSE)
57
                        StylesheetConstructionContext::ELEMNAME_CHOOSE)
58
{
58
{
59
    const unsigned int  nAttrs = atts.getLength();
59
    const XalanSize_t   nAttrs = atts.getLength();
60
60
61
    for(unsigned int i = 0; i < nAttrs; i++)
61
    for (XalanSize_t i = 0; i < nAttrs; i++)
62
    {
62
    {
63
        const XalanDOMChar* const   aname = atts.getName(i);
63
        const XalanDOMChar* const   aname = atts.getName(i);
64
64
65
        if(isAttrOK(
65
        if (isAttrOK(
66
                aname,
66
                aname,
67
                atts,
67
                atts,
68
                i,
68
                i,
69
                constructionContext) == false &&
69
                constructionContext) == false &&
70
           processSpaceAttr(
70
            processSpaceAttr(
71
                Constants::ELEMNAME_CHOOSE_WITH_PREFIX_STRING.c_str(),
71
                Constants::ELEMNAME_CHOOSE_WITH_PREFIX_STRING.c_str(),
72
                aname,
72
                aname,
73
                atts,
73
                atts,
Lines 107-123 Link Here
107
    {
107
    {
108
        const int   type = node->getXSLToken();
108
        const int   type = node->getXSLToken();
109
109
110
        if(StylesheetConstructionContext::ELEMNAME_WHEN == type)
110
        if (StylesheetConstructionContext::ELEMNAME_WHEN == type)
111
        {
111
        {
112
112
113
            const XPath* const      theXPath = node->getXPath();
113
            const XPath* const      theXPath = node->getXPath(0);
114
            assert(theXPath != 0);
114
            assert(theXPath != 0);
115
115
116
            bool    test;
116
            bool    test;
117
117
118
            theXPath->execute(*this, executionContext, test);
118
            theXPath->execute(*this, executionContext, test);
119
119
120
            if(0 != executionContext.getTraceListeners())
120
            if (0 != executionContext.getTraceListeners())
121
            {
121
            {
122
                executionContext.fireSelectEvent(
122
                executionContext.fireSelectEvent(
123
                    SelectionEvent(executionContext,
123
                    SelectionEvent(executionContext,
Lines 172-178 Link Here
172
        if(StylesheetConstructionContext::ELEMNAME_WHEN == type)
172
        if(StylesheetConstructionContext::ELEMNAME_WHEN == type)
173
        {
173
        {
174
174
175
            const XPath* const      theXPath = node->getXPath();
175
            const XPath* const      theXPath = node->getXPath(0);
176
            assert(theXPath != 0);
176
            assert(theXPath != 0);
177
177
178
            bool    test;
178
            bool    test;
(-)src/xalanc/XSLT/ElemApplyImport.cpp (-5 / +5 lines)
Lines 52-72 Link Here
52
            StylesheetConstructionContext&  constructionContext,
52
            StylesheetConstructionContext&  constructionContext,
53
            Stylesheet&                     stylesheetTree,
53
            Stylesheet&                     stylesheetTree,
54
            const AttributeListType&        atts,
54
            const AttributeListType&        atts,
55
            int                             lineNumber, 
55
            XalanFileLoc                    lineNumber, 
56
            int                             columnNumber) :
56
            XalanFileLoc                    columnNumber) :
57
        ElemTemplateElement(constructionContext,
57
        ElemTemplateElement(constructionContext,
58
                            stylesheetTree,
58
                            stylesheetTree,
59
                            lineNumber,
59
                            lineNumber,
60
                            columnNumber,
60
                            columnNumber,
61
                            StylesheetConstructionContext::ELEMNAME_APPLY_IMPORTS)
61
                            StylesheetConstructionContext::ELEMNAME_APPLY_IMPORTS)
62
{
62
{
63
    const unsigned int  nAttrs = atts.getLength();
63
    const XalanSize_t  nAttrs = atts.getLength();
64
64
65
    for(unsigned int i = 0; i < nAttrs; i++)
65
    for (XalanSize_t i = 0; i < nAttrs; i++)
66
    {
66
    {
67
        const XalanDOMChar* const   aname = atts.getName(i);
67
        const XalanDOMChar* const   aname = atts.getName(i);
68
68
69
        if(isAttrOK(
69
        if (isAttrOK(
70
                aname,
70
                aname,
71
                atts,
71
                atts,
72
                i,
72
                i,
(-)src/xalanc/XSLT/KeyDeclaration.hpp (-6 / +6 lines)
Lines 54-61 Link Here
54
			const XPath&				matchPattern,
54
			const XPath&				matchPattern,
55
			const XPath&				use,
55
			const XPath&				use,
56
			const XalanDOMString&		uri,
56
			const XalanDOMString&		uri,
57
			XalanLocator::size_type		lineNumber,
57
			XMLFileLoc		            lineNumber,
58
			XalanLocator::size_type		columnNumber) :
58
			XMLFileLoc		            columnNumber) :
59
		m_qname(&qname),
59
		m_qname(&qname),
60
		m_match(&matchPattern),
60
		m_match(&matchPattern),
61
		m_use(&use),
61
		m_use(&use),
Lines 136-142 Link Here
136
	 *
136
	 *
137
	 * @return The line number
137
	 * @return The line number
138
	 */
138
	 */
139
	XalanLocator::size_type
139
	XMLFileLoc
140
	getLineNumber() const
140
	getLineNumber() const
141
	{
141
	{
142
		return m_lineNumber;
142
		return m_lineNumber;
Lines 147-153 Link Here
147
	 *
147
	 *
148
	 * @return The column number
148
	 * @return The column number
149
	 */
149
	 */
150
	XalanLocator::size_type
150
	XMLFileLoc
151
	getColumnNumber() const
151
	getColumnNumber() const
152
	{
152
	{
153
		return m_columnNumber;
153
		return m_columnNumber;
Lines 163-171 Link Here
163
163
164
	const XalanDOMString*		m_uri;
164
	const XalanDOMString*		m_uri;
165
165
166
	XalanLocator::size_type		m_lineNumber;
166
	XMLFileLoc		            m_lineNumber;
167
167
168
	XalanLocator::size_type		m_columnNumber;
168
	XMLFileLoc                  m_columnNumber;
169
};
169
};
170
170
171
171
(-)src/xalanc/XSLT/ElemAttribute.cpp (-4 / +5 lines)
Lines 46-53 Link Here
46
            StylesheetConstructionContext&  constructionContext,
46
            StylesheetConstructionContext&  constructionContext,
47
            Stylesheet&                     stylesheetTree,
47
            Stylesheet&                     stylesheetTree,
48
            const AttributeListType&        atts,
48
            const AttributeListType&        atts,
49
            int                             lineNumber,
49
            XalanFileLoc                    lineNumber,
50
            int                             columnNumber) :
50
            XalanFileLoc                    columnNumber) :
51
    ElemTemplateElement(constructionContext,
51
    ElemTemplateElement(constructionContext,
52
                        stylesheetTree,
52
                        stylesheetTree,
53
                        lineNumber,
53
                        lineNumber,
Lines 56-64 Link Here
56
    m_nameAVT(0),   
56
    m_nameAVT(0),   
57
    m_namespaceAVT(0)
57
    m_namespaceAVT(0)
58
{
58
{
59
    const unsigned int  nAttrs = atts.getLength();
59
    const XalanSize_t   nAttrs = atts.getLength();
60
60
61
    for(unsigned int i = 0; i < nAttrs; i++)
61
    for (XalanSize_t i = 0; i < nAttrs; i++)
62
    {
62
    {
63
        const XalanDOMChar* const   aname = atts.getName(i);
63
        const XalanDOMChar* const   aname = atts.getName(i);
64
64
Lines 398-403 Link Here
398
    }
398
    }
399
399
400
    executionContext.getAndPopCachedString();
400
    executionContext.getAndPopCachedString();
401
401
    return 0;
402
    return 0;
402
}
403
}
403
404
(-)src/xalanc/XSLT/XSLTEngineImpl.hpp (-62 / +62 lines)
Lines 425-431 Link Here
425
	addResultNamespaceDecl(
425
	addResultNamespaceDecl(
426
			const XalanDOMString&		prefix, 
426
			const XalanDOMString&		prefix, 
427
			const XalanDOMChar*			namespaceVal,
427
			const XalanDOMChar*			namespaceVal,
428
			XalanDOMString::size_type	len)
428
			size_type					len)
429
	{
429
	{
430
		m_resultNamespacesStack.addDeclaration(
430
		m_resultNamespacesStack.addDeclaration(
431
			prefix,
431
			prefix,
Lines 496-510 Link Here
496
     * @param theLength The length of the value
496
     * @param theLength The length of the value
497
     * @param fromCopy true if the attribute is being copied from the source tree
497
     * @param fromCopy true if the attribute is being copied from the source tree
498
     * @param locator The Locator for reporting errors.
498
     * @param locator The Locator for reporting errors.
499
	 */
499
     */
500
	void
500
    void
501
	addResultAttribute(
501
    addResultAttribute(
502
			AttributeListImpl&			attList,
502
            AttributeListImpl&      attList,
503
			const XalanDOMString&		aname,
503
            const XalanDOMString&   aname,
504
			const XalanDOMChar*			value,
504
            const XalanDOMChar*     value,
505
            XalanDOMString::size_type   theLength,
505
            size_type               theLength,
506
            bool                        fromCopy = false,
506
            bool                    fromCopy = false,
507
			const LocatorType*	        locator = 0);
507
            const LocatorType*      locator = 0);
508
508
509
	/**
509
	/**
510
	 * Add attribute to pending attributes list, and if it is a namespace, add
510
	 * Add attribute to pending attributes list, and if it is a namespace, add
Lines 585-599 Link Here
585
	void
585
	void
586
	endElement(const XalanDOMChar*	name);
586
	endElement(const XalanDOMChar*	name);
587
587
588
	void
588
    void
589
	characters (
589
    characters (
590
			const XalanDOMChar*			ch,
590
            const XalanDOMChar*     ch,
591
			XalanDOMString::size_type	length);
591
            size_type               length);
592
592
593
	void
593
    void
594
	ignorableWhitespace(
594
    ignorableWhitespace(
595
			const XalanDOMChar*			ch,
595
            const XalanDOMChar*     ch,
596
			XalanDOMString::size_type	length);
596
            size_type               length);
597
597
598
	void
598
	void
599
	processingInstruction(
599
	processingInstruction(
Lines 603-620 Link Here
603
	void
603
	void
604
	resetDocument();
604
	resetDocument();
605
605
606
	/**
606
    /**
607
	 * Receive notification of character data.
607
     * Receive notification of character data.
608
	 *
608
     *
609
	 * @param ch	 pointer to characters from the XML document
609
     * @param ch     pointer to characters from the XML document
610
	 * @param start  startng offset in 'ch' array
610
     * @param start  startng offset in 'ch' array
611
	 * @param length number of characters to read from the array 
611
     * @param length number of characters to read from the array 
612
	 */
612
     */
613
	void
613
    void
614
	characters(
614
    characters(
615
			const XalanDOMChar*			ch,
615
            const XalanDOMChar*     ch,
616
			XalanDOMString::size_type	start,
616
            size_type               start,
617
			XalanDOMString::size_type	length);
617
            size_type               length);
618
618
619
	/**
619
	/**
620
	 * Send character data from the node to the result tree.
620
	 * Send character data from the node to the result tree.
Lines 641-660 Link Here
641
	void
641
	void
642
	startElement(const XalanDOMChar*	name);
642
	startElement(const XalanDOMChar*	name);
643
643
644
	/**
644
    /**
645
	 * Receive notification of character data. If available, when the
645
     * Receive notification of character data. If available, when the
646
	 * disable-output-escaping attribute is used, output raw text without
646
     * disable-output-escaping attribute is used, output raw text without
647
	 * escaping.
647
     * escaping.
648
	 *
648
     *
649
	 * @param ch pointer to characters from the XML document
649
     * @param ch pointer to characters from the XML document
650
	 * @param start start position in the array
650
     * @param start start position in the array
651
	 * @param length number of characters to read from the array
651
     * @param length number of characters to read from the array
652
	 */
652
     */
653
	void
653
    void
654
	charactersRaw(
654
    charactersRaw(
655
			const XalanDOMChar*			ch,
655
            const XalanDOMChar*     ch,
656
			XalanDOMString::size_type	start,
656
            size_type               start,
657
			XalanDOMString::size_type	length);
657
            size_type               length);
658
658
659
	/**
659
	/**
660
	 * Send raw character data from the node to the result tree.
660
	 * Send raw character data from the node to the result tree.
Lines 689-706 Link Here
689
	void
689
	void
690
	entityReference(const XalanDOMChar*		data);
690
	entityReference(const XalanDOMChar*		data);
691
691
692
	/**
692
    /**
693
	 * Receive notification of cdata.
693
     * Receive notification of cdata.
694
	 *
694
     *
695
	 * @param ch	 pointer to characters from the XML document
695
     * @param ch     pointer to characters from the XML document
696
	 * @param start  start position in the array
696
     * @param start  start position in the array
697
	 * @param length number of characters to read from the array
697
     * @param length number of characters to read from the array
698
	 */
698
     */
699
	void
699
    void
700
	cdata(
700
    cdata(
701
			const XalanDOMChar*			ch,
701
            const XalanDOMChar*     ch,
702
			XalanDOMString::size_type	start,
702
            size_type               start,
703
			XalanDOMString::size_type	length);
703
            size_type               length);
704
704
705
	/**
705
	/**
706
	 * Clone a node to the result tree
706
	 * Clone a node to the result tree
Lines 1600-1611 Link Here
1600
			const XalanDOMString&	theString,
1600
			const XalanDOMString&	theString,
1601
			bool					isCDATA);
1601
			bool					isCDATA);
1602
1602
1603
	void
1603
    void
1604
	fireCharacterGenerateEvent(
1604
    fireCharacterGenerateEvent(
1605
			const XalanDOMChar*			ch,
1605
            const XalanDOMChar*     ch,
1606
			XalanDOMString::size_type	start,
1606
            size_type               start,
1607
			XalanDOMString::size_type	length,
1607
            size_type               length,
1608
			bool						isCDATA);
1608
            bool                    isCDATA);
1609
1609
1610
	void
1610
	void
1611
	checkDefaultNamespace(
1611
	checkDefaultNamespace(
(-)src/xalanc/XSLT/ElemForEach.hpp (-11 / +11 lines)
Lines 67-77 Link Here
67
	 * @param columnNumber			column number in document
67
	 * @param columnNumber			column number in document
68
	 */
68
	 */
69
	ElemForEach(
69
	ElemForEach(
70
			StylesheetConstructionContext&	constructionContext,
70
			StylesheetConstructionContext&  constructionContext,
71
			Stylesheet&						stylesheetTree,
71
			Stylesheet&                     stylesheetTree,
72
			const AttributeListType&		atts,
72
			const AttributeListType&        atts,
73
			int								lineNumber,
73
			XalanFileLoc                    lineNumber,
74
			int								columnNumber);
74
			XalanFileLoc                    columnNumber);
75
75
76
	virtual
76
	virtual
77
	~ElemForEach();
77
	~ElemForEach();
Lines 112-118 Link Here
112
#endif
112
#endif
113
	
113
	
114
	virtual	const XPath*
114
	virtual	const XPath*
115
	getXPath(unsigned int	index = 0) const;
115
	getXPath(XalanSize_t    index) const;
116
116
117
protected:
117
protected:
118
118
Lines 126-136 Link Here
126
	 * @param xslToken             an integer representing the type of instance.
126
	 * @param xslToken             an integer representing the type of instance.
127
	 */
127
	 */
128
	ElemForEach(
128
	ElemForEach(
129
			StylesheetConstructionContext&	constructionContext,
129
			StylesheetConstructionContext&  constructionContext,
130
			Stylesheet&						stylesheetTree,
130
			Stylesheet&                     stylesheetTree,
131
			int								lineNumber,
131
			XalanFileLoc                    lineNumber,
132
			int								columnNumber,
132
			XalanFileLoc                    columnNumber,
133
			int								xslToken);
133
			int                             xslToken);
134
134
135
#if !defined(XALAN_RECURSIVE_STYLESHEET_EXECUTION)
135
#if !defined(XALAN_RECURSIVE_STYLESHEET_EXECUTION)
136
136
(-)src/xalanc/XSLT/XalanElemElementAllocator.cpp (-3 / +5 lines)
Lines 23-29 Link Here
23
23
24
24
25
25
26
XalanElemElementAllocator::XalanElemElementAllocator(MemoryManagerType&  theManager, size_type	theBlockCount) :
26
XalanElemElementAllocator::XalanElemElementAllocator(
27
            MemoryManagerType&  theManager,
28
            size_type	        theBlockCount) :
27
	m_allocator(theManager, theBlockCount)
29
	m_allocator(theManager, theBlockCount)
28
{
30
{
29
}
31
}
Lines 41-48 Link Here
41
			StylesheetConstructionContext&	constructionContext,
43
			StylesheetConstructionContext&	constructionContext,
42
			Stylesheet&						stylesheetTree,
44
			Stylesheet&						stylesheetTree,
43
			const AttributeListType&		atts,
45
			const AttributeListType&		atts,
44
			int								lineNumber,
46
			XalanFileLoc				    lineNumber,
45
			int								columnNumber)
47
			XalanFileLoc					columnNumber)
46
{
48
{
47
	data_type* const	theBlock = m_allocator.allocateBlock();
49
	data_type* const	theBlock = m_allocator.allocateBlock();
48
	assert(theBlock != 0);
50
	assert(theBlock != 0);
(-)src/xalanc/XSLT/XalanElemAttributeAllocator.cpp (-3 / +5 lines)
Lines 23-29 Link Here
23
23
24
24
25
25
26
XalanElemAttributeAllocator::XalanElemAttributeAllocator(MemoryManagerType&  theManager, size_type	theBlockCount) :
26
XalanElemAttributeAllocator::XalanElemAttributeAllocator(
27
            MemoryManagerType&  theManager,
28
            size_type	        theBlockCount) :
27
	m_allocator(theManager, theBlockCount)
29
	m_allocator(theManager, theBlockCount)
28
{
30
{
29
}
31
}
Lines 41-48 Link Here
41
			StylesheetConstructionContext&	constructionContext,
43
			StylesheetConstructionContext&	constructionContext,
42
			Stylesheet&						stylesheetTree,
44
			Stylesheet&						stylesheetTree,
43
			const AttributeListType&		atts,
45
			const AttributeListType&		atts,
44
			int								lineNumber,
46
			XalanFileLoc					lineNumber,
45
			int								columnNumber)
47
			XalanFileLoc					columnNumber)
46
{
48
{
47
	data_type* const	theBlock = m_allocator.allocateBlock();
49
	data_type* const	theBlock = m_allocator.allocateBlock();
48
	assert(theBlock != 0);
50
	assert(theBlock != 0);
(-)src/xalanc/XSLT/StylesheetHandler.hpp (-8 / +20 lines)
Lines 129-135 Link Here
129
     * @see #ignorableWhitespace 
129
     * @see #ignorableWhitespace 
130
     * @see org.xml.sax.Locator
130
     * @see org.xml.sax.Locator
131
     */
131
     */
132
    virtual void characters (const XMLCh* const chars, const unsigned int length);
132
    virtual void
133
    characters(
134
            const XMLCh* const  chars,
135
            const size_type     length);
133
136
134
    /**
137
    /**
135
     * Receive notification of character data. If available, when the
138
     * Receive notification of character data. If available, when the
Lines 141-147 Link Here
141
     * @param length number of characters to read from the array
144
     * @param length number of characters to read from the array
142
     * @exception SAXException
145
     * @exception SAXException
143
     */
146
     */
144
    virtual void charactersRaw(const XMLCh* const chars, const unsigned int length);
147
    virtual void
148
    charactersRaw(
149
            const XMLCh* const  chars,
150
            const size_type     length);
145
151
146
    /**
152
    /**
147
     * Receive notification of cdata.
153
     * Receive notification of cdata.
Lines 166-172 Link Here
166
     * @exception SAXException
172
     * @exception SAXException
167
     * @see #ignorableWhitespace 
173
     * @see #ignorableWhitespace 
168
     */
174
     */
169
    virtual void cdata(const XMLCh* const ch, const unsigned int length);
175
    virtual void
176
    cdata(
177
            const XMLCh* const  ch,
178
            const size_type     length);
170
179
171
    /**
180
    /**
172
     * Receive notification of ignorable whitespace in element content.
181
     * Receive notification of ignorable whitespace in element content.
Lines 191-197 Link Here
191
     * @exception SAXException
200
     * @exception SAXException
192
     * @see #characters
201
     * @see #characters
193
     */
202
     */
194
    virtual void ignorableWhitespace (const XMLCh* const chars, const unsigned int length);
203
    virtual void
204
    ignorableWhitespace(
205
            const XMLCh* const  chars,
206
            const size_type     length);
195
207
196
    /**
208
    /**
197
     * Receive notification of a processing instruction.
209
     * Receive notification of a processing instruction.
Lines 467-479 Link Here
467
479
468
    void
480
    void
469
    processText(
481
    processText(
470
            const XMLCh*                chars,
482
            const XMLCh*    chars,
471
            XalanDOMString::size_type   length);
483
            size_type       length);
472
484
473
    void
485
    void
474
    accumulateText(
486
    accumulateText(
475
            const XMLCh*                chars,
487
            const XMLCh*    chars,
476
            XalanDOMString::size_type   length);
488
            size_type       length);
477
489
478
    void
490
    void
479
    processAccumulatedText();
491
    processAccumulatedText();
(-)src/xalanc/XSLT/ElemDecimalFormat.cpp (-15 / +15 lines)
Lines 50-57 Link Here
50
            StylesheetConstructionContext&  constructionContext,
50
            StylesheetConstructionContext&  constructionContext,
51
            Stylesheet&                     stylesheetTree,
51
            Stylesheet&                     stylesheetTree,
52
            const AttributeListType&        atts,
52
            const AttributeListType&        atts,
53
            int                             lineNumber,
53
            XalanFileLoc                    lineNumber,
54
            int                             columnNumber) :
54
            XalanFileLoc                    columnNumber) :
55
    ElemTemplateElement(constructionContext,
55
    ElemTemplateElement(constructionContext,
56
                        stylesheetTree,
56
                        stylesheetTree,
57
                        lineNumber,
57
                        lineNumber,
Lines 66-78 Link Here
66
    m_decimalFormatSymbols.setInfinity(XalanDOMString(constructionContext.getMemoryManager()));
66
    m_decimalFormatSymbols.setInfinity(XalanDOMString(constructionContext.getMemoryManager()));
67
    m_decimalFormatSymbols.setNaN(XalanDOMString(constructionContext.getMemoryManager()));
67
    m_decimalFormatSymbols.setNaN(XalanDOMString(constructionContext.getMemoryManager()));
68
68
69
    const unsigned int  nAttrs = atts.getLength();
69
    const XalanSize_t  nAttrs = atts.getLength();
70
70
71
    for(unsigned int i = 0; i < nAttrs; i++)
71
    for (XalanSize_t i = 0; i < nAttrs; i++)
72
    {
72
    {
73
        const XalanDOMChar* const       aname = atts.getName(i);
73
        const XalanDOMChar* const       aname = atts.getName(i);
74
74
75
        if(equals(aname, Constants::ATTRNAME_NAME))
75
        if (equals(aname, Constants::ATTRNAME_NAME))
76
        {
76
        {
77
            assert(atts.getValue(i) != 0);
77
            assert(atts.getValue(i) != 0);
78
78
Lines 90-96 Link Here
90
                    atts.getValue(i));
90
                    atts.getValue(i));
91
            }
91
            }
92
        }
92
        }
93
        else if(equals(aname, Constants::ATTRNAME_DECIMALSEPARATOR))
93
        else if (equals(aname, Constants::ATTRNAME_DECIMALSEPARATOR))
94
        {
94
        {
95
            const XalanDOMChar* const   decimalSepValue = atts.getValue(i);
95
            const XalanDOMChar* const   decimalSepValue = atts.getValue(i);
96
            assert(decimalSepValue != 0);
96
            assert(decimalSepValue != 0);
Lines 109-115 Link Here
109
                    decimalSepValue);
109
                    decimalSepValue);
110
            }
110
            }
111
        }
111
        }
112
        else if(equals(aname, Constants::ATTRNAME_GROUPINGSEPARATOR))
112
        else if (equals(aname, Constants::ATTRNAME_GROUPINGSEPARATOR))
113
        {
113
        {
114
            const XalanDOMChar* const   sepValue = atts.getValue(i);
114
            const XalanDOMChar* const   sepValue = atts.getValue(i);
115
            assert(sepValue!= 0);
115
            assert(sepValue!= 0);
Lines 128-140 Link Here
128
                    sepValue);
128
                    sepValue);
129
            }
129
            }
130
        }
130
        }
131
        else if(equals(aname, Constants::ATTRNAME_INFINITY))
131
        else if (equals(aname, Constants::ATTRNAME_INFINITY))
132
        {
132
        {
133
            assert(atts.getValue(i) != 0);
133
            assert(atts.getValue(i) != 0);
134
134
135
            m_decimalFormatSymbols.setInfinity(atts.getValue(i));
135
            m_decimalFormatSymbols.setInfinity(atts.getValue(i));
136
        }
136
        }
137
        else if(equals(aname, Constants::ATTRNAME_MINUSSIGN))
137
        else if (equals(aname, Constants::ATTRNAME_MINUSSIGN))
138
        {
138
        {
139
            const XalanDOMChar* const   minusValue = atts.getValue(i);
139
            const XalanDOMChar* const   minusValue = atts.getValue(i);
140
            assert(minusValue != 0);
140
            assert(minusValue != 0);
Lines 153-165 Link Here
153
                    minusValue);
153
                    minusValue);
154
            }
154
            }
155
        }
155
        }
156
        else if(equals(aname, Constants::ATTRNAME_NAN))
156
        else if (equals(aname, Constants::ATTRNAME_NAN))
157
        {
157
        {
158
            assert(atts.getValue(i) != 0);
158
            assert(atts.getValue(i) != 0);
159
159
160
            m_decimalFormatSymbols.setNaN(atts.getValue(i));
160
            m_decimalFormatSymbols.setNaN(atts.getValue(i));
161
        }
161
        }
162
        else if(equals(aname, Constants::ATTRNAME_PERCENT))
162
        else if (equals(aname, Constants::ATTRNAME_PERCENT))
163
        {
163
        {
164
            const XalanDOMChar* const   percentValue = atts.getValue(i);
164
            const XalanDOMChar* const   percentValue = atts.getValue(i);
165
            assert(percentValue != 0);
165
            assert(percentValue != 0);
Lines 178-184 Link Here
178
                    percentValue);
178
                    percentValue);
179
            }
179
            }
180
        }
180
        }
181
        else if(equals(aname, Constants::ATTRNAME_PERMILLE))
181
        else if (equals(aname, Constants::ATTRNAME_PERMILLE))
182
        {
182
        {
183
            const XalanDOMChar* const   permilleValue = atts.getValue(i);
183
            const XalanDOMChar* const   permilleValue = atts.getValue(i);
184
            assert(permilleValue != 0);
184
            assert(permilleValue != 0);
Lines 197-203 Link Here
197
                    permilleValue);
197
                    permilleValue);
198
            }
198
            }
199
        }
199
        }
200
        else if(equals(aname, Constants::ATTRNAME_ZERODIGIT))
200
        else if (equals(aname, Constants::ATTRNAME_ZERODIGIT))
201
        {
201
        {
202
            const XalanDOMChar* const   zeroDigitValue = atts.getValue(i);
202
            const XalanDOMChar* const   zeroDigitValue = atts.getValue(i);
203
            assert(zeroDigitValue != 0);
203
            assert(zeroDigitValue != 0);
Lines 216-222 Link Here
216
                    zeroDigitValue);
216
                    zeroDigitValue);
217
            }
217
            }
218
        }
218
        }
219
        else if(equals(aname, Constants::ATTRNAME_DIGIT))
219
        else if (equals(aname, Constants::ATTRNAME_DIGIT))
220
        {
220
        {
221
            const XalanDOMChar* const   digitValue = atts.getValue(i);
221
            const XalanDOMChar* const   digitValue = atts.getValue(i);
222
            assert(digitValue != 0);
222
            assert(digitValue != 0);
Lines 308-314 Link Here
308
308
309
309
310
const XPath*
310
const XPath*
311
ElemDecimalFormat::getXPath(unsigned int    index) const
311
ElemDecimalFormat::getXPath(XalanSize_t index) const
312
{
312
{
313
    const XPath*    result = 0;
313
    const XPath*    result = 0;
314
314
(-)src/xalanc/XSLT/ElemAttributeSet.cpp (-8 / +8 lines)
Lines 41-48 Link Here
41
            StylesheetConstructionContext&  constructionContext,
41
            StylesheetConstructionContext&  constructionContext,
42
            Stylesheet&                     stylesheetTree,
42
            Stylesheet&                     stylesheetTree,
43
            const AttributeListType&        atts,
43
            const AttributeListType&        atts,
44
            int                             lineNumber,
44
            XalanFileLoc                    lineNumber,
45
            int                             columnNumber) :
45
            XalanFileLoc                    columnNumber) :
46
    ElemUse(constructionContext,
46
    ElemUse(constructionContext,
47
            stylesheetTree,
47
            stylesheetTree,
48
            lineNumber,
48
            lineNumber,
Lines 50-62 Link Here
50
            StylesheetConstructionContext::ELEMNAME_ATTRIBUTE_SET),
50
            StylesheetConstructionContext::ELEMNAME_ATTRIBUTE_SET),
51
    m_qname(0)
51
    m_qname(0)
52
{
52
{
53
    const unsigned int  nAttrs = atts.getLength();
53
    const XalanSize_t   nAttrs = atts.getLength();
54
54
55
    for(unsigned int i = 0; i < nAttrs; i++)
55
    for (XalanSize_t i = 0; i < nAttrs; i++)
56
    {
56
    {
57
        const XalanDOMChar* const   aname = atts.getName(i);
57
        const XalanDOMChar* const   aname = atts.getName(i);
58
58
59
        if(equals(aname, Constants::ATTRNAME_NAME))
59
        if (equals(aname, Constants::ATTRNAME_NAME))
60
        {
60
        {
61
            m_qname = constructionContext.createXalanQName(
61
            m_qname = constructionContext.createXalanQName(
62
                atts.getValue(i),
62
                atts.getValue(i),
Lines 72-83 Link Here
72
                    atts.getValue(i));
72
                    atts.getValue(i));
73
            }
73
            }
74
        }
74
        }
75
        else if(processUseAttributeSets(
75
        else if (processUseAttributeSets(
76
                    constructionContext,
76
                    constructionContext,
77
                    aname,
77
                    aname,
78
                    atts,
78
                    atts,
79
                    i) == false &&
79
                    i) == false &&
80
                isAttrOK(
80
                 isAttrOK(
81
                    aname,
81
                    aname,
82
                    atts,
82
                    atts,
83
                    i,
83
                    i,
Lines 91-97 Link Here
91
        }
91
        }
92
    }
92
    }
93
93
94
    if(m_qname == 0)
94
    if (m_qname == 0)
95
    {
95
    {
96
        error(
96
        error(
97
            constructionContext,
97
            constructionContext,
(-)src/xalanc/XSLT/ElemChoose.hpp (-2 / +2 lines)
Lines 49-56 Link Here
49
			StylesheetConstructionContext&	constructionContext,
49
			StylesheetConstructionContext&	constructionContext,
50
			Stylesheet&						stylesheetTree,
50
			Stylesheet&						stylesheetTree,
51
			const AttributeListType&		atts,
51
			const AttributeListType&		atts,
52
			int								lineNumber,
52
			XalanFileLoc					lineNumber,
53
			int								columnNumber);
53
			XalanFileLoc					columnNumber);
54
54
55
55
56
	// These methods are inherited from ElemTemplateElement ...
56
	// These methods are inherited from ElemTemplateElement ...
(-)src/xalanc/XSLT/ElemApplyImport.hpp (-3 / +2 lines)
Lines 50-57 Link Here
50
			StylesheetConstructionContext&	constructionContext,
50
			StylesheetConstructionContext&	constructionContext,
51
			Stylesheet&						stylesheetTree,
51
			Stylesheet&						stylesheetTree,
52
			const AttributeListType&		atts,
52
			const AttributeListType&		atts,
53
			int								lineNumber, 
53
			XalanFileLoc					lineNumber, 
54
			int								columnNumber);
54
			XalanFileLoc					columnNumber);
55
      
55
      
56
56
57
	// These methods are inherited from ElemTemplateElement ...
57
	// These methods are inherited from ElemTemplateElement ...
Lines 77-83 Link Here
77
	virtual ElemTemplateElement*
77
	virtual ElemTemplateElement*
78
	appendChildElem(ElemTemplateElement*	newChild);
78
	appendChildElem(ElemTemplateElement*	newChild);
79
79
80
81
private:
80
private:
82
};
81
};
83
82
(-)src/xalanc/XSLT/ElemElement.cpp (-4 / +5 lines)
Lines 45-52 Link Here
45
            StylesheetConstructionContext&  constructionContext,
45
            StylesheetConstructionContext&  constructionContext,
46
            Stylesheet&                     stylesheetTree,
46
            Stylesheet&                     stylesheetTree,
47
            const AttributeListType&        atts,
47
            const AttributeListType&        atts,
48
            int                             lineNumber,
48
            XalanFileLoc                    lineNumber,
49
            int                             columnNumber) :
49
            XalanFileLoc                    columnNumber) :
50
    ElemUse(constructionContext,
50
    ElemUse(constructionContext,
51
            stylesheetTree,
51
            stylesheetTree,
52
            lineNumber,
52
            lineNumber,
Lines 59-67 Link Here
59
    // turn them off...
59
    // turn them off...
60
//  m_namespacesHandler.setProcessNamespaceAliaises(false);
60
//  m_namespacesHandler.setProcessNamespaceAliaises(false);
61
61
62
    const unsigned int  nAttrs = atts.getLength();
62
    const XalanSize_t  nAttrs = atts.getLength();
63
63
64
    for(unsigned int i = 0; i < nAttrs; i++)
64
    for (XalanSize_t i = 0; i < nAttrs; i++)
65
    {
65
    {
66
        const XalanDOMChar* const   aname = atts.getName(i);
66
        const XalanDOMChar* const   aname = atts.getName(i);
67
67
Lines 125-130 Link Here
125
}
125
}
126
126
127
127
128
128
#if !defined(XALAN_RECURSIVE_STYLESHEET_EXECUTION)
129
#if !defined(XALAN_RECURSIVE_STYLESHEET_EXECUTION)
129
const ElemTemplateElement*
130
const ElemTemplateElement*
130
ElemElement::startElement(StylesheetExecutionContext&       executionContext) const
131
ElemElement::startElement(StylesheetExecutionContext&       executionContext) const
(-)src/xalanc/XSLT/XalanElemApplyTemplatesAllocator.cpp (-3 / +5 lines)
Lines 23-29 Link Here
23
23
24
24
25
25
26
XalanElemApplyTemplatesAllocator::XalanElemApplyTemplatesAllocator(MemoryManagerType&  theManager, size_type	theBlockCount) :
26
XalanElemApplyTemplatesAllocator::XalanElemApplyTemplatesAllocator(
27
            MemoryManagerType&  theManager,
28
            size_type	        theBlockCount) :
27
	m_allocator(theManager, theBlockCount)
29
	m_allocator(theManager, theBlockCount)
28
{
30
{
29
}
31
}
Lines 41-48 Link Here
41
			StylesheetConstructionContext&	constructionContext,
43
			StylesheetConstructionContext&	constructionContext,
42
			Stylesheet&						stylesheetTree,
44
			Stylesheet&						stylesheetTree,
43
			const AttributeListType&		atts,
45
			const AttributeListType&		atts,
44
			int								lineNumber,
46
			XalanFileLoc					lineNumber,
45
			int								columnNumber)
47
			XalanFileLoc					columnNumber)
46
{
48
{
47
	data_type* const	theBlock = m_allocator.allocateBlock();
49
	data_type* const	theBlock = m_allocator.allocateBlock();
48
	assert(theBlock != 0);
50
	assert(theBlock != 0);
(-)src/xalanc/XMLSupport/XalanIndentWriter.hpp (-3 / +6 lines)
Lines 22-39 Link Here
22
22
23
#include <xalanc/Include/XalanVector.hpp>
23
#include <xalanc/Include/XalanVector.hpp>
24
24
25
#include <xalanc/PlatformSupport/FormatterListener.hpp>
25
#include <xalanc/PlatformSupport/Writer.hpp>
26
#include <xalanc/PlatformSupport/Writer.hpp>
26
27
27
28
28
XALAN_CPP_NAMESPACE_BEGIN
29
XALAN_CPP_NAMESPACE_BEGIN
29
30
30
31
31
template<class WhiteSpaceWriter,
32
template<
32
         class NewLineWriter>
33
    class WhiteSpaceWriter,
34
    class NewLineWriter>
33
class XalanIndentWriter
35
class XalanIndentWriter
34
{
36
{
35
public:
37
public:
36
    typedef typename XalanDOMString::size_type       size_type;
38
 
39
    typedef FormatterListener::size_type    size_type;
37
    typedef XalanVector<bool>               BoolStackType;
40
    typedef XalanVector<bool>               BoolStackType;
38
    typedef typename WhiteSpaceWriter::writer_type   writer_type;
41
    typedef typename WhiteSpaceWriter::writer_type   writer_type;
39
42
(-)src/xalanc/XMLSupport/XalanUTF8Writer.hpp (-30 / +36 lines)
Lines 150-183 Link Here
150
    /**
150
    /**
151
     * Writes name chars , if not presentable, throws 
151
     * Writes name chars , if not presentable, throws 
152
     */
152
     */
153
    void writeNameChar(const XalanDOMChar*      data,
153
    void
154
                       size_type                theLength)
154
    writeNameChar(
155
            const XalanDOMChar*      data,
156
            size_type                theLength)
155
    {
157
    {
156
        write(data, theLength);
158
        write(data, theLength);
157
    }
159
    }
158
160
159
    /**
161
    /**
160
     * Writes name chars , if not presentable, throws 
162
     * Writes name chars, if not representable, throws 
161
     */
163
     */
162
    void writePIChars(const XalanDOMChar*       data,
164
    void
163
                        size_type               theLength)
165
    writePIChars(
166
            const XalanDOMChar*     data,
167
            size_type               theLength)
164
    {
168
    {
165
        write(data, theLength);
169
        write(data, theLength);
166
    }
170
    }
167
171
168
    /**
172
    /**
169
     * Writes name chars , if not presentable, throws 
173
     * Writes name chars, if not representable, throws 
170
     */
174
     */
171
    void writeCommentChars(const XalanDOMChar*      data,
175
    void
172
                           size_type                theLength)
176
    writeCommentChars(
177
            const XalanDOMChar*      data,
178
            size_type                theLength)
173
    {
179
    {
174
        write(data, theLength);
180
        write(data, theLength);
175
    }
181
    }
176
182
177
    void
183
    void
178
    safeWriteContent(
184
    safeWriteContent(
179
            const XalanDOMChar*         theChars,
185
            const XalanDOMChar*     theChars,
180
            XalanDOMString::size_type   theLength)
186
            size_type               theLength)
181
    {
187
    {
182
        for(size_type i = 0; i < theLength; ++i)
188
        for(size_type i = 0; i < theLength; ++i)
183
        { 
189
        { 
Lines 187-194 Link Here
187
193
188
    void
194
    void
189
    write(
195
    write(
190
            const value_type*           theChars,
196
            const value_type*   theChars,
191
            XalanDOMString::size_type   theLength)
197
            size_type           theLength)
192
    {
198
    {
193
    #if defined(NDEBUG)
199
    #if defined(NDEBUG)
194
        if (theLength > sizeof(m_buffer))
200
        if (theLength > sizeof(m_buffer))
Lines 214-220 Link Here
214
            m_bufferRemaining -= theLength;
220
            m_bufferRemaining -= theLength;
215
        }
221
        }
216
    #else
222
    #else
217
        for(XalanDOMString::size_type i = 0; i < theLength; ++i)
223
        for(size_type i = 0; i < theLength; ++i)
218
        {
224
        {
219
            write(theChars[i]);
225
            write(theChars[i]);
220
        }
226
        }
Lines 251-258 Link Here
251
257
252
    void
258
    void
253
    write(
259
    write(
254
                const XalanDOMChar*         theChars,
260
            const XalanDOMChar*     theChars,
255
                XalanDOMString::size_type   theLength)
261
            size_type               theLength)
256
    {
262
    {
257
        for(size_type i = 0; i < theLength; ++i)
263
        for(size_type i = 0; i < theLength; ++i)
258
        {
264
        {
Lines 262-274 Link Here
262
268
263
    size_type
269
    size_type
264
    write(
270
    write(
265
            const XalanDOMChar          chars[],
271
            const XalanDOMChar  chars[],
266
            XalanDOMString::size_type   start,
272
            size_type           start,
267
            XalanDOMString::size_type   length)
273
            size_type           length)
268
    {
274
    {
269
        XalanDOMChar ch = chars[start];
275
        XalanDOMChar ch = chars[start];
270
276
271
        if (XalanFormatterWriter::isUTF16HighSurrogate(ch) == false)
277
        if (isUTF16HighSurrogate(ch) == false)
272
        {
278
        {
273
            write((unsigned int)ch);
279
            write((unsigned int)ch);
274
        }
280
        }
Lines 276-282 Link Here
276
        {
282
        {
277
            if (start + 1 >= length)
283
            if (start + 1 >= length)
278
            {
284
            {
279
                XalanFormatterWriter::throwInvalidUTF16SurrogateException(
285
                throwInvalidUTF16SurrogateException(
280
                    ch, 
286
                    ch, 
281
                    0,
287
                    0,
282
                    getMemoryManager());
288
                    getMemoryManager());
Lines 284-290 Link Here
284
            else 
290
            else 
285
            {
291
            {
286
                write(
292
                write(
287
                    XalanFormatterWriter::decodeUTF16SurrogatePair(
293
                    decodeUTF16SurrogatePair(
288
                        ch,
294
                        ch,
289
                        chars[++start],
295
                        chars[++start],
290
                        getMemoryManager()));
296
                        getMemoryManager()));
Lines 296-303 Link Here
296
302
297
    void
303
    void
298
    writeSafe(
304
    writeSafe(
299
        const XalanDOMChar*         theChars,
305
        const XalanDOMChar*     theChars,
300
        XalanDOMString::size_type   theLength)
306
        size_type               theLength)
301
    {
307
    {
302
        XalanDOMChar ch = 0;
308
        XalanDOMChar ch = 0;
303
309
Lines 305-319 Link Here
305
        {
311
        {
306
            ch = theChars[i];
312
            ch = theChars[i];
307
313
308
            if (XalanFormatterWriter::isUTF16HighSurrogate(ch) == true)
314
            if (isUTF16HighSurrogate(ch) == true)
309
            {
315
            {
310
                if (i + 1 >= theLength)
316
                if (i + 1 >= theLength)
311
                {
317
                {
312
                    XalanFormatterWriter::throwInvalidUTF16SurrogateException(ch, 0,  getMemoryManager());
318
                    throwInvalidUTF16SurrogateException(ch, 0,  getMemoryManager());
313
                }
319
                }
314
                else 
320
                else 
315
                {
321
                {
316
                    write(XalanFormatterWriter::decodeUTF16SurrogatePair(ch, theChars[i+1],  getMemoryManager()));
322
                    write(decodeUTF16SurrogatePair(ch, theChars[i + 1],  getMemoryManager()));
317
323
318
                    ++i;
324
                    ++i;
319
                }
325
                }
Lines 410-416 Link Here
410
        }
416
        }
411
        else
417
        else
412
        {
418
        {
413
            XalanFormatterWriter::throwInvalidCharacterException(theChar, getMemoryManager());
419
            throwInvalidCharacterException(theChar, getMemoryManager());
414
        }
420
        }
415
    }
421
    }
416
422
Lines 421-431 Link Here
421
427
422
428
423
    // Data members...
429
    // Data members...
424
    value_type                  m_buffer[kBufferSize];
430
    value_type      m_buffer[kBufferSize];
425
431
426
    value_type*                 m_bufferPosition;
432
    value_type*     m_bufferPosition;
427
433
428
    XalanDOMString::size_type   m_bufferRemaining;
434
    size_type       m_bufferRemaining;
429
};
435
};
430
436
431
437
(-)src/xalanc/XMLSupport/XalanFormatterWriter.hpp (-6 / +7 lines)
Lines 24-29 Link Here
24
#include <xercesc/sax/SAXException.hpp>
24
#include <xercesc/sax/SAXException.hpp>
25
25
26
#include <xalanc/PlatformSupport/DOMStringHelper.hpp>
26
#include <xalanc/PlatformSupport/DOMStringHelper.hpp>
27
#include <xalanc/PlatformSupport/FormatterListener.hpp>
27
#include <xalanc/PlatformSupport/Writer.hpp>
28
#include <xalanc/PlatformSupport/Writer.hpp>
28
#include <xalanc/PlatformSupport/XalanMessageLoader.hpp>
29
#include <xalanc/PlatformSupport/XalanMessageLoader.hpp>
29
#include <xalanc/PlatformSupport/XalanOutputStream.hpp>
30
#include <xalanc/PlatformSupport/XalanOutputStream.hpp>
Lines 42-47 Link Here
42
{
43
{
43
public:
44
public:
44
45
46
    typedef FormatterListener::size_type    size_type;
47
48
45
    template <class WriterType>
49
    template <class WriterType>
46
    class NewLineWriterFunctor
50
    class NewLineWriterFunctor
47
    {
51
    {
Lines 90-103 Link Here
90
        /**
94
        /**
91
        * The length of the the string of characters that represents the newline
95
        * The length of the the string of characters that represents the newline
92
        */
96
        */
93
        XalanDOMString::size_type   m_newlineStringLength;
97
        size_type   m_newlineStringLength;
94
    };
98
    };
95
99
96
    template<class WriterType>
100
    template<class WriterType>
97
    class WhiteSpaceWriterFunctor
101
    class WhiteSpaceWriterFunctor
98
    {
102
    {
99
        typedef XalanDOMString::size_type       size_type;
100
        typedef typename WriterType::value_type value_type;
103
        typedef typename WriterType::value_type value_type;
104
101
    public:
105
    public:
102
        typedef WriterType                  writer_type;
106
        typedef WriterType                  writer_type;
103
107
Lines 150-158 Link Here
150
154
151
public:
155
public:
152
156
153
    typedef XalanDOMString::size_type   size_type;
154
155
156
    XalanFormatterWriter(
157
    XalanFormatterWriter(
157
                Writer&	        theWriter, 
158
                Writer&	        theWriter, 
158
                MemoryManager&  theMemoryManager) :
159
                MemoryManager&  theMemoryManager) :
Lines 313-319 Link Here
313
    /**
314
    /**
314
     * The length of the the string of characters that represents the newline
315
     * The length of the the string of characters that represents the newline
315
     */
316
     */
316
    XalanDOMString::size_type   m_newlineStringLength;
317
    size_type   m_newlineStringLength;
317
318
318
    /**
319
    /**
319
     * Format a code point as a numeric character reference.
320
     * Format a code point as a numeric character reference.
(-)src/xalanc/XMLSupport/FormatterToHTML.cpp (-21 / +21 lines)
Lines 156-162 Link Here
156
	m_attrCharsMap[XalanUnicode::charLessThanSign] = 0;
156
	m_attrCharsMap[XalanUnicode::charLessThanSign] = 0;
157
	m_attrCharsMap[XalanUnicode::charGreaterThanSign] = 0;
157
	m_attrCharsMap[XalanUnicode::charGreaterThanSign] = 0;
158
158
159
	for(XalanDOMString::size_type i = 160; i < SPECIALSSIZE; i++)
159
	for(size_type i = 160; i < SPECIALSSIZE; i++)
160
	{
160
	{
161
		m_attrCharsMap[i] = 'S';
161
		m_attrCharsMap[i] = 'S';
162
	}
162
	}
Lines 481-487 Link Here
481
void
481
void
482
FormatterToHTML::characters(
482
FormatterToHTML::characters(
483
			const XMLCh* const	chars,
483
			const XMLCh* const	chars,
484
			const unsigned int	length)
484
			const size_type 	length)
485
{
485
{
486
	if(length != 0)
486
	if(length != 0)
487
	{
487
	{
Lines 590-596 Link Here
590
void
590
void
591
FormatterToHTML::cdata(
591
FormatterToHTML::cdata(
592
			const XMLCh* const	ch,
592
			const XMLCh* const	ch,
593
			const unsigned int 	length)
593
			const size_type 	length)
594
{
594
{
595
	if(m_isScriptOrStyleElem == true)
595
	if(m_isScriptOrStyleElem == true)
596
	{
596
	{
Lines 632-638 Link Here
632
		const XMLCh* const	data)
632
		const XMLCh* const	data)
633
633
634
{
634
{
635
	const XalanDOMString::size_type		dataLength = length(data);
635
	const size_type		dataLength = length(data);
636
636
637
	// Use a fairly nasty hack to tell if the next node is supposed to be 
637
	// Use a fairly nasty hack to tell if the next node is supposed to be 
638
	// unescaped text.
638
	// unescaped text.
Lines 689-701 Link Here
689
689
690
void
690
void
691
FormatterToHTML::writeCharacters(
691
FormatterToHTML::writeCharacters(
692
			const XalanDOMChar*			theString,
692
			const XalanDOMChar*		theString,
693
			XalanDOMString::size_type	theLength)
693
			size_type	            theLength)
694
{
694
{
695
	assert(theString != 0);
695
	assert(theString != 0);
696
696
697
	XalanDOMString::size_type	i = 0;
697
	size_type	i = 0;
698
	XalanDOMString::size_type	firstIndex = 0;
698
	size_type	firstIndex = 0;
699
699
700
    while(i < theLength)
700
    while(i < theLength)
701
	{
701
	{
Lines 768-780 Link Here
768
768
769
void
769
void
770
FormatterToHTML::writeAttrString(
770
FormatterToHTML::writeAttrString(
771
			const XalanDOMChar*			theString,
771
			const XalanDOMChar*		theString,
772
			XalanDOMString::size_type	theStringLength)
772
			size_type	            theStringLength)
773
{
773
{
774
	assert(theString != 0);
774
	assert(theString != 0);
775
775
776
	XalanDOMString::size_type	i = 0;
776
	size_type	i = 0;
777
	XalanDOMString::size_type	firstIndex = 0;
777
	size_type	firstIndex = 0;
778
778
779
    while(i < theStringLength)
779
    while(i < theStringLength)
780
    {
780
    {
Lines 853-860 Link Here
853
853
854
void
854
void
855
FormatterToHTML::copyEntityIntoBuffer(
855
FormatterToHTML::copyEntityIntoBuffer(
856
			const XalanDOMChar*			s,
856
			const XalanDOMChar*		s,
857
			XalanDOMString::size_type	theLength)
857
			size_type	            theLength)
858
{
858
{
859
	assert(s != 0);
859
	assert(s != 0);
860
860
Lines 885-895 Link Here
885
			const XalanDOMChar*										value,
885
			const XalanDOMChar*										value,
886
			const XalanHTMLElementsProperties::ElementProperties&	elemProperties)
886
			const XalanHTMLElementsProperties::ElementProperties&	elemProperties)
887
{
887
{
888
	const XalanDOMString::size_type		nameLength = length(name);
888
	const size_type		nameLength = length(name);
889
889
890
	accumContent(XalanUnicode::charSpace);
890
	accumContent(XalanUnicode::charSpace);
891
891
892
	const XalanDOMString::size_type		valueLength = length(value);
892
	const size_type     valueLength = length(value);
893
893
894
	if((valueLength == 0 || equalsIgnoreCaseASCII(name, nameLength, value, valueLength)) &&
894
	if((valueLength == 0 || equalsIgnoreCaseASCII(name, nameLength, value, valueLength)) &&
895
	   elemProperties.isAttribute(name, XalanHTMLElementsProperties::ATTREMPTY) == true)
895
	   elemProperties.isAttribute(name, XalanHTMLElementsProperties::ATTREMPTY) == true)
Lines 919-926 Link Here
919
919
920
void
920
void
921
FormatterToHTML::writeAttrURI(
921
FormatterToHTML::writeAttrURI(
922
			const XalanDOMChar*			theString,
922
			const XalanDOMChar*		theString,
923
			XalanDOMString::size_type	theStringLength)
923
			size_type	            theStringLength)
924
{
924
{
925
	assert(theString != 0);
925
	assert(theString != 0);
926
926
Lines 939-945 Link Here
939
	// causing damage.	If the URL is already properly escaped, in theory, this 
939
	// causing damage.	If the URL is already properly escaped, in theory, this 
940
	// function should not change the string value.
940
	// function should not change the string value.
941
941
942
    for (XalanDOMString::size_type i = 0; i < theStringLength; ++i)
942
    for (size_type i = 0; i < theStringLength; ++i)
943
    {
943
    {
944
		const XalanDOMChar	ch = theString[i];
944
		const XalanDOMChar	ch = theString[i];
945
945
Lines 1123-1130 Link Here
1123
1123
1124
	if (m_prefixResolver != 0)
1124
	if (m_prefixResolver != 0)
1125
	{
1125
	{
1126
		const XalanDOMString::size_type		theLength = length(theElementName);
1126
		const size_type		theLength = length(theElementName);
1127
		const XalanDOMString::size_type		theColonIndex = indexOf(theElementName, XalanUnicode::charColon);
1127
		const size_type		theColonIndex = indexOf(theElementName, XalanUnicode::charColon);
1128
1128
1129
		const XalanDOMString*	thePrefix = &s_emptyString;
1129
		const XalanDOMString*	thePrefix = &s_emptyString;
1130
1130
(-)src/xalanc/XMLSupport/FormatterToHTML.hpp (-15 / +13 lines)
Lines 118-124 Link Here
118
    virtual void
118
    virtual void
119
	characters(
119
	characters(
120
			const XMLCh* const	chars,
120
			const XMLCh* const	chars,
121
			const unsigned int	length);
121
			const size_type 	length);
122
122
123
	// These methods are inherited from FormatterToXML...
123
	// These methods are inherited from FormatterToXML...
124
124
Lines 135-141 Link Here
135
	virtual void
135
	virtual void
136
	cdata(
136
	cdata(
137
			const XMLCh* const	ch,
137
			const XMLCh* const	ch,
138
			const unsigned int 	length);
138
			const size_type 	length);
139
139
140
	virtual void
140
	virtual void
141
	processingInstruction(
141
	processingInstruction(
Lines 159-177 Link Here
159
	{
159
	{
160
		enum { eMaxLength = 8 };
160
		enum { eMaxLength = 8 };
161
161
162
		XalanDOMChar				m_char;
162
		XalanDOMChar	m_char;
163
163
164
		XalanDOMString::size_type	m_length;
164
		size_type	    m_length;
165
165
166
		XalanDOMChar				m_string[eMaxLength + 1];
166
		XalanDOMChar	m_string[eMaxLength + 1];
167
	};
167
	};
168
168
169
protected:
169
protected:
170
170
171
	virtual void
171
	virtual void
172
	writeAttrString(
172
	writeAttrString(
173
			const XalanDOMChar*			theString,
173
			const XalanDOMChar*		theString,
174
			XalanDOMString::size_type	theStringLength);
174
			size_type	            theStringLength);
175
175
176
	virtual void
176
	virtual void
177
	accumCommentData(const XalanDOMChar*	data);
177
	accumCommentData(const XalanDOMChar*	data);
Lines 181-193 Link Here
181
181
182
	void
182
	void
183
	writeCharacters(
183
	writeCharacters(
184
			const XalanDOMChar*			theString,
184
			const XalanDOMChar*		theString,
185
			XalanDOMString::size_type	theLength);
185
			size_type	            theLength);
186
186
187
private:
187
private:
188
188
189
	typedef XalanDOMString::size_type	size_type;
190
191
	/**
189
	/**
192
	 * The string "<!DOCTYPE  HTML".
190
	 * The string "<!DOCTYPE  HTML".
193
	 */
191
	 */
Lines 230-237 Link Here
230
228
231
	void
229
	void
232
	copyEntityIntoBuffer(
230
	copyEntityIntoBuffer(
233
			const XalanDOMChar*			s,
231
			const XalanDOMChar*		s,
234
			XalanDOMString::size_type	theLength);
232
			size_type	            theLength);
235
233
236
	void
234
	void
237
	copyEntityIntoBuffer(const XalanDOMString&	s);
235
	copyEntityIntoBuffer(const XalanDOMString&	s);
Lines 256-263 Link Here
256
	 */
254
	 */
257
	void
255
	void
258
	writeAttrURI(
256
	writeAttrURI(
259
			const XalanDOMChar*			theString,
257
			const XalanDOMChar*		theString,
260
			XalanDOMString::size_type	theStringLength);
258
			size_type	            theStringLength);
261
259
262
	/**
260
	/**
263
	 * Accumulate the specified character by converting its numeric value to
261
	 * Accumulate the specified character by converting its numeric value to
(-)src/xalanc/XMLSupport/FormatterToNull.cpp (-5 / +5 lines)
Lines 76-82 Link Here
76
void
76
void
77
FormatterToNull::characters(
77
FormatterToNull::characters(
78
			const XMLCh* const	/* chars */,
78
			const XMLCh* const	/* chars */,
79
			const unsigned int	/* length */)
79
			const size_type	    /* length */)
80
{
80
{
81
}
81
}
82
82
Lines 85-91 Link Here
85
void
85
void
86
FormatterToNull::charactersRaw(
86
FormatterToNull::charactersRaw(
87
		const XMLCh* const	/* chars */,
87
		const XMLCh* const	/* chars */,
88
		const unsigned int	/*length */)
88
		const size_type	    /*length */)
89
{
89
{
90
}
90
}
91
91
Lines 100-106 Link Here
100
void
100
void
101
FormatterToNull::ignorableWhitespace(
101
FormatterToNull::ignorableWhitespace(
102
			const XMLCh* const	/* chars */,
102
			const XMLCh* const	/* chars */,
103
			const unsigned int	/* length */)
103
			const size_type	    /* length */)
104
{
104
{
105
}
105
}
106
106
Lines 131-138 Link Here
131
131
132
void
132
void
133
FormatterToNull::cdata(
133
FormatterToNull::cdata(
134
			const XMLCh* const	 /* ch */,
134
			const XMLCh* const  /* ch */,
135
			const unsigned int 	/* length */)
135
			const size_type	    /* length */)
136
{
136
{
137
}
137
}
138
138
(-)src/xalanc/XMLSupport/FormatterToXMLUnicode.hpp (-28 / +28 lines)
Lines 233-239 Link Here
233
    virtual void
233
    virtual void
234
    charactersRaw(
234
    charactersRaw(
235
            const XMLCh* const  chars,
235
            const XMLCh* const  chars,
236
            const unsigned int  length)
236
            const size_type     length)
237
    {
237
    {
238
        writeParentTagEnd();
238
        writeParentTagEnd();
239
    
239
    
Lines 391-397 Link Here
391
        m_writer.write(value_type(XalanUnicode::charQuestionMark));
391
        m_writer.write(value_type(XalanUnicode::charQuestionMark));
392
        writeName(target);
392
        writeName(target);
393
393
394
        const XalanDOMString::size_type     len = length(data);
394
        const size_type     len = length(data);
395
395
396
        // We need to make sure there is a least one whitespace character
396
        // We need to make sure there is a least one whitespace character
397
        // between the target and the data.
397
        // between the target and the data.
Lines 416-422 Link Here
416
    void
416
    void
417
    writeCharacters(
417
    writeCharacters(
418
            const XMLCh*    chars,
418
            const XMLCh*    chars,
419
            unsigned int    length)
419
            size_type       length)
420
    {
420
    {
421
        assert(length != 0);
421
        assert(length != 0);
422
422
Lines 424-431 Link Here
424
424
425
        m_indentHandler.setPreserve(true);
425
        m_indentHandler.setPreserve(true);
426
426
427
        unsigned int    i = 0;
427
        size_type   i = 0;
428
        unsigned int    firstIndex = 0;
428
        size_type   firstIndex = 0;
429
429
430
        while(i < length) 
430
        while(i < length) 
431
        {
431
        {
Lines 466-472 Link Here
466
    void
466
    void
467
    writeCDATA(
467
    writeCDATA(
468
            const XMLCh*    chars,
468
            const XMLCh*    chars,
469
            unsigned int    length)
469
            size_type       length)
470
    {
470
    {
471
        assert(length != 0);
471
        assert(length != 0);
472
    
472
    
Lines 638-649 Link Here
638
    * @param start the start offset into the string.
638
    * @param start the start offset into the string.
639
    * @param length the length of the string.
639
    * @param length the length of the string.
640
    */
640
    */
641
    XalanDOMString::size_type
641
    size_type
642
    writeNormalizedChar(
642
    writeNormalizedChar(
643
        XalanDOMChar                ch,
643
        XalanDOMChar        ch,
644
        const XalanDOMChar          chars[],
644
        const XalanDOMChar  chars[],
645
        XalanDOMString::size_type   start,
645
        size_type           start,
646
        XalanDOMString::size_type   length)
646
        size_type           length)
647
    {
647
    {
648
        if (XalanUnicode::charLF == ch)
648
        if (XalanUnicode::charLF == ch)
649
        {
649
        {
Lines 679-689 Link Here
679
        m_writer.write(value_type(XalanUnicode::charSemicolon));
679
        m_writer.write(value_type(XalanUnicode::charSemicolon));
680
    }
680
    }
681
681
682
    XalanDOMString::size_type
682
    size_type
683
    writeNormalizedCharBig(
683
    writeNormalizedCharBig(
684
            const XalanDOMChar          chars[],
684
            const XalanDOMChar  chars[],
685
            XalanDOMString::size_type   start,
685
            size_type           start,
686
            XalanDOMString::size_type   length)
686
            size_type           length)
687
    {
687
    {
688
        assert( start < length);
688
        assert( start < length);
689
689
Lines 712-722 Link Here
712
     */
712
     */
713
    void
713
    void
714
    writeCDATAChars(
714
    writeCDATAChars(
715
            const XalanDOMChar          chars[],
715
            const XalanDOMChar  chars[],
716
            XalanDOMString::size_type   length,
716
            size_type           length,
717
            bool&                       outsideCDATA)
717
            bool&               outsideCDATA)
718
    {
718
    {
719
        XalanDOMString::size_type i = 0;
719
        size_type   i = 0;
720
720
721
        while(i < length)
721
        while(i < length)
722
        {
722
        {
Lines 795-807 Link Here
795
     */
795
     */
796
    void
796
    void
797
    writeAttrString(
797
    writeAttrString(
798
            const XalanDOMChar*         theString,
798
            const XalanDOMChar*     theString,
799
            XalanDOMString::size_type   theStringLength)
799
            size_type               theStringLength)
800
    {
800
    {
801
        assert(theString != 0);
801
        assert(theString != 0);
802
802
803
        XalanDOMString::size_type   i = 0;
803
        size_type   i = 0;
804
        XalanDOMString::size_type   firstIndex = 0;
804
        size_type   firstIndex = 0;
805
805
806
        while(i < theStringLength)
806
        while(i < theStringLength)
807
        {
807
        {
Lines 863-872 Link Here
863
     */
863
     */
864
    void
864
    void
865
    writeNormalizedData(
865
    writeNormalizedData(
866
            const XalanDOMChar*         theData,
866
            const XalanDOMChar*     theData,
867
            XalanDOMString::size_type   theLength)
867
            size_type               theLength)
868
    {
868
    {
869
        for (XalanDOMString::size_type i = 0; i < theLength; ++i)
869
        for (size_type i = 0; i < theLength; ++i)
870
        {
870
        {
871
            const XalanDOMChar  theChar = theData[i];
871
            const XalanDOMChar  theChar = theData[i];
872
872
Lines 876-883 Link Here
876
876
877
    void
877
    void
878
    safeWriteContent(
878
    safeWriteContent(
879
                const XalanDOMChar*         theChars,
879
                const XalanDOMChar*     theChars,
880
                XalanDOMString::size_type   theLength)
880
                size_type               theLength)
881
    {
881
    {
882
        for(size_type i = 0; i < theLength; ++i)
882
        for(size_type i = 0; i < theLength; ++i)
883
        {
883
        {
(-)src/xalanc/XMLSupport/FormatterToNull.hpp (-4 / +4 lines)
Lines 74-85 Link Here
74
    virtual void
74
    virtual void
75
	characters(
75
	characters(
76
			const XMLCh* const	chars,
76
			const XMLCh* const	chars,
77
			const unsigned int	length);
77
			const size_type     length);
78
78
79
    virtual void
79
    virtual void
80
	charactersRaw(
80
	charactersRaw(
81
			const XMLCh* const	chars,
81
			const XMLCh* const	chars,
82
			const unsigned int	length);
82
			const size_type	    length);
83
83
84
	virtual void
84
	virtual void
85
	entityReference(const XMLCh* const	name);
85
	entityReference(const XMLCh* const	name);
Lines 87-93 Link Here
87
	virtual void
87
	virtual void
88
	ignorableWhitespace(
88
	ignorableWhitespace(
89
			const XMLCh* const	chars,
89
			const XMLCh* const	chars,
90
			const unsigned int	length);
90
			const size_type	    length);
91
91
92
	virtual void
92
	virtual void
93
	processingInstruction(
93
	processingInstruction(
Lines 104-110 Link Here
104
	virtual void
104
	virtual void
105
	cdata(
105
	cdata(
106
			const XMLCh* const	ch,
106
			const XMLCh* const	ch,
107
			const unsigned int 	length);
107
			const size_type 	length);
108
108
109
private:
109
private:
110
110
(-)src/xalanc/XMLSupport/XalanXMLSerializerBase.cpp (-34 / +34 lines)
Lines 258-264 Link Here
258
void
258
void
259
XalanXMLSerializerBase::characters(
259
XalanXMLSerializerBase::characters(
260
            const XMLCh* const  chars,
260
            const XMLCh* const  chars,
261
            const unsigned int  length)
261
            const size_type     length)
262
{
262
{
263
    if(length != 0)
263
    if(length != 0)
264
    {
264
    {
Lines 280-286 Link Here
280
void
280
void
281
XalanXMLSerializerBase::cdata(
281
XalanXMLSerializerBase::cdata(
282
            const XMLCh* const  ch,
282
            const XMLCh* const  ch,
283
            const unsigned int  length)
283
            const size_type     length)
284
{
284
{
285
    if (length != 0)
285
    if (length != 0)
286
    {
286
    {
Lines 322-328 Link Here
322
void
322
void
323
XalanXMLSerializerBase::ignorableWhitespace(
323
XalanXMLSerializerBase::ignorableWhitespace(
324
            const XMLCh* const  chars,
324
            const XMLCh* const  chars,
325
            const unsigned int  length)
325
            const size_type     length)
326
{
326
{
327
    if (length > 0)
327
    if (length > 0)
328
    {
328
    {
Lines 380-386 Link Here
380
    XalanDOMChar(0)
380
    XalanDOMChar(0)
381
};
381
};
382
382
383
const XalanDOMString::size_type     XalanXMLSerializerBase::s_xhtmlDocTypeStringLength =
383
const XalanXMLSerializerBase::size_type     XalanXMLSerializerBase::s_xhtmlDocTypeStringLength =
384
        FXML_SIZE(s_xhtmlDocTypeString);
384
        FXML_SIZE(s_xhtmlDocTypeString);
385
385
386
386
Lines 481-487 Link Here
481
    char(0)
481
    char(0)
482
};
482
};
483
483
484
const XalanDOMString::size_type XalanXMLSerializerBase::UTF8::s_doctypeHeaderStartStringLength =
484
const XalanXMLSerializerBase::size_type     XalanXMLSerializerBase::UTF8::s_doctypeHeaderStartStringLength =
485
        FXML_SIZE(s_doctypeHeaderStartString);
485
        FXML_SIZE(s_doctypeHeaderStartString);
486
486
487
const char  XalanXMLSerializerBase::UTF8::s_doctypeHeaderPublicString[] =
487
const char  XalanXMLSerializerBase::UTF8::s_doctypeHeaderPublicString[] =
Lines 498-504 Link Here
498
    char(0)
498
    char(0)
499
};
499
};
500
500
501
const XalanDOMString::size_type XalanXMLSerializerBase::UTF8::s_doctypeHeaderPublicStringLength =
501
const XalanXMLSerializerBase::size_type     XalanXMLSerializerBase::UTF8::s_doctypeHeaderPublicStringLength =
502
        FXML_SIZE(s_doctypeHeaderPublicString);
502
        FXML_SIZE(s_doctypeHeaderPublicString);
503
503
504
const char  XalanXMLSerializerBase::UTF8::s_doctypeHeaderSystemString[] =
504
const char  XalanXMLSerializerBase::UTF8::s_doctypeHeaderSystemString[] =
Lines 515-521 Link Here
515
    char(0)
515
    char(0)
516
};
516
};
517
517
518
const XalanDOMString::size_type     XalanXMLSerializerBase::UTF8::s_doctypeHeaderSystemStringLength =
518
const XalanXMLSerializerBase::size_type     XalanXMLSerializerBase::UTF8::s_doctypeHeaderSystemStringLength =
519
        FXML_SIZE(s_doctypeHeaderSystemString);
519
        FXML_SIZE(s_doctypeHeaderSystemString);
520
520
521
const char  XalanXMLSerializerBase::UTF8::s_xmlHeaderStartString[] =
521
const char  XalanXMLSerializerBase::UTF8::s_xmlHeaderStartString[] =
Lines 538-544 Link Here
538
    char(0)
538
    char(0)
539
};
539
};
540
540
541
const XalanDOMString::size_type     XalanXMLSerializerBase::UTF8::s_xmlHeaderStartStringLength =
541
const XalanXMLSerializerBase::size_type     XalanXMLSerializerBase::UTF8::s_xmlHeaderStartStringLength =
542
        FXML_SIZE(s_xmlHeaderStartString);
542
        FXML_SIZE(s_xmlHeaderStartString);
543
543
544
const char  XalanXMLSerializerBase::UTF8::s_xmlHeaderEncodingString[] =
544
const char  XalanXMLSerializerBase::UTF8::s_xmlHeaderEncodingString[] =
Lines 558-564 Link Here
558
    char(0)
558
    char(0)
559
};
559
};
560
560
561
const XalanDOMString::size_type     XalanXMLSerializerBase::UTF8::s_xmlHeaderEncodingStringLength =
561
const XalanXMLSerializerBase::size_type     XalanXMLSerializerBase::UTF8::s_xmlHeaderEncodingStringLength =
562
        FXML_SIZE(s_xmlHeaderEncodingString);
562
        FXML_SIZE(s_xmlHeaderEncodingString);
563
563
564
const char  XalanXMLSerializerBase::UTF8::s_xmlHeaderStandaloneString[] =
564
const char  XalanXMLSerializerBase::UTF8::s_xmlHeaderStandaloneString[] =
Lines 580-586 Link Here
580
    char(0)
580
    char(0)
581
};
581
};
582
582
583
const XalanDOMString::size_type     XalanXMLSerializerBase::UTF8::s_xmlHeaderStandaloneStringLength =
583
const XalanXMLSerializerBase::size_type     XalanXMLSerializerBase::UTF8::s_xmlHeaderStandaloneStringLength =
584
        FXML_SIZE(s_xmlHeaderStandaloneString);
584
        FXML_SIZE(s_xmlHeaderStandaloneString);
585
585
586
const char  XalanXMLSerializerBase::UTF8::s_xmlHeaderEndString[] =
586
const char  XalanXMLSerializerBase::UTF8::s_xmlHeaderEndString[] =
Lines 591-597 Link Here
591
    char(0)
591
    char(0)
592
};
592
};
593
593
594
const XalanDOMString::size_type     XalanXMLSerializerBase::UTF8::s_xmlHeaderEndStringLength =
594
const XalanXMLSerializerBase::size_type     XalanXMLSerializerBase::UTF8::s_xmlHeaderEndStringLength =
595
        FXML_SIZE(s_xmlHeaderEndString);
595
        FXML_SIZE(s_xmlHeaderEndString);
596
596
597
const char  XalanXMLSerializerBase::UTF8::s_defaultVersionString[] =
597
const char  XalanXMLSerializerBase::UTF8::s_defaultVersionString[] =
Lines 602-608 Link Here
602
    char(0)
602
    char(0)
603
};
603
};
604
604
605
const XalanDOMString::size_type     XalanXMLSerializerBase::UTF8::s_defaultVersionStringLength =
605
const XalanXMLSerializerBase::size_type     XalanXMLSerializerBase::UTF8::s_defaultVersionStringLength =
606
        FXML_SIZE(s_defaultVersionString);
606
        FXML_SIZE(s_defaultVersionString);
607
607
608
const char  XalanXMLSerializerBase::UTF8::s_cdataOpenString[] =
608
const char  XalanXMLSerializerBase::UTF8::s_cdataOpenString[] =
Lines 619-625 Link Here
619
    char(0)
619
    char(0)
620
};
620
};
621
621
622
const XalanDOMString::size_type     XalanXMLSerializerBase::UTF8::s_cdataOpenStringLength =
622
const XalanXMLSerializerBase::size_type     XalanXMLSerializerBase::UTF8::s_cdataOpenStringLength =
623
        FXML_SIZE(s_cdataOpenString);
623
        FXML_SIZE(s_cdataOpenString);
624
624
625
const char  XalanXMLSerializerBase::UTF8::s_cdataCloseString[] =
625
const char  XalanXMLSerializerBase::UTF8::s_cdataCloseString[] =
Lines 630-636 Link Here
630
    char(0)
630
    char(0)
631
};
631
};
632
632
633
const XalanDOMString::size_type     XalanXMLSerializerBase::UTF8::s_cdataCloseStringLength =
633
const XalanXMLSerializerBase::size_type     XalanXMLSerializerBase::UTF8::s_cdataCloseStringLength =
634
        FXML_SIZE(s_cdataCloseString);
634
        FXML_SIZE(s_cdataCloseString);
635
635
636
636
Lines 656-662 Link Here
656
    XalanDOMChar(0)
656
    XalanDOMChar(0)
657
};
657
};
658
658
659
const XalanDOMString::size_type     XalanXMLSerializerBase::UTF8::s_xhtmlDocTypeStringLength =
659
const XalanXMLSerializerBase::size_type     XalanXMLSerializerBase::UTF8::s_xhtmlDocTypeStringLength =
660
        FXML_SIZE(s_xhtmlDocTypeString);
660
        FXML_SIZE(s_xhtmlDocTypeString);
661
661
662
const char  XalanXMLSerializerBase::UTF8::s_lessThanEntityString[] =
662
const char  XalanXMLSerializerBase::UTF8::s_lessThanEntityString[] =
Lines 668-674 Link Here
668
    char(0)
668
    char(0)
669
};
669
};
670
670
671
const XalanDOMString::size_type     XalanXMLSerializerBase::UTF8::s_lessThanEntityStringLength =
671
const XalanXMLSerializerBase::size_type     XalanXMLSerializerBase::UTF8::s_lessThanEntityStringLength =
672
        FXML_SIZE(s_lessThanEntityString);
672
        FXML_SIZE(s_lessThanEntityString);
673
673
674
const char  XalanXMLSerializerBase::UTF8::s_greaterThanEntityString[] =
674
const char  XalanXMLSerializerBase::UTF8::s_greaterThanEntityString[] =
Lines 680-686 Link Here
680
    char(0)
680
    char(0)
681
};
681
};
682
682
683
const XalanDOMString::size_type     XalanXMLSerializerBase::UTF8::s_greaterThanEntityStringLength =
683
const XalanXMLSerializerBase::size_type     XalanXMLSerializerBase::UTF8::s_greaterThanEntityStringLength =
684
        FXML_SIZE(s_greaterThanEntityString);
684
        FXML_SIZE(s_greaterThanEntityString);
685
685
686
const char  XalanXMLSerializerBase::UTF8::s_ampersandEntityString[] =
686
const char  XalanXMLSerializerBase::UTF8::s_ampersandEntityString[] =
Lines 693-699 Link Here
693
    char(0)
693
    char(0)
694
};
694
};
695
695
696
const XalanDOMString::size_type     XalanXMLSerializerBase::UTF8::s_ampersandEntityStringLength =
696
const XalanXMLSerializerBase::size_type     XalanXMLSerializerBase::UTF8::s_ampersandEntityStringLength =
697
        FXML_SIZE(s_ampersandEntityString);
697
        FXML_SIZE(s_ampersandEntityString);
698
698
699
const char  XalanXMLSerializerBase::UTF8::s_quoteEntityString[] =
699
const char  XalanXMLSerializerBase::UTF8::s_quoteEntityString[] =
Lines 707-713 Link Here
707
    char(0)
707
    char(0)
708
};
708
};
709
709
710
const XalanDOMString::size_type     XalanXMLSerializerBase::UTF8::s_quoteEntityStringLength =
710
const XalanXMLSerializerBase::size_type     XalanXMLSerializerBase::UTF8::s_quoteEntityStringLength =
711
        FXML_SIZE(s_quoteEntityString);
711
        FXML_SIZE(s_quoteEntityString);
712
712
713
const XalanDOMChar  XalanXMLSerializerBase::UTF16::s_doctypeHeaderStartString[] =
713
const XalanDOMChar  XalanXMLSerializerBase::UTF16::s_doctypeHeaderStartString[] =
Lines 725-731 Link Here
725
    XalanDOMChar(0)
725
    XalanDOMChar(0)
726
};
726
};
727
727
728
const XalanDOMString::size_type XalanXMLSerializerBase::UTF16::s_doctypeHeaderStartStringLength =
728
const XalanXMLSerializerBase::size_type     XalanXMLSerializerBase::UTF16::s_doctypeHeaderStartStringLength =
729
        FXML_SIZE(s_doctypeHeaderStartString);
729
        FXML_SIZE(s_doctypeHeaderStartString);
730
730
731
const XalanDOMChar  XalanXMLSerializerBase::UTF16::s_doctypeHeaderPublicString[] =
731
const XalanDOMChar  XalanXMLSerializerBase::UTF16::s_doctypeHeaderPublicString[] =
Lines 742-748 Link Here
742
    XalanDOMChar(0)
742
    XalanDOMChar(0)
743
};
743
};
744
744
745
const XalanDOMString::size_type XalanXMLSerializerBase::UTF16::s_doctypeHeaderPublicStringLength =
745
const XalanXMLSerializerBase::size_type     XalanXMLSerializerBase::UTF16::s_doctypeHeaderPublicStringLength =
746
        FXML_SIZE(s_doctypeHeaderPublicString);
746
        FXML_SIZE(s_doctypeHeaderPublicString);
747
747
748
const XalanDOMChar  XalanXMLSerializerBase::UTF16::s_doctypeHeaderSystemString[] =
748
const XalanDOMChar  XalanXMLSerializerBase::UTF16::s_doctypeHeaderSystemString[] =
Lines 759-765 Link Here
759
    XalanDOMChar(0)
759
    XalanDOMChar(0)
760
};
760
};
761
761
762
const XalanDOMString::size_type     XalanXMLSerializerBase::UTF16::s_doctypeHeaderSystemStringLength =
762
const XalanXMLSerializerBase::size_type     XalanXMLSerializerBase::UTF16::s_doctypeHeaderSystemStringLength =
763
        FXML_SIZE(s_doctypeHeaderSystemString);
763
        FXML_SIZE(s_doctypeHeaderSystemString);
764
764
765
const XalanDOMChar  XalanXMLSerializerBase::UTF16::s_xmlHeaderStartString[] =
765
const XalanDOMChar  XalanXMLSerializerBase::UTF16::s_xmlHeaderStartString[] =
Lines 782-788 Link Here
782
    XalanDOMChar(0)
782
    XalanDOMChar(0)
783
};
783
};
784
784
785
const XalanDOMString::size_type     XalanXMLSerializerBase::UTF16::s_xmlHeaderStartStringLength =
785
const XalanXMLSerializerBase::size_type     XalanXMLSerializerBase::UTF16::s_xmlHeaderStartStringLength =
786
        FXML_SIZE(s_xmlHeaderStartString);
786
        FXML_SIZE(s_xmlHeaderStartString);
787
787
788
const XalanDOMChar  XalanXMLSerializerBase::UTF16::s_xmlHeaderEncodingString[] =
788
const XalanDOMChar  XalanXMLSerializerBase::UTF16::s_xmlHeaderEncodingString[] =
Lines 802-808 Link Here
802
    XalanDOMChar(0)
802
    XalanDOMChar(0)
803
};
803
};
804
804
805
const XalanDOMString::size_type     XalanXMLSerializerBase::UTF16::s_xmlHeaderEncodingStringLength =
805
const XalanXMLSerializerBase::size_type     XalanXMLSerializerBase::UTF16::s_xmlHeaderEncodingStringLength =
806
        FXML_SIZE(s_xmlHeaderEncodingString);
806
        FXML_SIZE(s_xmlHeaderEncodingString);
807
807
808
const XalanDOMChar  XalanXMLSerializerBase::UTF16::s_xmlHeaderStandaloneString[] =
808
const XalanDOMChar  XalanXMLSerializerBase::UTF16::s_xmlHeaderStandaloneString[] =
Lines 824-830 Link Here
824
    XalanDOMChar(0)
824
    XalanDOMChar(0)
825
};
825
};
826
826
827
const XalanDOMString::size_type     XalanXMLSerializerBase::UTF16::s_xmlHeaderStandaloneStringLength =
827
const XalanXMLSerializerBase::size_type     XalanXMLSerializerBase::UTF16::s_xmlHeaderStandaloneStringLength =
828
        FXML_SIZE(s_xmlHeaderStandaloneString);
828
        FXML_SIZE(s_xmlHeaderStandaloneString);
829
829
830
const XalanDOMChar  XalanXMLSerializerBase::UTF16::s_xmlHeaderEndString[] =
830
const XalanDOMChar  XalanXMLSerializerBase::UTF16::s_xmlHeaderEndString[] =
Lines 835-841 Link Here
835
    XalanDOMChar(0)
835
    XalanDOMChar(0)
836
};
836
};
837
837
838
const XalanDOMString::size_type     XalanXMLSerializerBase::UTF16::s_xmlHeaderEndStringLength =
838
const XalanXMLSerializerBase::size_type     XalanXMLSerializerBase::UTF16::s_xmlHeaderEndStringLength =
839
        FXML_SIZE(s_xmlHeaderEndString);
839
        FXML_SIZE(s_xmlHeaderEndString);
840
840
841
const XalanDOMChar  XalanXMLSerializerBase::UTF16::s_defaultVersionString[] =
841
const XalanDOMChar  XalanXMLSerializerBase::UTF16::s_defaultVersionString[] =
Lines 846-852 Link Here
846
    XalanDOMChar(0)
846
    XalanDOMChar(0)
847
};
847
};
848
848
849
const XalanDOMString::size_type     XalanXMLSerializerBase::UTF16::s_defaultVersionStringLength =
849
const XalanXMLSerializerBase::size_type     XalanXMLSerializerBase::UTF16::s_defaultVersionStringLength =
850
        FXML_SIZE(s_defaultVersionString);
850
        FXML_SIZE(s_defaultVersionString);
851
851
852
const XalanDOMChar  XalanXMLSerializerBase::UTF16::s_cdataOpenString[] =
852
const XalanDOMChar  XalanXMLSerializerBase::UTF16::s_cdataOpenString[] =
Lines 863-869 Link Here
863
    XalanDOMChar(0)
863
    XalanDOMChar(0)
864
};
864
};
865
865
866
const XalanDOMString::size_type     XalanXMLSerializerBase::UTF16::s_cdataOpenStringLength =
866
const XalanXMLSerializerBase::size_type     XalanXMLSerializerBase::UTF16::s_cdataOpenStringLength =
867
        FXML_SIZE(s_cdataOpenString);
867
        FXML_SIZE(s_cdataOpenString);
868
868
869
const XalanDOMChar  XalanXMLSerializerBase::UTF16::s_cdataCloseString[] =
869
const XalanDOMChar  XalanXMLSerializerBase::UTF16::s_cdataCloseString[] =
Lines 874-880 Link Here
874
    XalanDOMChar(0)
874
    XalanDOMChar(0)
875
};
875
};
876
876
877
const XalanDOMString::size_type     XalanXMLSerializerBase::UTF16::s_cdataCloseStringLength =
877
const XalanXMLSerializerBase::size_type     XalanXMLSerializerBase::UTF16::s_cdataCloseStringLength =
878
        FXML_SIZE(s_cdataCloseString);
878
        FXML_SIZE(s_cdataCloseString);
879
879
880
880
Lines 900-906 Link Here
900
    XalanDOMChar(0)
900
    XalanDOMChar(0)
901
};
901
};
902
902
903
const XalanDOMString::size_type     XalanXMLSerializerBase::UTF16::s_xhtmlDocTypeStringLength =
903
const XalanXMLSerializerBase::size_type     XalanXMLSerializerBase::UTF16::s_xhtmlDocTypeStringLength =
904
        FXML_SIZE(s_xhtmlDocTypeString);
904
        FXML_SIZE(s_xhtmlDocTypeString);
905
905
906
const XalanDOMChar  XalanXMLSerializerBase::UTF16::s_lessThanEntityString[] =
906
const XalanDOMChar  XalanXMLSerializerBase::UTF16::s_lessThanEntityString[] =
Lines 912-918 Link Here
912
    XalanDOMChar(0)
912
    XalanDOMChar(0)
913
};
913
};
914
914
915
const XalanDOMString::size_type     XalanXMLSerializerBase::UTF16::s_lessThanEntityStringLength =
915
const XalanXMLSerializerBase::size_type     XalanXMLSerializerBase::UTF16::s_lessThanEntityStringLength =
916
        FXML_SIZE(s_lessThanEntityString);
916
        FXML_SIZE(s_lessThanEntityString);
917
917
918
const XalanDOMChar  XalanXMLSerializerBase::UTF16::s_greaterThanEntityString[] =
918
const XalanDOMChar  XalanXMLSerializerBase::UTF16::s_greaterThanEntityString[] =
Lines 924-930 Link Here
924
    XalanDOMChar(0)
924
    XalanDOMChar(0)
925
};
925
};
926
926
927
const XalanDOMString::size_type     XalanXMLSerializerBase::UTF16::s_greaterThanEntityStringLength =
927
const XalanXMLSerializerBase::size_type     XalanXMLSerializerBase::UTF16::s_greaterThanEntityStringLength =
928
        FXML_SIZE(s_greaterThanEntityString);
928
        FXML_SIZE(s_greaterThanEntityString);
929
929
930
const XalanDOMChar  XalanXMLSerializerBase::UTF16::s_ampersandEntityString[] =
930
const XalanDOMChar  XalanXMLSerializerBase::UTF16::s_ampersandEntityString[] =
Lines 937-943 Link Here
937
    XalanDOMChar(0)
937
    XalanDOMChar(0)
938
};
938
};
939
939
940
const XalanDOMString::size_type     XalanXMLSerializerBase::UTF16::s_ampersandEntityStringLength =
940
const XalanXMLSerializerBase::size_type     XalanXMLSerializerBase::UTF16::s_ampersandEntityStringLength =
941
        FXML_SIZE(s_ampersandEntityString);
941
        FXML_SIZE(s_ampersandEntityString);
942
942
943
const XalanDOMChar  XalanXMLSerializerBase::UTF16::s_quoteEntityString[] =
943
const XalanDOMChar  XalanXMLSerializerBase::UTF16::s_quoteEntityString[] =
Lines 951-957 Link Here
951
    XalanDOMChar(0)
951
    XalanDOMChar(0)
952
};
952
};
953
953
954
const XalanDOMString::size_type     XalanXMLSerializerBase::UTF16::s_quoteEntityStringLength =
954
const XalanXMLSerializerBase::size_type     XalanXMLSerializerBase::UTF16::s_quoteEntityStringLength =
955
        FXML_SIZE(s_quoteEntityString);
955
        FXML_SIZE(s_quoteEntityString);
956
956
957
957
(-)src/xalanc/XMLSupport/FormatterToText.cpp (-4 / +4 lines)
Lines 187-193 Link Here
187
void
187
void
188
FormatterToText::characters(
188
FormatterToText::characters(
189
			const XMLCh* const	chars,
189
			const XMLCh* const	chars,
190
			const unsigned int	length)
190
			const size_type	    length)
191
{
191
{
192
	assert(m_writer != 0);
192
	assert(m_writer != 0);
193
193
Lines 245-251 Link Here
245
void
245
void
246
FormatterToText::charactersRaw(
246
FormatterToText::charactersRaw(
247
		const XMLCh* const	chars,
247
		const XMLCh* const	chars,
248
		const unsigned int	length)
248
		const size_type	    length)
249
{
249
{
250
	characters(chars, length);
250
	characters(chars, length);
251
}
251
}
Lines 262-268 Link Here
262
void
262
void
263
FormatterToText::ignorableWhitespace(
263
FormatterToText::ignorableWhitespace(
264
			const XMLCh* const	chars,
264
			const XMLCh* const	chars,
265
			const unsigned int	length)
265
			const size_type	    length)
266
{
266
{
267
	if (m_handleIgnorableWhitespace == true)
267
	if (m_handleIgnorableWhitespace == true)
268
	{
268
	{
Lines 301-307 Link Here
301
void
301
void
302
FormatterToText::cdata(
302
FormatterToText::cdata(
303
			const XMLCh* const	ch,
303
			const XMLCh* const	ch,
304
			const unsigned int 	length)
304
			const size_type 	length)
305
{
305
{
306
	characters(ch, length);
306
	characters(ch, length);
307
}
307
}
(-)src/xalanc/XMLSupport/XalanXMLSerializerBase.hpp (-69 / +69 lines)
Lines 122-133 Link Here
122
    virtual void
122
    virtual void
123
    characters(
123
    characters(
124
            const XMLCh* const  chars,
124
            const XMLCh* const  chars,
125
            const unsigned int  length);
125
            const size_type     length);
126
126
127
    virtual void
127
    virtual void
128
    charactersRaw(
128
    charactersRaw(
129
            const XMLCh* const  chars,
129
            const XMLCh* const  chars,
130
            const unsigned int  length) = 0;
130
            const size_type     length) = 0;
131
131
132
    virtual void
132
    virtual void
133
    entityReference(const XMLCh* const  name) = 0;
133
    entityReference(const XMLCh* const  name) = 0;
Lines 135-141 Link Here
135
    virtual void
135
    virtual void
136
    ignorableWhitespace(
136
    ignorableWhitespace(
137
            const XMLCh* const  chars,
137
            const XMLCh* const  chars,
138
            const unsigned int  length);
138
            const size_type     length);
139
139
140
    virtual void
140
    virtual void
141
    processingInstruction(
141
    processingInstruction(
Lines 151-157 Link Here
151
    virtual void
151
    virtual void
152
    cdata(
152
    cdata(
153
            const XMLCh* const  ch,
153
            const XMLCh* const  ch,
154
            const unsigned int  length);
154
            const size_type     length);
155
155
156
    virtual const XalanDOMString&
156
    virtual const XalanDOMString&
157
    getDoctypeSystem() const;
157
    getDoctypeSystem() const;
Lines 207-313 Link Here
207
        /**
207
        /**
208
         * The string "<!DOCTYPE ".
208
         * The string "<!DOCTYPE ".
209
         */
209
         */
210
        static const char                       s_doctypeHeaderStartString[];
210
        static const char           s_doctypeHeaderStartString[];
211
211
212
        static const XalanDOMString::size_type  s_doctypeHeaderStartStringLength;
212
        static const size_type      s_doctypeHeaderStartStringLength;
213
213
214
        /**
214
        /**
215
         * The string " PUBLIC \"".
215
         * The string " PUBLIC \"".
216
         */
216
         */
217
        static const char                       s_doctypeHeaderPublicString[];
217
        static const char       s_doctypeHeaderPublicString[];
218
218
219
        static const XalanDOMString::size_type  s_doctypeHeaderPublicStringLength;
219
        static const size_type  s_doctypeHeaderPublicStringLength;
220
220
221
        /**
221
        /**
222
         * The string " SYSTEM \"".
222
         * The string " SYSTEM \"".
223
         */
223
         */
224
        static const char                       s_doctypeHeaderSystemString[];
224
        static const char       s_doctypeHeaderSystemString[];
225
225
226
        static const XalanDOMString::size_type  s_doctypeHeaderSystemStringLength;
226
        static const size_type  s_doctypeHeaderSystemStringLength;
227
227
228
        /**
228
        /**
229
         * The string "<?xml version=\"".
229
         * The string "<?xml version=\"".
230
         */
230
         */
231
        static const char                       s_xmlHeaderStartString[];
231
        static const char       s_xmlHeaderStartString[];
232
232
233
        static const XalanDOMString::size_type  s_xmlHeaderStartStringLength;
233
        static const size_type  s_xmlHeaderStartStringLength;
234
234
235
        /**
235
        /**
236
         * The string "\" encoding=\"".
236
         * The string "\" encoding=\"".
237
         */
237
         */
238
        static const char                       s_xmlHeaderEncodingString[];
238
        static const char       s_xmlHeaderEncodingString[];
239
239
240
        static const XalanDOMString::size_type  s_xmlHeaderEncodingStringLength;
240
        static const size_type  s_xmlHeaderEncodingStringLength;
241
241
242
        /**
242
        /**
243
         * The string "\" standalone=\"".
243
         * The string "\" standalone=\"".
244
         */
244
         */
245
        static const char                       s_xmlHeaderStandaloneString[];
245
        static const char       s_xmlHeaderStandaloneString[];
246
246
247
        static const XalanDOMString::size_type  s_xmlHeaderStandaloneStringLength;
247
        static const size_type  s_xmlHeaderStandaloneStringLength;
248
248
249
        /**
249
        /**
250
         * The string "\"?>".
250
         * The string "\"?>".
251
         */
251
         */
252
        static const char                       s_xmlHeaderEndString[];
252
        static const char       s_xmlHeaderEndString[];
253
253
254
        static const XalanDOMString::size_type  s_xmlHeaderEndStringLength;
254
        static const size_type  s_xmlHeaderEndStringLength;
255
255
256
        /**
256
        /**
257
         * The string "1.0".
257
         * The string "1.0".
258
         */
258
         */
259
        static const char                       s_defaultVersionString[];
259
        static const char       s_defaultVersionString[];
260
260
261
        static const XalanDOMString::size_type  s_defaultVersionStringLength;
261
        static const size_type  s_defaultVersionStringLength;
262
262
263
        /**
263
        /**
264
         * The string "-//W3C//DTD XHTML".
264
         * The string "-//W3C//DTD XHTML".
265
         */
265
         */
266
        static const XalanDOMChar               s_xhtmlDocTypeString[];
266
        static const XalanDOMChar   s_xhtmlDocTypeString[];
267
267
268
        static const XalanDOMString::size_type  s_xhtmlDocTypeStringLength;
268
        static const size_type      s_xhtmlDocTypeStringLength;
269
269
270
        /**
270
        /**
271
         * The string "<![CDATA[".
271
         * The string "<![CDATA[".
272
         */
272
         */
273
        static const char                       s_cdataOpenString[];
273
        static const char       s_cdataOpenString[];
274
274
275
        static const XalanDOMString::size_type  s_cdataOpenStringLength;
275
        static const size_type  s_cdataOpenStringLength;
276
276
277
        /**
277
        /**
278
         * The string "]]>".
278
         * The string "]]>".
279
         */
279
         */
280
        static const char                       s_cdataCloseString[];
280
        static const char       s_cdataCloseString[];
281
281
282
        static const XalanDOMString::size_type  s_cdataCloseStringLength;
282
        static const size_type  s_cdataCloseStringLength;
283
283
284
        /**
284
        /**
285
         * The string "&lt;".
285
         * The string "&lt;".
286
         */
286
         */
287
        static const char                       s_lessThanEntityString[];
287
        static const char       s_lessThanEntityString[];
288
288
289
        static const XalanDOMString::size_type  s_lessThanEntityStringLength;
289
        static const size_type  s_lessThanEntityStringLength;
290
290
291
        /**
291
        /**
292
         * The string "&gt;".
292
         * The string "&gt;".
293
         */
293
         */
294
        static const char                       s_greaterThanEntityString[];
294
        static const char       s_greaterThanEntityString[];
295
295
296
        static const XalanDOMString::size_type  s_greaterThanEntityStringLength;
296
        static const size_type  s_greaterThanEntityStringLength;
297
297
298
        /**
298
        /**
299
         * The string "&amp;".
299
         * The string "&amp;".
300
         */
300
         */
301
        static const char                       s_ampersandEntityString[];
301
        static const char       s_ampersandEntityString[];
302
302
303
        static const XalanDOMString::size_type  s_ampersandEntityStringLength;
303
        static const size_type  s_ampersandEntityStringLength;
304
304
305
        /**
305
        /**
306
         * The string "&quot;".
306
         * The string "&quot;".
307
         */
307
         */
308
        static const char                       s_quoteEntityString[];
308
        static const char       s_quoteEntityString[];
309
309
310
        static const XalanDOMString::size_type  s_quoteEntityStringLength;
310
        static const size_type  s_quoteEntityStringLength;
311
    };
311
    };
312
312
313
    class XALAN_XMLSUPPORT_EXPORT UTF16
313
    class XALAN_XMLSUPPORT_EXPORT UTF16
Lines 322-428 Link Here
322
        /**
322
        /**
323
         * The string "<!DOCTYPE ".
323
         * The string "<!DOCTYPE ".
324
         */
324
         */
325
        static const XalanDOMChar               s_doctypeHeaderStartString[];
325
        static const XalanDOMChar   s_doctypeHeaderStartString[];
326
326
327
        static const XalanDOMString::size_type  s_doctypeHeaderStartStringLength;
327
        static const size_type      s_doctypeHeaderStartStringLength;
328
328
329
        /**
329
        /**
330
         * The string " PUBLIC \"".
330
         * The string " PUBLIC \"".
331
         */
331
         */
332
        static const XalanDOMChar               s_doctypeHeaderPublicString[];
332
        static const XalanDOMChar   s_doctypeHeaderPublicString[];
333
333
334
        static const XalanDOMString::size_type  s_doctypeHeaderPublicStringLength;
334
        static const size_type      s_doctypeHeaderPublicStringLength;
335
335
336
        /**
336
        /**
337
         * The string " SYSTEM \"".
337
         * The string " SYSTEM \"".
338
         */
338
         */
339
        static const XalanDOMChar               s_doctypeHeaderSystemString[];
339
        static const XalanDOMChar   s_doctypeHeaderSystemString[];
340
340
341
        static const XalanDOMString::size_type  s_doctypeHeaderSystemStringLength;
341
        static const size_type      s_doctypeHeaderSystemStringLength;
342
342
343
        /**
343
        /**
344
         * The string "<?xml version=\"".
344
         * The string "<?xml version=\"".
345
         */
345
         */
346
        static const XalanDOMChar               s_xmlHeaderStartString[];
346
        static const XalanDOMChar   s_xmlHeaderStartString[];
347
347
348
        static const XalanDOMString::size_type  s_xmlHeaderStartStringLength;
348
        static const size_type      s_xmlHeaderStartStringLength;
349
349
350
        /**
350
        /**
351
         * The string "\" encoding=\"".
351
         * The string "\" encoding=\"".
352
         */
352
         */
353
        static const XalanDOMChar               s_xmlHeaderEncodingString[];
353
        static const XalanDOMChar   s_xmlHeaderEncodingString[];
354
354
355
        static const XalanDOMString::size_type  s_xmlHeaderEncodingStringLength;
355
        static const size_type      s_xmlHeaderEncodingStringLength;
356
356
357
        /**
357
        /**
358
         * The string "\" standalone=\"".
358
         * The string "\" standalone=\"".
359
         */
359
         */
360
        static const XalanDOMChar               s_xmlHeaderStandaloneString[];
360
        static const XalanDOMChar   s_xmlHeaderStandaloneString[];
361
361
362
        static const XalanDOMString::size_type  s_xmlHeaderStandaloneStringLength;
362
        static const size_type      s_xmlHeaderStandaloneStringLength;
363
363
364
        /**
364
        /**
365
         * The string "\"?>".
365
         * The string "\"?>".
366
         */
366
         */
367
        static const XalanDOMChar               s_xmlHeaderEndString[];
367
        static const XalanDOMChar   s_xmlHeaderEndString[];
368
368
369
        static const XalanDOMString::size_type  s_xmlHeaderEndStringLength;
369
        static const size_type      s_xmlHeaderEndStringLength;
370
370
371
        /**
371
        /**
372
         * The string "1.0".
372
         * The string "1.0".
373
         */
373
         */
374
        static const XalanDOMChar               s_defaultVersionString[];
374
        static const XalanDOMChar   s_defaultVersionString[];
375
375
376
        static const XalanDOMString::size_type  s_defaultVersionStringLength;
376
        static const size_type      s_defaultVersionStringLength;
377
377
378
        /**
378
        /**
379
         * The string "-//W3C//DTD XHTML".
379
         * The string "-//W3C//DTD XHTML".
380
         */
380
         */
381
        static const XalanDOMChar               s_xhtmlDocTypeString[];
381
        static const XalanDOMChar   s_xhtmlDocTypeString[];
382
382
383
        static const XalanDOMString::size_type  s_xhtmlDocTypeStringLength;
383
        static const size_type      s_xhtmlDocTypeStringLength;
384
384
385
        /**
385
        /**
386
         * The string "<![CDATA[".
386
         * The string "<![CDATA[".
387
         */
387
         */
388
        static const XalanDOMChar               s_cdataOpenString[];
388
        static const XalanDOMChar   s_cdataOpenString[];
389
389
390
        static const XalanDOMString::size_type  s_cdataOpenStringLength;
390
        static const size_type      s_cdataOpenStringLength;
391
391
392
        /**
392
        /**
393
         * The string "]]>".
393
         * The string "]]>".
394
         */
394
         */
395
        static const XalanDOMChar               s_cdataCloseString[];
395
        static const XalanDOMChar   s_cdataCloseString[];
396
396
397
        static const XalanDOMString::size_type  s_cdataCloseStringLength;
397
        static const size_type      s_cdataCloseStringLength;
398
398
399
        /**
399
        /**
400
         * The string "&lt;".
400
         * The string "&lt;".
401
         */
401
         */
402
        static const XalanDOMChar               s_lessThanEntityString[];
402
        static const XalanDOMChar   s_lessThanEntityString[];
403
403
404
        static const XalanDOMString::size_type  s_lessThanEntityStringLength;
404
        static const size_type      s_lessThanEntityStringLength;
405
405
406
        /**
406
        /**
407
         * The string "&gt;".
407
         * The string "&gt;".
408
         */
408
         */
409
        static const XalanDOMChar               s_greaterThanEntityString[];
409
        static const XalanDOMChar   s_greaterThanEntityString[];
410
410
411
        static const XalanDOMString::size_type  s_greaterThanEntityStringLength;
411
        static const size_type      s_greaterThanEntityStringLength;
412
412
413
        /**
413
        /**
414
         * The string "&amp;".
414
         * The string "&amp;".
415
         */
415
         */
416
        static const XalanDOMChar               s_ampersandEntityString[];
416
        static const XalanDOMChar   s_ampersandEntityString[];
417
417
418
        static const XalanDOMString::size_type  s_ampersandEntityStringLength;
418
        static const size_type      s_ampersandEntityStringLength;
419
419
420
        /**
420
        /**
421
         * The string "&quot;".
421
         * The string "&quot;".
422
         */
422
         */
423
        static const XalanDOMChar               s_quoteEntityString[];
423
        static const XalanDOMChar   s_quoteEntityString[];
424
424
425
        static const XalanDOMString::size_type  s_quoteEntityStringLength;
425
        static const size_type      s_quoteEntityStringLength;
426
    };
426
    };
427
427
428
    enum
428
    enum
Lines 569-580 Link Here
569
    virtual void
569
    virtual void
570
    writeCharacters(
570
    writeCharacters(
571
            const XMLCh*    chars,
571
            const XMLCh*    chars,
572
            unsigned int    length) = 0;
572
            size_type       length) = 0;
573
573
574
    virtual void
574
    virtual void
575
    writeCDATA(
575
    writeCDATA(
576
            const XMLCh*    chars,
576
            const XMLCh*    chars,
577
            unsigned int    length) = 0;
577
            size_type       length) = 0;
578
578
579
    virtual void
579
    virtual void
580
    outputNewline() = 0;
580
    outputNewline() = 0;
Lines 692-698 Link Here
692
     */
692
     */
693
    const XalanDOMString    m_standalone;
693
    const XalanDOMString    m_standalone;
694
694
695
    const XalanDOMString  m_encoding;
695
    const XalanDOMString    m_encoding;
696
696
697
    static bool
697
    static bool
698
    isUTF16HighSurrogate(XalanDOMChar   theChar)
698
    isUTF16HighSurrogate(XalanDOMChar   theChar)
Lines 790-798 Link Here
790
    /**
790
    /**
791
     * The string "-//W3C//DTD XHTML".
791
     * The string "-//W3C//DTD XHTML".
792
     */
792
     */
793
    static const XalanDOMChar               s_xhtmlDocTypeString[];
793
    static const XalanDOMChar   s_xhtmlDocTypeString[];
794
794
795
    static const XalanDOMString::size_type  s_xhtmlDocTypeStringLength;
795
    static const size_type      s_xhtmlDocTypeStringLength;
796
};
796
};
797
797
798
798
(-)src/xalanc/XMLSupport/FormatterToText.hpp (-4 / +4 lines)
Lines 187-198 Link Here
187
    virtual void
187
    virtual void
188
	characters(
188
	characters(
189
			const XMLCh* const	chars,
189
			const XMLCh* const	chars,
190
			const unsigned int	length);
190
			const size_type	    length);
191
191
192
    virtual void
192
    virtual void
193
	charactersRaw(
193
	charactersRaw(
194
			const XMLCh* const	chars,
194
			const XMLCh* const	chars,
195
			const unsigned int	length);
195
			const size_type	    length);
196
196
197
	virtual void
197
	virtual void
198
	entityReference(const XMLCh* const	name);
198
	entityReference(const XMLCh* const	name);
Lines 200-206 Link Here
200
	virtual void
200
	virtual void
201
	ignorableWhitespace(
201
	ignorableWhitespace(
202
			const XMLCh* const	chars,
202
			const XMLCh* const	chars,
203
			const unsigned int	length);
203
			const size_type	    length);
204
204
205
	virtual void
205
	virtual void
206
	processingInstruction(
206
	processingInstruction(
Lines 216-222 Link Here
216
	virtual void
216
	virtual void
217
	cdata(
217
	cdata(
218
			const XMLCh* const	ch,
218
			const XMLCh* const	ch,
219
			const unsigned int 	length);
219
			const size_type 	length);
220
220
221
private:
221
private:
222
222
(-)src/xalanc/XMLSupport/FormatterToXML.cpp (-43 / +43 lines)
Lines 695-707 Link Here
695
695
696
void
696
void
697
FormatterToXML::accumNameArray(
697
FormatterToXML::accumNameArray(
698
            const XalanDOMChar          chars[],
698
            const XalanDOMChar  chars[],
699
            XalanDOMString::size_type   start,
699
            size_type           start,
700
            XalanDOMString::size_type   length)
700
            size_type           length)
701
{
701
{
702
    const XalanDOMString::size_type     n = start + length;
702
    const size_type     n = start + length;
703
703
704
    for(XalanDOMString::size_type i = start; i < n; ++i)
704
    for(size_type i = start; i < n; ++i)
705
    {
705
    {
706
        accumName(chars[i]);
706
        accumName(chars[i]);
707
    }
707
    }
Lines 711-723 Link Here
711
711
712
void
712
void
713
FormatterToXML::accumContentArray(
713
FormatterToXML::accumContentArray(
714
            const XalanDOMChar          chars[],
714
            const XalanDOMChar  chars[],
715
            XalanDOMString::size_type   start,
715
            size_type           start,
716
            XalanDOMString::size_type   length)
716
            size_type           length)
717
{
717
{
718
    const XalanDOMString::size_type     n = start + length;
718
    const size_type     n = start + length;
719
719
720
    for(XalanDOMString::size_type i = start; i < n; ++i)
720
    for(size_type i = start; i < n; ++i)
721
    {
721
    {
722
        accumContent(chars[i]);
722
        accumContent(chars[i]);
723
    }
723
    }
Lines 727-739 Link Here
727
727
728
void
728
void
729
FormatterToXML::accumArrayUTF(
729
FormatterToXML::accumArrayUTF(
730
            const XalanDOMChar          chars[],
730
            const XalanDOMChar  chars[],
731
            XalanDOMString::size_type   start,
731
            size_type           start,
732
            XalanDOMString::size_type   length)
732
            size_type           length)
733
{
733
{
734
    const XalanDOMString::size_type     n = start + length;
734
    const size_type     n = start + length;
735
735
736
    for(XalanDOMString::size_type i = start; i < n; ++i)
736
    for(size_type i = start; i < n; ++i)
737
    {
737
    {
738
        accumCharUTF(chars[i]);
738
        accumCharUTF(chars[i]);
739
    }
739
    }
Lines 743-751 Link Here
743
743
744
void
744
void
745
FormatterToXML::accumArrayUTFDirect(
745
FormatterToXML::accumArrayUTFDirect(
746
            const XalanDOMChar          chars[],
746
            const XalanDOMChar  chars[],
747
            XalanDOMString::size_type   start,
747
            size_type           start,
748
            XalanDOMString::size_type   length)
748
            size_type           length)
749
{
749
{
750
    assert(m_maxCharacter >= 65535);
750
    assert(m_maxCharacter >= 65535);
751
    assert(m_stream != 0);
751
    assert(m_stream != 0);
Lines 854-866 Link Here
854
854
855
855
856
856
857
XalanDOMString::size_type
857
FormatterToXML::size_type
858
FormatterToXML::accumDefaultEscape(
858
FormatterToXML::accumDefaultEscape(
859
            XalanDOMChar                ch,
859
            XalanDOMChar        ch,
860
            XalanDOMString::size_type   i,
860
            size_type           i,
861
            const XalanDOMChar          chars[],
861
            const XalanDOMChar  chars[],
862
            XalanDOMString::size_type   len,
862
            size_type           len,
863
            bool                        escLF)
863
            bool                escLF)
864
{
864
{
865
    if(!accumDefaultEntity(ch, escLF))
865
    if(!accumDefaultEntity(ch, escLF))
866
    {
866
    {
Lines 1258-1264 Link Here
1258
void
1258
void
1259
FormatterToXML::characters(
1259
FormatterToXML::characters(
1260
            const XMLCh* const  chars,
1260
            const XMLCh* const  chars,
1261
            const unsigned int  length)
1261
            const size_type     length)
1262
{
1262
{
1263
    if(length != 0)
1263
    if(length != 0)
1264
    {
1264
    {
Lines 1278-1285 Link Here
1278
1278
1279
            m_ispreserve = true;
1279
            m_ispreserve = true;
1280
1280
1281
            unsigned int    i = 0;
1281
            size_type    i = 0;
1282
            unsigned int    firstIndex = 0;
1282
            size_type   firstIndex = 0;
1283
1283
1284
            while(i < length) 
1284
            while(i < length) 
1285
            {
1285
            {
Lines 1318-1324 Link Here
1318
void
1318
void
1319
FormatterToXML::charactersRaw(
1319
FormatterToXML::charactersRaw(
1320
        const XMLCh* const  chars,
1320
        const XMLCh* const  chars,
1321
        const unsigned int  length)
1321
        const size_type     length)
1322
{
1322
{
1323
    writeParentTagEnd();
1323
    writeParentTagEnd();
1324
1324
Lines 1378-1390 Link Here
1378
1378
1379
void
1379
void
1380
FormatterToXML::writeAttrString(
1380
FormatterToXML::writeAttrString(
1381
            const XalanDOMChar*         theString,
1381
            const XalanDOMChar*     theString,
1382
            XalanDOMString::size_type   theStringLength)
1382
            size_type               theStringLength)
1383
{
1383
{
1384
    assert(theString != 0);
1384
    assert(theString != 0);
1385
1385
1386
    XalanDOMString::size_type   i = 0;
1386
    size_type   i = 0;
1387
    XalanDOMString::size_type   firstIndex = 0;
1387
    size_type   firstIndex = 0;
1388
1388
1389
    while(i < theStringLength)
1389
    while(i < theStringLength)
1390
    {
1390
    {
Lines 1423-1436 Link Here
1423
1423
1424
void
1424
void
1425
FormatterToXML::writeNormalizedChars(
1425
FormatterToXML::writeNormalizedChars(
1426
            const XalanDOMChar          ch[],
1426
            const XalanDOMChar  ch[],
1427
            XalanDOMString::size_type   start,
1427
            size_type           start,
1428
            XalanDOMString::size_type   length,
1428
            size_type           length,
1429
            bool                        isCData)
1429
            bool                isCData)
1430
{
1430
{
1431
    XalanDOMString::size_type   end = start + length;
1431
    size_type   end = start + length;
1432
1432
1433
    for(XalanDOMString::size_type i = start; i < end; i++)
1433
    for(size_type i = start; i < end; ++i)
1434
    {
1434
    {
1435
        const XalanDOMChar  c = ch[i];
1435
        const XalanDOMChar  c = ch[i];
1436
1436
Lines 1595-1601 Link Here
1595
void
1595
void
1596
FormatterToXML::ignorableWhitespace(
1596
FormatterToXML::ignorableWhitespace(
1597
            const XMLCh* const  chars,
1597
            const XMLCh* const  chars,
1598
            const unsigned int  length)
1598
            const size_type     length)
1599
{
1599
{
1600
#if 1
1600
#if 1
1601
    // We need to do normalization, which is slower,
1601
    // We need to do normalization, which is slower,
Lines 1678-1684 Link Here
1678
void
1678
void
1679
FormatterToXML::cdata(
1679
FormatterToXML::cdata(
1680
            const XMLCh* const  ch,
1680
            const XMLCh* const  ch,
1681
            const unsigned int  length)
1681
            const size_type     length)
1682
{
1682
{
1683
    if(m_nextIsRaw == true)
1683
    if(m_nextIsRaw == true)
1684
    {
1684
    {
Lines 1839-1848 Link Here
1839
1839
1840
void
1840
void
1841
FormatterToXML::accumNormalizedPIData(
1841
FormatterToXML::accumNormalizedPIData(
1842
            const XalanDOMChar*         theData,
1842
            const XalanDOMChar*     theData,
1843
            XalanDOMString::size_type   theLength)
1843
            size_type               theLength)
1844
{
1844
{
1845
    for (XalanDOMString::size_type i = 0; i < theLength; ++i)
1845
    for (size_type i = 0; i < theLength; ++i)
1846
    {
1846
    {
1847
        accumContent(theData[i]);
1847
        accumContent(theData[i]);
1848
    }
1848
    }
(-)src/xalanc/XMLSupport/XalanUTF16Writer.hpp (-13 / +19 lines)
Lines 56-65 Link Here
56
56
57
    size_type
57
    size_type
58
    writeCDATAChar(
58
    writeCDATAChar(
59
                const XalanDOMChar  chars[],
59
            const XalanDOMChar  chars[],
60
                size_type           start,
60
            size_type           start,
61
                size_type           /*length*/,
61
            size_type           /*length*/,
62
                bool&               /* outsideCDATA */)
62
            bool&               /* outsideCDATA */)
63
    {
63
    {
64
        assert( chars != 0 );
64
        assert( chars != 0 );
65
65
Lines 69-96 Link Here
69
    }
69
    }
70
70
71
    /**
71
    /**
72
     * Writes name chars , if not presentable, throws 
72
     * Writes name chars, if not representable, throws 
73
     */
73
     */
74
    void writeNameChar(const XalanDOMChar*            data,
74
    void
75
                       size_type                theLength)
75
    writeNameChar(
76
            const XalanDOMChar*     data,
77
            size_type               theLength)
76
    {
78
    {
77
        write(data, theLength);
79
        write(data, theLength);
78
    }
80
    }
79
81
80
    /**
82
    /**
81
     * Writes name chars , if not presentable, throws 
83
     * Writes name chars, if not representable, throws 
82
     */
84
     */
83
    void writePIChars(const XalanDOMChar*       data,
85
    void
84
                        size_type               theLength)
86
    writePIChars(
87
            const XalanDOMChar*     data,
88
            size_type               theLength)
85
    {
89
    {
86
        write(data, theLength);
90
        write(data, theLength);
87
    }
91
    }
88
92
89
    /**
93
    /**
90
     * Writes name chars , if not presentable, throws 
94
     * Writes name chars, if not representable, throws 
91
     */
95
     */
92
    void writeCommentChars(const XalanDOMChar*      data,
96
    void
93
                           size_type                theLength)
97
    writeCommentChars(
98
            const XalanDOMChar*      data,
99
            size_type                theLength)
94
    {
100
    {
95
        write(data, theLength);
101
        write(data, theLength);
96
    }
102
    }
(-)src/xalanc/XMLSupport/FormatterToXML.hpp (-39 / +39 lines)
Lines 146-157 Link Here
146
    virtual void
146
    virtual void
147
    characters(
147
    characters(
148
            const XMLCh* const  chars,
148
            const XMLCh* const  chars,
149
            const unsigned int  length);
149
            const size_type     length);
150
150
151
    virtual void
151
    virtual void
152
    charactersRaw(
152
    charactersRaw(
153
            const XMLCh* const  chars,
153
            const XMLCh* const  chars,
154
            const unsigned int  length);
154
            const size_type     length);
155
155
156
    virtual void
156
    virtual void
157
    entityReference(const XMLCh* const  name);
157
    entityReference(const XMLCh* const  name);
Lines 159-165 Link Here
159
    virtual void
159
    virtual void
160
    ignorableWhitespace(
160
    ignorableWhitespace(
161
            const XMLCh* const  chars,
161
            const XMLCh* const  chars,
162
            const unsigned int  length);
162
            const size_type     length);
163
163
164
    virtual void
164
    virtual void
165
    processingInstruction(
165
    processingInstruction(
Lines 176-182 Link Here
176
    virtual void
176
    virtual void
177
    cdata(
177
    cdata(
178
            const XMLCh* const  ch,
178
            const XMLCh* const  ch,
179
            const unsigned int  length);
179
            const size_type     length);
180
180
181
    virtual Writer*
181
    virtual Writer*
182
    getWriter() const;
182
    getWriter() const;
Lines 294-301 Link Here
294
294
295
    typedef void (FormatterToXML::*AccumArrayFunctionType)(
295
    typedef void (FormatterToXML::*AccumArrayFunctionType)(
296
                        const XalanDOMChar[],
296
                        const XalanDOMChar[],
297
                        XalanDOMString::size_type,
297
                        size_type,
298
                        XalanDOMString::size_type);
298
                        size_type);
299
299
300
    typedef void (FormatterToXML::*FlushFunctionType)();
300
    typedef void (FormatterToXML::*FlushFunctionType)();
301
301
Lines 374-382 Link Here
374
     */
374
     */
375
    void
375
    void
376
    accumName(
376
    accumName(
377
            const XalanDOMChar          chars[],
377
            const XalanDOMChar  chars[],
378
            XalanDOMString::size_type   start,
378
            size_type           start,
379
            XalanDOMString::size_type   length)
379
            size_type           length)
380
    {
380
    {
381
        assert(m_accumNameArrayFunction != 0);
381
        assert(m_accumNameArrayFunction != 0);
382
382
Lines 392-400 Link Here
392
     */
392
     */
393
    void
393
    void
394
    accumContent(
394
    accumContent(
395
            const XalanDOMChar          chars[],
395
            const XalanDOMChar  chars[],
396
            XalanDOMString::size_type   start,
396
            size_type           start,
397
            XalanDOMString::size_type   length)
397
            size_type           length)
398
    {
398
    {
399
        assert(m_accumContentArrayFunction != 0);
399
        assert(m_accumContentArrayFunction != 0);
400
400
Lines 434-446 Link Here
434
    /**
434
    /**
435
     * Escape and accum a character.
435
     * Escape and accum a character.
436
     */
436
     */
437
    XalanDOMString::size_type
437
    size_type
438
    accumDefaultEscape(
438
    accumDefaultEscape(
439
            XalanDOMChar                ch,
439
            XalanDOMChar        ch,
440
            XalanDOMString::size_type   i,
440
            size_type           i,
441
            const XalanDOMChar          chars[],
441
            const XalanDOMChar  chars[],
442
            XalanDOMString::size_type   len,
442
            size_type           len,
443
            bool                        escLF);
443
            bool                escLF);
444
444
445
    /**
445
    /**
446
     * Handle one of the default entities, return false if it 
446
     * Handle one of the default entities, return false if it 
Lines 513-522 Link Here
513
     */
513
     */
514
    virtual void
514
    virtual void
515
    writeNormalizedChars(
515
    writeNormalizedChars(
516
            const XalanDOMChar          ch[],
516
            const XalanDOMChar  ch[],
517
            XalanDOMString::size_type   start,
517
            size_type           start,
518
            XalanDOMString::size_type   length,
518
            size_type           length,
519
            bool                        isCData);
519
            bool                isCData);
520
520
521
    /**
521
    /**
522
     * Write a number into the buffer as an entity
522
     * Write a number into the buffer as an entity
Lines 534-541 Link Here
534
     */
534
     */
535
    virtual void
535
    virtual void
536
    writeAttrString(
536
    writeAttrString(
537
            const XalanDOMChar*         theString,
537
            const XalanDOMChar*     theString,
538
            XalanDOMString::size_type   theStringLength);
538
            size_type               theStringLength);
539
539
540
    /**
540
    /**
541
     * Write the data for a comment
541
     * Write the data for a comment
Lines 853-861 Link Here
853
     */
853
     */
854
    void
854
    void
855
    accumNameArray(
855
    accumNameArray(
856
            const XalanDOMChar          chars[],
856
            const XalanDOMChar  chars[],
857
            XalanDOMString::size_type   start,
857
            size_type           start,
858
            XalanDOMString::size_type   length);
858
            size_type           length);
859
859
860
    /**
860
    /**
861
     * Append an array of wide character to the buffer.
861
     * Append an array of wide character to the buffer.
Lines 868-876 Link Here
868
     */
868
     */
869
    void
869
    void
870
    accumContentArray(
870
    accumContentArray(
871
            const XalanDOMChar          chars[],
871
            const XalanDOMChar  chars[],
872
            XalanDOMString::size_type   start,
872
            size_type           start,
873
            XalanDOMString::size_type   length);
873
            size_type           length);
874
874
875
    /**
875
    /**
876
     * Append an array of wide character to the buffer.
876
     * Append an array of wide character to the buffer.
Lines 883-891 Link Here
883
     */
883
     */
884
    void
884
    void
885
    accumArrayUTF(
885
    accumArrayUTF(
886
            const XalanDOMChar          chars[],
886
            const XalanDOMChar  chars[],
887
            XalanDOMString::size_type   start,
887
            size_type           start,
888
            XalanDOMString::size_type   length);
888
            size_type           length);
889
889
890
    /**
890
    /**
891
     * Append an array of wide character to the output.
891
     * Append an array of wide character to the output.
Lines 898-906 Link Here
898
     */
898
     */
899
    void
899
    void
900
    accumArrayUTFDirect(
900
    accumArrayUTFDirect(
901
            const XalanDOMChar          chars[],
901
            const XalanDOMChar  chars[],
902
            XalanDOMString::size_type   start,
902
            size_type           start,
903
            XalanDOMString::size_type   length);
903
            size_type           length);
904
904
905
    /**
905
    /**
906
     * Append a string to the buffer.
906
     * Append a string to the buffer.
Lines 974-981 Link Here
974
     */
974
     */
975
    void
975
    void
976
    accumNormalizedPIData(
976
    accumNormalizedPIData(
977
            const XalanDOMChar*         theData,
977
            const XalanDOMChar*     theData,
978
            XalanDOMString::size_type   theLength);
978
            size_type               theLength);
979
979
980
980
981
    // Data members...
981
    // Data members...
Lines 1018-1024 Link Here
1018
     */
1018
     */
1019
    const XalanDOMString    m_attrSpecialChars;
1019
    const XalanDOMString    m_attrSpecialChars;
1020
1020
1021
    typedef XalanDOMString::size_type   size_type;
1021
    //typedef XalanDOMString::size_type   size_type;
1022
1022
1023
    /**
1023
    /**
1024
     * The string "<!DOCTYPE ".
1024
     * The string "<!DOCTYPE ".
(-)src/xalanc/Utils/MsgCreator/NLSHandler.hpp (-1 / +10 lines)
Lines 20-27 Link Here
20
#include "ICUResHandler.hpp"
20
#include "ICUResHandler.hpp"
21
21
22
22
23
24
XALAN_CPP_NAMESPACE_BEGIN
25
26
27
23
XERCES_CPP_NAMESPACE_USE
28
XERCES_CPP_NAMESPACE_USE
24
29
30
31
25
class NLSHandler : public ICUResHandler 
32
class NLSHandler : public ICUResHandler 
26
{
33
{
27
public:
34
public:
Lines 72-77 Link Here
72
79
73
80
74
81
75
#endif  //NLSHANDLER_MSGCREATOR_1357924680
82
XALAN_CPP_NAMESPACE_END
76
83
77
84
85
86
#endif  //NLSHANDLER_MSGCREATOR_1357924680
(-)src/xalanc/Utils/MsgCreator/InMemHandler.cpp (-7 / +16 lines)
Lines 26-31 Link Here
26
#include "InMemData.hpp"
26
#include "InMemData.hpp"
27
27
28
28
29
30
XALAN_CPP_NAMESPACE_BEGIN
31
32
33
29
// -----------------------------------------------------------------------
34
// -----------------------------------------------------------------------
30
//  Constructors
35
//  Constructors
31
// -----------------------------------------------------------------------
36
// -----------------------------------------------------------------------
Lines 68-74 Link Here
68
73
69
74
70
void InMemHandler::characters(	const   XMLCh* const    chars
75
void InMemHandler::characters(	const   XMLCh* const    chars
71
						, const unsigned int    length)
76
						, const XalanSize_t    length)
72
{
77
{
73
78
74
	if ( m_startCollectingCharacters == true )
79
	if ( m_startCollectingCharacters == true )
Lines 99-113 Link Here
99
104
100
}
105
}
101
106
102
void InMemHandler::endElement(const XMLCh* const ,
107
void InMemHandler::endElement(const XMLCh* const /* uri */,
103
					const XMLCh* const localname,
108
					const XMLCh* const /* localname */,
104
					const XMLCh* const )
109
					const XMLCh* const qname)
105
{
110
{
106
	if ( m_startCollectingCharacters == false)
111
	if ( m_startCollectingCharacters == false)
107
		return;
112
		return;
108
113
109
114
110
	if(!XMLString::compareString(localname,s_targetXMLCh))
115
	if(!XMLString::compareString(qname,s_targetXMLCh))
111
	{
116
	{
112
		m_startCollectingCharacters = false;
117
		m_startCollectingCharacters = false;
113
118
Lines 121-133 Link Here
121
								const   Attributes&		attributes)
126
								const   Attributes&		attributes)
122
{
127
{
123
	
128
	
124
	if(!XMLString::compareString(localname,s_transUnitXMLCh))
129
	if(!XMLString::compareString(qname,s_transUnitXMLCh))
125
	{
130
	{
126
		// this is an elemente, SAX2Handler class is responsible to handle:
131
		// this is an elemente, SAX2Handler class is responsible to handle:
127
		// creating Index file, commom for all localization styles
132
		// creating Index file, commom for all localization styles
128
		SAX2Handler::startElement(uri, localname, qname, attributes);
133
		SAX2Handler::startElement(uri, localname, qname, attributes);
129
	}
134
	}
130
	else if(!XMLString::compareString(localname,s_targetXMLCh))
135
	else if(!XMLString::compareString(qname,s_targetXMLCh))
131
	{
136
	{
132
137
133
		
138
		
Lines 203-205 Link Here
203
	printToDataFile( szEndDataFile );	
208
	printToDataFile( szEndDataFile );	
204
209
205
}
210
}
211
212
213
214
XALAN_CPP_NAMESPACE_END
(-)src/xalanc/Utils/MsgCreator/MsgCreator.cpp (-1 / +3 lines)
Lines 263-269 Link Here
263
	_CrtSetReportMode(_CRT_WARN, _CRTDBG_MODE_FILE);
263
	_CrtSetReportMode(_CRT_WARN, _CRTDBG_MODE_FILE);
264
	_CrtSetReportFile(_CRT_WARN, _CRTDBG_FILE_STDERR);
264
	_CrtSetReportFile(_CRT_WARN, _CRTDBG_FILE_STDERR);
265
#endif
265
#endif
266
    
266
267
    XALAN_CPP_NAMESPACE_USE
268
267
	CmdLineParams	theParams;
269
	CmdLineParams	theParams;
268
270
269
	int iReturnValue = 0;
271
	int iReturnValue = 0;
(-)src/xalanc/Utils/MsgCreator/InMemHandler.hpp (-1 / +13 lines)
Lines 20-27 Link Here
20
#include "SAX2Handler.hpp"
20
#include "SAX2Handler.hpp"
21
21
22
22
23
24
XALAN_CPP_NAMESPACE_BEGIN
25
26
27
23
XERCES_CPP_NAMESPACE_USE
28
XERCES_CPP_NAMESPACE_USE
24
29
30
25
class InMemHandler : public SAX2Handler
31
class InMemHandler : public SAX2Handler
26
{
32
{
27
public:
33
public:
Lines 54-60 Link Here
54
60
55
	virtual void 
61
	virtual void 
56
	characters(	const   XMLCh* const    chars
62
	characters(	const   XMLCh* const    chars
57
						, const unsigned int    length);
63
						, const XalanSize_t    length);
58
64
59
65
60
66
Lines 96-99 Link Here
96
102
97
};
103
};
98
104
105
106
107
XALAN_CPP_NAMESPACE_END
108
109
110
99
#endif /// INMEMHANDLER_MSGCREATOR_1357924680
111
#endif /// INMEMHANDLER_MSGCREATOR_1357924680
(-)src/xalanc/Utils/MsgCreator/SAX2Handler.cpp (-5 / +8 lines)
Lines 29-39 Link Here
29
#include "MsgCreator.hpp"
29
#include "MsgCreator.hpp"
30
30
31
31
32
XALAN_CPP_NAMESPACE_BEGIN
32
33
34
33
static const char* INDEX_FILE_NAME="LocalMsgIndex.hpp";
35
static const char* INDEX_FILE_NAME="LocalMsgIndex.hpp";
34
36
35
37
36
37
// ---------------------------------------------------------------------------
38
// ---------------------------------------------------------------------------
38
//  SAX2Handler: Constructors and Destructor
39
//  SAX2Handler: Constructors and Destructor
39
// ---------------------------------------------------------------------------
40
// ---------------------------------------------------------------------------
Lines 92-103 Link Here
92
93
93
94
94
95
95
void SAX2Handler::startElement(const   XMLCh* const    ,
96
void SAX2Handler::startElement(const   XMLCh* const    /* uri */,
96
									const   XMLCh* const    localname,
97
									const   XMLCh* const    /* localname */,
97
									const   XMLCh* const    ,
98
									const   XMLCh* const    qname,
98
                                    const   Attributes&		attributes)
99
                                    const   Attributes&		attributes)
99
{
100
{
100
	if(!XMLString::compareString(localname,s_transUnitXMLCh))
101
	if(!XMLString::compareString(qname,s_transUnitXMLCh))
101
	{
102
	{
102
		unsigned int len = attributes.getLength();
103
		unsigned int len = attributes.getLength();
103
		
104
		
Lines 192-194 Link Here
192
}
193
}
193
194
194
195
196
197
XALAN_CPP_NAMESPACE_END
(-)src/xalanc/Utils/MsgCreator/SAX2Handler.hpp (-1 / +8 lines)
Lines 23-28 Link Here
23
#include <xercesc/util/XMLUniDefs.hpp>
23
#include <xercesc/util/XMLUniDefs.hpp>
24
24
25
25
26
XALAN_CPP_NAMESPACE_BEGIN
27
28
29
26
XERCES_CPP_NAMESPACE_USE
30
XERCES_CPP_NAMESPACE_USE
27
31
28
32
Lines 210-215 Link Here
210
};
214
};
211
215
212
216
213
#endif //SAX2HANDLER_MSGCREATOR_1357924680
214
217
218
XALAN_CPP_NAMESPACE_END
215
219
220
221
222
#endif //SAX2HANDLER_MSGCREATOR_1357924680
(-)src/xalanc/Utils/MsgCreator/MsgFileOutputStream.cpp (-5 / +12 lines)
Lines 24-29 Link Here
24
#include <cstdio>
24
#include <cstdio>
25
25
26
26
27
XALAN_CPP_NAMESPACE_BEGIN
28
29
27
static  XalanFileOutputStream::HandleType
30
static  XalanFileOutputStream::HandleType
28
openFile(const char*	theFileName)
31
openFile(const char*	theFileName)
29
{
32
{
Lines 105-111 Link Here
105
void
108
void
106
XalanFileOutputStream::writeData(
109
XalanFileOutputStream::writeData(
107
			const char*		theBuffer,
110
			const char*		theBuffer,
108
			unsigned int		theBufferLength)
111
			XalanSize_t		theBufferLength)
109
{
112
{
110
#if defined(WIN32)
113
#if defined(WIN32)
111
	DWORD			theBytesWritten;
114
	DWORD			theBytesWritten;
Lines 204-216 Link Here
204
}
207
}
205
208
206
209
207
void 	XalanFileOutputStream::write(const UTF16Ch*	theString, unsigned int		theLength)
210
void 	XalanFileOutputStream::write(const UTF16Ch*	theString, XalanSize_t		theLength)
208
{
211
{
209
	assert ( theString != 0 );
212
	assert ( theString != 0 );
210
	writeData((const char*)theString,theLength * sizeof(UTF16Ch) );
213
	writeData((const char*)theString,theLength * sizeof(UTF16Ch) );
211
}
214
}
212
215
213
void 	XalanFileOutputStream::write(const char*	theString, unsigned int		theLength)
216
void 	XalanFileOutputStream::write(const char*	theString, XalanSize_t		theLength)
214
{
217
{
215
	assert ( theString != 0 );
218
	assert ( theString != 0 );
216
219
Lines 221-227 Link Here
221
	XMLString::release(&theUTFString);
224
	XMLString::release(&theUTFString);
222
}
225
}
223
226
224
void XalanFileOutputStream::writeAsASCII(const UTF16Ch*	theString, unsigned int		theLengts)
227
void XalanFileOutputStream::writeAsASCII(const UTF16Ch*	theString, XalanSize_t		theLengts)
225
{
228
{
226
	char* szString = XMLString::transcode(theString);
229
	char* szString = XMLString::transcode(theString);
227
	writeData( szString, theLengts );
230
	writeData( szString, theLengts );
Lines 229-235 Link Here
229
232
230
}
233
}
231
234
232
void XalanFileOutputStream::writeAsASCII(const char*	theString, unsigned int		theLengts)
235
void XalanFileOutputStream::writeAsASCII(const char*	theString, XalanSize_t		theLengts)
233
{
236
{
234
	writeData( theString, theLengts );
237
	writeData( theString, theLengts );
235
}
238
}
Lines 244-246 Link Here
244
{
247
{
245
	write(s_UTF16ByteOrderMark,1);
248
	write(s_UTF16ByteOrderMark,1);
246
}
249
}
250
251
252
253
XALAN_CPP_NAMESPACE_END
(-)src/xalanc/Utils/MsgCreator/MsgFileOutputStream.hpp (-7 / +10 lines)
Lines 20-25 Link Here
20
#define XALANOUTPUTFILE_1357924680
20
#define XALANOUTPUTFILE_1357924680
21
21
22
#include <xercesc/util/XMLUniDefs.hpp>
22
#include <xercesc/util/XMLUniDefs.hpp>
23
#include "xalanc/Include/PlatformDefinitions.hpp"
23
24
24
25
25
#if defined(WIN32)
26
#if defined(WIN32)
Lines 32-41 Link Here
32
33
33
34
34
35
35
XERCES_CPP_NAMESPACE_USE
36
XALAN_CPP_NAMESPACE_BEGIN
36
37
37
38
38
39
40
XERCES_CPP_NAMESPACE_USE
39
41
40
// Class responcible for printing into file with UTF16
42
// Class responcible for printing into file with UTF16
41
43
Lines 111-125 Link Here
111
113
112
114
113
	void 
115
	void 
114
	write(const UTF16Ch*	theString, unsigned int		theLength);
116
	write(const UTF16Ch*	theString, XalanSize_t		theLength);
115
	void 
117
	void 
116
	write(const char*	theString, unsigned int		theLength);
118
	write(const char*	theString, XalanSize_t		theLength);
117
119
118
	void 
120
	void 
119
	writeAsASCII(const char*	theString, unsigned int		theLengts);
121
	writeAsASCII(const char*	theString, XalanSize_t		theLengts);
120
122
121
	void
123
	void
122
	writeAsASCII(const UTF16Ch*	theString, unsigned int		theLengts);
124
	writeAsASCII(const UTF16Ch*	theString, XalanSize_t		theLengts);
123
	void
125
	void
124
	writeUTFprefix();
126
	writeUTFprefix();
125
protected:
127
protected:
Lines 127-133 Link Here
127
	void
129
	void
128
	writeData(
130
	writeData(
129
			const char*		theBuffer,
131
			const char*		theBuffer,
130
			unsigned int	theBufferLength);
132
			XalanSize_t	theBufferLength);
131
133
132
	void
134
	void
133
	doFlush();
135
	doFlush();
Lines 151-156 Link Here
151
};
153
};
152
154
153
155
154
#endif //XALANOUTPUTFILE_1357924680
156
XALAN_CPP_NAMESPACE_END
155
157
156
158
159
#endif //XALANOUTPUTFILE_1357924680
(-)src/xalanc/Utils/MsgCreator/ICUResHandler.cpp (-8 / +11 lines)
Lines 28-34 Link Here
28
28
29
29
30
30
31
XALAN_CPP_NAMESPACE_BEGIN
31
32
33
34
32
// -----------------------------------------------------------------------
35
// -----------------------------------------------------------------------
33
//  Constructors
36
//  Constructors
34
// -----------------------------------------------------------------------
37
// -----------------------------------------------------------------------
Lines 58-64 Link Here
58
// change tham with \", \{ and \}
61
// change tham with \", \{ and \}
59
62
60
void ICUResHandler::characters(	const   XMLCh* const    chars
63
void ICUResHandler::characters(	const   XMLCh* const    chars
61
						, const unsigned int    length)
64
						, const XalanSize_t    length)
62
{
65
{
63
66
64
	if ( m_startCollectingCharacters == true )
67
	if ( m_startCollectingCharacters == true )
Lines 100-114 Link Here
100
103
101
}
104
}
102
105
103
void ICUResHandler::endElement(const XMLCh* const ,
106
void ICUResHandler::endElement(const XMLCh* const /* uri */,
104
					const XMLCh* const localname,
107
					const XMLCh* const /* localname */,
105
					const XMLCh* const )
108
					const XMLCh* const qname)
106
{
109
{
107
	if ( m_startCollectingCharacters == false)
110
	if ( m_startCollectingCharacters == false)
108
		return;
111
		return;
109
112
110
113
111
    if(!XMLString::compareString(localname,s_targetXMLCh))
114
    if(!XMLString::compareString(qname,s_targetXMLCh))
112
	{
115
	{
113
		m_startCollectingCharacters = false;
116
		m_startCollectingCharacters = false;
114
117
Lines 122-134 Link Here
122
								const   Attributes&		attributes)
125
								const   Attributes&		attributes)
123
{
126
{
124
	
127
	
125
	if(!XMLString::compareString(localname,s_transUnitXMLCh))
128
	if(!XMLString::compareString(qname,s_transUnitXMLCh))
126
	{
129
	{
127
		// this is an elemente, SAX2Handler class is responsible to handle:
130
		// this is an elemente, SAX2Handler class is responsible to handle:
128
		// creating Index file, commom for all localization styles
131
		// creating Index file, commom for all localization styles
129
		SAX2Handler::startElement(uri, localname, qname, attributes);
132
		SAX2Handler::startElement(uri, localname, qname, attributes);
130
	}
133
	}
131
	else if(!XMLString::compareString(localname,s_targetXMLCh))
134
	else if(!XMLString::compareString(qname,s_targetXMLCh))
132
	{
135
	{
133
		if ( m_locale != 0 )
136
		if ( m_locale != 0 )
134
		{
137
		{
Lines 196-199 Link Here
196
}
199
}
197
200
198
201
199
202
XALAN_CPP_NAMESPACE_END
(-)src/xalanc/Utils/MsgCreator/NLSHandler.cpp (-1 / +10 lines)
Lines 22-27 Link Here
22
22
23
#include <cstdio>
23
#include <cstdio>
24
24
25
26
XALAN_CPP_NAMESPACE_BEGIN
27
28
29
25
// -----------------------------------------------------------------------
30
// -----------------------------------------------------------------------
26
//  Constructors
31
//  Constructors
27
// -----------------------------------------------------------------------
32
// -----------------------------------------------------------------------
Lines 48-54 Link Here
48
}
53
}
49
54
50
void NLSHandler::characters(	const   XMLCh* const    chars
55
void NLSHandler::characters(	const   XMLCh* const    chars
51
						, const unsigned int    length)
56
						, const XalanSize_t    length)
52
{
57
{
53
58
54
	if ( m_startCollectingCharacters == true )
59
	if ( m_startCollectingCharacters == true )
Lines 128-130 Link Here
128
		m_fStream.writeAsASCII("^\n",2);
133
		m_fStream.writeAsASCII("^\n",2);
129
	}
134
	}
130
}
135
}
136
137
138
139
XALAN_CPP_NAMESPACE_END
(-)src/xalanc/Utils/MsgCreator/ICUResHandler.hpp (-1 / +11 lines)
Lines 20-27 Link Here
20
#include "SAX2Handler.hpp"
20
#include "SAX2Handler.hpp"
21
21
22
22
23
24
XALAN_CPP_NAMESPACE_BEGIN
25
26
27
23
XERCES_CPP_NAMESPACE_USE
28
XERCES_CPP_NAMESPACE_USE
24
29
30
31
25
class ICUResHandler : public SAX2Handler
32
class ICUResHandler : public SAX2Handler
26
{
33
{
27
public:
34
public:
Lines 84-88 Link Here
84
	operator==(const ICUResHandler&) const;
91
	operator==(const ICUResHandler&) const;
85
};
92
};
86
93
94
95
XALAN_CPP_NAMESPACE_END
96
97
87
#endif // ICURESHANDLER_MSGCREATOR_1357924680
98
#endif // ICURESHANDLER_MSGCREATOR_1357924680
88
(-)src/xalanc/XalanDOM/XalanDOMString.hpp (-2 / +2 lines)
Lines 50-56 Link Here
50
	typedef XalanDOMChar&				reference;
50
	typedef XalanDOMChar&				reference;
51
	typedef const XalanDOMChar&			const_reference;
51
	typedef const XalanDOMChar&			const_reference;
52
52
53
    typedef unsigned int    size_type;
53
    typedef XalanSize_t     size_type;
54
54
55
	typedef XalanDOMCharVectorType::iterator				iterator;
55
	typedef XalanDOMCharVectorType::iterator				iterator;
56
	typedef XalanDOMCharVectorType::const_iterator			const_iterator;
56
	typedef XalanDOMCharVectorType::const_iterator			const_iterator;
Lines 60-66 Link Here
60
#if defined(XALAN_INLINE_INITIALIZATION)
60
#if defined(XALAN_INLINE_INITIALIZATION)
61
	static const size_type	npos = ~0u;
61
	static const size_type	npos = ~0u;
62
#else
62
#else
63
	enum { npos = -1 };
63
    enum { npos = ~0u };
64
#endif
64
#endif
65
65
66
	XalanDOMString(MemoryManagerType&  theManager XALAN_DEFAULT_CONSTRACTOR_MEMORY_MGR );
66
	XalanDOMString(MemoryManagerType&  theManager XALAN_DEFAULT_CONSTRACTOR_MEMORY_MGR );
(-)src/xalanc/Harness/XalanDiagnosticMemoryManager.hpp (+3 lines)
Lines 96-101 Link Here
96
    virtual void
96
    virtual void
97
    deallocate(void*    pointer);
97
    deallocate(void*    pointer);
98
98
99
    virtual MemoryManager*
100
    getExceptionMemoryManager();
101
99
    bool
102
    bool
100
    getAssertErrors() const
103
    getAssertErrors() const
101
    {
104
    {
(-)src/xalanc/Harness/XalanDiagnosticMemoryManager.cpp (+8 lines)
Lines 157-162 Link Here
157
157
158
158
159
159
160
MemoryManager*
161
XalanDiagnosticMemoryManager::getExceptionMemoryManager()
162
{
163
    return &m_memoryManager;
164
}
165
166
167
160
void
168
void
161
XalanDiagnosticMemoryManager::dumpStatistics(
169
XalanDiagnosticMemoryManager::dumpStatistics(
162
            StreamType*     theStream,
170
            StreamType*     theStream,
(-)src/xalanc/XalanSourceTree/XalanSourceTreeContentHandler.hpp (-6 / +7 lines)
Lines 74-80 Link Here
74
public:
74
public:
75
75
76
	typedef XalanVector<XalanSourceTreeElement*> 		ElementStackType;
76
	typedef XalanVector<XalanSourceTreeElement*> 		ElementStackType;
77
	typedef XalanVector<XalanNode*> 						LastChildStackType;
77
	typedef XalanVector<XalanNode*> 					LastChildStackType;
78
    typedef XalanSize_t                                 size_type;
78
79
79
	enum { eDefaultStackSize = 50, eDefaultTextBufferSize = 100 };
80
	enum { eDefaultStackSize = 50, eDefaultTextBufferSize = 100 };
80
81
Lines 94-100 Link Here
94
	virtual void
95
	virtual void
95
	characters(
96
	characters(
96
			const XMLCh* const	chars,
97
			const XMLCh* const	chars,
97
			const unsigned int	length);
98
			const size_type	    length);
98
99
99
	virtual void
100
	virtual void
100
	endDocument();
101
	endDocument();
Lines 108-114 Link Here
108
	virtual void
109
	virtual void
109
	ignorableWhitespace(
110
	ignorableWhitespace(
110
			const XMLCh* const	chars,
111
			const XMLCh* const	chars,
111
			const unsigned int	length);
112
			const size_type	    length);
112
113
113
	virtual void
114
	virtual void
114
	processingInstruction(
115
	processingInstruction(
Lines 165-171 Link Here
165
	virtual void
166
	virtual void
166
	comment(
167
	comment(
167
			const XMLCh* const	chars,
168
			const XMLCh* const	chars,
168
			const unsigned int	length);
169
			const size_type	    length);
169
170
170
	virtual void
171
	virtual void
171
	endCDATA();
172
	endCDATA();
Lines 225-232 Link Here
225
226
226
	void
227
	void
227
	doCharacters(
228
	doCharacters(
228
			const XMLCh*				chars,
229
			const XMLCh*	chars,
229
			XalanDOMString::size_type	length);
230
			size_type	    length);
230
231
231
	// Data members...
232
	// Data members...
232
233
(-)src/xalanc/XalanSourceTree/FormatterToSourceTree.cpp (-6 / +6 lines)
Lines 259-265 Link Here
259
void
259
void
260
FormatterToSourceTree::characters(
260
FormatterToSourceTree::characters(
261
			const XMLCh* const	chars,
261
			const XMLCh* const	chars,
262
			const unsigned int	length)
262
			const size_type	    length)
263
{
263
{
264
	if (m_documentFragment != 0)
264
	if (m_documentFragment != 0)
265
	{
265
	{
Lines 283-289 Link Here
283
void
283
void
284
FormatterToSourceTree::charactersRaw(
284
FormatterToSourceTree::charactersRaw(
285
		const XMLCh* const	chars,
285
		const XMLCh* const	chars,
286
		const unsigned int	length)
286
		const size_type	    length)
287
{
287
{
288
	assert(m_document != 0);
288
	assert(m_document != 0);
289
289
Lines 306-312 Link Here
306
void
306
void
307
FormatterToSourceTree::ignorableWhitespace(
307
FormatterToSourceTree::ignorableWhitespace(
308
			const XMLCh* const	chars,
308
			const XMLCh* const	chars,
309
			const unsigned int	length)
309
			const size_type	    length)
310
{
310
{
311
	assert(m_document != 0);
311
	assert(m_document != 0);
312
312
Lines 381-387 Link Here
381
void
381
void
382
FormatterToSourceTree::cdata(
382
FormatterToSourceTree::cdata(
383
			const XMLCh* const	/* ch */,
383
			const XMLCh* const	/* ch */,
384
			const unsigned int 	/* length */)
384
			const size_type 	/* length */)
385
{
385
{
386
}
386
}
387
387
Lines 402-409 Link Here
402
402
403
void
403
void
404
FormatterToSourceTree::doCharacters(
404
FormatterToSourceTree::doCharacters(
405
			const XMLCh*				chars,
405
			const XMLCh*	chars,
406
			XalanDOMString::size_type	length)
406
			size_type	    length)
407
{
407
{
408
	if (m_currentElement != 0)
408
	if (m_currentElement != 0)
409
	{
409
	{
(-)src/xalanc/XalanSourceTree/FormatterToSourceTree.hpp (-6 / +6 lines)
Lines 141-147 Link Here
141
	virtual void
141
	virtual void
142
	charactersRaw(
142
	charactersRaw(
143
			const XMLCh* const	chars,
143
			const XMLCh* const	chars,
144
			const unsigned int	length);
144
			const size_type	    length);
145
145
146
	virtual void
146
	virtual void
147
	comment(const XMLCh* const	data);
147
	comment(const XMLCh* const	data);
Lines 149-155 Link Here
149
	virtual void
149
	virtual void
150
	cdata(
150
	cdata(
151
			const XMLCh* const	ch,
151
			const XMLCh* const	ch,
152
			const unsigned int 	length);
152
			const size_type 	length);
153
153
154
	virtual void
154
	virtual void
155
	entityReference(const XMLCh* const	name);
155
	entityReference(const XMLCh* const	name);
Lines 174-185 Link Here
174
	virtual void
174
	virtual void
175
	characters(
175
	characters(
176
				const XMLCh* const	chars,
176
				const XMLCh* const	chars,
177
				const unsigned int	length);
177
				const size_type	    length);
178
178
179
	virtual void
179
	virtual void
180
	ignorableWhitespace(
180
	ignorableWhitespace(
181
				const XMLCh* const	chars,
181
				const XMLCh* const	chars,
182
				const unsigned int	length);
182
				const size_type	    length);
183
183
184
	virtual void
184
	virtual void
185
	processingInstruction(
185
	processingInstruction(
Lines 203-210 Link Here
203
203
204
	void
204
	void
205
	doCharacters(
205
	doCharacters(
206
			const XalanDOMChar*			chars,
206
			const XalanDOMChar*		chars,
207
			XalanDOMString::size_type	length);
207
			size_type	            length);
208
208
209
	void
209
	void
210
	doProcessingInstruction(
210
	doProcessingInstruction(
(-)src/xalanc/XalanSourceTree/XalanSourceTreeContentHandler.cpp (-5 / +5 lines)
Lines 65-71 Link Here
65
void
65
void
66
XalanSourceTreeContentHandler::characters(
66
XalanSourceTreeContentHandler::characters(
67
			const	XMLCh* const	chars,
67
			const	XMLCh* const	chars,
68
			const unsigned int		length)
68
			const size_type		    length)
69
{
69
{
70
	assert(m_inDTD == false);
70
	assert(m_inDTD == false);
71
71
Lines 194-200 Link Here
194
void
194
void
195
XalanSourceTreeContentHandler::ignorableWhitespace(
195
XalanSourceTreeContentHandler::ignorableWhitespace(
196
			const XMLCh* const	chars,
196
			const XMLCh* const	chars,
197
			const unsigned int	length)
197
			const size_type	    length)
198
{
198
{
199
	assert(m_inDTD == false);
199
	assert(m_inDTD == false);
200
200
Lines 370-376 Link Here
370
void
370
void
371
XalanSourceTreeContentHandler::comment(
371
XalanSourceTreeContentHandler::comment(
372
			const XMLCh* const	chars,
372
			const XMLCh* const	chars,
373
			const unsigned int	length)
373
			const size_type	    length)
374
{
374
{
375
	assert(m_document != 0);
375
	assert(m_document != 0);
376
376
Lines 499-506 Link Here
499
499
500
void
500
void
501
XalanSourceTreeContentHandler::doCharacters(
501
XalanSourceTreeContentHandler::doCharacters(
502
			const XMLCh*				chars,
502
			const XMLCh*	chars,
503
			XalanDOMString::size_type	length)
503
			size_type	    length)
504
{
504
{
505
	assert(m_inDTD == false);
505
	assert(m_inDTD == false);
506
506
(-)src/xalanc/DOMSupport/DOMSupportDefault.cpp (-7 / +3 lines)
Lines 90-107 Link Here
90
90
91
			if (theNode != 0 && theNode->getNodeType() == XalanNode::ENTITY_NODE)
91
			if (theNode != 0 && theNode->getNodeType() == XalanNode::ENTITY_NODE)
92
			{
92
			{
93
				const XalanEntity*	theEntity =
93
				const XalanEntity* const    theEntity =
94
#if defined(XALAN_OLD_STYLE_CASTS)
94
#if defined(XALAN_OLD_STYLE_CASTS)
95
					(const XalanEntity*)theNode;
95
					(const XalanEntity*)theNode;
96
#else
96
#else
97
					static_cast<const XalanEntity*>(theNode);
97
					static_cast<const XalanEntity*>(theNode);
98
#endif
98
#endif
99
99
100
                const XalanDOMString    theNotationName(
100
				if(length(theEntity->getNotationName()) != 0) // then it's unparsed
101
                                            theEntity->getNotationName(),
102
                                            theMemoryManager);
103
104
				if(isEmpty(theNotationName) == false) // then it's unparsed
105
				{
101
				{
106
					// The draft says: "The XSLT processor may use the public
102
					// The draft says: "The XSLT processor may use the public
107
					// identifier to generate a URI for the entity instead of the URI
103
					// identifier to generate a URI for the entity instead of the URI
Lines 114-120 Link Here
114
					// So I'm falling a bit short here.
110
					// So I'm falling a bit short here.
115
					theURI = theEntity->getSystemId();
111
					theURI = theEntity->getSystemId();
116
112
117
					if(isEmpty(theURI) == true)
113
                    if(theURI.length() == 0)
118
					{
114
					{
119
						theURI = theEntity->getPublicId();
115
						theURI = theEntity->getPublicId();
120
					}
116
					}
(-)src/xalanc/DOMSupport/DOMServices.hpp (-1 / +1 lines)
Lines 203-209 Link Here
203
		append(data, text.getData());
203
		append(data, text.getData());
204
	}
204
	}
205
205
206
	typedef void (FormatterListener::*MemberFunctionPtr)(const XMLCh* const, const unsigned int);
206
    typedef void (FormatterListener::*MemberFunctionPtr)(const XMLCh* const, const FormatterListener::size_type);
207
207
208
	/**
208
	/**
209
	 * Sends the data for a node to a FormatterListener
209
	 * Sends the data for a node to a FormatterListener
(-)Tests/Conf/conf.cpp (-1 / +8 lines)
Lines 207-213 Link Here
207
207
208
    XercesDOMParser  theParser(0, &mgr);
208
    XercesDOMParser  theParser(0, &mgr);
209
209
210
#if XERCES_VERSION_MAJOR < 3
210
    theParser.setDoValidation(true);
211
    theParser.setDoValidation(true);
212
#else
213
    theParser.setValidationScheme(XercesDOMParser::Val_Auto);
214
#endif
215
211
    theParser.setDoNamespaces(true);
216
    theParser.setDoNamespaces(true);
212
217
213
    theParser.parse(xmlInput);
218
    theParser.parse(xmlInput);
Lines 308-314 Link Here
308
                //
313
                //
309
                const XalanDOMString&   currentDir = dirs[j];
314
                const XalanDOMString&   currentDir = dirs[j];
310
315
311
                if (length(h.args.sub) == 0 || equals(currentDir, h.args.sub) == true)
316
                if ((length(h.args.sub) == 0 ||
317
                     equals(currentDir, h.args.sub) == true) &&
318
                    currentDir[0] != XalanUnicode::charFullStop)
312
                {
319
                {
313
                    // Check that output directory is there.
320
                    // Check that output directory is there.
314
                    //
321
                    //
(-)samples/SimpleTransform/XalanMemoryManagerImpl.hpp (-1 / +7 lines)
Lines 96-102 Link Here
96
96
97
    }
97
    }
98
98
99
	virtual 
99
    MemoryManager*
100
    getExceptionMemoryManager()
101
    {
102
        return this;
103
    }
104
105
    virtual 
100
	~XalanMemoryManagerImpl()
106
	~XalanMemoryManagerImpl()
101
	{
107
	{
102
       if( 0 == HeapDestroy(m_heapHandle) )
108
       if( 0 == HeapDestroy(m_heapHandle) )

Return to bug 242218