vec.cc (__cxxa_vec_new2): Qualify size_t.
[official-gcc.git] / libjava / doc / java-util-jar.texi
blob7a36859f45c1ebc2aa3f17ecbc5cab5d8da75b60
1 @deftypemethod Attributes {public String} getValue (java.lang.String@w{ }@var{name}) 
2 Gets the value of an attribute name given as a String.
3 @end deftypemethod
4 @deftypemethod Attributes {public String} getValue (java.util.jar.Attributes.Name@w{ }@var{name}) 
5 Gets the value of the given attribute name.
6 @end deftypemethod
7 @deftypemethod Attributes {public String} putValue (java.lang.String@w{ }@var{name}, java.lang.String@w{ }@var{value}) 
8 Stores an attribute name (represented by a String) and value in this
9  Attributes map.
10  When the (case insensitive string) name already exists the value is
11  replaced and the old value is returned.
12 @end deftypemethod
13 @deftypemethod Attributes {public Object} clone () 
14 Return a clone of this attribute map.
15 @end deftypemethod
16 @deftypemethod Attributes {public void} clear () 
17 Removes all attributes.
18 @end deftypemethod
19 @deftypemethod Attributes {public boolean} containsKey (java.lang.Object@w{ }@var{attrName}) 
20 Checks to see if there is an attribute with the specified name.
21  XXX - what if the object is a String?
22 @end deftypemethod
23 @deftypemethod Attributes {public boolean} containsValue (java.lang.Object@w{ }@var{attrValue}) 
24 Checks to see if there is an attribute name with the specified value.
25 @end deftypemethod
26 @deftypemethod Attributes {public Set} entrySet () 
27 Gives a Set of attribute name and values pairs as MapEntries.
28 @end deftypemethod
29 @deftypemethod Attributes {public boolean} equals (java.lang.Object@w{ }@var{o}) 
30 Checks to see if two Attributes are equal. The supplied object must be
31  a real instance of Attributes and contain the same attribute name/value
32  pairs.
33 @end deftypemethod
34 @deftypemethod Attributes {public Object} get (java.lang.Object@w{ }@var{attrName}) 
35 Gets the value of a specified attribute name.
36  XXX - what if the object is a String?
37 @end deftypemethod
38 @deftypemethod Attributes {public int} hashCode () 
39 Returns the hashcode of the attribute name/value map.
40 @end deftypemethod
41 @deftypemethod Attributes {public boolean} isEmpty () 
42 Returns true if there are no attributes set, false otherwise.
43 @end deftypemethod
44 @deftypemethod Attributes {public Set} keySet () 
45 Gives a Set of all the values of defined attribute names.
46 @end deftypemethod
47 @deftypemethod Attributes {public Object} put (java.lang.Object@w{ }@var{name}, java.lang.Object@w{ }@var{value}) 
48 Adds or replaces a attribute name/value pair.
49  XXX - What if the name is a string? What if the name is neither a Name
50  nor a String? What if the value is not a string?
51 @end deftypemethod
52 @deftypemethod Attributes {public void} putAll (java.util.Map@w{ }@var{attr}) 
53 Adds or replaces all attribute name/value pairs from another
54  Attributes object to this one. The supplied Map must be an instance of
55  Attributes.
56 @end deftypemethod
57 @deftypemethod Attributes {public Object} remove (java.lang.Object@w{ }@var{name}) 
58 Remove a attribute name/value pair.
59  XXX - What if the name is a String?
60 @end deftypemethod
61 @deftypemethod Attributes {public int} size () 
62 Returns the number of defined attribute name/value pairs.
63 @end deftypemethod
64 @deftypemethod Attributes {public Collection} values () 
65 Returns all the values of the defined attribute name/value pairs as a
66  Collection.
67 @end deftypemethod
68 @deftypemethod Attributes.Name {public int} hashCode () 
69 Returns the hash code of the (lowercase) String representation of
70  this Name.
71 @end deftypemethod
72 @deftypemethod Attributes.Name {public boolean} equals (java.lang.Object@w{ }@var{o}) 
73 Checks if another object is equal to this Name object.
74  Another object is equal to this Name object if it is an instance of
75  Name and the (lowercase) string representation of the name is equal.
76 @end deftypemethod
77 @deftypemethod Attributes.Name {public String} toString () 
78 Returns the string representation of this Name as given to the
79  constructor (not neccesarily the lower case representation).
80 @end deftypemethod
81 @deftypemethod JarEntry {public Attributes} getAttributes () @*throws IOException
82 Returns a copy of the Attributes set for this entry.
83  When no Attributes are set in the manifest null is returned.
84 @end deftypemethod
85 @deftypemethod JarEntry {public Certificate} getCertificates () 
86 Returns a copy of the certificates set for this entry.
87  When no certificates are set or when not all data of this entry has
88  been read null is returned.
92  To make sure that this call returns a valid value you must read all
93  data from the JarInputStream for this entry.
94  When you don't need the data for an entry but want to know the
95  certificates that are set for the entry then you can skip all data by
96  calling @code{skip(entry.getSize())} on the JarInputStream for
97  the entry.
98 @end deftypemethod
99 @deftypemethod JarFile {public Enumeration} entries () @*throws IllegalStateException
100 Returns a enumeration of all the entries in the JarFile.
101  Note that also the Jar META-INF entries are returned.
102 @end deftypemethod
103 @deftypemethod JarFile {public ZipEntry} getEntry (java.lang.String@w{ }@var{name}) 
105  It actually returns a JarEntry not a zipEntry
106 @end deftypemethod
107 @deftypemethod JarFile {public synchronized InputStream} getInputStream (java.util.zip.ZipEntry@w{ }@var{entry}) @*throws ZipException, IOException
108 XXX should verify the inputstream
109 @end deftypemethod
110 @deftypemethod JarFile {public JarEntry} getJarEntry (java.lang.String@w{ }@var{name}) 
111 Returns the JarEntry that belongs to the name if such an entry
112  exists in the JarFile. Returns null otherwise
113  Convenience method that just casts the result from @code{getEntry}
114  to a JarEntry.
115 @end deftypemethod
116 @deftypemethod JarFile {public Manifest} getManifest () 
117 Returns the manifest for this JarFile or null when the JarFile does not
118  contain a manifest file.
119 @end deftypemethod
120 @deftypemethod JarInputStream {protected ZipEntry} createZipEntry (java.lang.String@w{ }@var{name}) 
121 Creates a JarEntry for a particular name and consults the manifest
122  for the Attributes of the entry.
123  Used by @code{ZipEntry.getNextEntry()}
124 @end deftypemethod
125 @deftypemethod JarInputStream {public Manifest} getManifest () 
126 Returns the Manifest for the jar file or null if there was no Manifest.
127 @end deftypemethod
128 @deftypemethod JarInputStream {public ZipEntry} getNextEntry () @*throws IOException
129 Returns the next entry or null when there are no more entries.
130  Does actually return a JarEntry, if you don't want to cast it yourself
131  use @code{getNextJarEntry()}. Does not return any entries found
132  at the beginning of the ZipFile that are special
133  (those that start with "META-INF/").
134 @end deftypemethod
135 @deftypemethod JarInputStream {public JarEntry} getNextJarEntry () @*throws IOException
136 Returns the next jar entry or null when there are no more entries.
137 @end deftypemethod
138 @deftypemethod JarInputStream {public int} read (byte[]@w{ }@var{buf}, int@w{ }@var{off}, int@w{ }@var{len}) @*throws IOException
140 @end deftypemethod
141 @deftypemethod JarOutputStream {public void} putNextEntry (java.util.zip.ZipEntry@w{ }@var{entry}) @*throws IOException
142 Prepares the JarOutputStream for writing the next entry. 
143  This implementation just calls @code{super.putNextEntre()}.
144 @end deftypemethod
145 @deftypemethod Manifest {public Attributes} getMainAttributes () 
146 Gets the main attributes of this Manifest.
147 @end deftypemethod
148 @deftypemethod Manifest {public Map} getEntries () 
149 Gets a map of entry Strings to Attributes for all the entries described
150  in this manifest. Adding, changing or removing from this entries map
151  changes the entries of this manifest.
152 @end deftypemethod
153 @deftypemethod Manifest {public Attributes} getAttributes (java.lang.String@w{ }@var{entryName}) 
154 Returns the Attributes associated with the Entry.
158  Implemented as:
159  @code{return (Attributes)getEntries().get(entryName)}
160 @end deftypemethod
161 @deftypemethod Manifest {public void} clear () 
162 Clears the main attributes and removes all the entries from the
163  manifest.
164 @end deftypemethod
165 @deftypemethod Manifest {public void} read (java.io.InputStream@w{ }@var{in}) @*throws IOException
167 @end deftypemethod
168 @deftypemethod Manifest {public void} write (java.io.OutputStream@w{ }@var{out}) @*throws IOException
170 @end deftypemethod
171 @deftypemethod Manifest {public Object} clone () 
172 Makes a deep copy of the main attributes, but a shallow copy of
173  the other entries. This means that you can freely add, change or remove
174  the main attributes or the entries of the new manifest without effecting
175  the original manifest, but adding, changing or removing attributes from
176  a particular entry also changes the attributes of that entry in the
177  original manifest. Calls @code{new Manifest(this)}.
178 @end deftypemethod
179 @deftypemethod Manifest {public boolean} equals (java.lang.Object@w{ }@var{o}) 
180 Checks if another object is equal to this Manifest object.
181  Another Object is equal to this Manifest object if it is an instance of
182  Manifest and the main attributes and the entries of the other manifest
183  are equal to this one.
184 @end deftypemethod
185 @deftypemethod Manifest {public int} hashCode () 
186 Calculates the hash code of the manifest. Implemented by a xor of the
187  hash code of the main attributes with the hash code of the entries map.
188 @end deftypemethod