Class NullSafeFunction<F,T>

java.lang.Object
org.jenkinsci.plugins.github.util.misc.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 Details

    • NullSafeFunction

      public NullSafeFunction()
  • Method Details

    • 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)