code: public static Function.Factory factory(final Function fun)
      {
          return new Function.Factory()
          {
              public Function create(String ksName, String cfName)
              {
                  return fun;
              }
          };
      }
docs: Creates a trivial factory that always return the provided function.