Class ExternalOracle
- java.lang.Object
- 
- edu.odu.cs.zeil.codegrader.oracle.Oracle
- 
- edu.odu.cs.zeil.codegrader.oracle.ExternalOracle
 
 
- 
 public class ExternalOracle extends Oracle Oracle that works by running an external command.
- 
- 
Nested Class Summary- 
Nested classes/interfaces inherited from class edu.odu.cs.zeil.codegrader.oracle.OracleOracle.ScoringOptions
 
- 
 - 
Field Summary- 
Fields inherited from class edu.odu.cs.zeil.codegrader.oracle.OraclePASSED_TEST_MESSAGE
 
- 
 - 
Constructor SummaryConstructors Constructor Description ExternalOracle(OracleProperties config, TestCase testCase, Submission sub, Stage submitterStage)Create an oracle that launches an external command.
 - 
Method SummaryAll Methods Instance Methods Concrete Methods Modifier and Type Method Description OracleResultcompare(java.lang.String expected, java.lang.String actual)Compare two strings to see if one is an acceptable variant of the other.OracleResultexecuteOracle(java.io.File expected, java.io.File actual)Runs the test case using the code in submission.- 
Methods inherited from class edu.odu.cs.zeil.codegrader.oracle.OraclegetCap, getCommand, getIgnoreCase, getIgnoreEmptyLines, getIgnorePunctuation, getIgnoreWS, getNumbersOnly, getPattern, getPrecision, getScoring, getStage, getSubmission, getTestCase
 
- 
 
- 
- 
- 
Constructor Detail- 
ExternalOraclepublic ExternalOracle(OracleProperties config, TestCase testCase, Submission sub, Stage submitterStage) Create an oracle that launches an external command.- Parameters:
- config- properties
- testCase- the test case on which it is applied
- sub- submission being evaluated
- submitterStage- stage where submitter code has been built
 
 
- 
 - 
Method Detail- 
comparepublic OracleResult compare(java.lang.String expected, java.lang.String actual) Compare two strings to see if one is an acceptable variant of the other. The precise meaning of "acceptable" depends on the settings.
 - 
executeOraclepublic OracleResult executeOracle(java.io.File expected, java.io.File actual) Runs the test case using the code in submission. Standard out and standard err are captured and available as getOutput() and getErr(). The status code is also available.- Parameters:
- expected- file with expected output
- actual- file with actual output
- Returns:
- result of executing the oracle
 
 
- 
 
-