Rakesh API

biz.wedoit4u.ejb.entity
Class CategoryBean

java.lang.Object
  extended by biz.wedoit4u.ejb.entity.EntityBeanAdapter
      extended by biz.wedoit4u.ejb.entity.CategoryBean
All Implemented Interfaces:
java.io.Serializable, javax.ejb.EnterpriseBean, javax.ejb.EntityBean

public abstract class CategoryBean
extends EntityBeanAdapter

The implementation of the entity bean that represents a record in the categories table.

Copyright 2003, Rakesh Vidyadharan

Version:
$Id: CategoryBean.java,v 1.5 2004/05/26 11:42:33 rakesh Exp $
Author:
Rakesh Vidyadharan on 9th September 2003
See Also:
Serialized Form

Constructor Summary
CategoryBean()
           
 
Method Summary
 java.lang.Integer ejbCreate(Customer customer, java.lang.String menuName, java.lang.String longName)
          Create a new category record with just the required values.
 java.lang.Integer ejbCreate(Customer customer, java.lang.String menuName, java.lang.String longName, java.lang.String brief, java.lang.String picture, java.lang.String description)
          Create a new category record with all the column values.
 void ejbPostCreate(Customer customer, java.lang.String menuName, java.lang.String longName)
          Mandatory matching postCreate method to the ejbCreate( Customer, String, String ) method.
 void ejbPostCreate(Customer customer, java.lang.String menuName, java.lang.String longName, java.lang.String brief, java.lang.String picture, java.lang.String description)
          Mandatory matching postCreate method to the ejbCreate( Customer, String, String, String, String, String ) method.
abstract  java.lang.String getBrief()
          Returns the value in the brief column.
abstract  int getCategoryId()
          Returns the value in category_id column.
abstract  java.util.Set getContents()
          Return a Set of Content entity bean instances that are associated with this category.
abstract  Customer getCustomer()
          Returns a reference to the Customer entity bean instance that represents the value in the customer_id column.
abstract  java.lang.String getDescription()
          Returns the value of the description column.
abstract  java.lang.String getLongName()
          Returns the value in the long_name column.
abstract  java.lang.String getMenuName()
          Returns the value in the menu_name column.
abstract  java.lang.String getPicture()
          Returns the value in the picture column.
abstract  void setBrief(java.lang.String brief)
          Set the value of the brief column.
abstract  void setCategoryId(int categoryId)
          Set the value of the category_id column.
abstract  void setContents(java.util.Set set)
          Set a Set of Content entity bean instances that are associated with this category.
abstract  void setCustomer(Customer customer)
          Set the value of the customer_id column.
abstract  void setDescription(java.lang.String description)
          Set the value in the description column.
abstract  void setLongName(java.lang.String longName)
          Set the value of the long_name column.
abstract  void setMenuName(java.lang.String menuName)
          Set the value of the menu_name column.
abstract  void setPicture(java.lang.String picture)
          Set the value of the picture column.
 
Methods inherited from class biz.wedoit4u.ejb.entity.EntityBeanAdapter
ejbActivate, ejbLoad, ejbPassivate, ejbRemove, ejbStore, setEntityContext, unsetEntityContext
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

CategoryBean

public CategoryBean()
Method Detail

getCategoryId

public abstract int getCategoryId()
Returns the value in category_id column.

Returns:
int - The value/reference of/to categoryId.

setCategoryId

public abstract void setCategoryId(int categoryId)
Set the value of the category_id column.

Parameters:
categoryId - - The value to set.

getCustomer

public abstract Customer getCustomer()
Returns a reference to the Customer entity bean instance that represents the value in the customer_id column.

Returns:
Customer - The value/reference of/to customer.

setCustomer

public abstract void setCustomer(Customer customer)
Set the value of the customer_id column.

Parameters:
customer - - The value to set.

getMenuName

public abstract java.lang.String getMenuName()
Returns the value in the menu_name column.

Returns:
String - The value/reference of/to menuName.

setMenuName

public abstract void setMenuName(java.lang.String menuName)
Set the value of the menu_name column.

Parameters:
menuName - - The value to set.

getLongName

public abstract java.lang.String getLongName()
Returns the value in the long_name column.

