Package org.codehaus.groovy.control.customizers

Examples of org.codehaus.groovy.control.customizers.SourceAwareCustomizer


        }
    }

    public Object postCompleteNode(final FactoryBuilderSupport factory, final Object parent, final Object node) {
        SourceOptions data = (SourceOptions) node;
        SourceAwareCustomizer sourceAwareCustomizer = new SourceAwareCustomizer(data.delegate);
        if (data.extensionValidator !=null && (data.extension!=null || data.extensions!=null)) {
            throw new RuntimeException("You must choose between an extension name validator or an explicit extension name");
        }
        if (data.basenameValidator!=null && (data.basename!=null || data.basenames!=null)) {
            throw new RuntimeException("You must choose between an base name validator or an explicit base name");
        }

        addExtensionValidator(sourceAwareCustomizer, data);
        addBasenameValidator(sourceAwareCustomizer, data);
        if (data.unitValidator!=null) sourceAwareCustomizer.setSourceUnitValidator(data.unitValidator);
        if (data.classValidator!=null) sourceAwareCustomizer.setClassValidator(data.classValidator);
        return sourceAwareCustomizer;
    }
View Full Code Here

TOP

Related Classes of org.codehaus.groovy.control.customizers.SourceAwareCustomizer

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.