| 1 16 package org.outerj.daisy.doctaskrunner.commonimpl; 17 18 import org.outerj.daisy.doctaskrunner.TaskSpecification; 19 20 public class TaskSpecificationImpl implements TaskSpecification { 21 private final String description; 22 private final String script; 23 private final String scriptLanguage; 24 private final boolean stopOnFirstError; 25 26 public TaskSpecificationImpl(String description, String script, String scriptLanguage, boolean stopOnFirstError) { 27 if (description == null) 28 throw new IllegalArgumentException ("description parameter is null"); 29 if (script == null) 30 throw new IllegalArgumentException ("script parameter is null"); 31 if (scriptLanguage == null) 32 throw new IllegalArgumentException ("scriptLanguage parameter is null"); 33 34 this.description = description; 35 this.script = script; 36 this.scriptLanguage = scriptLanguage; 37 this.stopOnFirstError = stopOnFirstError; 38 } 39 40 public String getDescription() { 41 return description; 42 } 43 44 public String getScript() { 45 return script; 46 } 47 48 public String getScriptLanguage() { 49 return scriptLanguage; 50 } 51 52 public boolean stopOnFirstError() { 53 return stopOnFirstError; 54 } 55 } 56 | Popular Tags |