Class AbstractObjectConditions<T>

java.lang.Object
io.fluentlenium.core.conditions.AbstractObjectConditions<T>
Type Parameters:
T - type of condition
All Implemented Interfaces:
Conditions<T>, ConditionsObject<T>
Direct Known Subclasses:
DynamicIntegerConditionsImpl, IntegerConditionsImpl, RectangleConditionsImpl, StringConditionsImpl, WebElementConditions

public abstract class AbstractObjectConditions<T> extends Object implements Conditions<T>, ConditionsObject<T>
Abstract implementation supported negation and instantiation.
  • Field Details

    • object

      protected final T object
    • negation

      protected boolean negation
  • Constructor Details

    • AbstractObjectConditions

      public AbstractObjectConditions (T object)
      Initialize the conditions with given object.
      Parameters:
      object - underlying object
    • AbstractObjectConditions

      public AbstractObjectConditions (T object, boolean negation)
      Initialize the conditions with given object
      Parameters:
      object - underlying object
      negation - negation value
  • Method Details

    • verify

      public boolean verify (Predicate<T> predicate)
      Description copied from interface: Conditions
      Check that the given predicate is verified against this condition object.
      Specified by:
      verify in interface Conditions<T>
      Parameters:
      predicate - predicate to check
      Returns:
      true if the predicated is checked, false otherwise
    • getActualObject

      public T getActualObject()
      Description copied from interface: ConditionsObject
      Get the actual object.
      Specified by:
      getActualObject in interface ConditionsObject<T>
      Returns:
      actual object on which conditions are performed.
    • newInstance

      protected abstract AbstractObjectConditions<T> newInstance (boolean negationValue)
      Creates a new instance of this condition.
      Parameters:
      negationValue - negation value
      Returns:
      new instance of this condition
    • not

      public AbstractObjectConditions<T> not()
      Description copied from interface: Conditions
      Negates this condition object.
      Specified by:
      not in interface Conditions<T>
      Returns:
      a negated condition object