当前位置: 首页>>代码示例>>Java>>正文


Java FlaggedOption.setHelp方法代码示例

本文整理汇总了Java中com.martiansoftware.jsap.FlaggedOption.setHelp方法的典型用法代码示例。如果您正苦于以下问题:Java FlaggedOption.setHelp方法的具体用法?Java FlaggedOption.setHelp怎么用?Java FlaggedOption.setHelp使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在com.martiansoftware.jsap.FlaggedOption的用法示例。


在下文中一共展示了FlaggedOption.setHelp方法的5个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。

示例1: initJSAP

import com.martiansoftware.jsap.FlaggedOption; //导入方法依赖的package包/类
private static void initJSAP() throws JSAPException {
	jsap = new JSAP();
	    	
    FlaggedOption opt8 = new FlaggedOption(ARG_RESULT_DIR_LONG)
    	.setStringParser(JSAP.STRING_PARSER)
    	.setRequired(false) 
    	.setShortFlag(ARG_RESULT_DIR_SHORT)
    	.setLongFlag(ARG_RESULT_DIR_LONG)
    	.setDefault(".");
    opt8.setHelp("PATH/TO/directory where to search for results (output directory of DMTable).");
    
    jsap.registerParameter(opt8);	
    
    FlaggedOption opt9 = new FlaggedOption(ARG_OUTPUT_DIR_LONG)
    	.setStringParser(JSAP.STRING_PARSER)
    	.setRequired(false) 
    	.setShortFlag(ARG_OUTPUT_DIR_SHORT)
    	.setLongFlag(ARG_OUTPUT_DIR_LONG)
    	.setDefault(".");
    opt9.setHelp("PATH/TO/directory where to output results (does not need to exist).");
    
    jsap.registerParameter(opt9);	
    
    FlaggedOption opt1 = new FlaggedOption(ARG_OUTPUT_FILE_NAME_LONG)
    	.setStringParser(JSAP.STRING_PARSER)
    	.setRequired(false) 
    	.setShortFlag(ARG_OUTPUT_FILE_NAME_SHORT)
    	.setLongFlag(ARG_OUTPUT_FILE_NAME_LONG)
    	.setDefault("DMTable-Results.xls");
    opt1.setHelp("Name of the filename to produce. If it won't end with .xls, it will be extended with this suffix.");

    jsap.registerParameter(opt1);	    	   
}
 
开发者ID:kefik,项目名称:Pogamut3,代码行数:34,代码来源:MainExcelReport.java

示例2: initJSAP

import com.martiansoftware.jsap.FlaggedOption; //导入方法依赖的package包/类
private static void initJSAP() throws JSAPException {
jsap = new JSAP();
    	
  	FlaggedOption opt1 = new FlaggedOption(ARG_UT2004_HOME_DIR_LONG)
      	.setStringParser(JSAP.STRING_PARSER)
      	.setRequired(true) 
      	.setShortFlag(ARG_UT2004_HOME_DIR_SHORT)
      	.setLongFlag(ARG_UT2004_HOME_DIR_LONG);    
      opt1.setHelp("UT2004 home directory containing maps (within Maps folder).");
      
      jsap.registerParameter(opt1);
      
      FlaggedOption opt2 = new FlaggedOption(ARG_MAPS_LONG)
   	.setStringParser(JSAP.STRING_PARSER)
   	.setRequired(false) 
   	.setShortFlag(ARG_MAPS_SHORT)
   	.setLongFlag(ARG_MAPS_LONG);    
   opt2.setHelp("Semicolon separated list of maps for which navmeshes should be generated, e.g.: DM-Flux2;DM-1on1-Trite");
   
   jsap.registerParameter(opt2);
   
   Switch opt3 = new Switch(ARG_ALL_LONG)
	.setShortFlag(ARG_ALL_SHORT)
	.setLongFlag(ARG_ALL_LONG);    
opt3.setHelp("Create navmeshes for all maps (*.ut2) from Maps directory.");
	
   jsap.registerParameter(opt3);
   
   FlaggedOption opt4 = new FlaggedOption(ARG_OUTPUT_LONG)
   	.setStringParser(JSAP.STRING_PARSER)
   	.setRequired(false) 
   	.setShortFlag(ARG_OUTPUT_SHORT)
   	.setLongFlag(ARG_OUTPUT_LONG)
   	.setDefault("./output");    
   opt4.setHelp("Target directory where to output navmeshes and other files.");
   
   jsap.registerParameter(opt4);
   
   Switch opt5 = new Switch(ARG_REWRITE_LONG)
	.setShortFlag(ARG_REWRITE_SHORT)
	.setLongFlag(ARG_REWRITE_LONG);    
   opt5.setHelp("Rewrite any existing files when outputting navmesh(es).");
   
   jsap.registerParameter(opt5);
   
   Switch opt6 = new Switch(ARG_CONTINUE_LONG)
	.setShortFlag(ARG_CONTINUE_SHORT)
	.setLongFlag(ARG_CONTINUE_LONG);    
   opt6.setHelp("Do not rewrite any existing files, take them as inputs (e.g. continue the job / create missing files) if possible. ");
  
  	jsap.registerParameter(opt6);
 	}
 
