DSCParserConstants
public final class DSCTools extends java.lang.Object implements DSCParserConstants
COMMENT, DSC_COMMENT, EOF, HEADER_COMMENT, LINE
Modifier and Type | Method | Description |
---|---|---|
static DSCHeaderComment |
checkAndSkipDSC30Header(DSCParser parser) |
Verifies that the file being parsed is a DSC 3.0 file.
|
static boolean |
headerCommentsEndHere(DSCEvent event) |
Indicates whether the given event ends a header comment section according to the rules in
DSC 3.0, chapter 4.4.
|
static DSCComment |
nextPageOrTrailer(DSCParser parser,
PSGenerator gen) |
Advances the parser to the next page or to the trailer or the end of file comment.
|
public static boolean headerCommentsEndHere(DSCEvent event)
event
- the event to checkpublic static DSCHeaderComment checkAndSkipDSC30Header(DSCParser parser) throws DSCException, java.io.IOException
parser
- the DSC parserDSCException
- In case of a violation of the DSC specjava.io.IOException
- In case of an I/O problempublic static DSCComment nextPageOrTrailer(DSCParser parser, PSGenerator gen) throws java.io.IOException, DSCException
parser
- the DSC parsergen
- the PSGenerator instance to pass the skipped events through tojava.io.IOException
- In case of an I/O errorDSCException
- In case of a violation of the DSC specCopyright 1999-2016 The Apache Software Foundation. All Rights Reserved.