All Downloads are FREE. Search and download functionalities are using the official Maven repository.

system.web.validate.config.ValidateEngineFactory Maven / Gradle / Ivy

The newest version!
package system.web.validate.config;

import system.web.WebContext;

/**
 *
 * @author wangchunzi
 */
public class ValidateEngineFactory {

    public  JsonValidateEngineModel getJsonValidateEngineModel() {
        try {
            return WebContext.getWebContext().webConfig.validateEngine_json.newInstance();
        } catch (InstantiationException | IllegalAccessException ex) {
            System.err.println("初始化检验执行器失败:" + WebContext.getWebContext().webConfig.validateEngine_json.getName());
            return null;
        }
    }

    public  ParamValidateEngineModel getParamValidateEngineModel() {
        try {
            return WebContext.getWebContext().webConfig.validateEngine_param.newInstance();
        } catch (InstantiationException | IllegalAccessException ex) {
            System.err.println("初始化检验执行器失败:" + WebContext.getWebContext().webConfig.validateEngine_param.getName());
            return null;
        }
    }

}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy