Class WXYZHandler<Type,ValueType>
java.lang.Object
org.skriptlang.skript.lang.properties.handlers.WXYZHandler<Type,ValueType>
- Type Parameters:
Type- The type of the property holderValueType- The type of the value returned
- All Implemented Interfaces:
ExpressionPropertyHandler<Type,,ValueType> PropertyHandler<Type>
public abstract class WXYZHandler<Type,ValueType>
extends Object
implements ExpressionPropertyHandler<Type,ValueType>
A handler for types that have W, X, Y, or Z axes.
Since this handler contains state information (see the axis field), the newInstance method
must be implemented to return a new instance of the handler with the same axis set.
- See Also:
-
Nested Class Summary
Nested Classes -
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionaxis()voidaxis(WXYZHandler.Axis axis) Sets the specific axis for this handler to use.abstract PropertyHandler<Type> Creates a new instance of this handler.abstract booleansupportsAxis(WXYZHandler.Axis axis) Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface org.skriptlang.skript.lang.properties.handlers.base.ExpressionPropertyHandler
acceptChange, change, convert, possibleReturnTypes, requiresSourceExprChange, returnTypeMethods inherited from interface org.skriptlang.skript.lang.properties.handlers.base.PropertyHandler
init
-
Field Details
-
axis
-
-
Constructor Details
-
WXYZHandler
public WXYZHandler()
-
-
Method Details
-
newInstance
Description copied from interface:PropertyHandlerCreates a new instance of this handler. If a handler does not need to store state, it can simply returnthis. If a handler needs to store state, it **MUST** return a new instance of itself. Seefor an example of a stateful handler.invalid reference
ScriptClassInfo.ScriptNameHandler- Specified by:
newInstancein interfacePropertyHandler<Type>- Returns:
- A new instance of this handler, or
thisif no state is stored.
-
supportsAxis
- Returns:
- Whether this handler supports the given axis
-
axis
Sets the specific axis for this handler to use.- Parameters:
axis- The axis to set
-
axis
- Returns:
- The axis this handler is using
-