Package org.ghost4j.converter
Class PSConverter
- java.lang.Object
-
- org.ghost4j.AbstractComponent
-
- org.ghost4j.AbstractRemoteComponent
-
- org.ghost4j.converter.AbstractRemoteConverter
-
- org.ghost4j.converter.PSConverter
-
- All Implemented Interfaces:
Component
,Converter
,RemoteConverter
public class PSConverter extends AbstractRemoteConverter
PS converter.
-
-
Field Summary
Fields Modifier and Type Field Description private int
device
Ghostscript device to use to perform conversion.private int
languageLevel
PostScript language level: 1, 2 or 3.static int
OPTION_DEVICE_AUTO
static int
OPTION_DEVICE_PS2WRITE
static int
OPTION_DEVICE_PSWRITE
private PaperSize
paperSize
Define standard paper size for the generated PDF file.-
Fields inherited from class org.ghost4j.AbstractRemoteComponent
maxProcessCount, processCount
-
Fields inherited from class org.ghost4j.AbstractComponent
supportedDocumentClasses
-
-
Constructor Summary
Constructors Constructor Description PSConverter()
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description int
getDevice()
int
getLanguageLevel()
PaperSize
getPaperSize()
static void
main(java.lang.String[] args)
Main method used to start the converter in standalone 'slave mode'.void
run(Document document, java.io.OutputStream outputStream)
void
setDevice(int device)
void
setLanguageLevel(int languageLevel)
void
setPaperSize(PaperSize paperSize)
-
Methods inherited from class org.ghost4j.converter.AbstractRemoteConverter
convert, remoteConvert, startRemoteConverter
-
Methods inherited from class org.ghost4j.AbstractRemoteComponent
buildJavaFork, getMaxProcessCount, getProcessCount, getRemoteComponent, isStandAloneModeSupported, setMaxProcessCount, startRemoteServer, waitForFreeProcess
-
Methods inherited from class org.ghost4j.AbstractComponent
assertDeviceSupported, assertDocumentSupported, copySettings, extractSettings, isDeviceSupported
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface org.ghost4j.Component
copySettings, extractSettings
-
Methods inherited from interface org.ghost4j.converter.RemoteConverter
setMaxProcessCount
-
-
-
-
Field Detail
-
OPTION_DEVICE_AUTO
public static final int OPTION_DEVICE_AUTO
- See Also:
- Constant Field Values
-
OPTION_DEVICE_PSWRITE
public static final int OPTION_DEVICE_PSWRITE
- See Also:
- Constant Field Values
-
OPTION_DEVICE_PS2WRITE
public static final int OPTION_DEVICE_PS2WRITE
- See Also:
- Constant Field Values
-
device
private int device
Ghostscript device to use to perform conversion.
-
languageLevel
private int languageLevel
PostScript language level: 1, 2 or 3.
-
paperSize
private PaperSize paperSize
Define standard paper size for the generated PDF file. This parameter is ignored if a paper size is provided in the input file. Default value is "letter".
-
-
Method Detail
-
main
public static void main(java.lang.String[] args) throws ConverterException
Main method used to start the converter in standalone 'slave mode'.- Parameters:
args
-- Throws:
ConverterException
-
run
public void run(Document document, java.io.OutputStream outputStream) throws java.io.IOException, ConverterException, DocumentException
- Specified by:
run
in classAbstractRemoteConverter
- Throws:
java.io.IOException
ConverterException
DocumentException
-
getLanguageLevel
public int getLanguageLevel()
-
setLanguageLevel
public void setLanguageLevel(int languageLevel)
-
getPaperSize
public PaperSize getPaperSize()
-
setPaperSize
public void setPaperSize(PaperSize paperSize)
-
getDevice
public int getDevice()
-
setDevice
public void setDevice(int device)
-
-