Class ArenaConditionComparative
java.lang.Object
de.marcely.bedwars.api.arena.picker.condition.ArenaCondition
de.marcely.bedwars.api.arena.picker.condition.ArenaConditionComparative
Represents a basic condition persisting of a variable, an operator and the value that we are checking the variable with.
-
Constructor Summary
ConstructorDescriptionArenaConditionComparative
(ArenaConditionVariable<?> variable, ArenaConditionComparisonOperator comparisonOperator, ArenaConditionVariableValue<?> validatingValue) -
Method Summary
Modifier and TypeMethodDescriptionboolean
Checks whether the given arena fullfills the conditions or not.boolean
check
(RemoteArena arena) Checks whether the given arena fullfills the conditions or not.Returns the operator of this condition.Returns the value that we are comparing with.Returns the variable (or the variable value fetcher given by arena) of this condition.toString()
Methods inherited from class de.marcely.bedwars.api.arena.picker.condition.ArenaCondition
filterLocalArenas, filterRemoteArenas
-
Constructor Details
-
ArenaConditionComparative
public ArenaConditionComparative(ArenaConditionVariable<?> variable, ArenaConditionComparisonOperator comparisonOperator, ArenaConditionVariableValue<?> validatingValue)
-
-
Method Details
-
getVariable
Returns the variable (or the variable value fetcher given by arena) of this condition.- Returns:
- The variable
-
getComparisonOperator
Returns the operator of this condition.- Returns:
- The operator
-
getValidatingValue
Returns the value that we are comparing with.- Returns:
- The value
-
check
Description copied from class:ArenaCondition
Checks whether the given arena fullfills the conditions or not.- Specified by:
check
in classArenaCondition
- Parameters:
arena
- The local arena that is being checked- Returns:
true
in case it may pass
-
check
Description copied from class:ArenaCondition
Checks whether the given arena fullfills the conditions or not.- Specified by:
check
in classArenaCondition
- Parameters:
arena
- The remote arena that is being checked- Returns:
true
in case it may pass
-
toString
-