Package org.apache.bval.jsr303.util

Examples of org.apache.bval.jsr303.util.PathImplTest


                                    }
                                    stream = new StreamSource(inp1);
                                    unmarshaller = CONSTRAINTMAPPINGSTYPE_JAXBCONTEXT.createUnmarshaller();
                                    unmarshaller.setSchema(VALIDATION_MAPPING_SCHMEA);
                                    JAXBElement<ConstraintMappingsType> mappingRoot = unmarshaller.unmarshal(stream, ConstraintMappingsType.class);
                                    ConstraintMappingsType constraintMappings = mappingRoot.getValue();
                                } catch (JAXBException e) {
                                    log.debug("Error processing constraint mapping file "+mappingFileName+" specified in "+validationConfig+" in module "+module.getName(), e);
                                } catch (IOException e) {
                                    log.debug("Error processing constraint mapping file "+mappingFileName+" specified in "+validationConfig+" in module "+module.getName(), e);
                                } finally {
View Full Code Here


                    Unmarshaller unmarshaller = VALIDATION_CONFIGURATION_JAXBCONTEXT.createUnmarshaller();
                    unmarshaller.setSchema(VALIDATION_CONFIGURATION_SCHMEA);
                    inp = validationConfigEntry.openStream();
                    StreamSource stream = new StreamSource(inp);
                    JAXBElement<ValidationConfigType> root = unmarshaller.unmarshal(stream, ValidationConfigType.class);
                    ValidationConfigType xmlConfig = root.getValue();
                    if(xmlConfig.getConstraintMapping().size() > 0) {
                        for (JAXBElement<String> mappingFileNameElement : xmlConfig.getConstraintMapping()) {
                            String mappingFileName = mappingFileNameElement.getValue();
                            if(bundle.getEntry(mappingFileName) == null) {
                                if (log.isDebugEnabled()) {
                                    log.debug("Non-existent constraint mapping file " + mappingFileName + " specified in " + validationConfig + " in module " + module.getName());
                                }
View Full Code Here

            if (validationConfig == null) {
                // just create the default
                createDefaultFactory();
            } else {
                // Parse the validation xml
                ValidationConfigType validationConfigType = null;
                try {
                    Unmarshaller unmarshaller = VALIDATION_FACTORY_CONTEXT.createUnmarshaller();
                    unmarshaller.setSchema(VALIDATION_FACTORY_SCHEMA);
                    URL validationConfigURL = null;
                    if(moduleName == null) {
View Full Code Here

        getProperties().putAll(configuration.getProperties());
        setMessageInterpolator(configuration.getMessageInterpolator());
        setTraversableResolver(configuration.getTraversableResolver());
        setConstraintValidatorFactory(configuration
            .getConstraintValidatorFactory());
        ValidationMappingParser parser = new ValidationMappingParser(this);
        parser.processMappingConfig(configuration.getMappingStreams());
    }
View Full Code Here

        getProperties().putAll(configuration.getProperties());
        setMessageInterpolator(configuration.getMessageInterpolator());
        setTraversableResolver(configuration.getTraversableResolver());
        setConstraintValidatorFactory(configuration
                .getConstraintValidatorFactory());
        ValidationMappingParser parser = new ValidationMappingParser(this);
        parser.processMappingConfig(configuration.getMappingStreams());
    }
View Full Code Here

    public void configure(ConfigurationState configuration) {
        getProperties().putAll(configuration.getProperties());
        setMessageInterpolator(configuration.getMessageInterpolator());
        setTraversableResolver(configuration.getTraversableResolver());
        setConstraintValidatorFactory(configuration.getConstraintValidatorFactory());
        ValidationMappingParser parser = new ValidationMappingParser(this);
        parser.processMappingConfig(configuration.getMappingStreams());
    }
View Full Code Here

    /** Check whether a validation.xml file exists and parses it with JAXB */
    private void parseValidationXml() {
        if (isIgnoreXmlConfiguration()) {
            log.info("ignoreXmlConfiguration == true");
        } else {
            new ValidationParser(getProperties().get(Properties.VALIDATION_XML_PATH))
                  .processValidationConfig(this);
        }
    }
View Full Code Here

    /** Check whether a validation.xml file exists and parses it with JAXB */
    private void parseValidationXml() {
        if (isIgnoreXmlConfiguration()) {
            log.info("ignoreXmlConfiguration == true");
        } else {
            new ValidationParser(getProperties().get(Properties.VALIDATION_XML_PATH))
                  .processValidationConfig(this);
        }
    }
View Full Code Here

    /** Check whether a validation.xml file exists and parses it with JAXB */
    private void parseValidationXml() {
        if (isIgnoreXmlConfiguration()) {
            log.info("ignoreXmlConfiguration == true");
        } else {
            new ValidationParser(getProperties().get(Properties.VALIDATION_XML_PATH))
                  .processValidationConfig(this);
        }
    }
View Full Code Here

    /** Check whether a validation.xml file exists and parses it with JAXB */
    private void parseValidationXml() {
        if (isIgnoreXmlConfiguration()) {
            log.config("ignoreXmlConfiguration == true");
        } else {
            new ValidationParser(getProperties().get(Properties.VALIDATION_XML_PATH))
                  .processValidationConfig(this);
        }
    }
View Full Code Here

TOP

Related Classes of org.apache.bval.jsr303.util.PathImplTest

Copyright © 2018 www.massapicom. 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.