Class CosSaveParams
- java.lang.Object
-
- com.adobe.internal.pdftoolkit.core.cos.CosSaveParams
-
- All Implemented Interfaces:
java.lang.Cloneable
public class CosSaveParams extends java.lang.Object implements java.lang.Cloneable
-
-
Field Summary
Fields Modifier and Type Field Description static int
CURRENT_XREF
static int
SAVE_STYLE_DEFAULT
static int
SAVE_STYLE_FULL
static int
SAVE_STYLE_INCREMENTAL
static int
SAVE_STYLE_LINEAR
static int
XREFHYBRID
static int
XREFSTREAM
static int
XREFTABLE
-
Constructor Summary
Constructors Constructor Description CosSaveParams(int saveStyle)
Constructor with specified save style.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description java.lang.Object
clone()
Produce a simple, shallow clone.boolean
getCloseAfterSave()
Returns true if document to be closed after save.java.util.Map
getExtensions()
Returns version extensions.boolean
getForceCompress()
Returns true if force compression to be used.java.lang.String
getHeader()
Returns header.java.lang.String
getHeaderToken()
Returns header token.int
getSaveStyle()
Returns save style to save with.boolean
getSaveToCopy()
Save the CosDocument to the ByteWriter given during save but do NOT make it the backing store and continue to use the existing one.ByteWriter
getTempByteWriter()
Only for internal engineering use.java.lang.String
getVersion()
Returns version to save with.int
getXrefStyle()
Returns xref style to save with.void
setCloseAfterSave(boolean closeAfterSave)
Sets true if document to be closed after save.void
setExtensions(java.util.Map extensions)
Sets version extensions to use.void
setForceCompress(boolean forceCompress)
Specifies if force compression to be used.void
setHeader(java.lang.String header)
Sets header to sue while saving.void
setHeaderToken(java.lang.String headerToken)
Sets header token.void
setSaveStyle(int saveStyle)
Sets save style to save with.void
setSaveToCopy(boolean saveToCopy)
Save the CosDocument to the ByteWriter given during save but do NOT make it the backing store and continue to use the existing one.void
setTempByteWriter(ByteWriter tempByteWriter)
Only for internal engineering use.void
setVersion(java.lang.String version)
Sets version to save with.void
setXrefStyle(int xrefstyle)
-
-
-
Field Detail
-
CURRENT_XREF
public static final int CURRENT_XREF
- See Also:
- Constant Field Values
-
XREFTABLE
public static final int XREFTABLE
- See Also:
- Constant Field Values
-
XREFSTREAM
public static final int XREFSTREAM
- See Also:
- Constant Field Values
-
XREFHYBRID
public static final int XREFHYBRID
- See Also:
- Constant Field Values
-
SAVE_STYLE_DEFAULT
public static final int SAVE_STYLE_DEFAULT
- See Also:
- Constant Field Values
-
SAVE_STYLE_INCREMENTAL
public static final int SAVE_STYLE_INCREMENTAL
- See Also:
- Constant Field Values
-
SAVE_STYLE_FULL
public static final int SAVE_STYLE_FULL
- See Also:
- Constant Field Values
-
SAVE_STYLE_LINEAR
public static final int SAVE_STYLE_LINEAR
- See Also:
- Constant Field Values
-
-
Method Detail
-
setHeader
public void setHeader(java.lang.String header)
Sets header to sue while saving.
-
getHeader
public java.lang.String getHeader()
Returns header.
-
setHeaderToken
public void setHeaderToken(java.lang.String headerToken) throws PDFInvalidParameterException
Sets header token.- Throws:
PDFInvalidParameterException
-
getHeaderToken
public java.lang.String getHeaderToken()
Returns header token.
-
setVersion
public void setVersion(java.lang.String version)
Sets version to save with.
-
getVersion
public java.lang.String getVersion()
Returns version to save with.
-
getExtensions
public java.util.Map getExtensions()
Returns version extensions.
-
setExtensions
public void setExtensions(java.util.Map extensions)
Sets version extensions to use.
-
setXrefStyle
public void setXrefStyle(int xrefstyle)
- Parameters:
xrefstyle
- - int enum for specifying full save xref style: CURRENT_XREF - use existing style (default for existing document) XREFTABLE - xref table (default for new document) XREFSTREAM - xref stream (required if compressed object streams) XREFHYBRID - hybrid (compressed object streams only visible to v 1.5 or later)
-
getXrefStyle
public int getXrefStyle()
Returns xref style to save with.
-
setSaveStyle
public void setSaveStyle(int saveStyle)
Sets save style to save with.
-
getSaveStyle
public int getSaveStyle()
Returns save style to save with.
-
setCloseAfterSave
public void setCloseAfterSave(boolean closeAfterSave)
Sets true if document to be closed after save.
-
getCloseAfterSave
public boolean getCloseAfterSave()
Returns true if document to be closed after save.
-
setForceCompress
public void setForceCompress(boolean forceCompress)
Specifies if force compression to be used.
-
getForceCompress
public boolean getForceCompress()
Returns true if force compression to be used.
-
setTempByteWriter
public void setTempByteWriter(ByteWriter tempByteWriter)
Only for internal engineering use. This api can change without notice.
-
getTempByteWriter
public ByteWriter getTempByteWriter()
Only for internal engineering use. This api can change without notice.
-
setSaveToCopy
public void setSaveToCopy(boolean saveToCopy)
Save the CosDocument to the ByteWriter given during save but do NOT make it the backing store and continue to use the existing one.- Parameters:
saveToCopy
- will document be saved as a copy
-
getSaveToCopy
public boolean getSaveToCopy()
Save the CosDocument to the ByteWriter given during save but do NOT make it the backing store and continue to use the existing one.
-
clone
public java.lang.Object clone()
Produce a simple, shallow clone.
-
-