// FILE. . . . . d:/hak/hlt/src/hlt/fot/fuz/syntax/sources/FuzzyFOTLatticeMain.java
// EDIT BY . . . Hassan Ait-Kaci
// ON MACHINE. . Hak-Laptop
// STARTED ON. . Sun Jul 15 08:10:15 2018

/**
 * @version     Last modified on Sun Sep 29 14:50:52 2019 by hak
 * @author      <a href="mailto:hak@acm.org">Hassan A&iuml;t-Kaci</a>
 * @copyright   &copy; <a href="http://www.hassan-ait-kaci.net/">by the author</a>
 */

import java.io.File;

/**
 * This file (<b><tt>FuzzyFOTLatticeMain</tt></b>) defines is the root
 * Java class for the <b><tt>FFF</tt></b> parser <b><tt><a
 * href="../FuzzyFOTLatticeDoc/fff-description.html">FFF</a></tt></b>.
 *
 * @see		FuzzyFOTLattice
 * @see		FuzzyFOTLatticeParser
 * @see		FuzzyFOTLatticeTokenizer
 * @see 	fff-description
 * @see 	fff-declarations
 * @see 	fff-grammar-rules
 * @see 	fff-parser-javacode
 * @see 	fff-ancillary-classes
 */
public class FuzzyFOTLatticeMain
{
  public static FuzzyFOTLatticeTokenizer tokenizer;
  public static FuzzyFOTLatticeParser parser;
  
  public static void main (String args[])
    {
      try
        {
          if(args.length>0)
            tokenizer = new FuzzyFOTLatticeTokenizer(new File(args[0]));
          else
            tokenizer = new FuzzyFOTLatticeTokenizer();

          try
            {
              (parser = new FuzzyFOTLatticeParser(tokenizer)).parse();
            }
          catch (Exception e)
            {
              System.err.println("*** Parsing error: "+e);
	      e.printStackTrace();
            }
        }
      catch (Exception e)
        {
          System.err.println("*** Tokenizing error: "+e);
        }
    }
}
