nashorn/src/jdk/nashorn/internal/runtime/ECMAErrors.java
changeset 16275 d5d430071b22
parent 16256 f2d9a0c49914
child 19459 79e75274df99
equal deleted inserted replaced
16274:c3f35c5e0d1c 16275:d5d430071b22
    30 import java.text.MessageFormat;
    30 import java.text.MessageFormat;
    31 import java.util.Locale;
    31 import java.util.Locale;
    32 import java.util.ResourceBundle;
    32 import java.util.ResourceBundle;
    33 
    33 
    34 import jdk.nashorn.api.scripting.NashornException;
    34 import jdk.nashorn.api.scripting.NashornException;
    35 import jdk.nashorn.internal.scripts.JS$;
    35 import jdk.nashorn.internal.scripts.JS;
    36 
    36 
    37 /**
    37 /**
    38  * Helper class to throw various standard "ECMA error" exceptions such as Error, ReferenceError, TypeError etc.
    38  * Helper class to throw various standard "ECMA error" exceptions such as Error, ReferenceError, TypeError etc.
    39  */
    39  */
    40 public final class ECMAErrors {
    40 public final class ECMAErrors {
    53     }
    53     }
    54 
    54 
    55     /** We assume that compiler generates script classes into the known package. */
    55     /** We assume that compiler generates script classes into the known package. */
    56     private static final String scriptPackage;
    56     private static final String scriptPackage;
    57     static {
    57     static {
    58         String name = JS$.class.getName();
    58         String name = JS.class.getName();
    59         scriptPackage = name.substring(0, name.lastIndexOf('.'));
    59         scriptPackage = name.substring(0, name.lastIndexOf('.'));
    60     }
    60     }
    61 
    61 
    62     private ECMAErrors() {
    62     private ECMAErrors() {
    63     }
    63     }