You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@cocoon.apache.org by Dobri Kitipov <do...@eurisko.bitex.com> on 2003/06/17 08:57:15 UTC

Cocoon Object Model and custom attributes

Hi,

I have read an article about Model 2X. I really like the concept suggested in this article.(http://www.javaworld.com/javaworld/jw-02-2002/jw-0201-strutsxslt_p.html). 

 

My question is:

 

Is there a way to create a DOM tree from the Model (MVC), which is stored in request, session or application scope using a Cocoon Generator? The tricky part is when I have custom beans stored in these scopes. The standard RequestGenerator does this for request attributes but only if they are String objects. I need to create a DOM which would represent the serialized representation of my Model (e.g. session, request's attributes which could be custom bean). 

 

For example the following bean is set in the session as attribute:

 

public class MyBean {

            private Float number;

            private String name;

 

            // get() / set() methods

}

 

If yes, how can I do that or where can I find more information about this issue?

 

Thank you!

Whish you success!