Class FieldSupplierBuilder.NameFieldSupplier<T>

  • All Implemented Interfaces:
    java.util.concurrent.Callable<T>
    Enclosing class:
    FieldSupplierBuilder

    public class FieldSupplierBuilder.NameFieldSupplier<T>
    extends java.lang.Object
    implements java.util.concurrent.Callable<T>
    • Field Summary

      Fields 
      Modifier and Type Field Description
      private java.lang.reflect.Field foundField  
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      java.util.concurrent.Callable<T> andWithName​(java.lang.String fieldName)
      Find a field based on the type and name.
      T call()  
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Field Detail

      • foundField

        private final java.lang.reflect.Field foundField
    • Constructor Detail

      • NameFieldSupplier

        public NameFieldSupplier()
    • Method Detail

      • andWithName

        public java.util.concurrent.Callable<T> andWithName​(java.lang.String fieldName)
        Find a field based on the type and name. E.g.

         

        await().until(fieldIn(object).ofType(int.class).andWithName("fieldName"), equalTo(2));
        Parameters:
        fieldName - The name of the field
        Returns:
        The supplier
      • call

        public T call()
               throws java.lang.Exception
        Specified by:
        call in interface java.util.concurrent.Callable<T>
        Throws:
        java.lang.Exception