Examples of Cocoon


Examples of de.uniol.informatik.vlba.prototype.agent.Cocoon

      BeeDNA b = new BeeDNA(genes, "SimpleIntHarvester");

      String repPath = "src/de/uniol/informatik/vlba/intharvesters/unittest/behavior_repository.xml";

      System.out.println("Get a cocoon");
      Cocoon cocoon = new Cocoon(SimpleIntHarvester.class);

      // cocoon.createBees(b, 10, repPath);
      List<Bee> beeslst = cocoon
          .instanciateBees(config.getAgent_number(),
              "de.uniol.informatik.vlba.prototype.agent.Agent_1270717415470");
      SimpleIntHarvester[] bees = (SimpleIntHarvester[]) (beeslst
          .toArray(new SimpleIntHarvester[0]));
     
View Full Code Here

Examples of de.uniol.informatik.vlba.prototype.agent.Cocoon

            BeeDNA b = new BeeDNA(genes, "SimpleIntHarvester");

            String repPath = "src/de/uniol/informatik/vlba/intharvesters/unittest/behavior_repository.xml";

            System.out.println("Get a cocoon");
            Cocoon cocoon = new Cocoon(SimpleIntHarvester.class);

            // cocoon.createBees(b, 10, repPath);
            List<Bee> beeslst = cocoon
                    .instanciateBees(config.getAgent_number(),
                            "de.uniol.informatik.vlba.prototype.agent.Agent_1270717415470");
            // TODO changed code here to get easier bee names
            nameBees(beeslst);
            SimpleIntHarvester[] bees = (SimpleIntHarvester[]) (beeslst
View Full Code Here

Examples of de.uniol.informatik.vlba.prototype.agent.Cocoon

      BeeDNA b = new BeeDNA(genes, "SemHarvester");

      String repPath = "src/de/uniol/informatik/vlba/intharvesters/unittest/behavior_repository.xml";

      System.out.println("Get a cocoon");
      Cocoon cocoon = new Cocoon(SemHarvester.class);

      // cocoon.createBees(b, 10, repPath);
      List<Bee> beeslst = cocoon
          .instanciateBees(config.getAgent_number(),
              "de.uniol.informatik.vlba.prototype.agent.sembees.Agent_sem123456");
      SemHarvester[] bees = (SemHarvester[]) (beeslst
          .toArray(new SemHarvester[0]));
View Full Code Here

Examples of org.apache.cocoon.Cocoon

        // Check validity of members
        checkValidity();

        DefaultContext rootCtx = new DefaultContext();
        DefaultConfiguration configuration = new DefaultConfiguration("root", "");
        Cocoon cocoon = null;
        CocoonFactory cocoonFactory = null;

        try {
            // fill rootCtx
            rootCtx.put("dest-dir", destDir);
View Full Code Here

Examples of org.apache.cocoon.Cocoon

         * @exception  ContextException        thrown iff configuring of Cocoon instance fails
         * @exception  ConfigurationException  thrown iff contextualizing of Cocoon instance fails
         * @exception  Exception               thrown iff initializing of Cocoon instance fails
         */
        public Cocoon createCocoon() throws Exception, ContextException, ConfigurationException {
            Cocoon cocoon = new Cocoon();
            cocoon.enableLogging(new LogKitLogger(logger));
            cocoon.contextualize(this.ctx);
            cocoon.setLogKitManager(logKitManager);
            cocoon.initialize();
            return cocoon;
        }
View Full Code Here

Examples of org.apache.cocoon.Cocoon

        try {
            URL configFile = (URL) this.appContext.get(Constants.CONTEXT_CONFIG_URL);
            if (log.isInfoEnabled()) {
                log.info("Reloading from: " + configFile.toExternalForm());
            }
            Cocoon c = (Cocoon) ClassUtils.newInstance("org.apache.cocoon.Cocoon");
            final String rootlogger = getInitParameter("cocoon-logger");
            if (rootlogger != null) {
                c.enableLogging(new LogKitLogger(this.logKitManager.getLogger(rootlogger)));
            } else {
                c.enableLogging(new LogKitLogger(log));
            }
            c.contextualize(this.appContext);
            c.compose(getParentComponentManager());
            c.setLogKitManager(this.logKitManager);
            if (this.enableInstrumentation) {
                c.setInstrumentManager(getInstrumentManager());
            }
            c.initialize();
            this.creationTime = System.currentTimeMillis();

            disposeCocoon();
            this.cocoon = c;
        } catch (Exception e) {
View Full Code Here

Examples of org.apache.cocoon.Cocoon

            appContext.put(Constants.CONTEXT_CACHE_DIR, cacheDir);
            appContext.put(Constants.CONTEXT_CONFIG_URL, conf.toURL());

            loadClasses(classList);

            cocoon = new Cocoon();
            cocoon.enableLogging(new LogKitLogger(log));
            cocoon.contextualize(appContext);
            cocoon.setLogKitManager(logKitManager);
            cocoon.initialize();
View Full Code Here

Examples of org.apache.cocoon.Cocoon

        try {
            URL configFile = (URL) this.appContext.get(Constants.CONTEXT_CONFIG_URL);
            if (log.isInfoEnabled()) {
                log.info("Reloading from: " + configFile.toExternalForm());
            }
            Cocoon c = (Cocoon) ClassUtils.newInstance("org.apache.cocoon.Cocoon");
            final String rootlogger = getInitParameter("cocoon-logger");
            if (rootlogger != null) {
                c.setLogger(this.logKitManager.getLogger(rootlogger));
            } else {
                c.setLogger(log);
            }
            c.contextualize(this.appContext);
            c.compose(getParentComponentManager ());
            c.setLogKitManager(this.logKitManager);
            c.initialize();
            this.creationTime = System.currentTimeMillis();

            if (this.cocoon != null) {
                this.cocoon.dispose();
                this.cocoon = null;
View Full Code Here

Examples of org.apache.cocoon.Cocoon

        try {
            URL configFile = (URL) this.appContext.get(Constants.CONTEXT_CONFIG_URL);
            if (log.isInfoEnabled()) {
                log.info("Reloading from: " + configFile.toExternalForm());
            }
            Cocoon c = (Cocoon) ClassUtils.newInstance("org.apache.cocoon.Cocoon");
            final String rootlogger = getInitParameter("cocoon-logger");
            if (rootlogger != null) {
                c.setLogger(this.logKitManager.getLogger(rootlogger));
            } else {
                c.setLogger(log);
            }
            c.contextualize(this.appContext);
            c.compose(getParentComponentManager ());
            c.setLogKitManager(this.logKitManager);
            c.initialize();
            this.creationTime = System.currentTimeMillis();

            this.disposeCocoon();

            this.cocoon = c;
View Full Code Here

Examples of org.apache.cocoon.Cocoon

            this.exception = null;
            URL configFile = (URL) this.appContext.get(Constants.CONTEXT_CONFIG_URL);
            if (getLogger().isInfoEnabled()) {
                getLogger().info("Reloading from: " + configFile.toExternalForm());
            }
            Cocoon c = (Cocoon) ClassUtils.newInstance("org.apache.cocoon.Cocoon");
            ContainerUtil.enableLogging(c, getCocoonLogger());
            c.setLoggerManager(getLoggerManager());
            ContainerUtil.contextualize(c, this.appContext);
            final ComponentManager parent = this.getParentComponentManager();
            if (parent != null) {
                ContainerUtil.compose(c, parent);
            }
            if (this.enableInstrumentation) {
                c.setInstrumentManager(getInstrumentManager());
            }
            ContainerUtil.initialize(c);
            this.creationTime = System.currentTimeMillis();

            disposeCocoon();
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.