
system.xml.XmlReaderSettings Maven / Gradle / Ivy
/*
* MIT License
*
* Copyright (c) 2023 MASES s.r.l.
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
* in the Software without restriction, including without limitation the rights
* to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
* copies of the Software, and to permit persons to whom the Software is
* furnished to do so, subject to the following conditions:
*
* The above copyright notice and this permission notice shall be included in all
* copies or substantial portions of the Software.
*
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
* FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
* AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
* LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
* OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
* SOFTWARE.
*/
/**************************************************************************************
*
* This code was generated from a template using JCOReflector
*
* Manual changes to this file may cause unexpected behavior in your application.
* Manual changes to this file will be overwritten if the code is regenerated.
*
*************************************************************************************/
package system.xml;
import org.mases.jcobridge.*;
import org.mases.jcobridge.netreflection.*;
import java.util.ArrayList;
// Import section
import system.xml.XmlReaderSettings;
import system.xml.ConformanceLevel;
import system.xml.DtdProcessing;
import system.xml.schema.XmlSchemaSet;
import system.xml.schema.XmlSchemaValidationFlags;
import system.xml.ValidationType;
import system.xml.XmlNameTable;
import system.xml.XmlResolver;
import system.xml.schema.ValidationEventHandler;
/**
* The base .NET class managing System.Xml.XmlReaderSettings, System.Private.Xml, Version=6.0.0.0, Culture=neutral, PublicKeyToken=cc7b13ffcd2ddd51.
*
*
* .NET documentation at https://docs.microsoft.com/en-us/dotnet/api/System.Xml.XmlReaderSettings
*
*
* Powered by JCOBridge: more info at https://www.jcobridge.com
*/
public class XmlReaderSettings extends NetObject {
/**
* Fully assembly qualified name: System.Private.Xml, Version=6.0.0.0, Culture=neutral, PublicKeyToken=cc7b13ffcd2ddd51
*/
public static final String assemblyFullName = "System.Private.Xml, Version=6.0.0.0, Culture=neutral, PublicKeyToken=cc7b13ffcd2ddd51";
/**
* Assembly name: System.Private.Xml
*/
public static final String assemblyShortName = "System.Private.Xml";
/**
* Qualified class name: System.Xml.XmlReaderSettings
*/
public static final String className = "System.Xml.XmlReaderSettings";
static JCOBridge bridge = JCOBridgeInstance.getInstance(assemblyFullName);
/**
* The type managed from JCOBridge. See {@link JCType}
*/
public static JCType classType = createType();
static JCEnum enumInstance = null;
JCObject classInstance = null;
static JCType createType() {
try {
String classToCreate = className + ", "
+ (JCOReflector.getUseFullAssemblyName() ? assemblyFullName : assemblyShortName);
if (JCOReflector.getDebug())
JCOReflector.writeLog("Creating %s", classToCreate);
JCType typeCreated = bridge.GetType(classToCreate);
if (JCOReflector.getDebug())
JCOReflector.writeLog("Created: %s",
(typeCreated != null) ? typeCreated.toString() : "Returned null value");
return typeCreated;
} catch (JCException e) {
JCOReflector.writeLog(e);
return null;
}
}
void addReference(String ref) throws Throwable {
try {
bridge.AddReference(ref);
} catch (JCNativeException jcne) {
throw translateException(jcne);
}
}
/**
* Internal constructor. Use with caution
*/
public XmlReaderSettings(java.lang.Object instance) throws Throwable {
super(instance);
if (instance instanceof JCObject) {
classInstance = (JCObject) instance;
} else
throw new Exception("Cannot manage object, it is not a JCObject");
}
public String getJCOAssemblyName() {
return assemblyFullName;
}
public String getJCOClassName() {
return className;
}
public String getJCOObjectName() {
return className + ", " + (JCOReflector.getUseFullAssemblyName() ? assemblyFullName : assemblyShortName);
}
public java.lang.Object getJCOInstance() {
return classInstance;
}
public void setJCOInstance(JCObject instance) {
classInstance = instance;
super.setJCOInstance(classInstance);
}
public JCType getJCOType() {
return classType;
}
/**
* Try to cast the {@link IJCOBridgeReflected} instance into {@link XmlReaderSettings}, a cast assert is made to check if types are compatible.
* @param from {@link IJCOBridgeReflected} instance to be casted
* @return {@link XmlReaderSettings} instance
* @throws java.lang.Throwable in case of error during cast operation
*/
public static XmlReaderSettings cast(IJCOBridgeReflected from) throws Throwable {
NetType.AssertCast(classType, from);
return new XmlReaderSettings(from.getJCOInstance());
}
// Constructors section
public XmlReaderSettings() throws Throwable {
try {
// add reference to assemblyName.dll file
addReference(JCOReflector.getUseFullAssemblyName() ? assemblyFullName : assemblyShortName);
setJCOInstance((JCObject)classType.NewObject());
} catch (JCNativeException jcne) {
throw translateException(jcne);
}
}
// Methods section
public XmlReaderSettings Clone() throws Throwable, system.PlatformNotSupportedException {
if (classInstance == null)
throw new UnsupportedOperationException("classInstance is null.");
try {
JCObject objClone = (JCObject)classInstance.Invoke("Clone");
return new XmlReaderSettings(objClone);
} catch (JCNativeException jcne) {
throw translateException(jcne);
}
}
public void Reset() throws Throwable, system.ArgumentNullException, system.ArgumentException, system.ArgumentOutOfRangeException, system.globalization.CultureNotFoundException, system.IndexOutOfRangeException, system.PlatformNotSupportedException, system.InvalidOperationException, system.FormatException, system.xml.XmlException {
if (classInstance == null)
throw new UnsupportedOperationException("classInstance is null.");
try {
classInstance.Invoke("Reset");
} catch (JCNativeException jcne) {
throw translateException(jcne);
}
}
// Properties section
public boolean getAsync() throws Throwable {
if (classInstance == null)
throw new UnsupportedOperationException("classInstance is null.");
try {
return (boolean)classInstance.Get("Async");
} catch (JCNativeException jcne) {
throw translateException(jcne);
}
}
public void setAsync(boolean Async) throws Throwable, system.ArgumentNullException, system.ArgumentException, system.ArgumentOutOfRangeException, system.globalization.CultureNotFoundException, system.IndexOutOfRangeException, system.PlatformNotSupportedException, system.InvalidOperationException, system.FormatException, system.xml.XmlException {
if (classInstance == null)
throw new UnsupportedOperationException("classInstance is null.");
try {
classInstance.Set("Async", Async);
} catch (JCNativeException jcne) {
throw translateException(jcne);
}
}
public boolean getCheckCharacters() throws Throwable {
if (classInstance == null)
throw new UnsupportedOperationException("classInstance is null.");
try {
return (boolean)classInstance.Get("CheckCharacters");
} catch (JCNativeException jcne) {
throw translateException(jcne);
}
}
public void setCheckCharacters(boolean CheckCharacters) throws Throwable, system.ArgumentNullException, system.ArgumentException, system.ArgumentOutOfRangeException, system.globalization.CultureNotFoundException, system.IndexOutOfRangeException, system.PlatformNotSupportedException, system.InvalidOperationException, system.FormatException, system.xml.XmlException {
if (classInstance == null)
throw new UnsupportedOperationException("classInstance is null.");
try {
classInstance.Set("CheckCharacters", CheckCharacters);
} catch (JCNativeException jcne) {
throw translateException(jcne);
}
}
public boolean getCloseInput() throws Throwable {
if (classInstance == null)
throw new UnsupportedOperationException("classInstance is null.");
try {
return (boolean)classInstance.Get("CloseInput");
} catch (JCNativeException jcne) {
throw translateException(jcne);
}
}
public void setCloseInput(boolean CloseInput) throws Throwable, system.ArgumentNullException, system.ArgumentException, system.ArgumentOutOfRangeException, system.globalization.CultureNotFoundException, system.IndexOutOfRangeException, system.PlatformNotSupportedException, system.InvalidOperationException, system.FormatException, system.xml.XmlException {
if (classInstance == null)
throw new UnsupportedOperationException("classInstance is null.");
try {
classInstance.Set("CloseInput", CloseInput);
} catch (JCNativeException jcne) {
throw translateException(jcne);
}
}
public boolean getIgnoreComments() throws Throwable {
if (classInstance == null)
throw new UnsupportedOperationException("classInstance is null.");
try {
return (boolean)classInstance.Get("IgnoreComments");
} catch (JCNativeException jcne) {
throw translateException(jcne);
}
}
public void setIgnoreComments(boolean IgnoreComments) throws Throwable, system.ArgumentNullException, system.ArgumentException, system.ArgumentOutOfRangeException, system.globalization.CultureNotFoundException, system.IndexOutOfRangeException, system.PlatformNotSupportedException, system.InvalidOperationException, system.FormatException, system.xml.XmlException {
if (classInstance == null)
throw new UnsupportedOperationException("classInstance is null.");
try {
classInstance.Set("IgnoreComments", IgnoreComments);
} catch (JCNativeException jcne) {
throw translateException(jcne);
}
}
public boolean getIgnoreProcessingInstructions() throws Throwable {
if (classInstance == null)
throw new UnsupportedOperationException("classInstance is null.");
try {
return (boolean)classInstance.Get("IgnoreProcessingInstructions");
} catch (JCNativeException jcne) {
throw translateException(jcne);
}
}
public void setIgnoreProcessingInstructions(boolean IgnoreProcessingInstructions) throws Throwable, system.ArgumentNullException, system.ArgumentException, system.ArgumentOutOfRangeException, system.globalization.CultureNotFoundException, system.IndexOutOfRangeException, system.PlatformNotSupportedException, system.InvalidOperationException, system.FormatException, system.xml.XmlException {
if (classInstance == null)
throw new UnsupportedOperationException("classInstance is null.");
try {
classInstance.Set("IgnoreProcessingInstructions", IgnoreProcessingInstructions);
} catch (JCNativeException jcne) {
throw translateException(jcne);
}
}
public boolean getIgnoreWhitespace() throws Throwable {
if (classInstance == null)
throw new UnsupportedOperationException("classInstance is null.");
try {
return (boolean)classInstance.Get("IgnoreWhitespace");
} catch (JCNativeException jcne) {
throw translateException(jcne);
}
}
public void setIgnoreWhitespace(boolean IgnoreWhitespace) throws Throwable, system.ArgumentNullException, system.ArgumentException, system.ArgumentOutOfRangeException, system.globalization.CultureNotFoundException, system.IndexOutOfRangeException, system.PlatformNotSupportedException, system.InvalidOperationException, system.FormatException, system.xml.XmlException {
if (classInstance == null)
throw new UnsupportedOperationException("classInstance is null.");
try {
classInstance.Set("IgnoreWhitespace", IgnoreWhitespace);
} catch (JCNativeException jcne) {
throw translateException(jcne);
}
}
public boolean getProhibitDtd() throws Throwable {
if (classInstance == null)
throw new UnsupportedOperationException("classInstance is null.");
try {
return (boolean)classInstance.Get("ProhibitDtd");
} catch (JCNativeException jcne) {
throw translateException(jcne);
}
}
public void setProhibitDtd(boolean ProhibitDtd) throws Throwable, system.ArgumentNullException, system.ArgumentException, system.ArgumentOutOfRangeException, system.globalization.CultureNotFoundException, system.IndexOutOfRangeException, system.PlatformNotSupportedException, system.InvalidOperationException, system.FormatException, system.xml.XmlException {
if (classInstance == null)
throw new UnsupportedOperationException("classInstance is null.");
try {
classInstance.Set("ProhibitDtd", ProhibitDtd);
} catch (JCNativeException jcne) {
throw translateException(jcne);
}
}
public int getLineNumberOffset() throws Throwable {
if (classInstance == null)
throw new UnsupportedOperationException("classInstance is null.");
try {
return (int)classInstance.Get("LineNumberOffset");
} catch (JCNativeException jcne) {
throw translateException(jcne);
}
}
public void setLineNumberOffset(int LineNumberOffset) throws Throwable, system.ArgumentNullException, system.ArgumentException, system.ArgumentOutOfRangeException, system.globalization.CultureNotFoundException, system.IndexOutOfRangeException, system.PlatformNotSupportedException, system.InvalidOperationException, system.FormatException, system.xml.XmlException {
if (classInstance == null)
throw new UnsupportedOperationException("classInstance is null.");
try {
classInstance.Set("LineNumberOffset", LineNumberOffset);
} catch (JCNativeException jcne) {
throw translateException(jcne);
}
}
public int getLinePositionOffset() throws Throwable {
if (classInstance == null)
throw new UnsupportedOperationException("classInstance is null.");
try {
return (int)classInstance.Get("LinePositionOffset");
} catch (JCNativeException jcne) {
throw translateException(jcne);
}
}
public void setLinePositionOffset(int LinePositionOffset) throws Throwable, system.ArgumentNullException, system.ArgumentException, system.ArgumentOutOfRangeException, system.globalization.CultureNotFoundException, system.IndexOutOfRangeException, system.PlatformNotSupportedException, system.InvalidOperationException, system.FormatException, system.xml.XmlException {
if (classInstance == null)
throw new UnsupportedOperationException("classInstance is null.");
try {
classInstance.Set("LinePositionOffset", LinePositionOffset);
} catch (JCNativeException jcne) {
throw translateException(jcne);
}
}
public long getMaxCharactersFromEntities() throws Throwable {
if (classInstance == null)
throw new UnsupportedOperationException("classInstance is null.");
try {
return (long)classInstance.Get("MaxCharactersFromEntities");
} catch (JCNativeException jcne) {
throw translateException(jcne);
}
}
public void setMaxCharactersFromEntities(long MaxCharactersFromEntities) throws Throwable, system.ArgumentNullException, system.ArgumentException, system.ArgumentOutOfRangeException, system.globalization.CultureNotFoundException, system.IndexOutOfRangeException, system.PlatformNotSupportedException, system.InvalidOperationException, system.FormatException, system.xml.XmlException {
if (classInstance == null)
throw new UnsupportedOperationException("classInstance is null.");
try {
classInstance.Set("MaxCharactersFromEntities", MaxCharactersFromEntities);
} catch (JCNativeException jcne) {
throw translateException(jcne);
}
}
public long getMaxCharactersInDocument() throws Throwable {
if (classInstance == null)
throw new UnsupportedOperationException("classInstance is null.");
try {
return (long)classInstance.Get("MaxCharactersInDocument");
} catch (JCNativeException jcne) {
throw translateException(jcne);
}
}
public void setMaxCharactersInDocument(long MaxCharactersInDocument) throws Throwable, system.ArgumentNullException, system.ArgumentException, system.ArgumentOutOfRangeException, system.globalization.CultureNotFoundException, system.IndexOutOfRangeException, system.PlatformNotSupportedException, system.InvalidOperationException, system.FormatException, system.xml.XmlException {
if (classInstance == null)
throw new UnsupportedOperationException("classInstance is null.");
try {
classInstance.Set("MaxCharactersInDocument", MaxCharactersInDocument);
} catch (JCNativeException jcne) {
throw translateException(jcne);
}
}
public ConformanceLevel getConformanceLevel() throws Throwable {
if (classInstance == null)
throw new UnsupportedOperationException("classInstance is null.");
try {
JCObject val = (JCObject)classInstance.Get("ConformanceLevel");
return new ConformanceLevel(val);
} catch (JCNativeException jcne) {
throw translateException(jcne);
}
}
public void setConformanceLevel(ConformanceLevel ConformanceLevel) throws Throwable, system.ArgumentNullException, system.ArgumentException, system.ArgumentOutOfRangeException, system.globalization.CultureNotFoundException, system.IndexOutOfRangeException, system.PlatformNotSupportedException, system.InvalidOperationException, system.FormatException, system.xml.XmlException {
if (classInstance == null)
throw new UnsupportedOperationException("classInstance is null.");
try {
classInstance.Set("ConformanceLevel", ConformanceLevel == null ? null : ConformanceLevel.getJCOInstance());
} catch (JCNativeException jcne) {
throw translateException(jcne);
}
}
public DtdProcessing getDtdProcessing() throws Throwable {
if (classInstance == null)
throw new UnsupportedOperationException("classInstance is null.");
try {
JCObject val = (JCObject)classInstance.Get("DtdProcessing");
return new DtdProcessing(val);
} catch (JCNativeException jcne) {
throw translateException(jcne);
}
}
public void setDtdProcessing(DtdProcessing DtdProcessing) throws Throwable, system.ArgumentNullException, system.ArgumentException, system.ArgumentOutOfRangeException, system.globalization.CultureNotFoundException, system.IndexOutOfRangeException, system.PlatformNotSupportedException, system.InvalidOperationException, system.FormatException, system.xml.XmlException {
if (classInstance == null)
throw new UnsupportedOperationException("classInstance is null.");
try {
classInstance.Set("DtdProcessing", DtdProcessing == null ? null : DtdProcessing.getJCOInstance());
} catch (JCNativeException jcne) {
throw translateException(jcne);
}
}
public XmlSchemaSet getSchemas() throws Throwable, system.ArgumentException, system.ArgumentOutOfRangeException, system.IndexOutOfRangeException, system.PlatformNotSupportedException, system.NotSupportedException, system.ArgumentNullException, system.ObjectDisposedException, system.InvalidOperationException, system.RankException, system.ArrayTypeMismatchException, system.globalization.CultureNotFoundException, system.OutOfMemoryException, system.runtime.interopservices.ExternalException, system.FormatException, system.xml.schema.XmlSchemaException, system.xml.XmlException {
if (classInstance == null)
throw new UnsupportedOperationException("classInstance is null.");
try {
JCObject val = (JCObject)classInstance.Get("Schemas");
return new XmlSchemaSet(val);
} catch (JCNativeException jcne) {
throw translateException(jcne);
}
}
public void setSchemas(XmlSchemaSet Schemas) throws Throwable, system.ArgumentNullException, system.ArgumentException, system.ArgumentOutOfRangeException, system.globalization.CultureNotFoundException, system.IndexOutOfRangeException, system.PlatformNotSupportedException, system.InvalidOperationException, system.FormatException, system.xml.XmlException {
if (classInstance == null)
throw new UnsupportedOperationException("classInstance is null.");
try {
classInstance.Set("Schemas", Schemas == null ? null : Schemas.getJCOInstance());
} catch (JCNativeException jcne) {
throw translateException(jcne);
}
}
public XmlSchemaValidationFlags getValidationFlags() throws Throwable {
if (classInstance == null)
throw new UnsupportedOperationException("classInstance is null.");
try {
JCObject val = (JCObject)classInstance.Get("ValidationFlags");
return new XmlSchemaValidationFlags(val);
} catch (JCNativeException jcne) {
throw translateException(jcne);
}
}
public void setValidationFlags(XmlSchemaValidationFlags ValidationFlags) throws Throwable, system.ArgumentNullException, system.ArgumentException, system.ArgumentOutOfRangeException, system.globalization.CultureNotFoundException, system.IndexOutOfRangeException, system.PlatformNotSupportedException, system.InvalidOperationException, system.FormatException, system.xml.XmlException {
if (classInstance == null)
throw new UnsupportedOperationException("classInstance is null.");
try {
classInstance.Set("ValidationFlags", ValidationFlags == null ? null : ValidationFlags.getJCOInstance());
} catch (JCNativeException jcne) {
throw translateException(jcne);
}
}
public ValidationType getValidationType() throws Throwable {
if (classInstance == null)
throw new UnsupportedOperationException("classInstance is null.");
try {
JCObject val = (JCObject)classInstance.Get("ValidationType");
return new ValidationType(val);
} catch (JCNativeException jcne) {
throw translateException(jcne);
}
}
public void setValidationType(ValidationType ValidationType) throws Throwable, system.ArgumentNullException, system.ArgumentException, system.ArgumentOutOfRangeException, system.globalization.CultureNotFoundException, system.IndexOutOfRangeException, system.PlatformNotSupportedException, system.InvalidOperationException, system.FormatException, system.xml.XmlException, system.MulticastNotSupportedException, system.xml.schema.XmlSchemaException, system.NotSupportedException {
if (classInstance == null)
throw new UnsupportedOperationException("classInstance is null.");
try {
classInstance.Set("ValidationType", ValidationType == null ? null : ValidationType.getJCOInstance());
} catch (JCNativeException jcne) {
throw translateException(jcne);
}
}
public XmlNameTable getNameTable() throws Throwable {
if (classInstance == null)
throw new UnsupportedOperationException("classInstance is null.");
try {
JCObject val = (JCObject)classInstance.Get("NameTable");
return new XmlNameTable(val);
} catch (JCNativeException jcne) {
throw translateException(jcne);
}
}
public void setNameTable(XmlNameTable NameTable) throws Throwable, system.ArgumentNullException, system.ArgumentException, system.ArgumentOutOfRangeException, system.globalization.CultureNotFoundException, system.IndexOutOfRangeException, system.PlatformNotSupportedException, system.InvalidOperationException, system.FormatException, system.xml.XmlException {
if (classInstance == null)
throw new UnsupportedOperationException("classInstance is null.");
try {
classInstance.Set("NameTable", NameTable == null ? null : NameTable.getJCOInstance());
} catch (JCNativeException jcne) {
throw translateException(jcne);
}
}
public void setXmlResolver(XmlResolver XmlResolver) throws Throwable, system.ArgumentNullException, system.ArgumentException, system.ArgumentOutOfRangeException, system.globalization.CultureNotFoundException, system.IndexOutOfRangeException, system.PlatformNotSupportedException, system.InvalidOperationException, system.FormatException, system.xml.XmlException {
if (classInstance == null)
throw new UnsupportedOperationException("classInstance is null.");
try {
classInstance.Set("XmlResolver", XmlResolver == null ? null : XmlResolver.getJCOInstance());
} catch (JCNativeException jcne) {
throw translateException(jcne);
}
}
// Instance Events section
public void addValidationEventHandler(ValidationEventHandler handler) throws Throwable {
if (classInstance == null)
throw new UnsupportedOperationException("classInstance is null.");
try {
classInstance.RegisterEventListener("ValidationEventHandler", handler);
} catch (JCNativeException jcne) {
throw translateException(jcne);
}
}
public void removeValidationEventHandler(ValidationEventHandler handler) throws Throwable {
if (classInstance == null)
throw new UnsupportedOperationException("classInstance is null.");
try {
classInstance.UnregisterEventListener("ValidationEventHandler", handler);
} catch (JCNativeException jcne) {
throw translateException(jcne);
}
}
}