|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.codehaus.plexus.archiver.jar.Manifest.Section
public static class Manifest.Section
A manifest section - you can nest attribute elements into sections. A section consists of a set of attribute values, separated from other sections by a blank line.
| Constructor Summary | |
|---|---|
Manifest.Section()
|
|
| Method Summary | |
|---|---|
String |
addAttributeAndCheck(Manifest.Attribute attribute)
Add an attribute to the section |
void |
addConfiguredAttribute(Manifest.Attribute attribute)
Add an attribute to the section. |
Object |
clone()
Clone this section |
boolean |
equals(Object rhs)
|
Manifest.Attribute |
getAttribute(String attributeName)
Get a attribute of the section |
Enumeration |
getAttributeKeys()
Get the attribute keys. |
String |
getAttributeValue(String attributeName)
Get the value of the attribute with the name given. |
String |
getName()
Get the Section's name. |
Enumeration |
getWarnings()
Get the warnings for this section. |
int |
hashCode()
|
void |
merge(Manifest.Section section)
Merge in another section |
String |
read(BufferedReader reader)
Read a section through a reader. |
void |
removeAttribute(String attributeName)
Remove tge given attribute from the section |
void |
setName(String name)
The name of the section; optional -default is the main section. |
void |
write(PrintWriter writer)
Write the section out to a print writer. |
| Methods inherited from class java.lang.Object |
|---|
finalize, getClass, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public Manifest.Section()
| Method Detail |
|---|
public void setName(String name)
name - the section's namepublic String getName()
public String read(BufferedReader reader)
throws ManifestException,
IOException
reader - the reader from which the section is read
ManifestException - if the section is not valid according
to the JAR spec
IOException - if the section cannot be read from the reader.
public void merge(Manifest.Section section)
throws ManifestException
section - the section to be merged with this one.
ManifestException - if the sections cannot be merged.
public void write(PrintWriter writer)
throws IOException
writer - the Writer to which the section is written
IOException - if the section cannot be writtenpublic Manifest.Attribute getAttribute(String attributeName)
attributeName - the name of the attribute
public Enumeration getAttributeKeys()
public String getAttributeValue(String attributeName)
attributeName - the name of the attribute to be returned.
public void removeAttribute(String attributeName)
attributeName - the name of the attribute to be removed.
public void addConfiguredAttribute(Manifest.Attribute attribute)
throws ManifestException
attribute - the attribute to be added to the section
ManifestException - if the attribute is not valid.
public String addAttributeAndCheck(Manifest.Attribute attribute)
throws ManifestException
attribute - the attribute to be added.
ManifestException - if the attribute already
exists in this section.public Object clone()
clone in class Objectpublic Enumeration getWarnings()
public int hashCode()
hashCode in class ObjectObject.hashCode()public boolean equals(Object rhs)
equals in class ObjectObject.equals(java.lang.Object)
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||