Enum ScriptType

    • Enum Constant Detail

      • INLINE

        public static final ScriptType INLINE
        INLINE scripts are specified in numerous queries and compiled on-the-fly. They will be cached based on the lang and code of the script. They are turned off by default because most languages are insecure (Groovy and others), but can be overridden by the specific ScriptEngine if the language is naturally secure (Painless, Mustache, and Expressions).
      • STORED

        public static final ScriptType STORED
        STORED scripts are saved as part of the ClusterState based on user requests. They will be cached when they are first used in a query. They are turned off by default because most languages are insecure (Groovy and others), but can be overridden by the specific ScriptEngine if the language is naturally secure (Painless, Mustache, and Expressions).
    • Method Detail

      • values

        public static ScriptType[] values()
        Returns an array containing the constants of this enum type, in the order they are declared. This method may be used to iterate over the constants as follows:
        for (ScriptType c : ScriptType.values())
            System.out.println(c);
        
        Returns:
        an array containing the constants of this enum type, in the order they are declared
      • valueOf

        public static ScriptType valueOf​(String name)
        Returns the enum constant of this type with the specified name. The string must match exactly an identifier used to declare an enum constant in this type. (Extraneous whitespace characters are not permitted.)
        Parameters:
        name - the name of the enum constant to be returned.
        Returns:
        the enum constant with the specified name
        Throws:
        IllegalArgumentException - if this enum type has no constant with the specified name
        NullPointerException - if the argument is null
      • getId

        public int getId()
        Returns:
        The unique id for this ScriptType.
      • getParseField

        public ParseField getParseField()
        Returns:
        Specifies the name used to parse input from queries.