That's not necessarily true and depends on how your class is
structured...  My understanding, is that you have XML data that's
coming it, that is mapped into your object model, that is then
persisted using hibernate, right?  So you're unmarshaling the XML data
into a hibernate annotated/mapped model.

I don't believe there are any restrictions of that kind.  The standard
practice is to use getters/setters in hibernate enabled classes, which
is what I think is confusing you.   First of all, nothing stops you
from having both and if your getter/setter convention is purely to
encapsulate the access to fields without enforcing any invariants,
then you can use field in JiBX and setters in Hibernate.
Alternatively, of course if your setters enforce invariants, you'd
want to use set-method in jibx.  Also, if your getters are not purely
encapsulation of fields, but rather represent complex associations,
that's the case as well.  Now, you can also instruct hibernate to use
fields vs. the javabean get/set reflection.

Ilya



On 2/6/07, Vairoj A. <[EMAIL PROTECTED]> wrote:
> Hi,
>
> In order to use Hibernate with JibX enhanced classes, JibX mapping will
> need to use 'get-method' and 'set-method' instead of 'field' is that
> correct? Is this a hard requirement and apply to every attribute and
> relationship? Are there any other consideration to make these two works
> together (Hibernate 3.2 - JibX 1.1)?
>
> Regards,
> Vairoj
>
>
> -------------------------------------------------------------------------
> Using Tomcat but need to do more? Need to support web services, security?
> Get stuff done quickly with pre-integrated technology to make your job easier.
> Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo
> http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642
> _______________________________________________
> jibx-users mailing list
> [email protected]
> https://lists.sourceforge.net/lists/listinfo/jibx-users
>
>

-------------------------------------------------------------------------
Using Tomcat but need to do more? Need to support web services, security?
Get stuff done quickly with pre-integrated technology to make your job easier.
Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo
http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642
_______________________________________________
jibx-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/jibx-users

Reply via email to