InscoperAPI/Build/Java/com.inscoper.api/com/inscoper/api/XMLNode.java¶
Packages¶
| Name |
|---|
| com.inscoper.api |
Classes¶
| Name | |
|---|---|
| class | com.inscoper.api.XMLNode XMLNode class represents a node in an XML document. |
Source code¶
/* ----------------------------------------------------------------------------
* This file was automatically generated by SWIG (https://www.swig.org).
* Version 4.3.1
*
* Do not make changes to this file unless you know what you are doing - modify
* the SWIG interface file instead.
* ----------------------------------------------------------------------------- */
package com.inscoper.api;
import com.inscoper.api.logging.*;
public class XMLNode {
private transient long swigCPtr;
protected transient boolean swigCMemOwn;
protected XMLNode(long cPtr, boolean cMemoryOwn) {
swigCMemOwn = cMemoryOwn;
swigCPtr = cPtr;
}
protected static long getCPtr(XMLNode obj) {
return (obj == null) ? 0 : obj.swigCPtr;
}
protected static long swigRelease(XMLNode obj) {
long ptr = 0;
if (obj != null) {
if (!obj.swigCMemOwn)
throw new RuntimeException("Cannot release ownership as memory is not owned");
ptr = obj.swigCPtr;
obj.swigCMemOwn = false;
obj.delete();
}
return ptr;
}
@SuppressWarnings({"deprecation", "removal"})
protected void finalize() {
delete();
}
public synchronized void delete() {
if (swigCPtr != 0) {
if (swigCMemOwn) {
swigCMemOwn = false;
InscoperJNI.delete_XMLNode(swigCPtr);
}
swigCPtr = 0;
}
}
public XMLNode() {
this(InscoperJNI.new_XMLNode__SWIG_0(), true);
}
public XMLNode(XMLNode node) {
this(InscoperJNI.new_XMLNode__SWIG_1(XMLNode.getCPtr(node), node), true);
}
public XMLNode addChild(String childName) {
return new XMLNode(InscoperJNI.XMLNode_addChild__SWIG_0(swigCPtr, this, childName), true);
}
public XMLNode addChild() {
return new XMLNode(InscoperJNI.XMLNode_addChild__SWIG_1(swigCPtr, this), true);
}
public void removeChild(String childName) {
InscoperJNI.XMLNode_removeChild(swigCPtr, this, childName);
}
public XMLNode getChild(String name) {
return new XMLNode(InscoperJNI.XMLNode_getChild(swigCPtr, this, name), true);
}
public XMLNodeVector getChildren(String name) {
return new XMLNodeVector(InscoperJNI.XMLNode_getChildren__SWIG_0(swigCPtr, this, name), true);
}
public XMLNodeVector getChildren() {
return new XMLNodeVector(InscoperJNI.XMLNode_getChildren__SWIG_1(swigCPtr, this), true);
}
public void setName(String name) {
InscoperJNI.XMLNode_setName(swigCPtr, this, name);
}
public String getName() {
return InscoperJNI.XMLNode_getName(swigCPtr, this);
}
public boolean isEmpty() {
return InscoperJNI.XMLNode_isEmpty(swigCPtr, this);
}
public void addAttribute(String name, String value) {
InscoperJNI.XMLNode_addAttribute__SWIG_0(swigCPtr, this, name, value);
}
public void addAttribute(String name, boolean value) {
InscoperJNI.XMLNode_addAttribute__SWIG_1(swigCPtr, this, name, value);
}
public void addAttribute(String name, long value) {
InscoperJNI.XMLNode_addAttribute__SWIG_2(swigCPtr, this, name, value);
}
public void addAttribute(String name, int value) {
InscoperJNI.XMLNode_addAttribute__SWIG_3(swigCPtr, this, name, value);
}
public void addAttribute(String name, short value) {
InscoperJNI.XMLNode_addAttribute__SWIG_4(swigCPtr, this, name, value);
}
public void addAttribute(String name, char value) {
InscoperJNI.XMLNode_addAttribute__SWIG_5(swigCPtr, this, name, value);
}
public void addAttribute(String name, double value) {
InscoperJNI.XMLNode_addAttribute__SWIG_6(swigCPtr, this, name, value);
}
public XMLAttribute getAttribute(String name) {
return new XMLAttribute(InscoperJNI.XMLNode_getAttribute(swigCPtr, this, name), true);
}
public XMLAttributeVector getAttributes() {
return new XMLAttributeVector(InscoperJNI.XMLNode_getAttributes(swigCPtr, this), true);
}
public void addCDATA(String content) {
InscoperJNI.XMLNode_addCDATA(swigCPtr, this, content);
}
public String getText() {
return InscoperJNI.XMLNode_getText(swigCPtr, this);
}
}
Updated on 2026-09-03 at 12:14:19 +0200