Esempio n. 1
0
    @Override
    public ReturnState containFunction(RpcController controller, ContainFunctionRequest request) {

      try {
        boolean returnValue;
        if (request.hasFunctionType()) {
          returnValue =
              containFunction(
                  request.getSignature(),
                  request.getFunctionType(),
                  request.getParameterTypesList());
        } else {
          returnValue = containFunction(request.getSignature(), request.getParameterTypesList());
        }

        return returnValue
            ? OK
            : errUndefinedFunction(
                buildSimpleFunctionSignature(
                    request.getSignature(), request.getParameterTypesList()));

      } catch (Throwable t) {
        printStackTraceIfError(LOG, t);
        return returnError(t);
      }
    }
Esempio n. 2
0
 public static FunctionSignature create(ContainFunctionRequest proto) {
   return new FunctionSignature(
       proto.getSignature(), proto.getFunctionType(), proto.getParameterTypesList());
 }