Examples of ValidationConfig


Examples of org.vfny.geoserver.config.validation.ValidationConfig

    private Set plugInNames;
   
    public void reset(ActionMapping arg0, HttpServletRequest request) {
        super.reset(arg0, request);
       
        ValidationConfig validationConfig = (ValidationConfig) this.getServlet().getServletContext().getAttribute(ValidationConfig.CONFIG_KEY);
        plugInConfigs = validationConfig.getPlugIns().values();
        plugInNames = validationConfig.getPlugInNames();
       
        newName ="";
    }
View Full Code Here

Examples of org.vfny.geoserver.config.validation.ValidationConfig

        return errors;
    }
   
    public SortedSet getTests() {
        ServletContext context = this.getServlet().getServletContext();
        ValidationConfig validationConfig = (ValidationConfig) context.getAttribute(ValidationConfig.CONFIG_KEY);
        TestSuiteConfig suiteConfig = (TestSuiteConfig) request.getSession().getAttribute(TestSuiteConfig.CURRENTLY_SELECTED_KEY);
        return new TreeSet(suiteConfig.getTests().keySet());
    }
View Full Code Here

Examples of org.vfny.geoserver.config.validation.ValidationConfig

    }   
   
    public SortedSet getTestSuites(){
      try{
        ServletContext context = getServlet().getServletContext();
        ValidationConfig validationConfig = (ValidationConfig) context.getAttribute(ValidationConfig.CONFIG_KEY);
        if(validationConfig!=null && validationConfig.getTestSuiteNames()!=null)
          return new TreeSet(validationConfig.getTestSuiteNames());
      }catch(Exception e){
        e.printStackTrace();
      }
        return new TreeSet();
    }
View Full Code Here

Examples of org.vfny.geoserver.config.validation.ValidationConfig

        sc.setAttribute(WFSConfig.CONFIG_KEY, new WFSConfig((WFSDTO)wfs.toDTO()));
        sc.setAttribute(GlobalConfig.CONFIG_KEY,
            new GlobalConfig((GeoServerDTO)wfs.getGeoServer().toDTO()));
        sc.setAttribute(DataConfig.CONFIG_KEY, new DataConfig((DataDTO)wfs.getData().toDTO()));
       
        ValidationConfig vc = null;
    try{
      vc = new ValidationConfig((Map)wfs.getValidation().toPlugInDTO(), (Map)wfs.getValidation().toTestSuiteDTO());
    }catch(Exception e){
      //load error
      vc = new ValidationConfig();
    }
        sc.setAttribute(ValidationConfig.CONFIG_KEY, vc);
    }
View Full Code Here

Examples of org.vfny.geoserver.config.validation.ValidationConfig

            oldThread.stop(); //This is decprecated, but is there another way to stop a Runnable?
        }
    } else {
     
        ServletContext context = this.getServlet().getServletContext();
        ValidationConfig validationConfig = (ValidationConfig) context.getAttribute(ValidationConfig.CONFIG_KEY);
        TestSuiteConfig suiteConfig = (TestSuiteConfig) request.getSession().getAttribute(TestSuiteConfig.CURRENTLY_SELECTED_KEY);
        Map plugins = new HashMap();
        Map testSuites = new HashMap();
        validationConfig.toDTO(plugins,testSuites); // return by ref.
        TestValidationResults results = new TestValidationResults();
        try {
          ValidationRunnable testThread = new ValidationRunnable(request);
          testThread.setup(results, getDataConfig().toRepository(context), plugins, testSuites);
         
View Full Code Here

Examples of org.vfny.geoserver.config.validation.ValidationConfig

       
        TestSuiteConfig suiteConfig = new TestSuiteConfig();
        suiteConfig.setName(newName);

        ServletContext context = this.getServlet().getServletContext();
        ValidationConfig validationConfig = (ValidationConfig) context.getAttribute(ValidationConfig.CONFIG_KEY);
        validationConfig.addTestSuite(suiteConfig);
       
        request.getSession().setAttribute(TestSuiteConfig.CURRENTLY_SELECTED_KEY, suiteConfig);
       
        return mapping.findForward("validationTest");           
    }
View Full Code Here

Examples of org.vfny.geoserver.config.validation.ValidationConfig

        String description = form.getDescription();
        List attributeKeys = form.getAttributeKeys();
        List attributeValues = form.getAttributeValues();
      
        ServletContext context = getServlet().getServletContext();
        ValidationConfig validationConfig = (ValidationConfig) context.getAttribute(ValidationConfig.CONFIG_KEY);
        TestSuiteConfig suiteConfig = (TestSuiteConfig) request.getSession().getAttribute(TestSuiteConfig.CURRENTLY_SELECTED_KEY);
        TestConfig testConfig = (TestConfig) request.getSession().getAttribute(TestConfig.CURRENTLY_SELECTED_KEY);
       
        //this allows renaming. If they change the test's name, we just remove it add a new one
        suiteConfig.removeTest(testConfig.getName());
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.