Class NullSafeFunction<F,​T>

  • All Implemented Interfaces:
    com.google.common.base.Function<F,​T>, Function<F,​T>
    Direct Known Subclasses:
    GitHubLoginFunction

    public abstract class NullSafeFunction<F,​T>
    extends Object
    implements com.google.common.base.Function<F,​T>
    This abstract class calls applyNullSafe(Object) only after success validation of inner object for null
    Author:
    lanwen (Merkushev Kirill)
    • Constructor Detail

      • NullSafeFunction

        public NullSafeFunction()
    • Method Detail

      • apply

        public T apply​(F input)
        Specified by:
        apply in interface com.google.common.base.Function<F,​T>
        Specified by:
        apply in interface Function<F,​T>
      • applyNullSafe

        protected abstract T applyNullSafe​(@NonNull
                                           F input)
        This method will be called inside of apply(Object)