a whole bunch of stuff
[ephemerata.git] / Toady / lib / commons-lang-2.4 / apidocs / org / apache / commons / lang / mutable / Mutable.html
blob9262e29905fe12162e8d75e2a4507c5857ca5fce
1 <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
2 <!--NewPage-->
3 <HTML>
4 <HEAD>
5 <!-- Generated by javadoc (build 1.4.2_16) on Sat Mar 15 20:43:48 PDT 2008 -->
6 <META http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
7 <TITLE>
8 Mutable (Commons Lang 2.4 API)
9 </TITLE>
11 <META NAME="keywords" CONTENT="org.apache.commons.lang.mutable.Mutable interface">
13 <LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../../stylesheet.css" TITLE="Style">
15 <SCRIPT type="text/javascript">
16 function windowTitle()
18 parent.document.title="Mutable (Commons Lang 2.4 API)";
20 </SCRIPT>
22 </HEAD>
24 <BODY BGCOLOR="white" onload="windowTitle();">
27 <!-- ========= START OF TOP NAVBAR ======= -->
28 <A NAME="navbar_top"><!-- --></A>
29 <A HREF="#skip-navbar_top" title="Skip navigation links"></A>
30 <TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
31 <TR>
32 <TD COLSPAN=3 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
33 <A NAME="navbar_top_firstrow"><!-- --></A>
34 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
35 <TR ALIGN="center" VALIGN="top">
36 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
37 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>
38 <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Class</B></FONT>&nbsp;</TD>
39 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="class-use/Mutable.html"><FONT CLASS="NavBarFont1"><B>Use</B></FONT></A>&nbsp;</TD>
40 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
41 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
42 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
43 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
44 </TR>
45 </TABLE>
46 </TD>
47 <TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
48 </EM>
49 </TD>
50 </TR>
52 <TR>
53 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
54 &nbsp;PREV CLASS&nbsp;
55 &nbsp;NEXT CLASS</FONT></TD>
56 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
57 <A HREF="../../../../../index.html" target="_top"><B>FRAMES</B></A> &nbsp;
58 &nbsp;<A HREF="Mutable.html" target="_top"><B>NO FRAMES</B></A> &nbsp;
59 &nbsp;<SCRIPT type="text/javascript">
60 <!--
61 if(window==top) {
62 document.writeln('<A HREF="../../../../../allclasses-noframe.html"><B>All Classes</B></A>');
64 //-->
65 </SCRIPT>
66 <NOSCRIPT>
67 <A HREF="../../../../../allclasses-noframe.html"><B>All Classes</B></A>
68 </NOSCRIPT>
70 </FONT></TD>
71 </TR>
72 <TR>
73 <TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
74 SUMMARY:&nbsp;NESTED&nbsp;|&nbsp;FIELD&nbsp;|&nbsp;CONSTR&nbsp;|&nbsp;<A HREF="#method_summary">METHOD</A></FONT></TD>
75 <TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
76 DETAIL:&nbsp;FIELD&nbsp;|&nbsp;CONSTR&nbsp;|&nbsp;<A HREF="#method_detail">METHOD</A></FONT></TD>
77 </TR>
78 </TABLE>
79 <A NAME="skip-navbar_top"></A>
80 <!-- ========= END OF TOP NAVBAR ========= -->
82 <HR>
83 <!-- ======== START OF CLASS DATA ======== -->
84 <H2>
85 <FONT SIZE="-1">
86 org.apache.commons.lang.mutable</FONT>
87 <BR>
88 Interface Mutable</H2>
89 <DL>
90 <DT><B>All Known Implementing Classes:</B> <DD><A HREF="../../../../../org/apache/commons/lang/mutable/MutableBoolean.html" title="class in org.apache.commons.lang.mutable">MutableBoolean</A>, <A HREF="../../../../../org/apache/commons/lang/mutable/MutableByte.html" title="class in org.apache.commons.lang.mutable">MutableByte</A>, <A HREF="../../../../../org/apache/commons/lang/mutable/MutableDouble.html" title="class in org.apache.commons.lang.mutable">MutableDouble</A>, <A HREF="../../../../../org/apache/commons/lang/mutable/MutableFloat.html" title="class in org.apache.commons.lang.mutable">MutableFloat</A>, <A HREF="../../../../../org/apache/commons/lang/mutable/MutableInt.html" title="class in org.apache.commons.lang.mutable">MutableInt</A>, <A HREF="../../../../../org/apache/commons/lang/mutable/MutableLong.html" title="class in org.apache.commons.lang.mutable">MutableLong</A>, <A HREF="../../../../../org/apache/commons/lang/mutable/MutableObject.html" title="class in org.apache.commons.lang.mutable">MutableObject</A>, <A HREF="../../../../../org/apache/commons/lang/mutable/MutableShort.html" title="class in org.apache.commons.lang.mutable">MutableShort</A></DD>
91 </DL>
92 <HR>
93 <DL>
94 <DT>public interface <B>Mutable</B></DL>
96 <P>
97 Provides mutable access to a value.
98 <p>
99 <code>Mutable</code> is used as a generic interface to the implementations in this package.
101 A typical use case would be to enable a primitive or string to be passed to a method and allow that method to
102 effectively change the value of the primitive/string. Another use case is to store a frequently changing primitive in
103 a collection (for example a total in a map) without needing to create new Integer/Long wrapper objects.
107 <DL>
108 <DT><B>Since:</B></DT>
109 <DD>2.1</DD>
110 <DT><B>Version:</B></DT>
111 <DD>$Id: Mutable.java 618693 2008-02-05 16:33:29Z sebb $</DD>
112 <DT><B>Author:</B></DT>
113 <DD>Matthew Hawthorne</DD>
114 </DL>
115 <HR>
118 <!-- ======== NESTED CLASS SUMMARY ======== -->
121 <!-- =========== FIELD SUMMARY =========== -->
124 <!-- ======== CONSTRUCTOR SUMMARY ======== -->
127 <!-- ========== METHOD SUMMARY =========== -->
129 <A NAME="method_summary"><!-- --></A>
130 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
131 <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
132 <TD COLSPAN=2><FONT SIZE="+2">
133 <B>Method Summary</B></FONT></TD>
134 </TR>
135 <TR BGCOLOR="white" CLASS="TableRowColor">
136 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
137 <CODE>&nbsp;java.lang.Object</CODE></FONT></TD>
138 <TD><CODE><B><A HREF="../../../../../org/apache/commons/lang/mutable/Mutable.html#getValue()">getValue</A></B>()</CODE>
140 <BR>
141 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Gets the value of this mutable.</TD>
142 </TR>
143 <TR BGCOLOR="white" CLASS="TableRowColor">
144 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
145 <CODE>&nbsp;void</CODE></FONT></TD>
146 <TD><CODE><B><A HREF="../../../../../org/apache/commons/lang/mutable/Mutable.html#setValue(java.lang.Object)">setValue</A></B>(java.lang.Object&nbsp;value)</CODE>
148 <BR>
149 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Sets the value of this mutable.</TD>
150 </TR>
151 </TABLE>
152 &nbsp;
155 <!-- ============ FIELD DETAIL =========== -->
158 <!-- ========= CONSTRUCTOR DETAIL ======== -->
161 <!-- ============ METHOD DETAIL ========== -->
163 <A NAME="method_detail"><!-- --></A>
164 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
165 <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
166 <TD COLSPAN=1><FONT SIZE="+2">
167 <B>Method Detail</B></FONT></TD>
168 </TR>
169 </TABLE>
171 <A NAME="getValue()"><!-- --></A><H3>
172 getValue</H3>
173 <PRE>
174 public java.lang.Object <B>getValue</B>()</PRE>
175 <DL>
176 <DD>Gets the value of this mutable.
178 <DD><DL>
180 <DT><B>Returns:</B><DD>the stored value</DL>
181 </DD>
182 </DL>
183 <HR>
185 <A NAME="setValue(java.lang.Object)"><!-- --></A><H3>
186 setValue</H3>
187 <PRE>
188 public void <B>setValue</B>(java.lang.Object&nbsp;value)</PRE>
189 <DL>
190 <DD>Sets the value of this mutable.
192 <DD><DL>
193 <DT><B>Parameters:</B><DD><CODE>value</CODE> - the value to store
194 <DT><B>Throws:</B>
195 <DD><CODE>java.lang.NullPointerException</CODE> - if the object is null and null is invalid
196 <DD><CODE>java.lang.ClassCastException</CODE> - if the type is invalid</DL>
197 </DD>
198 </DL>
199 <!-- ========= END OF CLASS DATA ========= -->
200 <HR>
203 <!-- ======= START OF BOTTOM NAVBAR ====== -->
204 <A NAME="navbar_bottom"><!-- --></A>
205 <A HREF="#skip-navbar_bottom" title="Skip navigation links"></A>
206 <TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
207 <TR>
208 <TD COLSPAN=3 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
209 <A NAME="navbar_bottom_firstrow"><!-- --></A>
210 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
211 <TR ALIGN="center" VALIGN="top">
212 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
213 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>
214 <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Class</B></FONT>&nbsp;</TD>
215 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="class-use/Mutable.html"><FONT CLASS="NavBarFont1"><B>Use</B></FONT></A>&nbsp;</TD>
216 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
217 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
218 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
219 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
220 </TR>
221 </TABLE>
222 </TD>
223 <TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
224 </EM>
225 </TD>
226 </TR>
228 <TR>
229 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
230 &nbsp;PREV CLASS&nbsp;
231 &nbsp;NEXT CLASS</FONT></TD>
232 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
233 <A HREF="../../../../../index.html" target="_top"><B>FRAMES</B></A> &nbsp;
234 &nbsp;<A HREF="Mutable.html" target="_top"><B>NO FRAMES</B></A> &nbsp;
235 &nbsp;<SCRIPT type="text/javascript">
236 <!--
237 if(window==top) {
238 document.writeln('<A HREF="../../../../../allclasses-noframe.html"><B>All Classes</B></A>');
240 //-->
241 </SCRIPT>
242 <NOSCRIPT>
243 <A HREF="../../../../../allclasses-noframe.html"><B>All Classes</B></A>
244 </NOSCRIPT>
246 </FONT></TD>
247 </TR>
248 <TR>
249 <TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
250 SUMMARY:&nbsp;NESTED&nbsp;|&nbsp;FIELD&nbsp;|&nbsp;CONSTR&nbsp;|&nbsp;<A HREF="#method_summary">METHOD</A></FONT></TD>
251 <TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
252 DETAIL:&nbsp;FIELD&nbsp;|&nbsp;CONSTR&nbsp;|&nbsp;<A HREF="#method_detail">METHOD</A></FONT></TD>
253 </TR>
254 </TABLE>
255 <A NAME="skip-navbar_bottom"></A>
256 <!-- ======== END OF BOTTOM NAVBAR ======= -->
258 <HR>
259 Copyright © 2001-2008 <a href="http://www.apache.org/">The Apache Software Foundation</a>. All Rights Reserved.
260 </BODY>
261 </HTML>