@Override
    public void parseSql(String sql, SqlTree sqlTree) {
        Matcher matcher = FUNC_PATTERN.matcher(sql);
        if(matcher.find()){
            String type = matcher.group(1);
            String funcName = matcher.group(2);
            String className = matcher.group(3);
            SqlParserResult result = new SqlParserResult();
            result.setType(type);
            result.setName(funcName);
            result.setClassName(className);
            sqlTree.addFunc(result);
        }
    }
parser register udf sql
Date: 2018/6/26
Company: www.dtstack.com
@author xuchao
core/src/main/java/com/dtstack/flink/sql/parser/CreateFuncParser.java