Rakesh API

biz.wedoit4u.ejb.entity
Interface Customers

All Superinterfaces:
javax.ejb.EJBLocalHome

public interface Customers
extends javax.ejb.EJBLocalHome

The local home interface to the entity bean that represents a record in the customers table.

Copyright 2003, Rakesh Vidyadharan and wedoit4u.biz

Version:
$Id: Customers.java,v 1.3 2004/05/26 11:42:35 rakesh Exp $
Author:
Rakesh Vidyadharan 9th September 2003

Method Summary
 Customer create(java.lang.String username, java.lang.String password, char active, CustomerType customerType)
          Create a new customers record with just the values for the required columns.
 Customer create(java.lang.String username, java.lang.String password, CustomerType customerType)
          Create a new customers record with just the values for the required columns.
 Customer create(java.lang.String username, java.lang.String password, java.lang.String email, java.lang.String domain, char active, java.util.Date creationDate, java.util.Date activationDate, java.util.Date expirationDate, CustomerType customerType)
          Create a new customers record with the values specified for all the columns in the table.
 java.util.Collection findAll()
          Return a Collection of entity bean instances that represent all the records in the customers table.
 java.util.Collection findByCustomerType(CustomerType customerType)
          Return a Collection of entity bean instances that represent all the records in the customers table, that belong to the specified CustomerType.
 Customer findByPrimaryKey(int customerId)
          Return the entity bean instance identified by the primary key value specified.
 Customer findByUsername(java.lang.String username)
          Find the entity bean instance that is identified by the username specified.
 
Methods inherited from interface javax.ejb.EJBLocalHome
remove
 

Method Detail

create

Customer create(java.lang.String username,
                java.lang.String password,
                CustomerType customerType)
                throws javax.ejb.CreateException
Create a new customers record with just the values for the required columns. This method obtains the next sequence value for the customer_id value, and sets the customer_id value to the sequence value. The value for the active will be set to the default value specified for the column in the database.

Parameters:
username - - The username value.
password - - The password value.
customerType - - The customer_type_id represented by the entity bean instance.
Returns:
Customer - An entity bean representing the new record.
Throws:
javax.ejb.CreateException - - If errors are encountered while creating the new record.
See Also:
DatabaseHelper.getNextSequenceValue( String )

create

Customer create(java.lang.String username,
                java.lang.String password,
                char active,
                CustomerType customerType)
                throws javax.ejb.CreateException
Create a new customers record with just the values for the required columns. This method obtains the next sequence value for the customer_id value, and sets the customer_id value to the sequence value.

Parameters:
username - - The username value.
password - - The password value.
active - - The active value.
customerType - - The customer_type_id represented by the entity bean instance.
Returns:
Customer - An entity bean representing the new record.
Throws:
javax.ejb.CreateException - - If errors are encountered while creating the new record.
See Also:
DatabaseHelper.getNextSequenceValue( String )

create

Customer create(java.lang.String username,
                java.lang.String password,
                java.lang.String email,
                java.lang.String domain,
                char active,
                java.util.Date creationDate,
                java.util.Date activationDate,
                java.util.Date expirationDate,
                CustomerType customerType)
                throws javax.ejb.CreateException
Create a new customers record with the values specified for all the columns in the table. This method obtains the next sequence value for the customer_id value, and sets the customer_id value to the sequence value.

Parameters:
username - - The username value.
password - - The password value.
email - - The email value. This may be null.
domain - - The domain value. This may be null.
active - - The active value.
creationDate - - The creation_date value.
activationDate - - The activation_date value.
expirationDate - - The expiration_date value.
customerType - - The customer_type_id represented by the entity bean instance.
Throws:
javax.ejb.CreateException - - If errors are encountered while creating the new record.
See Also:
DatabaseHelper.getNextSequenceValue( String )

findByPrimaryKey

Customer findByPrimaryKey(int customerId)
                          throws javax.ejb.FinderException
Return the entity bean instance identified by the primary key value specified.

Parameters:
customerId - - The customer_id value by which to find the appropriate bean instance.
Returns:
Customer - The appropriate entity bean instance.
Throws:
javax.ejb.FinderException - - If errors are encountered while fetching the appropriate instance.

findByUsername

Customer findByUsername(java.lang.String username)
                        throws javax.ejb.FinderException
Find the entity bean instance that is identified by the username specified.

Parameters:
username - - The username value by which to find the appropriate bean instance.
Returns:
Customer - The appropriate entity bean instance.
Throws:
javax.ejb.FinderException - - If errors are encountered while fetching the appropriate bean instance.

findByCustomerType

java.util.Collection findByCustomerType(CustomerType customerType)
                                        throws javax.ejb.FinderException
Return a Collection of entity bean instances that represent all the records in the customers table, that belong to the specified CustomerType.

Parameters:
customerType - - The customer type for which the collection of customers is to be retrieved.
Returns:
Collection - The collection of bean instances.
Throws:
javax.ejb.FinderException - - If errors are encountered while fetching the appropriate instances.

findAll

java.util.Collection findAll()
                             throws javax.ejb.FinderException
Return a Collection of entity bean instances that represent all the records in the customers table.

Returns:
Collection - The collection of bean instances.
Throws:
javax.ejb.FinderException - - If errors are encountered while fetching the appropriate instances.

Rakesh API

Copyright © 2002-2005 - Rakesh Vidyadharan