All Downloads are FREE. Search and download functionalities are using the official Maven repository.

microsoft.jscript.LenientGlobalObject Maven / Gradle / Ivy

/*
 *  MIT License
 *
 *  Copyright (c) 2024 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 v. 1.15.0.0
 * 
 *      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 microsoft.jscript;

import org.mases.jcobridge.*;
import org.mases.jcobridge.netreflection.*;
import java.util.ArrayList;

// Import section
import microsoft.jscript.GlobalObject;


/**
 * The base .NET class managing Microsoft.JScript.LenientGlobalObject, Microsoft.JScript, Version=10.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a.
 * 

* * .NET documentation at https://docs.microsoft.com/en-us/dotnet/api/Microsoft.JScript.LenientGlobalObject *

* * Powered by JCOBridge: more info at https://www.jcobridge.com * * @author MASES s.r.l https://masesgroup.com * @version 1.15.0.0 */ public class LenientGlobalObject extends GlobalObject { /** * Fully assembly qualified name: Microsoft.JScript, Version=10.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a */ public static final String assemblyFullName = "Microsoft.JScript, Version=10.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a"; /** * Assembly name: Microsoft.JScript */ public static final String assemblyShortName = "Microsoft.JScript"; /** * Qualified class name: Microsoft.JScript.LenientGlobalObject */ public static final String className = "Microsoft.JScript.LenientGlobalObject"; 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 LenientGlobalObject(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 LenientGlobalObject}, a cast assert is made to check if types are compatible. * @param from {@link IJCOBridgeReflected} instance to be casted * @return {@link LenientGlobalObject} instance * @throws java.lang.Throwable in case of error during cast operation */ public static LenientGlobalObject cast(IJCOBridgeReflected from) throws Throwable { NetType.AssertCast(classType, from); return new LenientGlobalObject(from.getJCOInstance()); } // Constructors section public LenientGlobalObject() throws Throwable { } // Methods section // Properties section public NetObject getActiveXObjectNewLenientGlobalObject() throws Throwable { if (classInstance == null) throw new UnsupportedOperationException("classInstance is null."); try { JCObject val = (JCObject)classInstance.Get("ActiveXObject"); return new NetObject(val); } catch (JCNativeException jcne) { throw translateException(jcne); } } public void setActiveXObject(NetObject ActiveXObject) throws Throwable { if (classInstance == null) throw new UnsupportedOperationException("classInstance is null."); try { classInstance.Set("ActiveXObject", ActiveXObject == null ? null : ActiveXObject.getJCOInstance()); } catch (JCNativeException jcne) { throw translateException(jcne); } } public NetObject getArrayNewLenientGlobalObject() throws Throwable { if (classInstance == null) throw new UnsupportedOperationException("classInstance is null."); try { JCObject val = (JCObject)classInstance.Get("Array"); return new NetObject(val); } catch (JCNativeException jcne) { throw translateException(jcne); } } public void setArray(NetObject Array) throws Throwable { if (classInstance == null) throw new UnsupportedOperationException("classInstance is null."); try { classInstance.Set("Array", Array == null ? null : Array.getJCOInstance()); } catch (JCNativeException jcne) { throw translateException(jcne); } } public NetObject getBooleanNewLenientGlobalObject() throws Throwable { if (classInstance == null) throw new UnsupportedOperationException("classInstance is null."); try { JCObject val = (JCObject)classInstance.Get("Boolean"); return new NetObject(val); } catch (JCNativeException jcne) { throw translateException(jcne); } } public void setBoolean(NetObject Boolean) throws Throwable { if (classInstance == null) throw new UnsupportedOperationException("classInstance is null."); try { classInstance.Set("Boolean", Boolean == null ? null : Boolean.getJCOInstance()); } catch (JCNativeException jcne) { throw translateException(jcne); } } public NetObject getDateNewLenientGlobalObject() throws Throwable { if (classInstance == null) throw new UnsupportedOperationException("classInstance is null."); try { JCObject val = (JCObject)classInstance.Get("Date"); return new NetObject(val); } catch (JCNativeException jcne) { throw translateException(jcne); } } public void setDate(NetObject Date) throws Throwable { if (classInstance == null) throw new UnsupportedOperationException("classInstance is null."); try { classInstance.Set("Date", Date == null ? null : Date.getJCOInstance()); } catch (JCNativeException jcne) { throw translateException(jcne); } } public NetObject getEnumeratorNewLenientGlobalObject() throws Throwable { if (classInstance == null) throw new UnsupportedOperationException("classInstance is null."); try { JCObject val = (JCObject)classInstance.Get("Enumerator"); return new NetObject(val); } catch (JCNativeException jcne) { throw translateException(jcne); } } public void setEnumerator(NetObject Enumerator) throws Throwable { if (classInstance == null) throw new UnsupportedOperationException("classInstance is null."); try { classInstance.Set("Enumerator", Enumerator == null ? null : Enumerator.getJCOInstance()); } catch (JCNativeException jcne) { throw translateException(jcne); } } public NetObject getErrorNewLenientGlobalObject() throws Throwable { if (classInstance == null) throw new UnsupportedOperationException("classInstance is null."); try { JCObject val = (JCObject)classInstance.Get("Error"); return new NetObject(val); } catch (JCNativeException jcne) { throw translateException(jcne); } } public void setError(NetObject Error) throws Throwable { if (classInstance == null) throw new UnsupportedOperationException("classInstance is null."); try { classInstance.Set("Error", Error == null ? null : Error.getJCOInstance()); } catch (JCNativeException jcne) { throw translateException(jcne); } } public NetObject getEvalErrorNewLenientGlobalObject() throws Throwable { if (classInstance == null) throw new UnsupportedOperationException("classInstance is null."); try { JCObject val = (JCObject)classInstance.Get("EvalError"); return new NetObject(val); } catch (JCNativeException jcne) { throw translateException(jcne); } } public void setEvalError(NetObject EvalError) throws Throwable { if (classInstance == null) throw new UnsupportedOperationException("classInstance is null."); try { classInstance.Set("EvalError", EvalError == null ? null : EvalError.getJCOInstance()); } catch (JCNativeException jcne) { throw translateException(jcne); } } public NetObject getFunctionNewLenientGlobalObject() throws Throwable { if (classInstance == null) throw new UnsupportedOperationException("classInstance is null."); try { JCObject val = (JCObject)classInstance.Get("Function"); return new NetObject(val); } catch (JCNativeException jcne) { throw translateException(jcne); } } public void setFunction(NetObject Function) throws Throwable { if (classInstance == null) throw new UnsupportedOperationException("classInstance is null."); try { classInstance.Set("Function", Function == null ? null : Function.getJCOInstance()); } catch (JCNativeException jcne) { throw translateException(jcne); } } public NetObject getMathNewLenientGlobalObject() throws Throwable, system.NotImplementedException, system.NotSupportedException, system.ArgumentOutOfRangeException, system.IndexOutOfRangeException, system.InvalidOperationException, system.ArgumentNullException, system.ArgumentException, system.MissingMethodException, system.reflection.TargetInvocationException { if (classInstance == null) throw new UnsupportedOperationException("classInstance is null."); try { JCObject val = (JCObject)classInstance.Get("Math"); return new NetObject(val); } catch (JCNativeException jcne) { throw translateException(jcne); } } public void setMath(NetObject Math) throws Throwable { if (classInstance == null) throw new UnsupportedOperationException("classInstance is null."); try { classInstance.Set("Math", Math == null ? null : Math.getJCOInstance()); } catch (JCNativeException jcne) { throw translateException(jcne); } } public NetObject getNumberNewLenientGlobalObject() throws Throwable { if (classInstance == null) throw new UnsupportedOperationException("classInstance is null."); try { JCObject val = (JCObject)classInstance.Get("Number"); return new NetObject(val); } catch (JCNativeException jcne) { throw translateException(jcne); } } public void setNumber(NetObject Number) throws Throwable { if (classInstance == null) throw new UnsupportedOperationException("classInstance is null."); try { classInstance.Set("Number", Number == null ? null : Number.getJCOInstance()); } catch (JCNativeException jcne) { throw translateException(jcne); } } public NetObject getObjectNewLenientGlobalObject() throws Throwable { if (classInstance == null) throw new UnsupportedOperationException("classInstance is null."); try { JCObject val = (JCObject)classInstance.Get("Object"); return new NetObject(val); } catch (JCNativeException jcne) { throw translateException(jcne); } } public void setObject(NetObject Object) throws Throwable { if (classInstance == null) throw new UnsupportedOperationException("classInstance is null."); try { classInstance.Set("Object", Object == null ? null : Object.getJCOInstance()); } catch (JCNativeException jcne) { throw translateException(jcne); } } public NetObject getRangeErrorNewLenientGlobalObject() throws Throwable { if (classInstance == null) throw new UnsupportedOperationException("classInstance is null."); try { JCObject val = (JCObject)classInstance.Get("RangeError"); return new NetObject(val); } catch (JCNativeException jcne) { throw translateException(jcne); } } public void setRangeError(NetObject RangeError) throws Throwable { if (classInstance == null) throw new UnsupportedOperationException("classInstance is null."); try { classInstance.Set("RangeError", RangeError == null ? null : RangeError.getJCOInstance()); } catch (JCNativeException jcne) { throw translateException(jcne); } } public NetObject getReferenceErrorNewLenientGlobalObject() throws Throwable { if (classInstance == null) throw new UnsupportedOperationException("classInstance is null."); try { JCObject val = (JCObject)classInstance.Get("ReferenceError"); return new NetObject(val); } catch (JCNativeException jcne) { throw translateException(jcne); } } public void setReferenceError(NetObject ReferenceError) throws Throwable { if (classInstance == null) throw new UnsupportedOperationException("classInstance is null."); try { classInstance.Set("ReferenceError", ReferenceError == null ? null : ReferenceError.getJCOInstance()); } catch (JCNativeException jcne) { throw translateException(jcne); } } public NetObject getRegExpNewLenientGlobalObject() throws Throwable { if (classInstance == null) throw new UnsupportedOperationException("classInstance is null."); try { JCObject val = (JCObject)classInstance.Get("RegExp"); return new NetObject(val); } catch (JCNativeException jcne) { throw translateException(jcne); } } public void setRegExp(NetObject RegExp) throws Throwable { if (classInstance == null) throw new UnsupportedOperationException("classInstance is null."); try { classInstance.Set("RegExp", RegExp == null ? null : RegExp.getJCOInstance()); } catch (JCNativeException jcne) { throw translateException(jcne); } } public NetObject getStringNewLenientGlobalObject() throws Throwable { if (classInstance == null) throw new UnsupportedOperationException("classInstance is null."); try { JCObject val = (JCObject)classInstance.Get("String"); return new NetObject(val); } catch (JCNativeException jcne) { throw translateException(jcne); } } public void setString(NetObject String) throws Throwable { if (classInstance == null) throw new UnsupportedOperationException("classInstance is null."); try { classInstance.Set("String", String == null ? null : String.getJCOInstance()); } catch (JCNativeException jcne) { throw translateException(jcne); } } public NetObject getSyntaxErrorNewLenientGlobalObject() throws Throwable { if (classInstance == null) throw new UnsupportedOperationException("classInstance is null."); try { JCObject val = (JCObject)classInstance.Get("SyntaxError"); return new NetObject(val); } catch (JCNativeException jcne) { throw translateException(jcne); } } public void setSyntaxError(NetObject SyntaxError) throws Throwable { if (classInstance == null) throw new UnsupportedOperationException("classInstance is null."); try { classInstance.Set("SyntaxError", SyntaxError == null ? null : SyntaxError.getJCOInstance()); } catch (JCNativeException jcne) { throw translateException(jcne); } } public NetObject getTypeErrorNewLenientGlobalObject() throws Throwable { if (classInstance == null) throw new UnsupportedOperationException("classInstance is null."); try { JCObject val = (JCObject)classInstance.Get("TypeError"); return new NetObject(val); } catch (JCNativeException jcne) { throw translateException(jcne); } } public void setTypeError(NetObject TypeError) throws Throwable { if (classInstance == null) throw new UnsupportedOperationException("classInstance is null."); try { classInstance.Set("TypeError", TypeError == null ? null : TypeError.getJCOInstance()); } catch (JCNativeException jcne) { throw translateException(jcne); } } public NetObject getURIErrorNewLenientGlobalObject() throws Throwable { if (classInstance == null) throw new UnsupportedOperationException("classInstance is null."); try { JCObject val = (JCObject)classInstance.Get("URIError"); return new NetObject(val); } catch (JCNativeException jcne) { throw translateException(jcne); } } public void setURIError(NetObject URIError) throws Throwable { if (classInstance == null) throw new UnsupportedOperationException("classInstance is null."); try { classInstance.Set("URIError", URIError == null ? null : URIError.getJCOInstance()); } catch (JCNativeException jcne) { throw translateException(jcne); } } public NetObject getVBArrayNewLenientGlobalObject() throws Throwable { if (classInstance == null) throw new UnsupportedOperationException("classInstance is null."); try { JCObject val = (JCObject)classInstance.Get("VBArray"); return new NetObject(val); } catch (JCNativeException jcne) { throw translateException(jcne); } } public void setVBArray(NetObject VBArray) throws Throwable { if (classInstance == null) throw new UnsupportedOperationException("classInstance is null."); try { classInstance.Set("VBArray", VBArray == null ? null : VBArray.getJCOInstance()); } catch (JCNativeException jcne) { throw translateException(jcne); } } // Instance Events section }





© 2015 - 2025 Weber Informatics LLC | Privacy Policy