public class PostScriptLine extends AbstractEvent
COMMENT, DSC_COMMENT, EOF, HEADER_COMMENT, LINE
Constructor and Description |
---|
PostScriptLine(java.lang.String line)
Creates a new instance.
|
Modifier and Type | Method and Description |
---|---|
PostScriptLine |
asLine()
Casts this instance to a PostScriptLine if possible.
|
void |
generate(PSGenerator gen)
Writes the event to the given PSGenerator.
|
int |
getEventType()
Returns the event type.
|
java.lang.String |
getLine()
Returns the code line.
|
boolean |
isLine()
Indicates whether the instance is a PostScript line.
|
asDSCComment, isComment, isDSCComment, isHeaderComment
public PostScriptLine(java.lang.String line)
line
- the code linepublic java.lang.String getLine()
public void generate(PSGenerator gen) throws java.io.IOException
DSCEvent
gen
- the PSGenerator to write tojava.io.IOException
- In case of an I/O errorDSCEvent.generate(org.apache.xmlgraphics.ps.PSGenerator)
public int getEventType()
DSCEvent
DSCParserConstants
)DSCEvent.getEventType()
public PostScriptLine asLine()
DSCEvent
asLine
in interface DSCEvent
asLine
in class AbstractEvent
AbstractEvent.asLine()
public boolean isLine()
DSCEvent
isLine
in interface DSCEvent
isLine
in class AbstractEvent
AbstractEvent.isLine()
Copyright 1999-2012 The Apache Software Foundation. All Rights Reserved.