}
}
public void cascadeDelete(CmpEntityBeanContext ctx) throws RemoveException {
if (manager.registerCascadeDelete(ctx.getPrimaryKeyUnchecked(), ctx.getPrimaryKeyUnchecked())) {
EJBLocalObject value = (EJBLocalObject) getValue(ctx);
if (value != null) {
changeValue(null);
final Object relatedId = value.getPrimaryKey();
final JDBCStoreManager2 relatedManager = (JDBCStoreManager2) relatedEntity.getManager();
if (!relatedManager.isCascadeDeleted(relatedId)) {
value.remove();
}
}
manager.unregisterCascadeDelete(ctx.getPrimaryKeyUnchecked());
}