Package org.jitterbit.util.file

Examples of org.jitterbit.util.file.Folder


        }

        private void processFolder(Folder root) {
            for (File f : root.listFiles()) {
                if (f.isDirectory()) {
                    Folder dir = new Folder(f);
                    processFolder(dir);
                    if (dir.isEmpty()) {
                        if (!dir.delete()) {
                            success = false;
                        }
                    }
                } else {
                    if (!f.delete()) {
View Full Code Here


    private final MappingTreeStructureCache outputCache;

    public FileBasedInputAndOutputMappingTreeStructureCache(String cacheId, Folder location) {
        checkArgument(StringUtils.isNotBlank(cacheId), "cacheId may not be null or blank");
        checkNotNull(location, "location");
        Folder location2 = location.subFolder(cacheId);
        inputCache = createRequestCache(location2);
        outputCache = createResponseCache(location2);
    }
View Full Code Here

        private boolean isHidden(File dir) {
            // Hide a directory if
            //  1. There is a project file next to it; and
            //  2. The directory has a name that matches a predefined project folder
            Folder parent = Folder.parentOf(dir);
            if (parent != null && containsProjectFile(parent)) {
                return ProjectFolders.isProjectFolder(dir);
            }
            return false;
        }
View Full Code Here

     *
     * @param projectFolder
     *            the project's root folder
     */
    public static Folder getProjectDataFolder(File projectFolder) {
        return new Folder(projectFolder, PROJECT_DATA);
    }
View Full Code Here

     *
     * @param projectFolder
     *            the project's root folder.
     */
    public static Folder getCacheFolder(File projectFolder) {
        return new Folder(projectFolder, CACHE);
    }
View Full Code Here

     *
     * @param projectFolder
     *            the project's root folder.
     */
    public static Folder getPermissionsFolder(File projectFolder) {
        return new Folder(projectFolder, PERMISSIONS);
    }
View Full Code Here

     *
     * @param projectFolder
     *            the project's root folder.
     */
    public static Folder getSettingsFolder(File projectFolder) {
        return new Folder(projectFolder, SETTINGS);
    }
View Full Code Here

     *
     * @param projectFolder
     *            the project's root folder.
     */
    public static Folder getPersistFolder(File projectFolder) {
        return new Folder(projectFolder, PERSIST);
    }
View Full Code Here

* @since 4.0.0
*/
public class FunctionDocumentationSplitter {

    public static void main(String[] args) throws Exception {
        Folder folder = new Folder("C:\\tmp\\functions\\");
        folder.delete();
        folder.createOnDisk();
        FunctionRegistry functions = FunctionRegistry.getRegistry();
        for (FunctionCategory c : functions.getCategories()) {
            for (Function f : c.getFunctions()) {
                String name = KongaStringUtils.removeStartAndEnd(f.getName(), "<", ">");
                String html = "<html>" + f.getDocumentation() + "</html>";
                File output = folder.getFile(name.toLowerCase() + ".html");
                FileUtils.writeStringToFile(output, html, "utf-8");
            }
        }
    }
View Full Code Here

            }
            return cache;
        }

        private PipelinePluginManifestCache createCache(ServerGuid serverId) {
            Folder serverDir = getServerDirectory(serverId);
            Folder parentDir = serverDir.subFolder(getID());
            parentDir.createOnDisk();
            PipelinePluginManifestCacheFactory factory = PipelinePluginManifestCacheFactory
                            .newFileBasedCacheFactory(parentDir);
            return factory.createCache();
        }
View Full Code Here

TOP

Related Classes of org.jitterbit.util.file.Folder

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.