Package com.alphacsp.cit

Examples of com.alphacsp.cit.Environment.cd()


        List<String> parameters = executionContext.getParameters();

        FileValue pwd = environment.pwd();

        if (parameters.isEmpty()) {
            environment.cd();
        } else {
            String newFolder = parameters.get(0);
            FileValue newPwd = pwd.child(newFolder);
            File newFolderFile = newPwd.getAsFile();
            if (! newFolderFile.exists()) {
View Full Code Here


                throw new CommandExecutionException("No such directory: " + newFolderFile);
            }
            if (! newFolderFile.isDirectory()) {
                throw new CommandExecutionException(newFolderFile + "is not a directory");
            }
            environment.cd(newFolderFile.getAbsolutePath());
        }

    }
}
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.