Package stanfordlogic.util

Examples of stanfordlogic.util.CommandLineParser


    /**
     * @param args
     */
    public static void main(String[] args)
    {
        CommandLineParser clp = new CommandLineParser();
        clp.addFlag("--daemon");
        clp.addParam("--port");
        clp.setUsage("usage: <--daemon> <--port='portNum'>");

        clp.parse(args);
        boolean daemonMode = clp.argSpecified("--daemon");
        int port = clp.argSpecified("--port") ? clp.getArgAsInt("--port")
                : DEFAULT_PORT;

        if (!daemonMode)
        {
            System.out.println(" ########################################");
View Full Code Here


public class PrintTGTree
{
    public static void main(String[] args)
    {
        CommandLineParser clp = new CommandLineParser();
        clp.addFlag("--with-examples");
       
        clp.parse(args);
       
        boolean examples = clp.argSpecified("--with-examples");
       
        TGTree tree = TGTree.readFromFile(new File("TGTree.bin"));
        System.out.println(tree.getString(examples));
    }
View Full Code Here

    /**
     * @param args
     */
    public static void main(String[] args)
    {
        CommandLineParser clp = new CommandLineParser();
        clp.addFlag("--daemon");
        clp.addParam("--port");
        clp.setUsage("usage: <--daemon> <--port='portNum'>");

        clp.parse(args);
        boolean daemonMode = clp.argSpecified("--daemon");
        int port = clp.argSpecified("--port") ? clp.getArgAsInt("--port")
                : DEFAULT_PORT;
       
        if (!daemonMode)
        {
            System.out.println(" ########################################");
View Full Code Here

{
    public static void main(String[] args)
    {
        try
        {
            CommandLineParser clp = new CommandLineParser();
            clp.addFlag("--explore");
            clp.addParam("--config");
            clp.parse(args);
           
            boolean explore = clp.argSpecified("--explore");
            String config_path = clp.getArgAsString("--config");
        
            if(config_path == null)
            {
                config_path = "config.properties";
            }
View Full Code Here

{  
    public static void main(String[] args)
    {  
        try
        {
            CommandLineParser clp = new CommandLineParser();
            clp.addParam("--gamedef");
            clp.addParam("--config");
            clp.addParam("--iterations");
            clp.parse(args);
           
            String config_path = clp.getArgAsString("--config");
            String path_to_gdl = clp.getArgAsString("--gamedef");
            int iterations = Integer.parseInt(clp.getArgAsString("--iterations"));
        
            if(config_path == null)
            {
                config_path = "config.properties";
            }
View Full Code Here

TOP

Related Classes of stanfordlogic.util.CommandLineParser

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.