Hi, I am trying to create a uni-directional 1-to-1 relationship between my CreditApplicationBean and my BusinessBean. (A CreditApplication contains one Business).
The files are generated ok but when it comes time to compile, I get the following error: /usr/ice/gen/ejb-jar/com/wf/bd/ice/creditapplication/CreditApplicationCMP.ja va:167: cannot resolve symbol [javac] symbol : method setBusiness (com.wf.bd.ice.business.BusinessDto) [javac] location: interface com.wf.bd.ice.business.BusinessLocal [javac] relation.setBusiness(valueHolder.getBusiness()); This is telling me that the generated CreditApplicationCMP is trying to call a method on the BusinessLocal object ( setBusiness(BusinessDto) ) that does not exist. When I try to do 1-to-many relationships, I don't have any problems. Here are the following files: CreditApplicationBean public abstract class CreditApplicationBean implements javax.ejb.EntityBean { private javax.ejb.EntityContext myEntityCtx; . . . /** * Get Business for this CreditApplication. * This is a one (CreditApplication) to one (Business) relationship. * We can get a BusinessDto in the creditApplicationDto.getBusiness() method. * We can also setBusiness( pBusiness ) * * @ejb.interface-method * view-type="local" * * @ejb.value-object * compose="com.wf.bd.ice.business.BusinessDto" * compose-name="Business" * * @ejb.relation * name="CreditApplication-Business" * role-name="CreditApplication-has-Business" * target-ejb="Business" * target-role-name="Business-belongs_to-CreditApplication" * target-cascade-delete="yes" * * @weblogic.target-column-map * foreign-key-column="applicationId" * key-column="applicationid" * */ public abstract BusinessLocal getBusiness(); public abstract void setBusiness( BusinessLocal pBusinessLocal ); . . . } BusinessBean public abstract class BusinessBean implements javax.ejb.EntityBean { private javax.ejb.EntityContext myEntityCtx; . . (setters and getters) . /** * Manage the Business's DTO/Form object * * @ejb.interface-method **/ public abstract BusinessDto getBusinessDto(); /** * Manage the Business's DTO/Form object * * @ejb.interface-method **/ public abstract void setBusinessDto( BusinessDto pBusinessDto ); . . . } CreditApplicationCMP . . . . public void setCreditApplicationDto( com.wf.bd.ice.creditapplication.CreditApplicationDto valueHolder ) { try { setOriginationSource( valueHolder.getOriginationSource() ); setDateApplicationReceived( valueHolder.getDateApplicationReceived() ); setApplicationCompletionDate( valueHolder.getApplicationCompletionDate() ); // Anonymous block to allow variable declations without conflicts { // Checks for null composition if (valueHolder.getBusiness() != null) { java.lang.String pk = valueHolder.getBusiness().getBusinessId(); com.wf.bd.ice.business.BusinessLocalHome home = com.wf.bd.ice.business.BusinessUtil.getLocalHome(); com.wf.bd.ice.business.BusinessLocal relation = home.findByPrimaryKey(pk); // ***** THIS IS THE LINE OF CODE THAT IS FAILING ****** relation.setBusiness(valueHolder.getBusiness()); } } . . . } BusinessLocal public interface BusinessLocal extends javax.ejb.EJBLocalObject { /** * Manage the Business's DTO/Form object */ public com.wf.bd.ice.business.BusinessDto getBusinessDto( ) ; /** * Manage the Business's DTO/Form object */ public void setBusinessDto( com.wf.bd.ice.business.BusinessDto pBusinessDto ) ; . . . } Let me know if you need more information to assist properly. Thanks! Eileen Smith ------------------------------------------------------- This SF.Net email is sponsored by: SourceForge.net Broadband Sign-up now for SourceForge Broadband and get the fastest 6.0/768 connection for only $19.95/mo for the first 3 months! http://ads.osdn.com/?ad_id=2562&alloc_id=6184&op=click _______________________________________________ xdoclet-user mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/xdoclet-user