LexCheck

ValidateSyntaxFromTextFile

  • Descriptions:
    Validate syntax of lexical records from a text file. No auto-fixed file is generated. The result shows error message and confirm no errors if no error found.

  • Usage:
    shell>ValidateSyntaxFromTextFile <inFile (text)> <prepostionFile> <particleFile> <-v: verbose>
    • inFile: lexical file in text format
    • prepositionFile: the preposition file
      default: use the prepositions.data included in the lexCheck${YEAR}api.jar or lexCheck${YEAR}dist.jar
      => prepositions are used in the class of Compl.CheckPreposition.java If this file is not found (empty file name or no such file exists), the default file of prepositions.data in the lexCheck jar file is used. Due to the design of abstract class of CheckFormat.java, this file can't be passing through as a parameter. However, the file can be stored in GlobalVars class if needed.
    • particleFile: the particle file
      default: use the particles.data included in the lexCheck${YEAR}api.jar or lexCheck${YEAR}dist.jar
      => particles are used in the class of Compl.CheckParticle.java If this file is not found (empty file name or no such file exists), the default file of prepositions.data in the lexCheck jar file is used. Due to the design of abstract class of CheckFormat.java, this file can't be passing through as a parameter. However, the file can be stored in GlobalVars class if needed.
    • -v: set verbose to true, default: fault

  • Outputs:
    On screen message:
    • Confirmed message if records are valid.
    • Otherwise, error message.

  • Notes:
    • Must include:
      • lexCheck${YEAR}dist.jar (for LVG APIs) or
      • lexCheck${YEAR}api.jar and lvg${YEAR}api.jar
    • Benchmark run time for Lexicon to generate both Lexicon and inflVars: 3 ~ 5 sec.

  • Examples:
    • shell> ValidateSyntaxFromTextFile lexicon.txt ./data/Files/prepositions.data ./data/Files/particles.data -v
    • shell> ValidateSyntaxFromTextFile lexicon.txt ./data/Files/prepositions.data ./data/Files/particles.data