⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 runonegroovyscript.java

📁 大名鼎鼎的java动态脚本语言。已经通过了sun的认证
💻 JAVA
字号:
package groovy.security;import java.io.File;import junit.framework.Test;import junit.framework.TestSuite;import junit.textui.TestRunner;/** * Test case for running a single groovy script parsed from a .groovy file. */public class RunOneGroovyScript extends SecurityTestSupport {	protected static String file;	    public static void main(String[] args) {        if (args.length > 0) {            file = args[0];        }        TestRunner.run( suite() );    }        public static Test suite() {    	return new TestSuite(RunOneGroovyScript.class);    }	public void testScript() {        String fileName = System.getProperty("script", file);        if (fileName == null) {            throw new RuntimeException("No filename given in the 'script' system property so cannot run a Groovy script");        }		assertExecute(new File(fileName), null);	}}

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -