Class AutoValidator<G extends GameObject<G,A,R>,A extends MapArchObject<A>,R extends Archetype<G,A,R>>
- java.lang.Object
-
- net.sf.gridarta.gui.autovalidator.AutoValidator<G,A,R>
-
public class AutoValidator<G extends GameObject<G,A,R>,A extends MapArchObject<A>,R extends Archetype<G,A,R>> extends java.lang.ObjectImplements the auto-validator for map validation. It tracks changes to maps, then asynchronously re-runs the map validator.
-
-
Constructor Summary
Constructors Constructor Description AutoValidator(@NotNull DelegatingMapValidator<G,A,R> validators, boolean autoDefault, @NotNull DelayedMapModelListenerManager<G,A,R> delayedMapModelListenerManager)Creates a new instance.
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static booleanisEnabled()Returns whether the auto-validator is enabled.static voidsetEnabled(boolean enabled)Set whether the auto-validator is enabled.
-
-
-
Constructor Detail
-
AutoValidator
public AutoValidator(@NotNull @NotNull DelegatingMapValidator<G,A,R> validators, boolean autoDefault, @NotNull @NotNull DelayedMapModelListenerManager<G,A,R> delayedMapModelListenerManager)Creates a new instance.- Parameters:
validators- the map validatorsautoDefault- whether the auto-validator is enabled by defaultdelayedMapModelListenerManager- the delayed map model listener manager to use
-
-
Method Detail
-
isEnabled
public static boolean isEnabled()
Returns whether the auto-validator is enabled.- Returns:
- whether the auto-validator is enabled
-
setEnabled
public static void setEnabled(boolean enabled)
Set whether the auto-validator is enabled.- Parameters:
enabled- whether the auto-validator is enabled
-
-