Package com.consol.citrus.model.config.core

Examples of com.consol.citrus.model.config.core.NamespaceContext


*/
public class NamespaceContextSpringBeanConverter implements SpringBeanConverter<NamespaceContext> {

    @Override
    public NamespaceContext convert(SpringBean springBean) {
        NamespaceContext context = new ObjectFactory().createNamespaceContext();

        for (Property property : springBean.getProperties()) {
            if (property.getName().equals("namespaceMappings")) {
                for (Entry entry : property.getMap().getEntries()) {
                    NamespaceContext.Namespace namespace = new NamespaceContext.Namespace();
                    namespace.setPrefix(entry.getKey());
                    namespace.setUri(entry.getValue());
                    context.getNamespaces().add(namespace);
                }
            }
        }

        return context;
View Full Code Here


                return springBeanConverter.convert(springBeans.get(0));
            }
        }

        if (CollectionUtils.isEmpty(contexts)) {
            return new NamespaceContext();
        } else {
            return contexts.get(0);
        }
    }
View Full Code Here

TOP

Related Classes of com.consol.citrus.model.config.core.NamespaceContext

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.