Package org.lilyproject.runtime.model

Examples of org.lilyproject.runtime.model.SourceLocations


            newModel = settings.getModel();
        } else {
            Conf modulesConf = confRegistry.getConfiguration("wiring", false, false);
            Set<String> disabledModuleIds = settings.getDisabledModuleIds() != null ?
                    settings.getDisabledModuleIds() : Collections.<String>emptySet();
            SourceLocations sourceLocations = settings.getSourceLocations() != null ?
                    settings.getSourceLocations() : new SourceLocations();
            try {
                newModel = LilyRuntimeModelBuilder.build(modulesConf, disabledModuleIds, settings.getRepository(), sourceLocations);
            } catch (Exception e) {
                throw new LilyRTException("Error building the Lily model from configuration.", e);
            }
View Full Code Here


        }


        Set<String> disabledModuleIds = getDisabledModuleIds(cmd.getOptionValue(disabledModulesOption.getOpt()));

        SourceLocations sourceLocations;
        if (cmd.hasOption(sourceLocationsOption.getOpt())) {
            File file = new File(cmd.getOptionValue(sourceLocationsOption.getOpt())).getAbsoluteFile();
            if (!file.exists()) {
                System.out.println("The specified source locations property file does not exist: " + file.getAbsolutePath());
                System.exit(1);
            }

            InputStream is = null;
            try {
                is = new FileInputStream(file);
                sourceLocations = new SourceLocations(is, file.getParent());
            } catch (Throwable t) {
                throw new LilyRTException("Problem reading source locations property file.", t);
            } finally {
                IOUtils.closeQuietly(is);
            }
        } else {
            sourceLocations = new SourceLocations();
        }



        LilyRuntimeSettings settings = new LilyRuntimeSettings();
View Full Code Here

        if (moduleSourceLocations != null) {
            File sourceLocationsFile = new File(moduleSourceLocations);
            FileInputStream sourceLocationsStream = null;
            try {
                sourceLocationsStream = new FileInputStream(sourceLocationsFile);
                sourceLocations = new SourceLocations(sourceLocationsStream, sourceLocationsFile.getParentFile().getAbsolutePath());
            } catch (Exception e) {
                throw new MojoExecutionException("Problem reading module source locations file from " +
                        sourceLocationsFile.getAbsolutePath(), e);
            } finally {
                if (sourceLocationsStream != null) {
View Full Code Here

TOP

Related Classes of org.lilyproject.runtime.model.SourceLocations

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.