开发者ID:kefik,项目名称:Pogamut3,代码行数:53,代码来源:Main.java

示例3: initJSAP

import com.martiansoftware.jsap.FlaggedOption; //导入方法依赖的package包/类
private static void initJSAP() throws JSAPException {
jsap = new JSAP();
    	
  	FlaggedOption opt1 = new FlaggedOption(ARG_INPUT_FILE_LONG)
      	.setStringParser(JSAP.STRING_PARSER)
      	.setRequired(true) 
      	.setShortFlag(ARG_INPUT_FILE_SHORT)
      	.setLongFlag(ARG_INPUT_FILE_LONG);    
      opt1.setHelp("Source file to read (.xml output from UShock). We're assuming that the file name (without its extension) is the name of the map.");
      
      jsap.registerParameter(opt1);
      
      FlaggedOption opt2 = new FlaggedOption(ARG_OUTPUT_DIR_LONG)
   	.setStringParser(JSAP.STRING_PARSER)
   	.setRequired(false) 
   	.setShortFlag(ARG_OUTPUT_DIR_SHORT)
   	.setLongFlag(ARG_OUTPUT_DIR_LONG)
   	.setDefault("./output");    
   opt2.setHelp("Target dir where to output results (.obj, .scale, .center).");
   
   jsap.registerParameter(opt2);
   
   FlaggedOption opt3 = new FlaggedOption(ARG_JUMPPAD_FILE_LONG)
   	.setStringParser(JSAP.STRING_PARSER)
   	.setRequired(false) 
   	.setShortFlag(ARG_JUMPPAD_FILE_SHORT)
   	.setLongFlag(ARG_JUMPPAD_FILE_LONG);    
   opt3.setHelp("Jumppad file containing jumppad per row in the form x;y;z e.g. 1,25;2,34;3,45 ... if not specified we will use INPUT_FILE.jumppads as default.");
   
   jsap.registerParameter(opt3);
   
   FlaggedOption opt5 = new FlaggedOption(ARG_ENVELOPE_FILE_LONG)
   	.setStringParser(JSAP.STRING_PARSER)
   	.setRequired(false) 
   	.setShortFlag(ARG_ENVELOPE_FILE_SHORT)
   	.setLongFlag(ARG_ENVELOPE_FILE_LONG);    
   opt5.setHelp("Envelope file containing minX;minY;minZ;maxX;maxY;maxZ coordinates ... if not specified we will use INPUT_FILE.envelope as default.");
   
   jsap.registerParameter(opt5);
   
   FlaggedOption opt4 = new FlaggedOption(ARG_UT2004_DIR_LONG)
   	.setStringParser(JSAP.STRING_PARSER)
   	.setRequired(false) 
   	.setShortFlag(ARG_UT2004_DIR_SHORT)
   	.setLongFlag(ARG_UT2004_DIR_LONG)
   	.setDefault("./output");    
   opt4.setHelp("Path to UT2004 that should be used to extract jumppads for the map.");
   
   jsap.registerParameter(opt4);
 	}
 
