@@ -41,7 +41,7 @@ public enum ScriptType implements Writeable {
41
41
* (Groovy and others), but can be overridden by the specific {@link ScriptEngine}
42
42
* if the language is naturally secure (Painless, Mustache, and Expressions).
43
43
*/
44
- INLINE ( 0 , new ParseField ("source" , "inline" ) , false ),
44
+ INLINE ( 0 , new ParseField ("source" , "inline" )),
45
45
46
46
/**
47
47
* STORED scripts are saved as part of the {@link org.elasticsearch.cluster.ClusterState}
@@ -50,7 +50,7 @@ public enum ScriptType implements Writeable {
50
50
* (Groovy and others), but can be overridden by the specific {@link ScriptEngine}
51
51
* if the language is naturally secure (Painless, Mustache, and Expressions).
52
52
*/
53
- STORED ( 1 , new ParseField ("id" , "stored" ) , false );
53
+ STORED ( 1 , new ParseField ("id" , "stored" ));
54
54
55
55
/**
56
56
* Reads an int from the input stream and converts it to a {@link ScriptType}.
@@ -73,18 +73,15 @@ public static ScriptType readFrom(StreamInput in) throws IOException {
73
73
74
74
private final int id ;
75
75
private final ParseField parseField ;
76
- private final boolean defaultEnabled ;
77
76
78
77
/**
79
78
* Standard constructor.
80
79
* @param id A unique identifier for a type that can be read/written to a stream.
81
80
* @param parseField Specifies the name used to parse input from queries.
82
- * @param defaultEnabled Whether or not a {@link ScriptType} can be run by default.
83
81
*/
84
- ScriptType (int id , ParseField parseField , boolean defaultEnabled ) {
82
+ ScriptType (int id , ParseField parseField ) {
85
83
this .id = id ;
86
84
this .parseField = parseField ;
87
- this .defaultEnabled = defaultEnabled ;
88
85
}
89
86
90
87
public void writeTo (StreamOutput out ) throws IOException {
@@ -112,14 +109,6 @@ public ParseField getParseField() {
112
109
return parseField ;
113
110
}
114
111
115
- /**
116
- * @return Whether or not a {@link ScriptType} can be run by default. Note
117
- * this can be potentially overridden by any {@link ScriptEngine}.
118
- */
119
- public boolean isDefaultEnabled () {
120
- return defaultEnabled ;
121
- }
122
-
123
112
/**
124
113
* @return The same as calling {@link #getName()}.
125
114
*/
0 commit comments