goja-web/src/main/java/goja/mvc/render/ftl/kit/DirectiveKit.java
@SuppressWarnings("rawtypes")
    public static String getRequiredParam(Map params, String key) throws TemplateException {
        Object value = params.get(key);
        if (value == null || StringUtils.isEmpty(value.toString())) {
            throw new TemplateModelException("not found required parameter:" + key + " for directive");
        }
        return value.toString();
    }
@SuppressWarnings("rawtypes")
    public static String getRequiredParam(Map params, String key) throws TemplateException {
        Object value = params.get(key);
        if (value == null || StringUtils.isEmpty(value.toString())) {
            throw new TemplateModelException("not found required parameter:" + key + " for directive");
        }
        return value.toString();
    }
取得参数<code>params</code>中必须存在的指定Key的值，如果不存在，抛出异常

@param params 参数Map
@param key    必须存在的Key
@return 对应key的值
@throws freemarker.template.TemplateException 异常，如果key不存在params中则会出现异常