Class NullSafeBiMapper<F,​T>

    • Method Summary

      All Methods Instance Methods Abstract Methods Concrete Methods 
      Modifier and Type Method Description
      protected abstract F nonNullReverse​(T input)
      Maps the to type to the from type.
      F reverse​(T input)
      Maps the to type to the from type.
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
      • Methods inherited from interface nl.rkuijt.mapperlib.mapper.single.Mapper

        from
    • Constructor Detail

      • NullSafeBiMapper

        public NullSafeBiMapper()
    • Method Detail

      • reverse

        public final F reverse​(T input)
        Maps the to type to the from type. Does not pass null references to the mapping method.
        Specified by:
        reverse in interface BiMapper<F,​T>
        Parameters:
        input - to object.
        Returns:
        from object. null if input is null.
      • nonNullReverse

        protected abstract F nonNullReverse​(T input)
        Maps the to type to the from type.
        Parameters:
        input - to object.
        Returns:
        from object.
        See Also:
        BiMapper.reverse(Object)