Skip to content
Snippets Groups Projects
Commit 85841848 authored by Jason Edward Stewart's avatar Jason Edward Stewart
Browse files

preparing for DOM split

git-svn-id: https://svn.apache.org/repos/asf/xerces/c/trunk@437644 13f79535-47bb-0310-9956-ffa450edef68
parent 24c531c5
No related branches found
No related tags found
No related merge requests found
/*
* Copyright 2002,2004 The Apache Software Foundation.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
/*
* DOM_Node*
*/
%typemap(out) XERCES_CPP_NAMESPACE::DOMNode * = SWIGTYPE *DYNAMIC;
DYNAMIC_CAST(SWIGTYPE_p_XERCES_CPP_NAMESPACE__DOMNode, DOMNode_dynamic_cast);
%{
static swig_type_info *
DOMNode_dynamic_cast(void **ptr) {
DOMNode **nptr = (DOMNode **) ptr;
if (*nptr == NULL) {
return NULL;
}
short int type = (*nptr)->getNodeType();
if (type == DOMNode::TEXT_NODE) {
return SWIGTYPE_p_XERCES_CPP_NAMESPACE__DOMText;
}
if (type == DOMNode::PROCESSING_INSTRUCTION_NODE) {
return SWIGTYPE_p_XERCES_CPP_NAMESPACE__DOMProcessingInstruction;
}
if (type == DOMNode::DOCUMENT_NODE) {
return SWIGTYPE_p_XERCES_CPP_NAMESPACE__DOMDocument;
}
if (type == DOMNode::ELEMENT_NODE) {
return SWIGTYPE_p_XERCES_CPP_NAMESPACE__DOMElement;
}
if (type == DOMNode::ENTITY_REFERENCE_NODE) {
return SWIGTYPE_p_XERCES_CPP_NAMESPACE__DOMEntityReference;
}
if (type == DOMNode::CDATA_SECTION_NODE) {
return SWIGTYPE_p_XERCES_CPP_NAMESPACE__DOMCDATASection;
}
if (type == DOMNode::CDATA_SECTION_NODE) {
return SWIGTYPE_p_XERCES_CPP_NAMESPACE__DOMCDATASection;
}
if (type == DOMNode::COMMENT_NODE) {
return SWIGTYPE_p_XERCES_CPP_NAMESPACE__DOMComment;
}
if (type == DOMNode::DOCUMENT_TYPE_NODE) {
return SWIGTYPE_p_XERCES_CPP_NAMESPACE__DOMDocumentType;
}
if (type == DOMNode::ENTITY_NODE) {
return SWIGTYPE_p_XERCES_CPP_NAMESPACE__DOMEntity;
}
if (type == DOMNode::ATTRIBUTE_NODE) {
return SWIGTYPE_p_XERCES_CPP_NAMESPACE__DOMAttr;
}
if (type == DOMNode::NOTATION_NODE) {
return SWIGTYPE_p_XERCES_CPP_NAMESPACE__DOMNotation;
}
return NULL;
}
%}
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment