code: public static AbstractServerPredicate ofKeyPredicate(final Predicate<PredicateKey> p) {
          return new AbstractServerPredicate() {
              @Override
              @edu.umd.cs.findbugs.annotations.SuppressWarnings(value = "NP")
              public boolean apply(PredicateKey input) {
                  return p.apply(input);
              }            
          };        
      }
docs: Create an instance from a predicate.