Examples of load()


Examples of org.apache.cayenne.configuration.DataMapLoader.load()

    DataMapLoader loader = runtime.getInjector().getInstance(
        DataMapLoader.class);
    URL url = getClass().getClassLoader().getResource(
        "inheritance-vertical.map.xml");
    DataMap dataMap = loader.load(new URLResource(url));
    EntityResolver resolver = new EntityResolver(
        Collections.singleton(dataMap));

    ObjEntity iv2Sub1 = resolver.getObjEntity(Iv2Sub1.class);
    ObjRelationship x = (ObjRelationship) iv2Sub1
View Full Code Here

Examples of org.apache.cayenne.configuration.XMLDataChannelDescriptorLoader.load()

        injector.injectMembers(loader);

        String testConfigName = "relationship-optimisation";
        URL url = getClass().getResource("cayenne-" + testConfigName + ".xml");

        ConfigurationTree<DataChannelDescriptor> tree = loader.load(new URLResource(url));

        map = tree.getRootNode().getDataMap(testConfigName);
    }

    public void testMatchingForManyToManyEntity() throws Exception {
View Full Code Here

Examples of org.apache.cloudstack.spring.module.model.impl.DefaultModuleDefinitionSet.load()

    public ModuleDefinitionSet loadModules(Collection<ModuleDefinition> defs, String root) throws IOException {

        Map<String, ModuleDefinition> modules = wireUpModules(root, defs);

        DefaultModuleDefinitionSet moduleSet = new DefaultModuleDefinitionSet(modules, root);
        moduleSet.load();

        return moduleSet;
    }

    protected Map<String, ModuleDefinition> wireUpModules(String root, Collection<ModuleDefinition> defs) throws IOException {
View Full Code Here

Examples of org.apache.cocoon.components.language.generator.ProgramGenerator.load()

                getLogger().debug("XSP generation begin:" + fileName);
            }

            programGenerator = (ProgramGenerator) this.componentManager.lookup(ProgramGenerator.ROLE);

            CompiledComponent xsp = programGenerator.load(this.componentManager,
                    environment.resolveURI(fileName),
                    markupLanguage, programmingLanguage, environment);
            if (getLogger().isDebugEnabled()) {
                getLogger().debug("XSP generation complete:" + xsp);
            }
View Full Code Here

Examples of org.apache.cocoon.components.language.programming.ProgrammingLanguage.load()

                    markupLanguage =
                            (MarkupLanguage)this.markupSelector.select(markupLanguageName);
                    programmingLanguage =
                            (ProgrammingLanguage)this.languageSelector.select(programmingLanguageName);
                    programmingLanguage.setLanguageName(programmingLanguageName);
                    program = programmingLanguage.load(normalizedName,
                            this.workDir, markupLanguage.getEncoding());

                    this.cache.addGenerator(newManager, normalizedName, program);
                    programInstance = (CompiledComponent)this.cache.select(normalizedName);
                } catch (Exception e) {
View Full Code Here

Examples of org.apache.cocoon.forms.flow.java.FormInstance.load()

        // Load form descriptor
        FormInstance form = new FormInstance("forms/employee.xml");
        // Load form binding
        form.createBinding("forms/employee-binding.xml");
        // Load the Bean to the form
        form.load(employee);
        // Let Cocoon Forms handle the form
        form.show("form/employee");
        // Update the Bean based on user input
        form.save(employee);
        // Update Bean in Database
View Full Code Here

Examples of org.apache.commons.collections.ExtendedProperties.load()

     * @param input the InputStream to read from
     */
    public void read(InputStream input) throws IOException
    {
        ExtendedProperties props = new ExtendedProperties();
        props.load(input);

        // all factory settings should be prefixed with "tools"
        read(props.subset("tools"));
    }

View Full Code Here

Examples of org.apache.commons.configuration.DefaultConfigurationBuilder.load()

                    interpolator.addValueSource( new PropertiesBasedValueSource( System.getProperties() ) );

                    String interpolatedProps = interpolator.interpolate( properties );

                    logger.debug( "Loading configuration into commons-configuration, xml {}", interpolatedProps );
                    builder.load( new StringReader( interpolatedProps ) );
                    configuration = builder.getConfiguration( false );
                    configuration.setExpressionEngine( expressionEngine );
                    //configuration.set
                }
                catch ( InterpolationException e )
View Full Code Here

Examples of org.apache.commons.configuration.FileConfiguration.load()

            this.shell.getInterp().getContext().setProperty("g", this.giraphGraph);
        }
        if (args.size() == 1) {
            try {
                final FileConfiguration configuration = new PropertiesConfiguration();
                configuration.load(new File(args.get(0)));
                this.giraphGraph = GiraphGraph.open(configuration);
                this.shell.getInterp().getContext().setProperty("g", this.giraphGraph);
            } catch (final Exception e) {
                throw new RuntimeException(e.getMessage(), e);
            }
View Full Code Here

Examples of org.apache.commons.configuration.HierarchicalINIConfiguration.load()

    InputStream is;
    if (Play.application().isProd()) is  =Play.application().resourceAsStream(CONFIGURATION_FILE_NAME);
    else is = new FileInputStream(Play.application().getFile("conf/"+CONFIGURATION_FILE_NAME));
    HierarchicalINIConfiguration c = new HierarchicalINIConfiguration();
    c.setEncoding("UTF-8");
    c.load(is);
    CharSequence doubleDot = "..";
    CharSequence dot = ".";

    Set<String> sections= c.getSections();
    for (String section: sections){
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. 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.