Class ConstantStringMapper

  • All Implemented Interfaces:
    IValueMapper

    public class ConstantStringMapper
    extends java.lang.Object
    implements IValueMapper
    Mapper that returns a constant value not depending on the input value.
    • Field Summary

      Fields 
      Modifier and Type Field Description
      protected java.lang.Object val
      The value that is returned.
    • Constructor Summary

      Constructors 
      Constructor Description
      ConstantStringMapper​(java.lang.Object val)
      Create a new mapper.
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      java.lang.Object convertValue​(java.lang.Object value)
      Convert the given value.
      • Methods inherited from class java.lang.Object

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

      • val

        protected java.lang.Object val
        The value that is returned.
    • Constructor Detail

      • ConstantStringMapper

        public ConstantStringMapper​(java.lang.Object val)
        Create a new mapper.
        Parameters:
        val - The constant value.
    • Method Detail

      • convertValue

        public java.lang.Object convertValue​(java.lang.Object value)
                                      throws java.lang.Exception
        Convert the given value.
        Specified by:
        convertValue in interface IValueMapper
        Parameters:
        value - The value to convert.
        Returns:
        The converted value.
        Throws:
        java.lang.Exception