Package ch.njol.skript.lang.function
Class Parameter<T>
java.lang.Object
ch.njol.skript.lang.function.Parameter<T>
- All Implemented Interfaces:
Parameter<T>
@Deprecated(forRemoval=true,
since="2.14")
public final class Parameter<T>
extends Object
implements Parameter<T>
Deprecated, for removal: This API element is subject to removal in a future version.
-
Nested Class Summary
Nested classes/interfaces inherited from interface org.skriptlang.skript.common.function.Parameter
Parameter.Modifier -
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final PatternDeprecated, for removal: This API element is subject to removal in a future version. -
Constructor Summary
ConstructorsConstructorDescriptionDeprecated, for removal: This API element is subject to removal in a future version.Parameter(String name, ClassInfo<T> type, boolean single, @Nullable Expression<? extends T> def, boolean keyed) Deprecated, for removal: This API element is subject to removal in a future version.Parameter(String name, ClassInfo<T> type, boolean single, @Nullable Expression<? extends T> def, boolean keyed, boolean optional) Deprecated, for removal: This API element is subject to removal in a future version. -
Method Summary
Modifier and TypeMethodDescriptionbooleanDeprecated, for removal: This API element is subject to removal in a future version.@Nullable Expression<? extends T> Deprecated, for removal: This API element is subject to removal in a future version.Get the Expression that will be used to provide the default value of this parameter when the function is called.getName()Deprecated, for removal: This API element is subject to removal in a future version.Usename()instead.getType()Deprecated, for removal: This API element is subject to removal in a future version.Usetype()instead.booleanDeprecated, for removal: This API element is subject to removal in a future version.Returns whether this parameter is optional or not.booleanisSingle()Deprecated, for removal: This API element is subject to removal in a future version.booleanDeprecated, for removal: This API element is subject to removal in a future version.Get whether this parameter takes one or many values.@Unmodifiable @NotNull Set<Parameter.Modifier> Deprecated, for removal: This API element is subject to removal in a future version.@NotNull Stringname()Deprecated, for removal: This API element is subject to removal in a future version.static <T> @Nullable Parameter<T> newInstance(String name, ClassInfo<T> type, boolean single, @Nullable String def) Deprecated, for removal: This API element is subject to removal in a future version.UseScriptParameter.parse(String, Class, String)} instead.Deprecated, for removal: This API element is subject to removal in a future version.Useinstead.invalid reference
ch.njol.skript.structures.StructFunction.FunctionParser#parse(String, String, String, String, boolean)toString()Deprecated, for removal: This API element is subject to removal in a future version.toString(boolean debug) Deprecated, for removal: This API element is subject to removal in a future version.type()Deprecated, for removal: This API element is subject to removal in a future version.Methods inherited from class java.lang.Object
clone, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitMethods inherited from interface org.skriptlang.skript.common.function.Parameter
evaluate, getModifier, hasModifier, single
-
Field Details
-
PARAM_PATTERN
Deprecated, for removal: This API element is subject to removal in a future version.
-
-
Constructor Details
-
Parameter
@Deprecated(since="2.13", forRemoval=true) public Parameter(String name, ClassInfo<T> type, boolean single, @Nullable @Nullable Expression<? extends T> def) Deprecated, for removal: This API element is subject to removal in a future version. -
Parameter
@Deprecated(since="2.13", forRemoval=true) public Parameter(String name, ClassInfo<T> type, boolean single, @Nullable @Nullable Expression<? extends T> def, boolean keyed) Deprecated, for removal: This API element is subject to removal in a future version. -
Parameter
@Deprecated(since="2.13", forRemoval=true) public Parameter(String name, ClassInfo<T> type, boolean single, @Nullable @Nullable Expression<? extends T> def, boolean keyed, boolean optional) Deprecated, for removal: This API element is subject to removal in a future version.
-
-
Method Details
-
isOptional
public boolean isOptional()Deprecated, for removal: This API element is subject to removal in a future version.Returns whether this parameter is optional or not.- Returns:
- Whether this parameter is optional or not.
-
getType
Deprecated, for removal: This API element is subject to removal in a future version.Usetype()instead. -
newInstance
@Deprecated(forRemoval=true, since="2.14") @Nullable public static <T> @Nullable Parameter<T> newInstance(String name, ClassInfo<T> type, boolean single, @Nullable @Nullable String def) Deprecated, for removal: This API element is subject to removal in a future version.UseScriptParameter.parse(String, Class, String)} instead. -
parse
@Deprecated(forRemoval=true, since="2.14") @Nullable public static @Nullable List<Parameter<?>> parse(String args) Deprecated, for removal: This API element is subject to removal in a future version.Useinstead.invalid reference
ch.njol.skript.structures.StructFunction.FunctionParser#parse(String, String, String, String, boolean) -
getName
Deprecated, for removal: This API element is subject to removal in a future version.Usename()instead. -
getDefaultExpression
Deprecated, for removal: This API element is subject to removal in a future version.Get the Expression that will be used to provide the default value of this parameter when the function is called.- Returns:
- Expression that will provide default value of this parameter
-
isSingleValue
public boolean isSingleValue()Deprecated, for removal: This API element is subject to removal in a future version.Get whether this parameter takes one or many values.- Returns:
- True if this parameter takes one value, false otherwise
-
equals
Deprecated, for removal: This API element is subject to removal in a future version. -
toString
Deprecated, for removal: This API element is subject to removal in a future version. -
toString
Deprecated, for removal: This API element is subject to removal in a future version. -
name
Deprecated, for removal: This API element is subject to removal in a future version. -
type
Deprecated, for removal: This API element is subject to removal in a future version. -
modifiers
Deprecated, for removal: This API element is subject to removal in a future version. -
isSingle
public boolean isSingle()Deprecated, for removal: This API element is subject to removal in a future version.
-
ScriptParameterorDefaultFunction.Builder.parameter(String, Class, Modifier...)instead.