|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES All Classes | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.at4j.zip.builder.ZipEntrySettings
public class ZipEntrySettings
This object contains the settings for Zip entries. It is used by the
ZipBuilder
.
The properties and methods of this object works as is described in the
ArchiveEntrySettings
documentation.
ZipBuilder
Constructor Summary | |
---|---|
ZipEntrySettings()
Create a new read/write Zip entry settings object. |
|
ZipEntrySettings(ZipEntrySettings template)
Create a new read/write Zip entry settings object using the supplied object as a template. |
Method Summary | |
---|---|
ZipEntrySettings |
addExtraFieldFactory(ZipEntryExtraFieldFactory f)
Add a ZipEntryExtraFieldFactory that creates a Zip entry extra
field for each Zip entry configured by this settings object. |
ZipEntrySettings |
clone()
Clone this settings object. |
ZipEntrySettings |
combineWith(ZipEntrySettings zes)
Combine this settings object with the supplied object. |
String |
getComment()
Get the Zip entry comment. |
ZipEntryCompressionMethod |
getCompressionMethod()
Get the Zip entry compression method. |
ZipExternalFileAttributesFactory |
getExternalFileAttributesFactory()
Get the external file attributes factory for this Zip entry. |
List<ZipEntryExtraFieldFactory> |
getExtraFieldFactories()
Get the factories for creating extra fields for Zip entries. |
ZipEntrySettings |
setComment(String comment)
Set the Zip entry comment. |
ZipEntrySettings |
setCompressionMethod(ZipEntryCompressionMethod cm)
Set the compression method to use. |
ZipEntrySettings |
setExternalFileAttributesFactory(ZipExternalFileAttributesFactory f)
Set a factory object for creating the external file attributes. |
ZipEntrySettings |
setReadOnly()
Set this settings object to be read only to prevent accidental modification. |
Methods inherited from class java.lang.Object |
---|
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public ZipEntrySettings()
public ZipEntrySettings(ZipEntrySettings template)
The properties from the template object is copied to this object.
template
- The template object.Method Detail |
---|
public ZipEntrySettings setReadOnly()
ArchiveEntrySettings
After calling this method, a call to any of the object's setter methods
will result in an IllegalStateException
.
This method can safely be called several times.
setReadOnly
in interface ArchiveEntrySettings<ZipEntrySettings>
this
.public ZipEntrySettings setCompressionMethod(ZipEntryCompressionMethod cm) throws IllegalStateException
cm
- The compression method to use, or null
if this property
should not be set in this settings object.
this
IllegalStateException
- If this configuration object is read only.public ZipEntryCompressionMethod getCompressionMethod()
null
if it is not
set.setCompressionMethod(ZipEntryCompressionMethod)
public ZipEntrySettings setExternalFileAttributesFactory(ZipExternalFileAttributesFactory f) throws IllegalStateException
f
- The external file attributes factory, or null
if that
should not be set.
this
IllegalStateException
- If this configuration object is read only.public ZipExternalFileAttributesFactory getExternalFileAttributesFactory()
null
if it is not set.setExternalFileAttributesFactory(ZipExternalFileAttributesFactory)
public ZipEntrySettings setComment(String comment) throws IllegalStateException
comment
- The Zip entry comment or null
if that should not
be set.
this
IllegalStateException
- If this configuration object is read only.public String getComment()
null
if that is not set.setComment(String)
public ZipEntrySettings addExtraFieldFactory(ZipEntryExtraFieldFactory f) throws IllegalStateException
ZipEntryExtraFieldFactory
that creates a Zip entry extra
field for each Zip entry configured by this settings object.
If this object is combined with another settings object, that settings object's list of extra field factories is appended to this object's list.
f
- The factory.
this
.
IllegalStateException
- If this configuration object is read only.public List<ZipEntryExtraFieldFactory> getExtraFieldFactories()
addExtraFieldFactory(ZipEntryExtraFieldFactory)
public ZipEntrySettings combineWith(ZipEntrySettings zes)
If a property is not set in either of this or the supplied object, it
will be set to null
in the new object.
The created object will have a list of extra field factories that first contains the factories of this object and then the factories of the supplied object.
None of this or the supplied settings objects are modified by this method.
combineWith
in interface ArchiveEntrySettings<ZipEntrySettings>
zes
- The settings object to combine this object's properties with.
public ZipEntrySettings clone()
ArchiveEntrySettings
clone
in interface ArchiveEntrySettings<ZipEntrySettings>
clone
in class Object
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES All Classes | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |