Class ScriptAbuseException
java.lang.Object
java.lang.Throwable
java.lang.Exception
java.lang.RuntimeException
delight.nashornsandbox.exceptions.ScriptAbuseException
- All Implemented Interfaces:
Serializable
- Direct Known Subclasses:
ScriptCPUAbuseException
,ScriptMemoryAbuseException
Exception is thrown when JS script abuse was detected.
Created on 2017.11.24
- Version:
- $Id$
- See Also:
-
Field Summary
FieldsModifier and TypeFieldDescriptionprivate final boolean
private static final long
-
Constructor Summary
ConstructorsConstructorDescriptionScriptAbuseException
(String message, boolean scriptKilled, Throwable throwable) -
Method Summary
Modifier and TypeMethodDescriptionboolean
Check if script when asked exited nicely, or not.Methods inherited from class java.lang.Throwable
addSuppressed, fillInStackTrace, getCause, getLocalizedMessage, getStackTrace, getSuppressed, initCause, printStackTrace, printStackTrace, printStackTrace, setStackTrace, toString
-
Field Details
-
serialVersionUID
private static final long serialVersionUID- See Also:
-
scriptKilled
private final boolean scriptKilled
-
-
Constructor Details
-
ScriptAbuseException
-
-
Method Details
-
isScriptKilled
public boolean isScriptKilled()Check if script when asked exited nicely, or not.Note, killint java thread is very dangerous to VM health.
- Returns:
true
when evaluator thread was finished byThread.stop()
method,false
when onlyThread.interrupt()
was used
-
getMessage
- Overrides:
getMessage
in classThrowable
-