public class RunParmFile extends java.lang.Object implements java.util.Iterator<RunParmArrayEntry>, java.io.Closeable
Comment lines are identified in RunParmFileArrayEntry and this class knows nothing whatsoever about mmj or Metamath.
Coincidentally (ha), the "String[] args" parameter for the constructor is the same as the BatchMMJ2 command line parms.
Constructor and Description |
---|
RunParmFile(Paths paths,
java.lang.String runParmFileNameArgument)
Construct using
Paths object and runParmFileName argument. |
Modifier and Type | Method and Description |
---|---|
void |
close()
Close RunParmFile.
|
static void |
displayArgumentOptionReport(Paths paths,
java.lang.String runParmFileNameArgument)
Dumps the absolute path names to System.out for testing purposes.
|
java.lang.String |
getAbsolutePath()
Returns the canonical path name of the RunParmFile.
|
boolean |
hasNext()
Checks to see if another line of input is available.
|
RunParmArrayEntry |
next()
Returns next line of RunParmFile formatted as a fully parsed
RunParmArrayEntry object.
|
public RunParmFile(Paths paths, java.lang.String runParmFileNameArgument) throws MMJException, java.io.IOException
Paths
object and runParmFileName argument.paths
- mmj2 Paths object.runParmFileNameArgument
- file name of RunParm file.MMJException
- if an error occurredjava.io.IOException
- if an error occurredpublic static void displayArgumentOptionReport(Paths paths, java.lang.String runParmFileNameArgument) throws java.io.IOException
paths
- the path namesrunParmFileNameArgument
- if an error occurredjava.io.IOException
- if an error occurredpublic boolean hasNext()
hasNext
in interface java.util.Iterator<RunParmArrayEntry>
public RunParmArrayEntry next()
next
in interface java.util.Iterator<RunParmArrayEntry>
java.lang.IllegalArgumentException
- if parsing problem.public void close() throws java.io.IOException
close
in interface java.io.Closeable
close
in interface java.lang.AutoCloseable
java.io.IOException
- if IO errorpublic java.lang.String getAbsolutePath()