1 <!DOCTYPE HTML PUBLIC
"-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
5 <!-- Generated by javadoc (build 1.5.0_07) on Fri Apr 11 15:39:20 BST 2008 -->
6 <META http-equiv=
"Content-Type" content=
"text/html; charset=ISO-8859-1">
8 AbstractMapEntry (Commons Collections
3.2.1 API)
11 <META NAME=
"keywords" CONTENT=
"org.apache.commons.collections.keyvalue.AbstractMapEntry class">
13 <LINK REL =
"stylesheet" TYPE=
"text/css" HREF=
"../../../../../stylesheet.css" TITLE=
"Style">
15 <SCRIPT type=
"text/javascript">
16 function windowTitle()
18 parent.document.
title=
"AbstractMapEntry (Commons Collections 3.2.1 API)";
26 <BODY BGCOLOR=
"white" onload=
"windowTitle();">
29 <!-- ========= START OF TOP NAVBAR ======= -->
30 <A NAME=
"navbar_top"><!-- --></A>
31 <A HREF=
"#skip-navbar_top" title=
"Skip navigation links"></A>
32 <TABLE BORDER=
"0" WIDTH=
"100%" CELLPADDING=
"1" CELLSPACING=
"0" SUMMARY=
"">
34 <TD COLSPAN=
2 BGCOLOR=
"#EEEEFF" CLASS=
"NavBarCell1">
35 <A NAME=
"navbar_top_firstrow"><!-- --></A>
36 <TABLE BORDER=
"0" CELLPADDING=
"0" CELLSPACING=
"3" SUMMARY=
"">
37 <TR ALIGN=
"center" VALIGN=
"top">
38 <TD BGCOLOR=
"#EEEEFF" CLASS=
"NavBarCell1"> <A HREF=
"../../../../../overview-summary.html"><FONT CLASS=
"NavBarFont1"><B>Overview
</B></FONT></A> </TD>
39 <TD BGCOLOR=
"#EEEEFF" CLASS=
"NavBarCell1"> <A HREF=
"package-summary.html"><FONT CLASS=
"NavBarFont1"><B>Package
</B></FONT></A> </TD>
40 <TD BGCOLOR=
"#FFFFFF" CLASS=
"NavBarCell1Rev"> <FONT CLASS=
"NavBarFont1Rev"><B>Class
</B></FONT> </TD>
41 <TD BGCOLOR=
"#EEEEFF" CLASS=
"NavBarCell1"> <A HREF=
"class-use/AbstractMapEntry.html"><FONT CLASS=
"NavBarFont1"><B>Use
</B></FONT></A> </TD>
42 <TD BGCOLOR=
"#EEEEFF" CLASS=
"NavBarCell1"> <A HREF=
"package-tree.html"><FONT CLASS=
"NavBarFont1"><B>Tree
</B></FONT></A> </TD>
43 <TD BGCOLOR=
"#EEEEFF" CLASS=
"NavBarCell1"> <A HREF=
"../../../../../deprecated-list.html"><FONT CLASS=
"NavBarFont1"><B>Deprecated
</B></FONT></A> </TD>
44 <TD BGCOLOR=
"#EEEEFF" CLASS=
"NavBarCell1"> <A HREF=
"../../../../../index-all.html"><FONT CLASS=
"NavBarFont1"><B>Index
</B></FONT></A> </TD>
45 <TD BGCOLOR=
"#EEEEFF" CLASS=
"NavBarCell1"> <A HREF=
"../../../../../help-doc.html"><FONT CLASS=
"NavBarFont1"><B>Help
</B></FONT></A> </TD>
49 <TD ALIGN=
"right" VALIGN=
"top" ROWSPAN=
3><EM>
55 <TD BGCOLOR=
"white" CLASS=
"NavBarCell2"><FONT SIZE=
"-2">
56 <A HREF=
"../../../../../org/apache/commons/collections/keyvalue/AbstractKeyValue.html" title=
"class in org.apache.commons.collections.keyvalue"><B>PREV CLASS
</B></A>
57 <A HREF=
"../../../../../org/apache/commons/collections/keyvalue/AbstractMapEntryDecorator.html" title=
"class in org.apache.commons.collections.keyvalue"><B>NEXT CLASS
</B></A></FONT></TD>
58 <TD BGCOLOR=
"white" CLASS=
"NavBarCell2"><FONT SIZE=
"-2">
59 <A HREF=
"../../../../../index.html?org/apache/commons/collections/keyvalue/AbstractMapEntry.html" target=
"_top"><B>FRAMES
</B></A>
60 <A HREF=
"AbstractMapEntry.html" target=
"_top"><B>NO FRAMES
</B></A>
61 <SCRIPT type=
"text/javascript">
64 document.writeln('<A HREF="../../../../../allclasses-noframe.html"><B>All Classes</B></A>');
69 <A HREF=
"../../../../../allclasses-noframe.html"><B>All Classes
</B></A>
76 <TD VALIGN=
"top" CLASS=
"NavBarCell3"><FONT SIZE=
"-2">
77 SUMMARY:
NESTED
|
<A HREF=
"#fields_inherited_from_class_org.apache.commons.collections.keyvalue.AbstractKeyValue">FIELD
</A> |
<A HREF=
"#constructor_summary">CONSTR
</A> |
<A HREF=
"#method_summary">METHOD
</A></FONT></TD>
78 <TD VALIGN=
"top" CLASS=
"NavBarCell3"><FONT SIZE=
"-2">
79 DETAIL:
FIELD
|
<A HREF=
"#constructor_detail">CONSTR
</A> |
<A HREF=
"#method_detail">METHOD
</A></FONT></TD>
82 <A NAME=
"skip-navbar_top"></A>
83 <!-- ========= END OF TOP NAVBAR ========= -->
86 <!-- ======== START OF CLASS DATA ======== -->
89 org.apache.commons.collections.keyvalue
</FONT>
91 Class AbstractMapEntry
</H2>
94 <IMG SRC=
"../../../../../resources/inherit.gif" ALT=
"extended by "><A HREF=
"../../../../../org/apache/commons/collections/keyvalue/AbstractKeyValue.html" title=
"class in org.apache.commons.collections.keyvalue">org.apache.commons.collections.keyvalue.AbstractKeyValue
</A>
95 <IMG SRC=
"../../../../../resources/inherit.gif" ALT=
"extended by "><B>org.apache.commons.collections.keyvalue.AbstractMapEntry
</B>
98 <DT><B>All Implemented Interfaces:
</B> <DD>java.util.Map.Entry,
<A HREF=
"../../../../../org/apache/commons/collections/KeyValue.html" title=
"interface in org.apache.commons.collections">KeyValue
</A></DD>
101 <DT><B>Direct Known Subclasses:
</B> <DD><A HREF=
"../../../../../org/apache/commons/collections/BeanMap.MyMapEntry.html" title=
"class in org.apache.commons.collections">BeanMap.MyMapEntry
</A>,
<A HREF=
"../../../../../org/apache/commons/collections/keyvalue/DefaultMapEntry.html" title=
"class in org.apache.commons.collections.keyvalue">DefaultMapEntry
</A>,
<A HREF=
"../../../../../org/apache/commons/collections/keyvalue/UnmodifiableMapEntry.html" title=
"class in org.apache.commons.collections.keyvalue">UnmodifiableMapEntry
</A></DD>
105 <DT><PRE>public abstract class
<B>AbstractMapEntry
</B><DT>extends
<A HREF=
"../../../../../org/apache/commons/collections/keyvalue/AbstractKeyValue.html" title=
"class in org.apache.commons.collections.keyvalue">AbstractKeyValue
</A><DT>implements java.util.Map.Entry
</DL>
109 Abstract Pair class to assist with creating correct
110 <CODE>Map.Entry
</CODE> implementations.
115 <DT><B>Since:
</B></DT>
116 <DD>Commons Collections
3.0</DD>
117 <DT><B>Version:
</B></DT>
118 <DD>$Revision:
646777 $ $Date:
2008-
04-
10 13:
33:
15 +
0100 (Thu,
10 Apr
2008) $
</DD>
119 <DT><B>Author:
</B></DT>
120 <DD>James Strachan, Michael A. Smith, Neil O'Toole, Stephen Colebourne
</DD>
125 <!-- =========== FIELD SUMMARY =========== -->
127 <A NAME=
"field_summary"><!-- --></A>
128 <TABLE BORDER=
"1" WIDTH=
"100%" CELLPADDING=
"3" CELLSPACING=
"0" SUMMARY=
"">
129 <TR BGCOLOR=
"#CCCCFF" CLASS=
"TableHeadingColor">
130 <TH ALIGN=
"left" COLSPAN=
"2"><FONT SIZE=
"+2">
131 <B>Field Summary
</B></FONT></TH>
134 <A NAME=
"fields_inherited_from_class_org.apache.commons.collections.keyvalue.AbstractKeyValue"><!-- --></A>
135 <TABLE BORDER=
"1" WIDTH=
"100%" CELLPADDING=
"3" CELLSPACING=
"0" SUMMARY=
"">
136 <TR BGCOLOR=
"#EEEEFF" CLASS=
"TableSubHeadingColor">
137 <TH ALIGN=
"left"><B>Fields inherited from class org.apache.commons.collections.keyvalue.
<A HREF=
"../../../../../org/apache/commons/collections/keyvalue/AbstractKeyValue.html" title=
"class in org.apache.commons.collections.keyvalue">AbstractKeyValue
</A></B></TH>
139 <TR BGCOLOR=
"white" CLASS=
"TableRowColor">
140 <TD><CODE><A HREF=
"../../../../../org/apache/commons/collections/keyvalue/AbstractKeyValue.html#key">key
</A>,
<A HREF=
"../../../../../org/apache/commons/collections/keyvalue/AbstractKeyValue.html#value">value
</A></CODE></TD>
144 <!-- ======== CONSTRUCTOR SUMMARY ======== -->
146 <A NAME=
"constructor_summary"><!-- --></A>
147 <TABLE BORDER=
"1" WIDTH=
"100%" CELLPADDING=
"3" CELLSPACING=
"0" SUMMARY=
"">
148 <TR BGCOLOR=
"#CCCCFF" CLASS=
"TableHeadingColor">
149 <TH ALIGN=
"left" COLSPAN=
"2"><FONT SIZE=
"+2">
150 <B>Constructor Summary
</B></FONT></TH>
152 <TR BGCOLOR=
"white" CLASS=
"TableRowColor">
153 <TD ALIGN=
"right" VALIGN=
"top" WIDTH=
"1%"><FONT SIZE=
"-1">
154 <CODE>protected
</CODE></FONT></TD>
155 <TD><CODE><B><A HREF=
"../../../../../org/apache/commons/collections/keyvalue/AbstractMapEntry.html#AbstractMapEntry(java.lang.Object, java.lang.Object)">AbstractMapEntry
</A></B>(java.lang.Object
key,
156 java.lang.Object
value)
</CODE>
159 Constructs a new entry with the given key and given value.
</TD>
163 <!-- ========== METHOD SUMMARY =========== -->
165 <A NAME=
"method_summary"><!-- --></A>
166 <TABLE BORDER=
"1" WIDTH=
"100%" CELLPADDING=
"3" CELLSPACING=
"0" SUMMARY=
"">
167 <TR BGCOLOR=
"#CCCCFF" CLASS=
"TableHeadingColor">
168 <TH ALIGN=
"left" COLSPAN=
"2"><FONT SIZE=
"+2">
169 <B>Method Summary
</B></FONT></TH>
171 <TR BGCOLOR=
"white" CLASS=
"TableRowColor">
172 <TD ALIGN=
"right" VALIGN=
"top" WIDTH=
"1%"><FONT SIZE=
"-1">
173 <CODE> boolean
</CODE></FONT></TD>
174 <TD><CODE><B><A HREF=
"../../../../../org/apache/commons/collections/keyvalue/AbstractMapEntry.html#equals(java.lang.Object)">equals
</A></B>(java.lang.Object
obj)
</CODE>
177 Compares this
<code>Map.Entry
</code> with another
<code>Map.Entry
</code>.
</TD>
179 <TR BGCOLOR=
"white" CLASS=
"TableRowColor">
180 <TD ALIGN=
"right" VALIGN=
"top" WIDTH=
"1%"><FONT SIZE=
"-1">
181 <CODE> int
</CODE></FONT></TD>
182 <TD><CODE><B><A HREF=
"../../../../../org/apache/commons/collections/keyvalue/AbstractMapEntry.html#hashCode()">hashCode
</A></B>()
</CODE>
185 Gets a hashCode compatible with the equals method.
</TD>
187 <TR BGCOLOR=
"white" CLASS=
"TableRowColor">
188 <TD ALIGN=
"right" VALIGN=
"top" WIDTH=
"1%"><FONT SIZE=
"-1">
189 <CODE> java.lang.Object
</CODE></FONT></TD>
190 <TD><CODE><B><A HREF=
"../../../../../org/apache/commons/collections/keyvalue/AbstractMapEntry.html#setValue(java.lang.Object)">setValue
</A></B>(java.lang.Object
value)
</CODE>
193 Sets the value stored in this
<code>Map.Entry
</code>.
</TD>
196 <A NAME=
"methods_inherited_from_class_org.apache.commons.collections.keyvalue.AbstractKeyValue"><!-- --></A>
197 <TABLE BORDER=
"1" WIDTH=
"100%" CELLPADDING=
"3" CELLSPACING=
"0" SUMMARY=
"">
198 <TR BGCOLOR=
"#EEEEFF" CLASS=
"TableSubHeadingColor">
199 <TH ALIGN=
"left"><B>Methods inherited from class org.apache.commons.collections.keyvalue.
<A HREF=
"../../../../../org/apache/commons/collections/keyvalue/AbstractKeyValue.html" title=
"class in org.apache.commons.collections.keyvalue">AbstractKeyValue
</A></B></TH>
201 <TR BGCOLOR=
"white" CLASS=
"TableRowColor">
202 <TD><CODE><A HREF=
"../../../../../org/apache/commons/collections/keyvalue/AbstractKeyValue.html#getKey()">getKey
</A>,
<A HREF=
"../../../../../org/apache/commons/collections/keyvalue/AbstractKeyValue.html#getValue()">getValue
</A>,
<A HREF=
"../../../../../org/apache/commons/collections/keyvalue/AbstractKeyValue.html#toString()">toString
</A></CODE></TD>
205 <A NAME=
"methods_inherited_from_class_java.lang.Object"><!-- --></A>
206 <TABLE BORDER=
"1" WIDTH=
"100%" CELLPADDING=
"3" CELLSPACING=
"0" SUMMARY=
"">
207 <TR BGCOLOR=
"#EEEEFF" CLASS=
"TableSubHeadingColor">
208 <TH ALIGN=
"left"><B>Methods inherited from class java.lang.Object
</B></TH>
210 <TR BGCOLOR=
"white" CLASS=
"TableRowColor">
211 <TD><CODE>clone, finalize, getClass, notify, notifyAll, wait, wait, wait
</CODE></TD>
214 <A NAME=
"methods_inherited_from_class_java.util.Map.Entry"><!-- --></A>
215 <TABLE BORDER=
"1" WIDTH=
"100%" CELLPADDING=
"3" CELLSPACING=
"0" SUMMARY=
"">
216 <TR BGCOLOR=
"#EEEEFF" CLASS=
"TableSubHeadingColor">
217 <TH ALIGN=
"left"><B>Methods inherited from interface java.util.Map.Entry
</B></TH>
219 <TR BGCOLOR=
"white" CLASS=
"TableRowColor">
220 <TD><CODE>getKey, getValue
</CODE></TD>
226 <!-- ========= CONSTRUCTOR DETAIL ======== -->
228 <A NAME=
"constructor_detail"><!-- --></A>
229 <TABLE BORDER=
"1" WIDTH=
"100%" CELLPADDING=
"3" CELLSPACING=
"0" SUMMARY=
"">
230 <TR BGCOLOR=
"#CCCCFF" CLASS=
"TableHeadingColor">
231 <TH ALIGN=
"left" COLSPAN=
"1"><FONT SIZE=
"+2">
232 <B>Constructor Detail
</B></FONT></TH>
236 <A NAME=
"AbstractMapEntry(java.lang.Object, java.lang.Object)"><!-- --></A><H3>
237 AbstractMapEntry
</H3>
239 protected
<B>AbstractMapEntry
</B>(java.lang.Object
key,
240 java.lang.Object
value)
</PRE>
242 <DD>Constructs a new entry with the given key and given value.
245 <DT><B>Parameters:
</B><DD><CODE>key
</CODE> - the key for the entry, may be null
<DD><CODE>value
</CODE> - the value for the entry, may be null
</DL>
248 <!-- ============ METHOD DETAIL ========== -->
250 <A NAME=
"method_detail"><!-- --></A>
251 <TABLE BORDER=
"1" WIDTH=
"100%" CELLPADDING=
"3" CELLSPACING=
"0" SUMMARY=
"">
252 <TR BGCOLOR=
"#CCCCFF" CLASS=
"TableHeadingColor">
253 <TH ALIGN=
"left" COLSPAN=
"1"><FONT SIZE=
"+2">
254 <B>Method Detail
</B></FONT></TH>
258 <A NAME=
"setValue(java.lang.Object)"><!-- --></A><H3>
261 public java.lang.Object
<B>setValue
</B>(java.lang.Object
value)
</PRE>
263 <DD>Sets the value stored in this
<code>Map.Entry
</code>.
265 This
<code>Map.Entry
</code> is not connected to a Map, so only the
266 local data is changed.
269 <DT><B>Specified by:
</B><DD><CODE>setValue
</CODE> in interface
<CODE>java.util.Map.Entry
</CODE></DL>
272 <DT><B>Parameters:
</B><DD><CODE>value
</CODE> - the new value
273 <DT><B>Returns:
</B><DD>the previous value
</DL>
278 <A NAME=
"equals(java.lang.Object)"><!-- --></A><H3>
281 public boolean
<B>equals
</B>(java.lang.Object
obj)
</PRE>
283 <DD>Compares this
<code>Map.Entry
</code> with another
<code>Map.Entry
</code>.
285 Implemented per API documentation of
<CODE>Map.Entry.equals(Object)
</CODE>
288 <DT><B>Specified by:
</B><DD><CODE>equals
</CODE> in interface
<CODE>java.util.Map.Entry
</CODE><DT><B>Overrides:
</B><DD><CODE>equals
</CODE> in class
<CODE>java.lang.Object
</CODE></DL>
291 <DT><B>Parameters:
</B><DD><CODE>obj
</CODE> - the object to compare to
292 <DT><B>Returns:
</B><DD>true if equal key and value
</DL>
297 <A NAME=
"hashCode()"><!-- --></A><H3>
300 public int
<B>hashCode
</B>()
</PRE>
302 <DD>Gets a hashCode compatible with the equals method.
304 Implemented per API documentation of
<CODE>Map.Entry.hashCode()
</CODE>
307 <DT><B>Specified by:
</B><DD><CODE>hashCode
</CODE> in interface
<CODE>java.util.Map.Entry
</CODE><DT><B>Overrides:
</B><DD><CODE>hashCode
</CODE> in class
<CODE>java.lang.Object
</CODE></DL>
311 <DT><B>Returns:
</B><DD>a suitable hash code
</DL>
314 <!-- ========= END OF CLASS DATA ========= -->
318 <!-- ======= START OF BOTTOM NAVBAR ====== -->
319 <A NAME=
"navbar_bottom"><!-- --></A>
320 <A HREF=
"#skip-navbar_bottom" title=
"Skip navigation links"></A>
321 <TABLE BORDER=
"0" WIDTH=
"100%" CELLPADDING=
"1" CELLSPACING=
"0" SUMMARY=
"">
323 <TD COLSPAN=
2 BGCOLOR=
"#EEEEFF" CLASS=
"NavBarCell1">
324 <A NAME=
"navbar_bottom_firstrow"><!-- --></A>
325 <TABLE BORDER=
"0" CELLPADDING=
"0" CELLSPACING=
"3" SUMMARY=
"">
326 <TR ALIGN=
"center" VALIGN=
"top">
327 <TD BGCOLOR=
"#EEEEFF" CLASS=
"NavBarCell1"> <A HREF=
"../../../../../overview-summary.html"><FONT CLASS=
"NavBarFont1"><B>Overview
</B></FONT></A> </TD>
328 <TD BGCOLOR=
"#EEEEFF" CLASS=
"NavBarCell1"> <A HREF=
"package-summary.html"><FONT CLASS=
"NavBarFont1"><B>Package
</B></FONT></A> </TD>
329 <TD BGCOLOR=
"#FFFFFF" CLASS=
"NavBarCell1Rev"> <FONT CLASS=
"NavBarFont1Rev"><B>Class
</B></FONT> </TD>
330 <TD BGCOLOR=
"#EEEEFF" CLASS=
"NavBarCell1"> <A HREF=
"class-use/AbstractMapEntry.html"><FONT CLASS=
"NavBarFont1"><B>Use
</B></FONT></A> </TD>
331 <TD BGCOLOR=
"#EEEEFF" CLASS=
"NavBarCell1"> <A HREF=
"package-tree.html"><FONT CLASS=
"NavBarFont1"><B>Tree
</B></FONT></A> </TD>
332 <TD BGCOLOR=
"#EEEEFF" CLASS=
"NavBarCell1"> <A HREF=
"../../../../../deprecated-list.html"><FONT CLASS=
"NavBarFont1"><B>Deprecated
</B></FONT></A> </TD>
333 <TD BGCOLOR=
"#EEEEFF" CLASS=
"NavBarCell1"> <A HREF=
"../../../../../index-all.html"><FONT CLASS=
"NavBarFont1"><B>Index
</B></FONT></A> </TD>
334 <TD BGCOLOR=
"#EEEEFF" CLASS=
"NavBarCell1"> <A HREF=
"../../../../../help-doc.html"><FONT CLASS=
"NavBarFont1"><B>Help
</B></FONT></A> </TD>
338 <TD ALIGN=
"right" VALIGN=
"top" ROWSPAN=
3><EM>
344 <TD BGCOLOR=
"white" CLASS=
"NavBarCell2"><FONT SIZE=
"-2">
345 <A HREF=
"../../../../../org/apache/commons/collections/keyvalue/AbstractKeyValue.html" title=
"class in org.apache.commons.collections.keyvalue"><B>PREV CLASS
</B></A>
346 <A HREF=
"../../../../../org/apache/commons/collections/keyvalue/AbstractMapEntryDecorator.html" title=
"class in org.apache.commons.collections.keyvalue"><B>NEXT CLASS
</B></A></FONT></TD>
347 <TD BGCOLOR=
"white" CLASS=
"NavBarCell2"><FONT SIZE=
"-2">
348 <A HREF=
"../../../../../index.html?org/apache/commons/collections/keyvalue/AbstractMapEntry.html" target=
"_top"><B>FRAMES
</B></A>
349 <A HREF=
"AbstractMapEntry.html" target=
"_top"><B>NO FRAMES
</B></A>
350 <SCRIPT type=
"text/javascript">
353 document.writeln('<A HREF="../../../../../allclasses-noframe.html"><B>All Classes</B></A>');
358 <A HREF=
"../../../../../allclasses-noframe.html"><B>All Classes
</B></A>
365 <TD VALIGN=
"top" CLASS=
"NavBarCell3"><FONT SIZE=
"-2">
366 SUMMARY:
NESTED
|
<A HREF=
"#fields_inherited_from_class_org.apache.commons.collections.keyvalue.AbstractKeyValue">FIELD
</A> |
<A HREF=
"#constructor_summary">CONSTR
</A> |
<A HREF=
"#method_summary">METHOD
</A></FONT></TD>
367 <TD VALIGN=
"top" CLASS=
"NavBarCell3"><FONT SIZE=
"-2">
368 DETAIL:
FIELD
|
<A HREF=
"#constructor_detail">CONSTR
</A> |
<A HREF=
"#method_detail">METHOD
</A></FONT></TD>
371 <A NAME=
"skip-navbar_bottom"></A>
372 <!-- ======== END OF BOTTOM NAVBAR ======= -->
375 Copyright ©
2001-
2008 <a href=
"http://www.apache.org/">The Apache Software Foundation
</a>. All Rights Reserved.