blob: 41f4bf13eff29720600fecea02c85004093e547b [file] [log] [blame]
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Frameset//EN""http://www.w3.org/TR/REC-html40/frameset.dtd">
<!--NewPage-->
<HTML>
<HEAD>
<!-- Generated by javadoc on Fri Jun 15 16:53:37 PDT 2001 -->
<TITLE>
Apache Struts API Documentation: Class BeanUtils
</TITLE>
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../stylesheet.css" TITLE="Style">
</HEAD>
<BODY BGCOLOR="white">
<!-- ========== START OF NAVBAR ========== -->
<A NAME="navbar_top"><!-- --></A>
<TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0">
<TR>
<TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
<A NAME="navbar_top_firstrow"><!-- --></A>
<TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3">
<TR ALIGN="center" VALIGN="top">
<TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
<TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>
<TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Class</B></FONT>&nbsp;</TD>
<TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
<TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
<TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
<TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
</TR>
</TABLE>
</TD>
<TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
</EM>
</TD>
</TR>
<TR>
<TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
&nbsp;<A HREF="../../../../org/apache/struts/util/ArrayStack.html"><B>PREV CLASS</B></A>&nbsp;
&nbsp;<A HREF="../../../../org/apache/struts/util/ConvertUtils.html"><B>NEXT CLASS</B></A></FONT></TD>
<TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
<A HREF="../../../../index.html" TARGET="_top"><B>FRAMES</B></A> &nbsp;
&nbsp;<A HREF="BeanUtils.html" TARGET="_top"><B>NO FRAMES</B></A></FONT></TD>
</TR>
<TR>
<TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
SUMMARY: &nbsp;INNER&nbsp;|&nbsp;<A HREF="#field_summary">FIELD</A>&nbsp;|&nbsp;<A HREF="#constructor_summary">CONSTR</A>&nbsp;|&nbsp;<A HREF="#method_summary">METHOD</A></FONT></TD>
<TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
DETAIL: &nbsp;<A HREF="#field_detail">FIELD</A>&nbsp;|&nbsp;<A HREF="#constructor_detail">CONSTR</A>&nbsp;|&nbsp;<A HREF="#method_detail">METHOD</A></FONT></TD>
</TR>
</TABLE>
<!-- =========== END OF NAVBAR =========== -->
<HR>
<!-- ======== START OF CLASS DATA ======== -->
<H2>
<FONT SIZE="-1">
org.apache.struts.util</FONT>
<BR>
Class BeanUtils</H2>
<PRE>
java.lang.Object
|
+--<B>org.apache.struts.util.BeanUtils</B>
</PRE>
<HR>
<B>Deprecated.</B>&nbsp;<I>At some point after Struts 1.0 final, will be replaced by
an equivalent class in the Jakarta Commons Beanutils package.</I>
<P>
<DL>
<DT>public class <B>BeanUtils</B><DT>extends java.lang.Object</DL>
<P>
Utility methods for populating JavaBeans properties via reflection.
<P>
<DL>
<DT><B>Version: </B><DD>$Revision: 1.1 $ $Date$</DD>
<DT><B>Author: </B><DD>Craig R. McClanahan, Ralph Schaer, Chris Audley</DD>
</DL>
<HR>
<P>
<!-- ======== INNER CLASS SUMMARY ======== -->
<!-- =========== FIELD SUMMARY =========== -->
<A NAME="field_summary"><!-- --></A>
<TABLE BORDER="1" CELLPADDING="3" CELLSPACING="0" WIDTH="100%">
<TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
<TD COLSPAN=2><FONT SIZE="+2">
<B>Field Summary</B></FONT></TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>private static&nbsp;int</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../../org/apache/struts/util/BeanUtils.html#debug">debug</A></B></CODE>
<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<B>Deprecated.</B>&nbsp;The debugging detail level for this component.</TD>
</TR>
</TABLE>
&nbsp;
<!-- ======== CONSTRUCTOR SUMMARY ======== -->
<A NAME="constructor_summary"><!-- --></A>
<TABLE BORDER="1" CELLPADDING="3" CELLSPACING="0" WIDTH="100%">
<TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
<TD COLSPAN=2><FONT SIZE="+2">
<B>Constructor Summary</B></FONT></TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD><CODE><B><A HREF="../../../../org/apache/struts/util/BeanUtils.html#BeanUtils()">BeanUtils</A></B>()</CODE>
<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<B>Deprecated.</B>&nbsp;&nbsp;</TD>
</TR>
</TABLE>
&nbsp;
<!-- ========== METHOD SUMMARY =========== -->
<A NAME="method_summary"><!-- --></A>
<TABLE BORDER="1" CELLPADDING="3" CELLSPACING="0" WIDTH="100%">
<TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
<TD COLSPAN=2><FONT SIZE="+2">
<B>Method Summary</B></FONT></TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>static&nbsp;java.lang.Object</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../../org/apache/struts/util/BeanUtils.html#cloneBean(java.lang.Object)">cloneBean</A></B>(java.lang.Object&nbsp;bean)</CODE>
<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<B>Deprecated.</B>&nbsp;Clone a bean based on the available property getters and setters,
even if the bean class itself does not implement Cloneable.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>static&nbsp;java.util.Map</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../../org/apache/struts/util/BeanUtils.html#describe(java.lang.Object)">describe</A></B>(java.lang.Object&nbsp;bean)</CODE>
<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<B>Deprecated.</B>&nbsp;Return the entire set of properties for which the specified bean
provides a read method.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>static&nbsp;java.lang.String[]</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../../org/apache/struts/util/BeanUtils.html#getArrayProperty(java.lang.Object, java.lang.String)">getArrayProperty</A></B>(java.lang.Object&nbsp;bean,
java.lang.String&nbsp;name)</CODE>
<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<B>Deprecated.</B>&nbsp;Return the value of the specified array property of the specified
bean, as a String array.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>static&nbsp;int</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../../org/apache/struts/util/BeanUtils.html#getDebug()">getDebug</A></B>()</CODE>
<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<B>Deprecated.</B>&nbsp;&nbsp;</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>static&nbsp;java.lang.String</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../../org/apache/struts/util/BeanUtils.html#getIndexedProperty(java.lang.Object, java.lang.String)">getIndexedProperty</A></B>(java.lang.Object&nbsp;bean,
java.lang.String&nbsp;name)</CODE>
<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<B>Deprecated.</B>&nbsp;Return the value of the specified indexed property of the specified
bean, as a String.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>static&nbsp;java.lang.String</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../../org/apache/struts/util/BeanUtils.html#getIndexedProperty(java.lang.Object, java.lang.String, int)">getIndexedProperty</A></B>(java.lang.Object&nbsp;bean,
java.lang.String&nbsp;name,
int&nbsp;index)</CODE>
<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<B>Deprecated.</B>&nbsp;Return the value of the specified indexed property of the specified
bean, as a String.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>static&nbsp;java.lang.String</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../../org/apache/struts/util/BeanUtils.html#getNestedProperty(java.lang.Object, java.lang.String)">getNestedProperty</A></B>(java.lang.Object&nbsp;bean,
java.lang.String&nbsp;name)</CODE>
<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<B>Deprecated.</B>&nbsp;Return the value of the (possibly nested) property of the specified
name, for the specified bean, as a String.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>static&nbsp;java.lang.String</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../../org/apache/struts/util/BeanUtils.html#getProperty(java.lang.Object, java.lang.String)">getProperty</A></B>(java.lang.Object&nbsp;bean,
java.lang.String&nbsp;name)</CODE>
<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<B>Deprecated.</B>&nbsp;Return the value of the specified property of the specified bean,
no matter which property reference format is used, as a String.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>static&nbsp;java.lang.String</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../../org/apache/struts/util/BeanUtils.html#getSimpleProperty(java.lang.Object, java.lang.String)">getSimpleProperty</A></B>(java.lang.Object&nbsp;bean,
java.lang.String&nbsp;name)</CODE>
<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<B>Deprecated.</B>&nbsp;Return the value of the specified simple property of the specified
bean, converted to a String.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>static&nbsp;void</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../../org/apache/struts/util/BeanUtils.html#populate(java.lang.Object, java.util.Map)">populate</A></B>(java.lang.Object&nbsp;bean,
java.util.Map&nbsp;properties)</CODE>
<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<B>Deprecated.</B>&nbsp;Populate the JavaBeans properties of the specified bean, based on
the specified name/value pairs.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>static&nbsp;void</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../../org/apache/struts/util/BeanUtils.html#setDebug(int)">setDebug</A></B>(int&nbsp;newDebug)</CODE>
<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<B>Deprecated.</B>&nbsp;&nbsp;</TD>
</TR>
</TABLE>
&nbsp;<A NAME="methods_inherited_from_class_java.lang.Object"><!-- --></A>
<TABLE BORDER="1" CELLPADDING="3" CELLSPACING="0" WIDTH="100%">
<TR BGCOLOR="#EEEEFF" CLASS="TableSubHeadingColor">
<TD><B>Methods inherited from class java.lang.Object</B></TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD><CODE><clinit>, clone, equals, finalize, getClass, hashCode, notify, notifyAll, registerNatives, toString, wait, wait, wait</CODE></TD>
</TR>
</TABLE>
&nbsp;
<P>
<!-- ============ FIELD DETAIL =========== -->
<A NAME="field_detail"><!-- --></A>
<TABLE BORDER="1" CELLPADDING="3" CELLSPACING="0" WIDTH="100%">
<TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
<TD COLSPAN=1><FONT SIZE="+2">
<B>Field Detail</B></FONT></TD>
</TR>
</TABLE>
<A NAME="debug"><!-- --></A><H3>
debug</H3>
<PRE>
private static int <B>debug</B></PRE>
<DL>
<DD><B>Deprecated.</B>&nbsp;<DD>The debugging detail level for this component.</DL>
<!-- ========= CONSTRUCTOR DETAIL ======== -->
<A NAME="constructor_detail"><!-- --></A>
<TABLE BORDER="1" CELLPADDING="3" CELLSPACING="0" WIDTH="100%">
<TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
<TD COLSPAN=1><FONT SIZE="+2">
<B>Constructor Detail</B></FONT></TD>
</TR>
</TABLE>
<A NAME="BeanUtils()"><!-- --></A><H3>
BeanUtils</H3>
<PRE>
public <B>BeanUtils</B>()</PRE>
<DL>
<DD><B>Deprecated.</B>&nbsp;</DL>
<!-- ============ METHOD DETAIL ========== -->
<A NAME="method_detail"><!-- --></A>
<TABLE BORDER="1" CELLPADDING="3" CELLSPACING="0" WIDTH="100%">
<TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
<TD COLSPAN=1><FONT SIZE="+2">
<B>Method Detail</B></FONT></TD>
</TR>
</TABLE>
<A NAME="getDebug()"><!-- --></A><H3>
getDebug</H3>
<PRE>
public static int <B>getDebug</B>()</PRE>
<DL>
<DD><B>Deprecated.</B>&nbsp;</DL>
<HR>
<A NAME="setDebug(int)"><!-- --></A><H3>
setDebug</H3>
<PRE>
public static void <B>setDebug</B>(int&nbsp;newDebug)</PRE>
<DL>
<DD><B>Deprecated.</B>&nbsp;</DL>
<HR>
<A NAME="cloneBean(java.lang.Object)"><!-- --></A><H3>
cloneBean</H3>
<PRE>
public static java.lang.Object <B>cloneBean</B>(java.lang.Object&nbsp;bean)
throws java.lang.IllegalAccessException,
java.lang.InstantiationException,
java.lang.reflect.InvocationTargetException,
java.lang.NoSuchMethodException</PRE>
<DL>
<DD><B>Deprecated.</B>&nbsp;<DD>Clone a bean based on the available property getters and setters,
even if the bean class itself does not implement Cloneable.<DD><DL>
<DT><B>Parameters:</B><DD><CODE>bean</CODE> - Bean to be cloned<DT><B>Throws:</B><DD><CODE>java.lang.IllegalAccessException</CODE> - if the caller does not have
access to the property accessor method<DD><CODE>java.lang.InstantiationException</CODE> - if a new instance of the bean's
class cannot be instantiated<DD><CODE>java.lang.reflect.InvocationTargetException</CODE> - if the property accessor method
throws an exception<DD><CODE>java.lang.NoSuchMethodException</CODE> - if an accessor method for this
propety cannot be found</DL>
</DD>
</DL>
<HR>
<A NAME="describe(java.lang.Object)"><!-- --></A><H3>
describe</H3>
<PRE>
public static java.util.Map <B>describe</B>(java.lang.Object&nbsp;bean)
throws java.lang.IllegalAccessException,
java.lang.reflect.InvocationTargetException,
java.lang.NoSuchMethodException</PRE>
<DL>
<DD><B>Deprecated.</B>&nbsp;<DD>Return the entire set of properties for which the specified bean
provides a read method. This map can be fed back to a call to
<code>BeanUtils.populate()</code> to reconsitute the same set of
properties, modulo differences for read-only and write-only
properties.<DD><DL>
<DT><B>Parameters:</B><DD><CODE>bean</CODE> - Bean whose properties are to be extracted<DT><B>Throws:</B><DD><CODE>java.lang.IllegalAccessException</CODE> - if the caller does not have
access to the property accessor method<DD><CODE>java.lang.reflect.InvocationTargetException</CODE> - if the property accessor method
throws an exception<DD><CODE>java.lang.NoSuchMethodException</CODE> - if an accessor method for this
propety cannot be found</DL>
</DD>
</DL>
<HR>
<A NAME="getArrayProperty(java.lang.Object, java.lang.String)"><!-- --></A><H3>
getArrayProperty</H3>
<PRE>
public static java.lang.String[] <B>getArrayProperty</B>(java.lang.Object&nbsp;bean,
java.lang.String&nbsp;name)
throws java.lang.IllegalAccessException,
java.lang.reflect.InvocationTargetException,
java.lang.NoSuchMethodException</PRE>
<DL>
<DD><B>Deprecated.</B>&nbsp;<DD>Return the value of the specified array property of the specified
bean, as a String array.<DD><DL>
<DT><B>Parameters:</B><DD><CODE>bean</CODE> - Bean whose property is to be extracted<DD><CODE>name</CODE> - Name of the property to be extracted<DT><B>Throws:</B><DD><CODE>java.lang.IllegalAccessException</CODE> - if the caller does not have
access to the property accessor method<DD><CODE>java.lang.reflect.InvocationTargetException</CODE> - if the property accessor method
throws an exception<DD><CODE>java.lang.NoSuchMethodException</CODE> - if an accessor method for this
propety cannot be found</DL>
</DD>
</DL>
<HR>
<A NAME="getIndexedProperty(java.lang.Object, java.lang.String)"><!-- --></A><H3>
getIndexedProperty</H3>
<PRE>
public static java.lang.String <B>getIndexedProperty</B>(java.lang.Object&nbsp;bean,
java.lang.String&nbsp;name)
throws java.lang.IllegalAccessException,
java.lang.reflect.InvocationTargetException,
java.lang.NoSuchMethodException</PRE>
<DL>
<DD><B>Deprecated.</B>&nbsp;<DD>Return the value of the specified indexed property of the specified
bean, as a String. The zero-relative index of the
required value must be included (in square brackets) as a suffix to
the property name, or <code>IllegalArgumentException</code> will be
thrown.<DD><DL>
<DT><B>Parameters:</B><DD><CODE>bean</CODE> - Bean whose property is to be extracted<DD><CODE>name</CODE> - <code>propertyname[index]</code> of the property value
to be extracted<DT><B>Throws:</B><DD><CODE>java.lang.IllegalAccessException</CODE> - if the caller does not have
access to the property accessor method<DD><CODE>java.lang.reflect.InvocationTargetException</CODE> - if the property accessor method
throws an exception<DD><CODE>java.lang.NoSuchMethodException</CODE> - if an accessor method for this
propety cannot be found</DL>
</DD>
</DL>
<HR>
<A NAME="getIndexedProperty(java.lang.Object, java.lang.String, int)"><!-- --></A><H3>
getIndexedProperty</H3>
<PRE>
public static java.lang.String <B>getIndexedProperty</B>(java.lang.Object&nbsp;bean,
java.lang.String&nbsp;name,
int&nbsp;index)
throws java.lang.IllegalAccessException,
java.lang.reflect.InvocationTargetException,
java.lang.NoSuchMethodException</PRE>
<DL>
<DD><B>Deprecated.</B>&nbsp;<DD>Return the value of the specified indexed property of the specified
bean, as a String. The index is specified as a method parameter and
must *not* be included in the property name expression<DD><DL>
<DT><B>Parameters:</B><DD><CODE>bean</CODE> - Bean whose property is to be extracted<DD><CODE>name</CODE> - Simple property name of the property value to be extracted<DD><CODE>index</CODE> - Index of the property value to be extracted<DT><B>Throws:</B><DD><CODE>java.lang.IllegalAccessException</CODE> - if the caller does not have
access to the property accessor method<DD><CODE>java.lang.reflect.InvocationTargetException</CODE> - if the property accessor method
throws an exception<DD><CODE>java.lang.NoSuchMethodException</CODE> - if an accessor method for this
propety cannot be found</DL>
</DD>
</DL>
<HR>
<A NAME="getNestedProperty(java.lang.Object, java.lang.String)"><!-- --></A><H3>
getNestedProperty</H3>
<PRE>
public static java.lang.String <B>getNestedProperty</B>(java.lang.Object&nbsp;bean,
java.lang.String&nbsp;name)
throws java.lang.IllegalAccessException,
java.lang.reflect.InvocationTargetException,
java.lang.NoSuchMethodException</PRE>
<DL>
<DD><B>Deprecated.</B>&nbsp;<DD>Return the value of the (possibly nested) property of the specified
name, for the specified bean, as a String.<DD><DL>
<DT><B>Parameters:</B><DD><CODE>bean</CODE> - Bean whose property is to be extracted<DD><CODE>name</CODE> - Possibly nested name of the property to be extracted<DT><B>Throws:</B><DD><CODE>java.lang.IllegalAccessException</CODE> - if the caller does not have
access to the property accessor method<DD><CODE>java.lang.IllegalArgumentException</CODE> - if a nested reference to a
property returns null<DD><CODE>java.lang.reflect.InvocationTargetException</CODE> - if the property accessor method
throws an exception<DD><CODE>java.lang.NoSuchMethodException</CODE> - if an accessor method for this
propety cannot be found</DL>
</DD>
</DL>
<HR>
<A NAME="getProperty(java.lang.Object, java.lang.String)"><!-- --></A><H3>
getProperty</H3>
<PRE>
public static java.lang.String <B>getProperty</B>(java.lang.Object&nbsp;bean,
java.lang.String&nbsp;name)
throws java.lang.IllegalAccessException,
java.lang.reflect.InvocationTargetException,
java.lang.NoSuchMethodException</PRE>
<DL>
<DD><B>Deprecated.</B>&nbsp;<DD>Return the value of the specified property of the specified bean,
no matter which property reference format is used, as a String.<DD><DL>
<DT><B>Parameters:</B><DD><CODE>bean</CODE> - Bean whose property is to be extracted<DD><CODE>name</CODE> - Possibly indexed and/or nested name of the property
to be extracted<DT><B>Throws:</B><DD><CODE>java.lang.IllegalAccessException</CODE> - if the caller does not have
access to the property accessor method<DD><CODE>java.lang.reflect.InvocationTargetException</CODE> - if the property accessor method
throws an exception<DD><CODE>java.lang.NoSuchMethodException</CODE> - if an accessor method for this
propety cannot be found</DL>
</DD>
</DL>
<HR>
<A NAME="getSimpleProperty(java.lang.Object, java.lang.String)"><!-- --></A><H3>
getSimpleProperty</H3>
<PRE>
public static java.lang.String <B>getSimpleProperty</B>(java.lang.Object&nbsp;bean,
java.lang.String&nbsp;name)
throws java.lang.IllegalAccessException,
java.lang.reflect.InvocationTargetException,
java.lang.NoSuchMethodException</PRE>
<DL>
<DD><B>Deprecated.</B>&nbsp;<DD>Return the value of the specified simple property of the specified
bean, converted to a String.<DD><DL>
<DT><B>Parameters:</B><DD><CODE>bean</CODE> - Bean whose property is to be extracted<DD><CODE>name</CODE> - Name of the property to be extracted<DT><B>Throws:</B><DD><CODE>java.lang.IllegalAccessException</CODE> - if the caller does not have
access to the property accessor method<DD><CODE>java.lang.reflect.InvocationTargetException</CODE> - if the property accessor method
throws an exception<DD><CODE>java.lang.NoSuchMethodException</CODE> - if an accessor method for this
propety cannot be found</DL>
</DD>
</DL>
<HR>
<A NAME="populate(java.lang.Object, java.util.Map)"><!-- --></A><H3>
populate</H3>
<PRE>
public static void <B>populate</B>(java.lang.Object&nbsp;bean,
java.util.Map&nbsp;properties)
throws java.lang.IllegalAccessException,
java.lang.reflect.InvocationTargetException</PRE>
<DL>
<DD><B>Deprecated.</B>&nbsp;<DD>Populate the JavaBeans properties of the specified bean, based on
the specified name/value pairs. This method uses Java reflection APIs
to identify corresponding "property setter" method names, and deals
with setter arguments of type <code>String</code>, <code>boolean</code>,
<code>int</code>, <code>long</code>, <code>float</code>, and
<code>double</code>. In addition, array setters for these types (or the
corresponding primitive types) can also be identified.
<p>
The particular setter method to be called for each property is
determined using the usual JavaBeans introspection mechanisms. Thus,
you may identify custom setter methods using a BeanInfo class that is
associated with the class of the bean itself. If no such BeanInfo
class is available, the standard method name conversion ("set" plus
the capitalized name of the property in question) is used.
<p>
<strong>NOTE</strong>: It is contrary to the JavaBeans Specification
to have more than one setter method (with different argument
signatures) for the same property.<DD><DL>
<DT><B>Parameters:</B><DD><CODE>bean</CODE> - JavaBean whose properties are being populated<DD><CODE>properties</CODE> - Map keyed by property name, with the
corresponding (String or String[]) value(s) to be set<DT><B>Throws:</B><DD><CODE>java.lang.IllegalAccessException</CODE> - if the caller does not have
access to the property accessor method<DD><CODE>java.lang.reflect.InvocationTargetException</CODE> - if the property accessor method
throws an exception</DL>
</DD>
</DL>
<!-- ========= END OF CLASS DATA ========= -->
<HR>
<!-- ========== START OF NAVBAR ========== -->
<A NAME="navbar_bottom"><!-- --></A>
<TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0">
<TR>
<TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
<A NAME="navbar_bottom_firstrow"><!-- --></A>
<TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3">
<TR ALIGN="center" VALIGN="top">
<TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
<TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>
<TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Class</B></FONT>&nbsp;</TD>
<TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
<TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
<TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
<TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
</TR>
</TABLE>
</TD>
<TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
</EM>
</TD>
</TR>
<TR>
<TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
&nbsp;<A HREF="../../../../org/apache/struts/util/ArrayStack.html"><B>PREV CLASS</B></A>&nbsp;
&nbsp;<A HREF="../../../../org/apache/struts/util/ConvertUtils.html"><B>NEXT CLASS</B></A></FONT></TD>
<TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
<A HREF="../../../../index.html" TARGET="_top"><B>FRAMES</B></A> &nbsp;
&nbsp;<A HREF="BeanUtils.html" TARGET="_top"><B>NO FRAMES</B></A></FONT></TD>
</TR>
<TR>
<TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
SUMMARY: &nbsp;INNER&nbsp;|&nbsp;<A HREF="#field_summary">FIELD</A>&nbsp;|&nbsp;<A HREF="#constructor_summary">CONSTR</A>&nbsp;|&nbsp;<A HREF="#method_summary">METHOD</A></FONT></TD>
<TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
DETAIL: &nbsp;<A HREF="#field_detail">FIELD</A>&nbsp;|&nbsp;<A HREF="#constructor_detail">CONSTR</A>&nbsp;|&nbsp;<A HREF="#method_detail">METHOD</A></FONT></TD>
</TR>
</TABLE>
<!-- =========== END OF NAVBAR =========== -->
<HR>
Copyright © 2000-2001 - Apache Software Foundation
</BODY>
</HTML>