Package org.apache.cocoon.environment.commandline

Examples of org.apache.cocoon.environment.commandline.CommandLineContext


                }
            }

            this.conf = getConfigurationFile(this.context, this.configFile);

            cliContext = new CommandLineContext(contextDir);
            cliContext.enableLogging(log);

            appContext.put(Constants.CONTEXT_ENVIRONMENT_CONTEXT, cliContext);
            appContext.put(Constants.CONTEXT_CLASS_LOADER,
                    CocoonWrapper.class.getClassLoader());
View Full Code Here


            this.ctx = new DefaultContext(context);

            File contextDir = (File) this.ctx.get("context-root");
            File workDir = (File) this.ctx.get(Constants.CONTEXT_WORK_DIR);

            CommandLineContext clContext = new CommandLineContext(contextDir.toString());
            clContext.enableLogging(getLogger());
            this.ctx.put(Constants.CONTEXT_ENVIRONMENT_CONTEXT, clContext);
            this.ctx.put(Constants.CONTEXT_CLASSPATH, getClassPath(contextDir));

            this.ctx.put(Constants.CONTEXT_UPLOAD_DIR, new File(contextDir, "upload-dir"));
            this.ctx.put(Constants.CONTEXT_CACHE_DIR, new File(workDir, "cache-dir"));
View Full Code Here

    protected void addContext(DefaultContext context) {
        this.context = context;

        context.put(Constants.CONTEXT_WORK_DIR, workDir);

        CommandLineContext commandline_context = new CommandLineContext(commandlineContextDir.toString());
        commandline_context.enableLogging(getLogEnabledLogger());
        context.put(Constants.CONTEXT_ENVIRONMENT_CONTEXT, commandline_context);
    }
View Full Code Here

        try {
            DefaultContext appContext = new DefaultContext();
            appContext.put(
                Constants.CONTEXT_CLASS_LOADER,
                CocoonWrapper.class.getClassLoader());
            cliContext = new CommandLineContext(contextDir);
            cliContext.enableLogging(log);
            appContext.put(Constants.CONTEXT_ENVIRONMENT_CONTEXT, cliContext);
            LogKitLoggerManager logKitLoggerManager =
                    new LogKitLoggerManager(Hierarchy.getDefaultHierarchy());
            logKitLoggerManager.enableLogging(log);
View Full Code Here

            classLoader = (ClassLoader) this.ctx.get(Constants.CONTEXT_CLASS_LOADER);
            File contextDir = (File) this.ctx.get("context-root");
            File workDir = (File) this.ctx.get(Constants.CONTEXT_WORK_DIR);

            CommandLineContext clContext = new CommandLineContext(contextDir.toString());
            clContext.enableLogging(getLogger());
            this.ctx.put(Constants.CONTEXT_ENVIRONMENT_CONTEXT, clContext);
            this.ctx.put(Constants.CONTEXT_CLASSPATH, getClassPath(contextDir));

            this.ctx.put(Constants.CONTEXT_UPLOAD_DIR, new File(contextDir, "upload-dir"));
            this.ctx.put(Constants.CONTEXT_CACHE_DIR, new File(workDir, "cache-dir"));
View Full Code Here

    protected void addContext(DefaultContext context) {
        this.context = context;

        context.put(Constants.CONTEXT_WORK_DIR, workDir);

        CommandLineContext commandline_context = new CommandLineContext(commandlineContextDir.toString());
        commandline_context.enableLogging(getLogEnabledLogger());
        context.put(Constants.CONTEXT_ENVIRONMENT_CONTEXT, commandline_context);
    }
View Full Code Here

     * @since
     */
    public void setUp() throws Exception {
        commandLineContextDir = System.getProperty("java.io.tmpdir", "/tmp");
        new File(commandLineContextDir, "foo"+File.separator+"bar").mkdirs();
        commandLineContext = new CommandLineContext(commandLineContextDir);
        commandLineContext.enableLogging( new ConsoleLogger() );
    }
View Full Code Here

            classLoader = (ClassLoader) this.ctx.get(Constants.CONTEXT_CLASS_LOADER);
            File contextDir = (File) this.ctx.get("context-root");
            File workDir = (File) this.ctx.get(Constants.CONTEXT_WORK_DIR);

            CommandlineContext clContext = new CommandlineContext(contextDir.toString());
            clContext.enableLogging(getLogger());
            this.ctx.put(Constants.CONTEXT_ENVIRONMENT_CONTEXT, clContext);
            this.ctx.put(Constants.CONTEXT_CLASSPATH, getClassPath(contextDir));

            this.ctx.put(Constants.CONTEXT_UPLOAD_DIR, new File(contextDir, "upload-dir"));
            this.ctx.put(Constants.CONTEXT_CACHE_DIR, new File(workDir, "cache-dir"));
View Full Code Here

     * @exception  Exception  Description of Exception
     * @since
     */
    public void setUp() throws Exception {
        commandlineContextDir = System.getProperty("java.io.tmpdir", "/tmp");
        commandlineContext = new CommandlineContext(commandlineContextDir);
        commandlineContext.enableLogging( new ConsoleLogger() );
    }
View Full Code Here

    protected void addContext(DefaultContext context) {
        this.context = context;

        context.put(Constants.CONTEXT_WORK_DIR, workDir);

        CommandlineContext commandline_context = new CommandlineContext(commandlineContextDir.toString());
        commandline_context.enableLogging(getLogEnabledLogger());
        context.put(Constants.CONTEXT_ENVIRONMENT_CONTEXT, commandline_context);
    }
View Full Code Here

TOP

Related Classes of org.apache.cocoon.environment.commandline.CommandLineContext

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.