开发者ID:kefik,项目名称:Pogamut3,代码行数:51,代码来源:Main.java

示例4: cfgJSAP

import com.martiansoftware.jsap.FlaggedOption; //导入方法依赖的package包/类
private static void cfgJSAP() throws JSAPException {
	// Assists with capturing command-line parameters and constructing usage
	jsap = new JSAP();

	// top design flag and source file
	FlaggedOption optTopFileName = new FlaggedOption("topFileName");
	optTopFileName.setStringParser(JSAP.STRING_PARSER);
	optTopFileName.setShortFlag('t');
	optTopFileName.setLongFlag("top");
	optTopFileName.setHelp("PHDL top level design file name.");
	jsap.registerParameter(optTopFileName);

	// directory containing phdl source files
	FlaggedOption optDirectory = new FlaggedOption("directory");
	optDirectory.setStringParser(JSAP.STRING_PARSER);
	optDirectory.setShortFlag('d');
	optDirectory.setLongFlag("dir");
	optDirectory.setHelp("Directory where phdl source files are located");
	jsap.registerParameter(optDirectory);

	// source files
	UnflaggedOption optFileName = new UnflaggedOption("fileName");
	optFileName.setStringParser(JSAP.STRING_PARSER);
	optFileName.setGreedy(true);
	optFileName.setHelp("PHDL source file name.");
	jsap.registerParameter(optFileName);

	// verbose flag
	Switch swVerbose = new Switch("verbose");
	swVerbose.setShortFlag('v');
	swVerbose.setLongFlag("verbose");
	swVerbose.setHelp("Requests verbose output.");
	jsap.registerParameter(swVerbose);

	// generate hierarcy DOT and PNG output flag
	Switch swDOT = new Switch("png");
	swDOT.setShortFlag('p');
	swDOT.setLongFlag("png");
	swDOT.setHelp("Exports hierarchy PNG pictures using DOT in the /png folder.");
	jsap.registerParameter(swDOT);

	// suppress warnings flag
	Switch swSuppress = new Switch("suppress");
	swSuppress.setShortFlag('s');
	swSuppress.setLongFlag("suppress");
	swSuppress.setHelp("Suppress all warnings from the compiler.");
	jsap.registerParameter(swSuppress);

	// report design hierarchy on the command line flag
	Switch swReport = new Switch("report");
	swReport.setShortFlag('r');
	swReport.setLongFlag("report");
	swReport.setHelp("Report design hierarchy at the command line. (Extremely verbose)");
	jsap.registerParameter(swReport);

	// clean flag (remove all generated files and folders)
	Switch swClean = new Switch("clean");
	swClean.setShortFlag('c');
	swClean.setLongFlag("clean");
	swClean.setHelp("Clean (remove) all generated files and folders.");
	jsap.registerParameter(swClean);

	// generate AST output from parser (for debug only)
	Switch swAST = new Switch("ast");
	swAST.setShortFlag('a');
	swAST.setLongFlag("ast");
	swAST.setHelp("Generates a DOT graphical ast of all source files in the /ast folder.");
	jsap.registerParameter(swAST);

	// help
	Switch swHelp = new Switch("help");
	swHelp.setShortFlag('h');
	swHelp.setLongFlag("help");
	swHelp.setHelp("Display this usage help.");
	jsap.registerParameter(swHelp);
}
 
开发者ID:timofonic,项目名称:PHDL,代码行数:77,代码来源:Compile.java