Returns:
String - The value/reference of/to longName.

setLongName

public abstract void setLongName(java.lang.String longName)
Set the value of the long_name column.

Parameters:
longName - - The value to set.

getBrief

public abstract java.lang.String getBrief()
Returns the value in the brief column.

Returns:
String - The value/reference of/to brief.

setBrief

public abstract void setBrief(java.lang.String brief)
Set the value of the brief column.

Parameters:
brief - - The value to set.

getPicture

public abstract java.lang.String getPicture()
Returns the value in the picture column.

Returns:
String - The value/reference of/to picture.

setPicture

public abstract void setPicture(java.lang.String picture)
Set the value of the picture column.

Parameters:
picture - - The value to set.

getDescription

public abstract java.lang.String getDescription()
Returns the value of the description column.

Returns:
String - The value/reference of/to description.

setDescription

public abstract void setDescription(java.lang.String description)
Set the value in the description column.

Parameters:
description - - The value to set.

getContents

public abstract java.util.Set getContents()
Return a Set of Content entity bean instances that are associated with this category.

Returns:
Set - The Set of entity bean instances.
Throws:
javax.ejb.FinderException - - If errors are encountered while fetching the associated Content entity bean instances.

setContents

public abstract void setContents(java.util.Set set)
Set a Set of Content entity bean instances that are associated with this category.

Parameters:
set - The Set of entity bean instances.

ejbCreate

public java.lang.Integer ejbCreate(Customer customer,
                                   java.lang.String menuName,
                                   java.lang.String longName)
                            throws javax.ejb.CreateException
Create a new category record with just the required values. This method obtains the next sequence value for the category_id value, and sets the category_id to the sequence value.

Parameters:
customer - - The reference to the entity bean that represents a record in the customer table. This will be used to set the foreign key customer_id column.
menuName - - The value for the menu_name column.
longName - - The value for the long_name column.
Returns:
Integer - The primary key value of the newly created bean.
Throws:
javax.ejb.CreateException - - If errors are encountered while creating the new record.
See Also:
DatabaseHelper.getNextSequenceValue( String )

ejbPostCreate

public void ejbPostCreate(Customer customer,
                          java.lang.String menuName,
                          java.lang.String longName)
Mandatory matching postCreate method to the ejbCreate( Customer, String, String ) method. No special handling required after the new record is created.

Parameters:
customer - - The reference to the entity bean that represents a record in the customer table. This will be used to set the foreign key customer_id column.
menuName - - The value for the menu_name column.
longName - - The value for the long_name column.

ejbCreate

public java.lang.Integer ejbCreate(Customer customer,
                                   java.lang.String menuName,
                                   java.lang.String longName,
                                   java.lang.String brief,
                                   java.lang.String picture,
                                   java.lang.String description)
                            throws javax.ejb.CreateException
Create a new category record with all the column values. This method obtains the next sequence value for the category_id value, and sets the category_id value to the sequence value.

Parameters:
customer - - The reference to the entity bean that represents a record in the customer table. This will be used to set the foreign key customer_id column.
menuName - - The value for the menu_name column.
longName - - The value for the long_name column.
brief - - The value for the brief column.
picture - - The value for the picture column.
description - - The value for the description column.
Returns:
Integer - The primary key value of the newly created bean.
Throws:
javax.ejb.CreateException - - If errors are encountered while creating the new record.
See Also:
DatabaseHelper.getNextSequenceValue( String )

ejbPostCreate

public void ejbPostCreate(Customer customer,
                          java.lang.String menuName,
                          java.lang.String longName,
                          java.lang.String brief,
                          java.lang.String picture,
                          java.lang.String description)
Mandatory matching postCreate method to the ejbCreate( Customer, String, String, String, String, String ) method. No special handling required after the new record is created.

Parameters:
customer - - The reference to the entity bean that represents a record in the customer table. This will be used to set the foreign key customer_id column.
menuName - - The value for the menu_name column.
longName - - The value for the long_name column.
brief - - The value for the brief column.
picture - - The value for the picture column.
description - - The value for the description column.

Rakesh API

Copyright © 2002-2005 - Rakesh Vidyadharan