Class IntegerValueExtractor

java.lang.Object
microsim.reflection.AbstractValueExtractor
microsim.reflection.IntegerValueExtractor

public class IntegerValueExtractor extends AbstractValueExtractor
Employs Java reflection to call objects' methods which return integer values.
  • Constructor Details

  • Method Details

    • getInt

      public int getInt(@NonNull @NonNull Object target)
      Invoke the method of the target object and return its integer result.
      Parameters:
      target - Object to be invoked.
      Returns:
      The requested integer value.
    • getInt

      public int getInt()
      Invoke the method of the object passed to constructor and return its integer result.
      Returns:
      The requested integer value.
    • getIntValue

      public int getIntValue(int ignoredValueID)
      This is an implementation of the IntSource interface. It calls the getInt() method.
      Parameters:
      ignoredValueID - This parameter is ignored. It is put for compatibility with the IntSource interface.
      Returns:
      The requested integer value.
    • getCollectionValue

      public int @NonNull [] getCollectionValue(@NonNull @NonNull Collection<?> c)