I don't think you need to do that though.  I'm pretty sure if you
subclass a class that isn't serializeable and make the subclass
implement serializeable, the serialization should succeed.


On Thu, 17 Mar 2005 16:40:02 -0600, Jonathan Eric Miller
<[EMAIL PROTECTED]> wrote:
> Actually, I guess maybe I just don't understand how Serializable works. I
> think the reason why the following didn't work is that it only serialized
> the immediate class and not the parent classes.
> 
> I copied javax.faces.model.ListDataModel to my own file and then modified it
> by only adding "implements Serializable" and now it seems to work.
> 
> Jon
> 
> ----- Original Message -----
> From: "Jonathan Eric Miller" <[EMAIL PROTECTED]>
> To: "MyFaces Discussion" <[email protected]>
> Sent: Thursday, March 17, 2005 3:57 PM
> Subject: Re: Fw: DataModels not Serializable?
> 
> >I tried doing something like this, but, it doesn't seem to work. When I
> >undeploy and redeploy my Web application, it appears that the list is
> >disappearing (I have a h:dataTable bound to a data model and the table size
> >goes to 0). The rest of my bean's state (i.e. simple properties) seem to be
> >OK...
> >
> > package mypackage.faces.model;
> > import java.io.Serializable;
> > import java.util.List;
> > public class ListDataModel extends javax.faces.model.ListDataModel
> > implements Serializable {
> >    public ListDataModel() {
> >        super();
> >    }
> >    public ListDataModel(List list) {
> >        super(list);
> >    }
> > }
> >
> > Jon
> 
> 


-- 
-Heath Borders-Wing
[EMAIL PROTECTED]

Reply via email to