public static SessionState.ResourceType getResourceType(ResourceType rt) {
    switch (rt) {
    case JAR:
      return SessionState.ResourceType.JAR;
    case FILE:
      return SessionState.ResourceType.FILE;
    case ARCHIVE:
      return SessionState.ResourceType.ARCHIVE;
    default:
      throw new AssertionError("Unexpected resource type " + rt);
    }
  }
Extracts the UDAFE evaluators of the specified class from the provided aggregations.
ql/src/java/org/apache/hadoop/hive/ql/exec/FunctionUtils.java