Class AbstractBooleanProperty
java.lang.Object
com.pixelmonmod.pixelmon.battles.api.rules.property.type.AbstractBooleanProperty
- All Implemented Interfaces:
BattleProperty<Boolean>
- Direct Known Subclasses:
BooleanBattleProperty,ExitableProperty,FullHealProperty,NoCritsProperty,RaiseToCapProperty,TeamPreviewProperty
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionGets the default value when not supplied If returning an empty optional this means it isn't always requiredGets a new instanceof thePropertyValue<T>Attempts to parse the object into aPropertyValue<T>Will returnOptional.empty()if fails to parseMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface com.pixelmonmod.pixelmon.battles.api.rules.BattleProperty
getId, requiredByClient
-
Constructor Details
-
AbstractBooleanProperty
public AbstractBooleanProperty()
-
-
Method Details
-
parse
Description copied from interface:BattlePropertyAttempts to parse the object into aPropertyValue<T>Will returnOptional.empty()if fails to parse- Specified by:
parsein interfaceBattleProperty<Boolean>- Parameters:
o- The object being parsed- Returns:
- The optional
PropertyValue<T>
-
getDefault
Description copied from interface:BattlePropertyGets the default value when not supplied If returning an empty optional this means it isn't always required- Specified by:
getDefaultin interfaceBattleProperty<Boolean>- Returns:
- The default
Optional<PropertyValue<T>>
-
getInstance
Description copied from interface:BattlePropertyGets a new instanceof thePropertyValue<T>- Specified by:
getInstancein interfaceBattleProperty<Boolean>- Returns:
- The new value instance
-