Package org.milyn.edisax.registry

Examples of org.milyn.edisax.registry.DefaultMappingsRegistry


        ignoreEmptyNodes(ignoreEmptyNodes);
    validate(validate);
    // Default Mappings Registry is already set to LazyMappingsRegistry
    // only if mappingModel is defined we should set another instance
    if (!StringUtils.isEmpty(mappingModel)) {
      setMappingsRegistry(new DefaultMappingsRegistry(mappingModel, applicationContext.getResourceLocator().getBaseURI()));
    }
    super.parse(unedifactInterchange);
  }
View Full Code Here


  public void test_with_groupref() throws IOException, SAXException, EDIConfigurationException {
    EdifactModel model1 = EDIParser.parseMappingModel(getClass().getResourceAsStream("../MSG1-model.xml"));
    EdifactModel model2 = EDIParser.parseMappingModel(getClass().getResourceAsStream("../MSG2-model.xml"));
   
    UNEdifactInterchangeParser parser = new UNEdifactInterchangeParser();
    parser.setMappingsRegistry(new DefaultMappingsRegistry(model1, model2));
    parser.ignoreNewLines(true);

    MockContentHandlerNS handler;
   
    // Test message 01 - no UNA segment...
View Full Code Here

  public void test_without_groupref() throws IOException, SAXException, EDIConfigurationException {
    EdifactModel model1 = EDIParser.parseMappingModel(getClass().getResourceAsStream("../MSG1-model.xml"));
    EdifactModel model2 = EDIParser.parseMappingModel(getClass().getResourceAsStream("../MSG2-model.xml"));
   
    UNEdifactInterchangeParser parser = new UNEdifactInterchangeParser();
    parser.setMappingsRegistry(new DefaultMappingsRegistry(model1, model2));
    parser.ignoreNewLines(true);

    MockContentHandler handler;
   
    handler = new MockContentHandler();
View Full Code Here

  public void test_full_group_header() throws IOException, SAXException, EDIConfigurationException {
    EdifactModel model1 = EDIParser.parseMappingModel(getClass().getResourceAsStream("../MSG1-model.xml"));
    EdifactModel model2 = EDIParser.parseMappingModel(getClass().getResourceAsStream("../MSG2-model.xml"));
   
    UNEdifactInterchangeParser parser = new UNEdifactInterchangeParser();
    parser.setMappingsRegistry(new DefaultMappingsRegistry(model1, model2));
    parser.ignoreNewLines(true);

    MockContentHandlerNS handler;
   
    // Test message 01 - no UNA segment...
View Full Code Here

  public void test_with_unknown_ucd_segment() throws IOException, SAXException, EDIConfigurationException {
    EdifactModel model1 = EDIParser.parseMappingModel(getClass().getResourceAsStream("../MSG1-model.xml"));
    EdifactModel model2 = EDIParser.parseMappingModel(getClass().getResourceAsStream("../MSG2-model.xml"));
   
    UNEdifactInterchangeParser parser = new UNEdifactInterchangeParser();
    parser.setMappingsRegistry(new DefaultMappingsRegistry(model1, model2));
    parser.ignoreNewLines(true);

    MockContentHandler handler;
   
    // Test message 01 - no UNA segment...
View Full Code Here

  public void test_unzipped() throws IOException, SAXException, EDIConfigurationException {
    EdifactModel model1 = EDIParser.parseMappingModel(getClass().getResourceAsStream("../MSG1-model.xml"));
    EdifactModel model2 = EDIParser.parseMappingModel(getClass().getResourceAsStream("../MSG2-model.xml"));
   
    UNEdifactInterchangeParser parser = new UNEdifactInterchangeParser();
    parser.setMappingsRegistry(new DefaultMappingsRegistry(model1, model2));

    testExchanges(parser);
  }
View Full Code Here

  }

  public void test_zipped() throws IOException, SAXException, EDIConfigurationException {
    createZip();
    UNEdifactInterchangeParser parser = new UNEdifactInterchangeParser();
    parser.setMappingsRegistry(new DefaultMappingsRegistry("mapping-models.zip", URI.create("./target")));
    testExchanges(parser);
  }
View Full Code Here

TOP

Related Classes of org.milyn.edisax.registry.DefaultMappingsRegistry

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.