© 2002 BEA Systems, Inc.


examples.e2e.common.inventory.ref
Class InventoryProviderNoOpImpl

java.lang.Object
  |
  +--examples.e2e.common.inventory.ref.InventoryProviderNoOpImpl

public class InventoryProviderNoOpImpl
extends java.lang.Object
implements javax.ejb.SessionBean

InventoryProviderNoOpImpl is a stateless Session Bean. This bean provides: the following services:

See Also:
Serialized Form

Constructor Summary
InventoryProviderNoOpImpl()
          Create an instance of InventoryProviderNoOpImpl.
 
Method Summary
 int checkInventory(java.lang.String aProductSKU)
          Checks the quantity in stock for a given product (sku)
 void ejbActivate()
          This method is required by the EJB Specification,
 void ejbCreate()
          This method corresponds to the create method in the home interface
 void ejbPassivate()
          This method is required by the EJB Specification,
 void ejbRemove()
          This method is required by the EJB Specification,
 java.util.List getProductInventory(java.util.List skus)
          Returns a list of Inventory objects
 java.util.List getProductPartInventory(java.lang.String sku)
          Returns a list of Inventory objects.
 void setSessionContext(javax.ejb.SessionContext ctx)
          Sets the session context.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

InventoryProviderNoOpImpl

public InventoryProviderNoOpImpl()
Create an instance of InventoryProviderNoOpImpl.
Method Detail

checkInventory

public int checkInventory(java.lang.String aProductSKU)
                   throws java.rmi.RemoteException,
                          java.lang.IllegalArgumentException,
                          ApplicationException
Checks the quantity in stock for a given product (sku)

Parameters:
aProductSKU - sku (unique identifier for a given product)
Throws:
java.lang.IllegalArgumentException - if aProductSKU is null
ApplicationException - if an exception was returned in accessing the information.
java.rmi.RemoteException - if a communication error occurs during the execution of a remote method call.

ejbActivate

public void ejbActivate()
This method is required by the EJB Specification,
Specified by:
ejbActivate in interface javax.ejb.SessionBean


ejbCreate

public void ejbCreate()
               throws javax.ejb.CreateException
This method corresponds to the create method in the home interface

Throws:
javax.ejb.CreateException - if there is a communications or systems failure

ejbPassivate

public void ejbPassivate()
This method is required by the EJB Specification,
Specified by:
ejbPassivate in interface javax.ejb.SessionBean


ejbRemove

public void ejbRemove()
This method is required by the EJB Specification,
Specified by:
ejbRemove in interface javax.ejb.SessionBean


setSessionContext

public void setSessionContext(javax.ejb.SessionContext ctx)
Sets the session context.
Specified by:
setSessionContext in interface javax.ejb.SessionBean

Parameters:
ctx - SessionContext Context for session

getProductInventory

public java.util.List getProductInventory(java.util.List skus)
                                   throws java.rmi.RemoteException,
                                          java.lang.IllegalArgumentException,
                                          ApplicationException
Returns a list of Inventory objects

Throws:
ApplicationException - if an exception was returned in accessing the information.
java.rmi.RemoteException - if a communication error occurs during the execution of a remote method call.
java.lang.IllegalArgumentException - if skus is null or of zero-length.

getProductPartInventory

public java.util.List getProductPartInventory(java.lang.String sku)
                                       throws java.rmi.RemoteException,
                                              java.lang.IllegalArgumentException,
                                              ApplicationException
Returns a list of Inventory objects. Each inventory object represents a part for a product (referenced by one of the product SKUs contained in the List passed).

Parameters:
aProductSKU - sku (unique identifier for a given product)
Throws:
java.lang.IllegalArgumentException - if sku is null
ApplicationException - if an exception was returned in accessing the information.
java.rmi.RemoteException - if a communication error occurs during the execution of a remote method call.

© 2002 BEA Systems, Inc.

Copyright © 2002 BEA Systems, Inc. All Rights Reserved