Package com.iizix.js

Class JSFiles

java.lang.Object
com.iizix.js.JSFiles

public class JSFiles extends Object
Main class for the iiziGo Designer JavaScript plug-in used to hold the file required for browser and JavaScript on disk outside of Jar plug-in files to be accessed directly as file:/ or http[s]:// URI's.
Author:
Christopher Mindus
  • Field Details

  • Constructor Details

    • JSFiles

      public JSFiles()
  • Method Details

    • getRootFiles

      public static List<String> getRootFiles()
      Gets root directory and all files required for the web server.
      Returns:
      An immutable list of file names.
    • setFileLocator

      public static void setFileLocator(IGenericFileLocator newFileLocator)
      Assigns a new file locator, to be used for iiziGo Designer.
      Parameters:
      newFileLocator - The new file locator for Eclipse IDE URL bundle resolving to File.
    • getRoot

      public static File getRoot(File dirHint)
      Gets the file location on disk of the root directory.
      Parameters:
      dirHint - The directory hint might be non-null. If so, that one should be used.
    • getFile

      public static File getFile(String name)
      Gets the file location on disk of a specific file name or system setting.
    • getFileUrl

      public static String getFileUrl(String name)
      Gets the file location in root disk of a specific file.
    • getDojoRoot

      public static File getDojoRoot()
      Gets the Dojo root directory.
      Returns:
      The Dojo Root directory.
    • getJQueryFile

      public static File getJQueryFile()
      Gets the JQuery file.
      Returns:
      The file of the jQuery Jar.
    • getReplacementsFile

      public static String getReplacementsFile(String fileInRoot, String... replacements) throws IOException
      Gets a cached file from disk and processes replacements.

      Replacements are processed as all text between to replacement strings, e.g. "%REPL%" or "".

      Parameters:
      fileInRoot - The file in the root to load (and cache).
      replacements - The list of pairs for the replacements.
      Throws:
      IOException