Update of /cvsroot/displaytag/display09/src/org/apache/taglibs/display
In directory sc8-pr-cvs1:/tmp/cvs-serv23874/src/org/apache/taglibs/display
Modified Files:
Decorator.java
Log Message:
moved deprecated methods to the old org.apache.taglibs.display package
Index: Decorator.java
===================================================================
RCS file: /cvsroot/displaytag/display09/src/org/apache/taglibs/display/Decorator.java,v
retrieving revision 1.1
retrieving revision 1.2
diff -C2 -d -r1.1 -r1.2
*** Decorator.java 21 Jun 2003 12:34:49 -0000 1.1
--- Decorator.java 22 Jun 2003 16:16:56 -0000 1.2
***************
*** 1,4 ****
--- 1,7 ----
package org.apache.taglibs.display;
+ import java.util.Collection;
+ import java.util.List;
+
import org.displaytag.decorator.TableDecorator;
***************
*** 13,16 ****
--- 16,53 ----
public abstract class Decorator extends TableDecorator
{
+
+ /**
+ * returns the Object where the iteration is performed as a List
+ * @return List
+ * @deprecated use getObject()
+ */
+ public List getList()
+ {
+ if (getObject() instanceof List)
+ {
+ return (List) getObject();
+ }
+ else
+ {
+ throw new RuntimeException("This function is only supported if
the given collection is a java.util.List.");
+ }
+ }
+
+ /**
+ * returns the Object where the iteration is performed as a Collection
+ * @return Collection
+ * @deprecated use getObject()
+ */
+ public Collection getCollection()
+ {
+ if (getObject() instanceof Collection)
+ {
+ return (Collection) getObject();
+ }
+ else
+ {
+ throw new RuntimeException("Function only supported if the
given collection is a java.util.Collection.");
+ }
+ }
}
-------------------------------------------------------
This SF.Net email is sponsored by: INetU
Attention Web Developers & Consultants: Become An INetU Hosting Partner.
Refer Dedicated Servers. We Manage Them. You Get 10% Monthly Commission!
INetU Dedicated Managed Hosting http://www.inetu.net/partner/index.php
_______________________________________________
displaytag-devel mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/displaytag-devel