示例5: initJSAP

import com.martiansoftware.jsap.FlaggedOption; //导入方法依赖的package包/类
private static void initJSAP() throws JSAPException {
jsap = new JSAP();
    	
  	FlaggedOption opt1 = new FlaggedOption(ARG_AGENT_FQCN_LONG)
      	.setStringParser(JSAP.STRING_PARSER)
      	.setRequired(true) 
      	.setShortFlag(ARG_AGENT_FQCN_SHORT)
      	.setLongFlag(ARG_AGENT_FQCN_LONG);    
      opt1.setHelp("Agent fully-qualified class name to evaluate. Must be present on classpath.");
      
      jsap.registerParameter(opt1);
      
      FlaggedOption opt2 = new FlaggedOption(ARG_AGNET_ID_LONG)
   	.setStringParser(JSAP.STRING_PARSER)
   	.setRequired(true) 
   	.setShortFlag(ARG_AGENT_ID_SHORT)
   	.setLongFlag(ARG_AGNET_ID_LONG);    
   opt2.setHelp("Id of the agent that will serve as identificator within results file.");
	
   jsap.registerParameter(opt2);
   
   FlaggedOption opt3 = new FlaggedOption(ARG_ONE_RUN_REPETITIONS_LONG)
   	.setStringParser(JSAP.INTEGER_PARSER)
   	.setRequired(false)
   	.setDefault("10")
   	.setShortFlag(ARG_ONE_RUN_REPETITIONS_SHORT)
   	.setLongFlag(ARG_ONE_RUN_REPETITIONS_LONG);    
   opt3.setHelp("How many times should be one PacMan game configuration be repeated (in order to gain statistically sound data).");
   
   jsap.registerParameter(opt3);
   
   FlaggedOption opt31 = new FlaggedOption(ARG_SIMULATOR_OPTIONS_LONG)
   	.setStringParser(JSAP.STRING_PARSER)
   	.setRequired(true) 
   	.setShortFlag(ARG_SIMULATOR_OPTIONS_SHORT)
   	.setLongFlag(ARG_SIMULATOR_OPTIONS_LONG);    
   opt31.setHelp("List of simulator options.");
	
   jsap.registerParameter(opt31);
   
   FlaggedOption opt32 = new FlaggedOption(ARG_RESULT_DIR_LONG)
   	.setStringParser(JSAP.STRING_PARSER)
   	.setRequired(false)
   	.setDefault("./results")
   	.setShortFlag(ARG_RESULT_DIR_SHORT)
   	.setLongFlag(ARG_RESULT_DIR_LONG);    
   opt32.setHelp("Directory where to output results, will be created if not exist.");
   
   jsap.registerParameter(opt32);
   
   FlaggedOption opt33 = new FlaggedOption(ARG_RUNS_COUNT_LONG)
   	.setStringParser(JSAP.INTEGER_PARSER)
   	.setRequired(false)
   	.setDefault("100")
   	.setShortFlag(ARG_RUNS_COUNT_SHORT)
   	.setLongFlag(ARG_RUNS_COUNT_LONG);    
   opt33.setHelp("How many different levels should an agent be evaluated in.");
	
   jsap.registerParameter(opt33);
  
   FlaggedOption opt6 = new FlaggedOption(ARG_SEED_LONG)
   	.setStringParser(JSAP.INTEGER_PARSER)
   	.setRequired(false)
   	.setDefault("0")
   	.setShortFlag(ARG_SEED_SHORT)
   	.setLongFlag(ARG_SEED_LONG);    
   opt6.setHelp("Seed to be used when generating seeds for respective levels.");
	
   jsap.registerParameter(opt6);
 	}
 
开发者ID:kefik,项目名称:MsPacMan-vs-Ghosts-AI,代码行数:71,代码来源:EvaluateAgentConsole.java


注:本文中的com.martiansoftware.jsap.FlaggedOption.setHelp方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。