I am generating a value object for my CMP EJB. I would like to only
generate a getter in the VO not the setter (for a particular exposed method
in the EJB).
Even when I apply the "@ejb.value-object" Tag to the getter method, the VO
still contains the setter method. It appears that flagging an ejb method,
whether it's the getXXX or setYYY, the VO that is generated will still
contain both getXXX and setYYY. I would only like to generate the getXXX.
Here's the EJB code example:
/**
* Method getModifiedDate gets the modified date of the record.
* @return Date
*
* @ejb.interface-method
* @ejb.persistent-field
* @ejb.persistence
* column-name="modified_dt"
* @ejb.value-object match="main"
*
* @jboss:column-name name="modified_dt"
*/
public abstract Date getModifiedDate();
/**
* Method setModifiedDate.
* @param _date
*
* @ejb.interface-method
*/
public abstract void setModifiedDate(Date _date);
----------------------------------------------------------------------------
-------
Here's the generated code:
public java.sql.Date getModifiedDate()
{
return this.modifiedDate;
}
public void setModifiedDate( java.sql.Date modifiedDate )
{
this.modifiedDate = modifiedDate;
modifiedDateHasBeenSet = true;
}
public boolean modifiedDateHasBeenSet(){
return modifiedDateHasBeenSet;
}
***NOTE: you don't really need the setter since the value object property
can be initialized in the constructor.
-------------------------------------------------------
This SF.Net email is sponsored by: IBM Linux Tutorials
Free Linux tutorial presented by Daniel Robbins, President and CEO of
GenToo technologies. Learn everything from fundamentals to system
administration.http://ads.osdn.com/?ad_id=1470&alloc_id=3638&op=click
_______________________________________________
xdoclet-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/xdoclet-user