Package Torello.Java

Class HiLiteMe.Params

  • Enclosing class:

    public static class HiLiteMe.Params
    extends java.lang.Object
    Inner class for providing a list of parameters when hiliting multiple files on disk.

    The purpose of this short inner class is to make the calls to the http://HiLite.ME/ servers a little more customize-able. Their are no methods in this class; instead each field is left public and can be modified directly be the user. Getter and Setter methods are eliminated for brevity.

    • Field Summary

      Default, Static String Constants
      Modifier and Type Field
      static String DEFAULT_ENDING_HTML
      static String DEFAULT_HEADER_HTML
      HTML Page Header & Footer Settings
      Modifier and Type Field
      String endingHTML
      String headerHTML
      Customizable Boolean-Flags
      Modifier and Type Field
      boolean copyTextFiles
      boolean verbose
      Choosing a Style Type
      Modifier and Type Field
      String styleTag
      Use a File-System Cache
      Modifier and Type Field
      HiLiteMe.Cache cache
      File-System Save-File Location
      Modifier and Type Field
      String targetDirectory
      Selecting which Source-Code or HTML Files to HiLite
      Modifier and Type Field
      TreeSet<String> fileIndexList
      Specifying per-File Style-Types
      Modifier and Type Field
      TreeMap<String,​String> customMappings
    • Constructor Summary

      Constructor Description
      The public constructor has no body.
    • Method Summary

      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Field Detail


        🡇     🗕  🗗  🗖
        public static final java.lang.String DEFAULT_HEADER_HTML
        The default value for 'headerHTML' This value may be reset by accessing the field 'headerHTML', which is a 'public' field in this class.
        See Also:
        Constant Field Values
        Exact Field Declaration Expression:
         public static final String DEFAULT_HEADER_HTML =
                     "<HTML>\n<HEAD>\n<META http-equiv=\"Content-Type\" content=\"text/html; " +
                     "charset=utf-8\" />\n<TITLE>INSERT HERE</TITLE>\n</HEAD>\n<BODY>\n";

        🡅  🡇     🗕  🗗  🗖
        public static final java.lang.String DEFAULT_ENDING_HTML
        The default value for 'endingHTML' This value may be reset by accessing the field 'endingHTML', which is a 'public' field in this class.
        See Also:
        Constant Field Values
        Exact Field Declaration Expression:
         public static final String DEFAULT_ENDING_HTML = "\n</BODY>\n</HTML>\n";
      • verbose

        🡅  🡇     🗕  🗗  🗖
        public boolean verbose
        When this is TRUE, System.out will print a line each time a file in the FileNode tree is visited and sent to the pretty-printing HiLite servers.
      • headerHTML

        🡅  🡇     🗕  🗗  🗖
        public java.lang.String headerHTML
        This is the header HTML that is inserted above each post-processed / pretty-printed source-code file that is received from HiLite.ME servers. The default version includes a META-UTF8 clause, because often higher-level Uni-Code characters from Mandarin Chinese, Spanish, Korean, Vietnamese and other foreign languages are in (the writer, Torello's code).

        NOTE: The header must have a sub-string that says (in all caps) "INSERT HERE" - the file name will be inserted.
      • endingHTML

        🡅  🡇     🗕  🗗  🗖
        public java.lang.String endingHTML
        This is the HTML that is appended to each pretty-printed source-code file received from HiLite.ME servers. The default version of this java.lang.String simply contains <BODY>, </HTML> - change this if necessary!.
      • fileIndexList

        🡅  🡇     🗕  🗗  🗖
        public java.util.TreeSet<java.lang.String> fileIndexList
        This will store each file that is successfully converted into a "Pretty Printed HTML" file in the passed parameter TreeSet. Java's TreeSet stores things alphabetically, and does not allow duplicates. It can be used to generate an 'index.html' file. Send this field to the HiLiteMe.createIndex(TreeSet, String) method to build the 'index.html' file. If this is null, files that are pretty-printed by the http://HiLite.ME/ server will just not be logged to this data-structure.
      • customMappings

        🡅  🡇     🗕  🗗  🗖
        public java.util.TreeMap<java.lang.String,​java.lang.String> customMappings
        This is null by default. If it is not null, then each java.lang.string 'key' in the Map should be a file ending, and the 'value' to which the key maps should be a Code Type Tag that is recognized by the HiLite Pretty-Print HTML servers.

        NOTE: It is important to know that the 'keys' in this TreeMap data-structure are valid file-name extensions, that leave out the leading '.' (period). The key should be 'java' not '.java'. Furthermore, the values in the data-structure to which these keys map, should be valid HiLiteMe Pretty-Print Servers code-type values. The complete list of valid 'Code Types' can be viewed by iterating through public Iterator<String> getCodeTypes()
        See Also:
        HiLiteMe.getCodeTypes(), HiLiteMe.isCodeType(String), HiLiteMe.deduceCodeType(String, TreeMap)
        Exact Field Declaration Expression:
         public TreeMap<String, String> customMappings = null;
      • cache

        🡅  🡇     🗕  🗗  🗖
        public HiLiteMe.Cache cache
        Instantiate a Cache, and the HiLite.ME server will save all code-String's into a cache. For each source code request that is made which includes BOTH a Params parameter class, AND a non-null 'cache' field, the logic will first check the code-cache to see if an identical String is in the cache. If the String is identical, querying the HiLite.ME server will be skipped, and the local copy used instead. This can increase build time many-fold, as seconds are reduced to milliseconds in large builds where only 2 or 3 classes have seen code-changes since a previous build.
        See Also:
        Exact Field Declaration Expression:
         public Cache cache = null;
    • Constructor Detail

      • Params

        🡅     🗕  🗗  🗖
        public Params()
        The public constructor has no body. Modify the constants as necessary - since the fields are all 'public', and are not 'final'