|
bea Systems, Inc. | ||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--theory.smart.foundation.SessionImpl | +--theory.smart.ebusiness.shoppingadvisor.ShoppingAdvisorImpl
This class is the interface to the shopping advisor package. It builds a searchable table of Qualities from Items. That table is used to provide search and customer profile matching functionality.
ShoppingAdvisor
,
ShoppingAdvisorHome
, Serialized FormField Summary | |
protected static java.lang.String |
CUSTOMER_PROFILE_HOME
|
CustomerProfileHome |
customerProfileHome
|
protected static java.lang.String |
ITEM_QUALITIES_HOME
|
int |
itemDepth
itemDepth [ShoppingAdvisor] <*>------> [ int ]
|
ItemQualitiesHome |
itemQualitiesHome
|
protected static java.lang.String |
ITEMS_BY_QUALITY_HOME
|
ItemsByQualityHome |
itemsByQualityHome
|
Customer |
lastCustomer
|
CustomerProfile |
lastCustomerProfile
|
boolean |
matchAll
matchAll [ShoppingAdvisor] <*>------> [ boolean ]
|
int |
qualityDepth
qualityDepth [ShoppingAdvisor] <*>------> [ int ]
|
int |
suggestionCount
suggestionCount [ShoppingAdvisor] <*>------> [ int ]
|
Fields inherited from class theory.smart.foundation.SessionImpl |
ctx,
isDirty |
Constructor Summary | |
ShoppingAdvisorImpl()
|
Method Summary | |
void |
addCustomerPreference(Customer customer,
Quality quality)
Adds a quality to the customer's profile. |
void |
addDefaultItem(Item item,
int degree)
Add an item that will be returned by the getDefaultSuggestions method. |
void |
addItem(Item item)
Add a single item to the shopping engine. |
void |
deleteCustomerPreference(Customer customer,
Quality quality)
Removes a quality from the customer's profile. |
void |
deleteCustomerProfile(Customer customer)
Remove a customer profile. |
void |
deleteDefaultItem(Item item)
Remove an item from the list that will be returned when getDefaultSuggestions is called. |
void |
deleteItem(Item delete)
Delete a single item from the shopping engine. |
void |
ejbActivate()
|
void |
ejbCreate()
|
void |
ejbPassivate()
|
void |
ejbPostCreate()
|
void |
ejbRemove()
|
protected CustomerProfileHome |
getCPHome()
|
protected CustomerProfile |
getCustomerProfile(Customer customer)
|
protected ItemsByQuality |
getDefaultItemsByQuality()
|
Suggestions |
getDefaultSuggestions()
Return a default list of suggestions as configured with teh addDefaultItem method. |
protected ItemsByQualityHome |
getIBQHome()
|
protected ItemQualitiesHome |
getIQHome()
|
int |
getItemDepth()
Get the value of itemDepth |
protected ItemQualities |
getItemQualities(Item item)
|
boolean |
getMatchAll()
Get the value of matchAll |
int |
getQualityDepth()
Get the value of qualityDepth |
int |
getSuggestionCount()
Get the value of suggestionCount |
Suggestions |
getSuggestions(Customer customer)
Get suggestions based soley on a customers profile. |
Suggestions |
getSuggestions(Customer customer,
Item item)
Get suggestions based on the customer profile and the qualities of the item. |
Suggestions |
getSuggestions(Customer customer,
java.lang.String searchString)
Get suggestions based on a customer profile and a search string. |
protected Suggestions |
getSuggestions(com.sun.java.util.collections.LinkedList qualities)
|
protected Suggestions |
getSuggestions(com.sun.java.util.collections.LinkedList qualities,
Suggestions suggestions)
|
Suggestions |
getSuggestions(java.lang.String searchString)
Tokenize the search string into a list of qualities to be searched for. |
void |
learnCustomerPreference(Customer customer,
Item item)
Adds an item's qualities to the customer's profile. |
protected void |
removeItemReferences(Item item,
com.sun.java.util.collections.LinkedList listOfQualities)
|
void |
setItemDepth(int itemDepth)
Set the value of itemDepth |
void |
setMatchAll(boolean matchAll)
Set the value of matchAll |
void |
setQualityDepth(int qualityDepth)
Set the value of qualityDepth |
void |
setSessionContext(SessionContext ctx)
|
void |
setSuggestionCount(int suggestionCount)
Set the value of suggestionCount |
Methods inherited from class java.lang.Object |
clone,
equals,
finalize,
getClass,
hashCode,
notify,
notifyAll,
toString,
wait,
wait,
wait |
Field Detail |
public transient ItemQualitiesHome itemQualitiesHome
public transient ItemsByQualityHome itemsByQualityHome
public transient CustomerProfileHome customerProfileHome
public transient Customer lastCustomer
public transient CustomerProfile lastCustomerProfile
protected static java.lang.String CUSTOMER_PROFILE_HOME
protected static java.lang.String ITEMS_BY_QUALITY_HOME
protected static java.lang.String ITEM_QUALITIES_HOME
public int suggestionCount
suggestionCount
[ShoppingAdvisor] <*>------> [int
]
public int qualityDepth
qualityDepth
[ShoppingAdvisor] <*>------> [int
]
public int itemDepth
itemDepth
[ShoppingAdvisor] <*>------> [int
]
public boolean matchAll
matchAll
[ShoppingAdvisor] <*>------> [boolean
]
Constructor Detail |
public ShoppingAdvisorImpl() throws CreateException
Method Detail |
public void ejbCreate() throws CreateException, java.rmi.RemoteException
public void ejbPostCreate() throws CreateException, java.rmi.RemoteException
public void ejbActivate() throws java.rmi.RemoteException
public void ejbPassivate() throws java.rmi.RemoteException
public void ejbRemove() throws java.rmi.RemoteException
public void setSessionContext(SessionContext ctx) throws java.rmi.RemoteException
public int getSuggestionCount() throws java.rmi.RemoteException
public void setSuggestionCount(int suggestionCount) throws java.rmi.RemoteException
suggestionCount
- suggestionCount to be addedpublic int getQualityDepth() throws java.rmi.RemoteException
public void setQualityDepth(int qualityDepth) throws java.rmi.RemoteException
qualityDepth
- qualityDepth to be addedpublic int getItemDepth() throws java.rmi.RemoteException
public void setItemDepth(int itemDepth) throws java.rmi.RemoteException
itemDepth
- itemDepth to be addedpublic boolean getMatchAll() throws java.rmi.RemoteException
public void setMatchAll(boolean matchAll) throws java.rmi.RemoteException
matchAll
- matchAll to be addedpublic void deleteItem(Item delete) throws java.rmi.RemoteException
public void addItem(Item item) throws java.rmi.RemoteException
public void addDefaultItem(Item item, int degree) throws java.rmi.RemoteException
public void deleteDefaultItem(Item item) throws java.rmi.RemoteException
public Suggestions getDefaultSuggestions() throws java.rmi.RemoteException
public Suggestions getSuggestions(Customer customer) throws java.rmi.RemoteException
public Suggestions getSuggestions(Customer customer, java.lang.String searchString) throws java.rmi.RemoteException
public void learnCustomerPreference(Customer customer, Item item) throws java.rmi.RemoteException
public void addCustomerPreference(Customer customer, Quality quality) throws java.rmi.RemoteException
public void deleteCustomerPreference(Customer customer, Quality quality) throws java.rmi.RemoteException
public void deleteCustomerProfile(Customer customer) throws java.rmi.RemoteException
public Suggestions getSuggestions(java.lang.String searchString) throws java.rmi.RemoteException
public Suggestions getSuggestions(Customer customer, Item item) throws java.rmi.RemoteException
protected CustomerProfileHome getCPHome() throws java.rmi.RemoteException
protected CustomerProfile getCustomerProfile(Customer customer) throws java.rmi.RemoteException
customer
- Customerprotected ItemsByQuality getDefaultItemsByQuality() throws java.rmi.RemoteException
protected ItemsByQualityHome getIBQHome() throws java.rmi.RemoteException
protected ItemQualitiesHome getIQHome() throws java.rmi.RemoteException
protected ItemQualities getItemQualities(Item item) throws java.rmi.RemoteException
protected Suggestions getSuggestions(com.sun.java.util.collections.LinkedList qualities) throws java.rmi.RemoteException
qualities
- com.sun.java.util.collections.LinkedListprotected Suggestions getSuggestions(com.sun.java.util.collections.LinkedList qualities, Suggestions suggestions) throws java.rmi.RemoteException
qualities
- com.sun.java.util.collections.LinkedListprotected void removeItemReferences(Item item, com.sun.java.util.collections.LinkedList listOfQualities) throws java.rmi.RemoteException
listOfQualities
- com.sun.java.util.collections.LinkedList
|
bea Systems, Inc. | ||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |