I am trying to deploy the examples to WLS 6.1 sp1, and I'm having a problem
with soft locking.
ejb-jar.xml contains a
<cmp-field>
<description>Version number for soft locking</description>
<field-name>version</field-name>
</cmp-field>
element, but the ejbc compiler complains about not finding the corresponding
getVersion() method. Here is ejbc's output:
weblogic-ejb-jar:
[java]
[java] ERROR: Error from ejbc: For cmp-field 'version' of bean
'bank/Customer', we expected to find a corresponding 'getVersion' method
in the abstract bean class. Compilation cannot continue without this 'get'
method
[java] ERROR: ejbc found errors
[java] Java Result: 1
So I was wondering if maybe entitycmp.j should generate a method to set and
get the version. I did, and it solved my problem,
but I'm not sure whether it is a good solution. Here is the diff:
diff -r1.18 entitycmp.j
29a30,46
> <XDoclet:ifUseSoftLocking>
> public int getVersion()
> {
> return this.version;
> }
>
> public void setVersion( int version )
> {
> this.version = version;
>
> makeDirty();
> <XDoclet:ifIsWithDataContainer>
> dataHolder = null;
> </XDoclet:ifIsWithDataContainer>
> }
> </XDoclet:ifUseSoftLocking>
>
Could somebody who understands this better confirm if I'm on the right
track? If yes, I'll commit the fix.
</aslak>
_______________________________________________
Xdoclet-devel mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/xdoclet-devel