Class EmptyParamValue

java.lang.Object
io.higson.runtime.core.EmptyParamValue
All Implemented Interfaces:
ParamValue, Iterable<MultiValue>

public class EmptyParamValue extends Object implements ParamValue
This class represents empty parameter's value. It is mostly used, when engine HigsonEngine is defined in a way that, it should never return null for missing parameter's value. The usage of this class depends on setup done through HigsonEngineFactory.setValueNeverNull(boolean) set to true.

Most values will be either null, 0, true.

Author:
przemek hertel
See Also:
  • Constructor Details

    • EmptyParamValue

      public EmptyParamValue()
  • Method Details

    • row

      public MultiValue row(int rowNo)
      Always returns null.
      Specified by:
      row in interface ParamValue
      Parameters:
      rowNo - row index
      Returns:
      null
    • row

      public MultiValue row()
      Always returns null.
      Specified by:
      row in interface ParamValue
      Returns:
      null
    • rows

      public List<MultiValue> rows()
      Returns empty list of rows.
      Specified by:
      rows in interface ParamValue
      Returns:
      empty list
    • getHolder

      public ValueHolder getHolder(int rowNo, int colNo)
      Always returns null.
      Specified by:
      getHolder in interface ParamValue
      Parameters:
      rowNo - row index
      colNo - column index
      Returns:
      null
    • get

      public <T> T get(int rowNo, int colNo)
      Always returns null.
      Specified by:
      get in interface ParamValue
      Type Parameters:
      T - type of return value, but it doesn't matter since it returns null
      Parameters:
      rowNo - row index
      colNo - column index
      Returns:
      null
    • get

      public <T> T get(int rowNo, int colNo, Class<T> clazz)
      Always returns null.
      Specified by:
      get in interface ParamValue
      Type Parameters:
      T - type of return value, but it doesn't matter since it returns null
      Parameters:
      rowNo - row index
      colNo - column index
      clazz - class of return object, but it doesn't matter since it returns null
      Returns:
      null
    • getHolder

      public ValueHolder getHolder(int rowNo, String name)
      Always returns null.
      Specified by:
      getHolder in interface ParamValue
      Parameters:
      rowNo - row index
      name - level name as column indicator
      Returns:
      null
    • get

      public <T> T get(int rowNo, String name)
      Always returns null.
      Specified by:
      get in interface ParamValue
      Type Parameters:
      T - type of return value, but it doesn't matter since it returns null
      Parameters:
      rowNo - row index
      name - level name as column indicator
      Returns:
      null
    • get

      public <T> T get(int rowNo, String name, Class<T> clazz)
      Always returns null.
      Specified by:
      get in interface ParamValue
      Type Parameters:
      T - type of return value, but it doesn't matter since it returns null
      Parameters:
      rowNo - row index
      name - level name as column indicator
      clazz - class of return object, but it doesn't matter since it returns null
      Returns:
      null
    • getHolder

      public ValueHolder getHolder(int colNo)
      Always returns null.
      Specified by:
      getHolder in interface ParamValue
      Parameters:
      colNo - column index
      Returns:
      null
    • get

      public <T> T get(int colNo)
      Always returns null.
      Specified by:
      get in interface ParamValue
      Type Parameters:
      T - type of return value, but it doesn't matter since it returns null
      Parameters:
      colNo - column index
      Returns:
      null
    • get

      public <T> T get(int colNo, Class<T> clazz)
      Always returns null.
      Specified by:
      get in interface ParamValue
      Type Parameters:
      T - type of return value, but it doesn't matter since it returns null
      Parameters:
      colNo - column index
      clazz - class of return object, but it doesn't matter since it returns null
      Returns:
      null
    • getHolder

      public ValueHolder getHolder(String name)
      Always returns null.
      Specified by:
      getHolder in interface ParamValue
      Parameters:
      name - level name as column indicator
      Returns:
      null
    • get

      public <T> T get(String name)
      Always returns null.
      Specified by:
      get in interface ParamValue
      Type Parameters:
      T - type of return value, but it doesn't matter since it returns null
      Parameters:
      name - level name as column indicator
      Returns:
      null
    • get

      public <T> T get(String name, Class<T> clazz)
      Always returns null.
      Specified by:
      get in interface ParamValue
      Type Parameters:
      T - type of return value, but it doesn't matter since it returns null
      Parameters:
      name - level name as column indicator
      clazz - class of return object, but it doesn't matter since it returns null
      Returns:
      null
    • getString

      public String getString(String name)
      Always returns null.
      Specified by:
      getString in interface ParamValue
      Parameters:
      name - level name as column indicator
      Returns:
      null
    • getBigDecimal

      public BigDecimal getBigDecimal(String name)
      Always returns null.
      Specified by:
      getBigDecimal in interface ParamValue
      Parameters:
      name - level name as column indicator
      Returns:
      null
    • getDate

      public Date getDate(String name)
      Always returns null.
      Specified by:
      getDate in interface ParamValue
      Parameters:
      name - level name as column indicator
      Returns:
      null
    • getDatetime

      public Date getDatetime(String name)
      Always returns null.
      Specified by:
      getDatetime in interface ParamValue
      Parameters:
      name - level name as column indicator
      Returns:
      null
    • getLocalDate

      public LocalDate getLocalDate(String name)
      Always returns null.
      Specified by:
      getLocalDate in interface ParamValue
      Parameters:
      name - level name as column indicator
      Returns:
      null
    • getLocalDatetime

      public LocalDateTime getLocalDatetime(String name)
      Always returns null.
      Specified by:
      getLocalDatetime in interface ParamValue
      Parameters:
      name - level name as column indicator
      Returns:
      null
    • getInteger

      public Integer getInteger(String name)
      Always returns null.
      Specified by:
      getInteger in interface ParamValue
      Parameters:
      name - level name as column indicator
      Returns:
      null
    • getLong

      public Long getLong(String name)
      Always returns null.
      Specified by:
      getLong in interface ParamValue
      Parameters:
      name - level name as column indicator
      Returns:
      null
    • getBoolean

      public Boolean getBoolean(String name)
      Always returns null.
      Specified by:
      getBoolean in interface ParamValue
      Parameters:
      name - level name as column indicator
      Returns:
      null
    • getEnum

      public <T extends Enum<T>> T getEnum(String name, Class<T> enumClass)
      Always returns null.
      Specified by:
      getEnum in interface ParamValue
      Type Parameters:
      T - type of return value, but it doesn't matter since it returns null
      Parameters:
      name - level name as column indicator
      enumClass - enum of return object, but it doesn't matter since it returns null
      Returns:
      null
    • getEnumSet

      public <T extends Enum<T>> Set<T> getEnumSet(String name, Class<T> enumClass)
      Specified by:
      getEnumSet in interface ParamValue
      Type Parameters:
      T - type of return value
      Parameters:
      name - level name as column indicator
      enumClass - enum of return object
      Returns:
      empty set
    • getHolder

      public ValueHolder getHolder()
      Always returns null.
      Specified by:
      getHolder in interface ParamValue
      Returns:
      null
    • get

      public <T> T get()
      Always returns null.
      Specified by:
      get in interface ParamValue
      Type Parameters:
      T - type of return value, but it doesn't matter since it returns null
      Returns:
      null
    • get

      public <T> T get(Class<T> clazz)
      Always returns null.
      Specified by:
      get in interface ParamValue
      Type Parameters:
      T - type of return value, but it doesn't matter since it returns null
      Parameters:
      clazz - class of return object, but it doesn't matter since it returns null
      Returns:
      null
    • getString

      public String getString()
      Always returns null.
      Specified by:
      getString in interface ParamValue
      Returns:
      null
    • getBigDecimal

      public BigDecimal getBigDecimal()
      Always returns null.
      Specified by:
      getBigDecimal in interface ParamValue
      Returns:
      null
    • getDate

      public Date getDate()
      Always returns null.
      Specified by:
      getDate in interface ParamValue
      Returns:
      null
    • getDatetime

      public Date getDatetime()
      Always returns null.
      Specified by:
      getDatetime in interface ParamValue
      Returns:
      null
    • getLocalDate

      public LocalDate getLocalDate()
      Always returns null.
      Specified by:
      getLocalDate in interface ParamValue
      Returns:
      null
    • getLocalDatetime

      public LocalDateTime getLocalDatetime()
      Always returns null.
      Specified by:
      getLocalDatetime in interface ParamValue
      Returns:
      null
    • getInteger

      public Integer getInteger()
      Always returns null.
      Specified by:
      getInteger in interface ParamValue
      Returns:
      null
    • getLong

      public Long getLong()
      Always returns null.
      Specified by:
      getLong in interface ParamValue
      Returns:
      null
    • getEnum

      public <T extends Enum<T>> T getEnum(Class<T> enumClass)
      Always returns null.
      Specified by:
      getEnum in interface ParamValue
      Type Parameters:
      T - type of return value, but it doesn't matter since it returns null
      Parameters:
      enumClass - enum of return object, but it doesn't matter since it returns null
      Returns:
      null
    • getEnumSet

      public <T extends Enum<T>> Set<T> getEnumSet(Class<T> enumClass)
      Specified by:
      getEnumSet in interface ParamValue
      Type Parameters:
      T - type
      Parameters:
      enumClass - enum of return object
      Returns:
      empty set
    • size

      public int size()
      Always return 0.
      Specified by:
      size in interface ParamValue
      Returns:
      size of 0
    • getMetadata

      public Object getMetadata()
      Always returns null.
      Specified by:
      getMetadata in interface ParamValue
      Returns:
      null
    • getBoolean

      public Boolean getBoolean()
      Always returns null.
      Specified by:
      getBoolean in interface ParamValue
      Returns:
      null
    • isEmpty

      public boolean isEmpty()
      Always returns true.
      Specified by:
      isEmpty in interface ParamValue
      Returns:
      true
    • isBlank

      public boolean isBlank()
      Always returns true.
      Specified by:
      isBlank in interface ParamValue
      Returns:
      true
    • stream

      public Stream<MultiValue> stream()
      Specified by:
      stream in interface ParamValue
      Returns:
      always returns empty Stream
    • iterator

      public Iterator<MultiValue> iterator()
      Always returns iterator of empty list.
      Specified by:
      iterator in interface Iterable<MultiValue>
      Returns:
      instance of Iterator<MultiValue>
      See Also: