UnderprivilegeException CLASS

The exception due to the script running without required privilege to get access to certain system or platform resources. Such access can be denied by either the scripting engine or the underlying platform.

When instantiating an engine instance, the user may explicitly set platform access control in the form of a tuple: <bool: allowOrDeny, string category, string operation>. If started without any setting, the engine will have unrestricted access, but still be subject to the regulation by the platform beneath, such as JVM's Security Manager.

For more details on access control, see here.

Parent Class

All Members


TypeNameSignature
constructorUnderprivilegeExceptionpublic UnderprivilegeException(string)
constructorUnderprivilegeExceptionpublic UnderprivilegeException(System.HostingPlatformException)
methodisCausedByPlatformpublic bool isCausedByPlatform()

Constructors


public UnderprivilegeException(string msg)

Create an instance of UnderprivilegeException with specified category and operation name.

Parameters

  • msg The message for this exception.

public UnderprivilegeException(HostingPlatformException ex)

Create an instance of UnderprivilegeException with specified platform-born exception.

Parameters

  • ex The exception thrown by the platform due to access denied to system resources.

Methods


public bool isCausedByPlatform()

Check whether the exception was caused by the platform or the engine.

Returns

  • True if it's caused by the platform, false the engine.