124VisualAge for JavaVersion 3: PersistenceBuilder with GUIs, Servlets, and JSPs
Do notworry, the changed method isnot lost when you regenerate the code.
Initialization Example
After initializationofaBankAccountBeanwewouldlikethebalancetoholda
BigDecimal instance withvalue0.00rather than to hold null.Weoverwrite
theejbCreatemethod in the BankAccountBeanclass to initialize the balance:
/**
* Custom initialization for BankAccountBean
*/
public void ejbCreate() {
super.ejbCreate();
setBalance(new java.math.BigDecimal("0"));
}
Add Methods and Business Rule Validation
Newbehaviorshould beaddedtothegeneratedXYBeanclass. Resist the
temp ...
Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month, and much more.