Overview | Package | Class | Tree | Deprecated | Index | Help
| bea Systems, Inc.
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## theory.smart.ebusiness.giftregistry
Interface GiftRegistry

public interface GiftRegistry
extends Order

A gift registry is a list of things that a customer would like to have purchased on their behalf. Items are removed from the Registries OrderLines and added to the collection of PurchasedOrderLines.

     Primary Key = theory.smart.ebusiness.giftregistry.GiftRegistryPk

                      password
     [GiftRegistry] <*>------> [String]

                      purchasedOrderLine (List)
     [GiftRegistry] <*>------> [theory.smart.ebusiness.giftregistry.PurchasedOrderLine]
                         0..*

                      owner
     [GiftRegistry] <>------> [theory.smart.ebusiness.customer.Customer]

                      email (Map)
     [GiftRegistry] <*>------> [theory.smart.axiom.contact.Email]
                         0..*

See Also:
  `GiftRegistryPk`, `GiftRegistryHome`, `GiftRegistryImpl`, `GiftRegistryValue`

Method Summary
`void` | `addFirstPurchasedOrderLine(PurchasedOrderLine purchasedOrderLine)` Inserts the given purchasedOrderLine at the beginning of the purchasedOrderLine list.
`void` | `addLastPurchasedOrderLine(PurchasedOrderLine purchasedOrderLine)` Appends the given purchasedOrderLine to the end of the purchasedOrderLine list.
`void` | `addPurchasedOrderLine(int index, PurchasedOrderLine purchasedOrderLine)` Inserts the specified purchasedOrderLine at the specified position in the purchasedOrderLine list.
`boolean` | `addPurchasedOrderLine(PurchasedOrderLine purchasedOrderLine)` Appends the specified purchasedOrderLine to the end of the purchasedOrderLine list.
`boolean` | `addPurchasedOrderLines(int index, com.sun.java.util.collections.LinkedList purchasedOrderLines)` Inserts all of the purchasedOrderLines in the specified collection into this list, starting at the specified position.
`boolean` | `addPurchasedOrderLines(com.sun.java.util.collections.LinkedList purchasedOrderLines)` Appends all of the purchasedOrderLines in the specified collection to the end of the purchasedOrderLine list, in the order that they are returned by the specified collection's iterator.
`boolean` | `containsEmailKey(java.lang.String key)` Returns `true` if the email map contains a email for the specified key.
`boolean` | `containsEmailValue(Email email)` Returns `true` if the email map maps one or more keys to the specified email.
`boolean` | `containsPurchasedOrderLine(PurchasedOrderLine purchasedOrderLine)` Returns `true` if the purchasedOrderLine list contains the specified element.
`Email` | `getEmailByKey(java.lang.String key)` Returns the email to which the email map maps the specified key.
`com.sun.java.util.collections.TreeMap` | `getEmails()` Returns a copy all of the emails from the specified map to the email map.
`PurchasedOrderLine` | `getFirstPurchasedOrderLine()` Returns the first purchasedOrderLine in the purchasedOrderLine list.
`GiftRegistryValue` | `getGiftRegistryByValue()` Get all of GiftRegistry's attributes.
`PurchasedOrderLine` | `getLastPurchasedOrderLine()` Returns the last purchasedOrderLine in the purchasedOrderLine list.
`int` | `getNumberOfEmails()` Returns the number of key-value mappings in the email map.
`int` | `getNumberOfPurchasedOrderLines()` Returns the number of purchasedOrderLines in the purchasedOrderLine list.
`Customer` | `getOwner()` Get the remote object reference of owner
`java.lang.String` | `getPassword()` Get the value of password
`PurchasedOrderLine` | `getPurchasedOrderLine(int index)` Returns the purchasedOrderLine at the specified position in the purchasedOrderLine list.
`com.sun.java.util.collections.LinkedList` | `getPurchasedOrderLines()` Returns all of the purchasedOrderLines in the purchasedOrderLine list.
`com.sun.java.util.collections.LinkedList` | `getPurchasedOrderLines(int fromIndex, int toIndex)` Returns a view of the portion of the purchasedOrderLine list between `fromIndex`, inclusive, and `toIndex`, exclusive.
`int` | `indexOfPurchasedOrderLine(PurchasedOrderLine purchasedOrderLine)` Returns the index in the purchasedOrderLine list of the first occurrence of the specified element, or -1 if the purchasedOrderLine list does not contain this element.
`boolean` | `isEmailsEmpty()` Returns `true` if the email map contains no key-value mappings.
`boolean` | `isPurchasedOrderLinesEmtpy()` Returns `true` if the purchasedOrderLine list contains no purchasedOrderLines.
`int` | `lastIndexOfPurchasedOrderLine(PurchasedOrderLine purchasedOrderLine)` Returns the index in the purchasedOrderLine list of the last occurrence of the specified element, or -1 if the purchasedOrderLine list does not contain this element.
`void` | `putEmail(java.lang.String key, Email email)` Associates the specified email with the specified key in the email map.
`void` | `putEmails(com.sun.java.util.collections.TreeMap emails)` Copies all of the emails from the specified email map to this email map.
`PurchasedOrderLine` | `recordPurchase(Customer customer, OrderLine line)` This method is used to record purchases outside of this system.
`PurchasedOrderLine` | `recordPurchase(Customer customer, OrderLine line, PackingList packingList)` This method is used to record purchases made using this system.
`void` | `removeAllEmails()` Removes all emails from this email map.
`void` | `removeAllPurchasedOrderLines()` Removes all of the purchasedOrderLines from the purchasedOrderLine list.
`Email` | `removeEmailByKey(java.lang.String key)` Removes the email for this key from this email map if present.
`PurchasedOrderLine` | `removeFirstPurchasedOrderLine()` Removes and returns the first purchasedOrderLine from the purchasedOrderLine list.
`PurchasedOrderLine` | `removeLastPurchasedOrderLine()` Removes and returns the last purchasedOrderLine from the purchasedOrderLine list.
`PurchasedOrderLine` | `removePurchasedOrderLine(int index)` Removes the purchasedOrderLine at the specified position in the purchasedOrderLine list.
`boolean` | `removePurchasedOrderLine(PurchasedOrderLine purchasedOrderLine)` Removes the first occurrence of the specified purchasedOrderLine in the purchasedOrderLine list.
`void` | `reversePurchase(int lineNo)`
`void` | `setGiftRegistryByValue(GiftRegistryValue value)` Set all of GiftRegistry's attributes to the passed in value.
`void` | `setOwner(Customer owner)` Set the remote object reference of owner
`void` | `setPassword(java.lang.String password)` Set the value of password
`PurchasedOrderLine` | `setPurchasedOrderLine(int index, PurchasedOrderLine purchasedOrderLine)` Replaces the purchasedOrderLine at the specified position in the purchasedOrderLine list with the specified element.

Methods inherited from interface theory.smart.ebusiness.order.Order
`addFirstOrderLine, addItem, addItems, addLastOrderLine, addOrderLine, addOrderLine, addOrderLines, addOrderLines, cancel, containsOrderLine, finalizePrices, findOrderLine, getCustomer, getFirstOrderLine, getItems, getKey, getLastOrderLine, getNumberOfOrderLines, getNumberOfUnits, getOrderByValue, getOrderLine, getOrderLines, getOrderLines, getOrderPriceCalculationPolicyName, getStatus, getTotalPrice, indexOfOrderLine, invoice, isOrderLinesEmtpy, lastIndexOfOrderLine, removeAllItems, removeAllOrderLines, removeFirstOrderLine, removeItem, removeLastOrderLine, removeOrderLine, removeOrderLine, returnOrder, sendToShipping, setCustomer, setItemQuantity, setOrderByValue, setOrderLine, ship`

Methods inherited from interface javax.ejb.EJBObject
`getEJBHome, getHandle, getPrimaryKey, isIdentical, remove`

Method Detail

### getGiftRegistryByValue

    public GiftRegistryValue getGiftRegistryByValue()
                                             throws java.rmi.RemoteException

  Get all of GiftRegistry's attributes.
  Returns:
    GiftRegistryValue the GiftRegistry value object

### setGiftRegistryByValue

    public void setGiftRegistryByValue(GiftRegistryValue value)
                                throws java.rmi.RemoteException

  Set all of GiftRegistry's attributes to the passed in value. Note: Primary key attributes are not set.
  Parameters:
    `GiftRegistryValue` - the GiftRegistry value object

### getPassword

    public java.lang.String getPassword()
                                 throws java.rmi.RemoteException

  Get the value of password
  Returns:
    password.

### setPassword

    public void setPassword(java.lang.String password)
                     throws java.rmi.RemoteException

  Set the value of password
  Parameters:
    `passwords` - password to be added

### addPurchasedOrderLine

    public void addPurchasedOrderLine(int index,
                                      PurchasedOrderLine purchasedOrderLine)
                               throws java.rmi.RemoteException

  Inserts the specified purchasedOrderLine at the specified position in the purchasedOrderLine list. Shifts the purchasedOrderLine currently at that position (if any) and any subsequent purchasedOrderLines to the right (adds one to their indices).
  Parameters:
    `index` - index at which the specified purchasedOrderLine is to be inserted.
    `purchasedOrderLine` - purchasedOrderLine to be inserted.
  Throws:
    IndexOutOfBoundsException - if the specified index is out of range (`index < 0 || index > size()`).

### addPurchasedOrderLine

    public boolean addPurchasedOrderLine(PurchasedOrderLine purchasedOrderLine)
                                  throws java.rmi.RemoteException

  Appends the specified purchasedOrderLine to the end of the purchasedOrderLine list.
  Parameters:
    `purchasedOrderLine` - purchasedOrderLine to be appended to the purchasedOrderLine list.
  Returns:
    `true` (as per the general contract of `Collection.add`).

### addPurchasedOrderLines

    public boolean addPurchasedOrderLines(int index,
                                          com.sun.java.util.collections.LinkedList purchasedOrderLines)
                                   throws java.rmi.RemoteException

  Inserts all of the purchasedOrderLines in the specified collection into this list, starting at the specified position. Shifts the element currently at that position (if any) and any subsequent purchasedOrderLines to the right (increases their indices). The new purchasedOrderLines will appear in the purchasedOrderLine list in the order that they are returned by the specified collection's iterator.
  Parameters:
    `index` - index at which to insert first element from the specified collection.
    `purchasedOrderLines` - purchasedOrderLines to be inserted into the purchasedOrderLine list.
  Throws:
    IndexOutOfBoundsException - if the specified index is out of range (`index < 0 || index > size()`).

### addPurchasedOrderLines

    public boolean addPurchasedOrderLines(com.sun.java.util.collections.LinkedList purchasedOrderLines)
                                   throws java.rmi.RemoteException

  Appends all of the purchasedOrderLines in the specified collection to the end of the purchasedOrderLine list, in the order that they are returned by the specified collection's iterator. The behavior of this operation is undefined if the specified collection is modified while the operation is in progress. (This implies that the behavior of this call is undefined if the specified Collection is the purchasedOrderLine list, and the purchasedOrderLine list is nonempty.)
  Parameters:
    `purchasedOrderLines` - purchasedOrderLines to be inserted into the purchasedOrderLine list.
  Throws:
    IndexOutOfBoundsException - if the specified index is out of range (`index < 0 || index > size()`).

### addFirstPurchasedOrderLine

    public void addFirstPurchasedOrderLine(PurchasedOrderLine purchasedOrderLine)
                                    throws java.rmi.RemoteException

  Inserts the given purchasedOrderLine at the beginning of the purchasedOrderLine list.

### addLastPurchasedOrderLine

    public void addLastPurchasedOrderLine(PurchasedOrderLine purchasedOrderLine)
                                   throws java.rmi.RemoteException

  Appends the given purchasedOrderLine to the end of the purchasedOrderLine list. (Identical in function to the `add` method; included only for consistency.)

### containsPurchasedOrderLine

    public boolean containsPurchasedOrderLine(PurchasedOrderLine purchasedOrderLine)
                                       throws java.rmi.RemoteException

  Returns `true` if the purchasedOrderLine list contains the specified element. More formally, returns `true` if and only if the purchasedOrderLine list contains at least one purchasedOrderLine `e` such that `(o==null ? e==null : o.equals(e))`.
  Parameters:
    `purchasedOrderLine` - purchasedOrderLine whose presence in the purchasedOrderLine list is to be tested.
  Returns:
    `true` if the purchasedOrderLine list contains the specified element.

### getPurchasedOrderLine

    public PurchasedOrderLine getPurchasedOrderLine(int index)
                                             throws java.rmi.RemoteException

  Returns the purchasedOrderLine at the specified position in the purchasedOrderLine list.
  Parameters:
    `index` - index of purchasedOrderLine to return.
  Returns:
    the purchasedOrderLine at the specified position in the purchasedOrderLine list.
  Throws:
    IndexOutOfBoundsException - if the specified index is is out of range (`index < 0 || index >= size()`).

### getPurchasedOrderLines

    public com.sun.java.util.collections.LinkedList getPurchasedOrderLines(int fromIndex,
                                                                           int toIndex)
                                                                    throws java.rmi.RemoteException

  Returns a view of the portion of the purchasedOrderLine list between `fromIndex`, inclusive, and `toIndex`, exclusive.
  Parameters:
    `fromIndex` - low endpoint (inclusive) of the subList.
    `toKey` - high endpoint (exclusive) of the subList.
  Returns:
    a view of the specified range within the purchasedOrderLine list.
  Throws:
    IndexOutOfBoundsException - endpoint index value out of range `(fromIndex < 0 || toIndex > size)`
    java.lang.IllegalArgumentException - endpoint indices out of order `(fromIndex > toIndex)`

### getPurchasedOrderLines

    public com.sun.java.util.collections.LinkedList getPurchasedOrderLines()
                                                                    throws java.rmi.RemoteException

  Returns all of the purchasedOrderLines in the purchasedOrderLine list.
  Returns:
    all of the purchasedOrderLines in the purchasedOrderLine list.

### getFirstPurchasedOrderLine

    public PurchasedOrderLine getFirstPurchasedOrderLine()
                                                  throws java.rmi.RemoteException

  Returns the first purchasedOrderLine in the purchasedOrderLine list.
  Returns:
    the first purchasedOrderLine in the purchasedOrderLine list.

### getLastPurchasedOrderLine

    public PurchasedOrderLine getLastPurchasedOrderLine()
                                                 throws java.rmi.RemoteException

  Returns the last purchasedOrderLine in the purchasedOrderLine list.
  Returns:
    the last purchasedOrderLine in the purchasedOrderLine list.
  Throws:
    NoSuchElementException - if the purchasedOrderLine list is empty.

### getNumberOfPurchasedOrderLines

    public int getNumberOfPurchasedOrderLines()
                                       throws java.rmi.RemoteException

  Returns the number of purchasedOrderLines in the purchasedOrderLine list.
  Returns:
    the number of purchasedOrderLines in the purchasedOrderLine list.

### indexOfPurchasedOrderLine

    public int indexOfPurchasedOrderLine(PurchasedOrderLine purchasedOrderLine)
                                  throws java.rmi.RemoteException

  Returns the index in the purchasedOrderLine list of the first occurrence of the specified element, or -1 if the purchasedOrderLine list does not contain this element. More formally, returns the lowest index i such that `(o==null ? get(i)==null : o.equals(get(i)))`, or -1 if there is no such index.
  Parameters:
    `purchasedOrderLine` - purchasedOrderLine to search for.
  Returns:
    the index in the purchasedOrderLine list of the first occurrence of the specified element, or -1 if the purchasedOrderLine list does not contain this element.

### isPurchasedOrderLinesEmtpy

    public boolean isPurchasedOrderLinesEmtpy()
                                       throws java.rmi.RemoteException

  Returns `true` if the purchasedOrderLine list contains no purchasedOrderLines.

  Returns:
    `true` if the purchasedOrderLine list contains no purchasedOrderLines.

### lastIndexOfPurchasedOrderLine

    public int lastIndexOfPurchasedOrderLine(PurchasedOrderLine purchasedOrderLine)
                                      throws java.rmi.RemoteException

  Returns the index in the purchasedOrderLine list of the last occurrence of the specified element, or -1 if the purchasedOrderLine list does not contain this element. More formally, returns the highest index i such that `(o==null ? get(i)==null : o.equals(get(i)))`, or -1 if there is no such index.
  Parameters:
    `purchasedOrderLine` - purchasedOrderLine to search for.
  Returns:
    the index in the purchasedOrderLine list of the last occurrence of the specified element, or -1 if the purchasedOrderLine list does not contain this element.

### removeAllPurchasedOrderLines

    public void removeAllPurchasedOrderLines()
                                      throws java.rmi.RemoteException

  Removes all of the purchasedOrderLines from the purchasedOrderLine list.

### removePurchasedOrderLine

    public PurchasedOrderLine removePurchasedOrderLine(int index)
                                                throws java.rmi.RemoteException

  Removes the purchasedOrderLine at the specified position in the purchasedOrderLine list. Shifts any subsequent purchasedOrderLines to the left (subtracts one from their indices). Returns the purchasedOrderLine that was removed from the purchasedOrderLine list.
  Parameters:
    `index` - the index of the purchasedOrderLine to removed.
  Returns:
    the purchasedOrderLine previously at the specified position.
  Throws:
    IndexOutOfBoundsException - if the specified index is out of range (`index < 0 || index >= size()`).

### removePurchasedOrderLine

    public boolean removePurchasedOrderLine(PurchasedOrderLine purchasedOrderLine)
                                     throws java.rmi.RemoteException

  Removes the first occurrence of the specified purchasedOrderLine in the purchasedOrderLine list. If the purchasedOrderLine list does not contain the element, it is unchanged. More formally, removes the purchasedOrderLine with the lowest index `i` such that `(o==null ? get(i)==null : o.equals(get(i)))` (if such an purchasedOrderLine exists).
  Parameters:
    `purchasedOrderLine` - purchasedOrderLine to be removed from the purchasedOrderLine list, if present.
  Returns:
    `true` if the purchasedOrderLine list contained the specified element.

### removeFirstPurchasedOrderLine

    public PurchasedOrderLine removeFirstPurchasedOrderLine()
                                                     throws java.rmi.RemoteException

  Removes and returns the first purchasedOrderLine from the purchasedOrderLine list.
  Returns:
    the first purchasedOrderLine from the purchasedOrderLine list.
  Throws:
    NoSuchElementException - if the purchasedOrderLine list is empty.

### removeLastPurchasedOrderLine

    public PurchasedOrderLine removeLastPurchasedOrderLine()
                                                    throws java.rmi.RemoteException

  Removes and returns the last purchasedOrderLine from the purchasedOrderLine list.
  Returns:
    the last purchasedOrderLine from the purchasedOrderLine list.
  Throws:
    NoSuchElementException - if the purchasedOrderLine list is empty.

### setPurchasedOrderLine

    public PurchasedOrderLine setPurchasedOrderLine(int index,
                                                    PurchasedOrderLine purchasedOrderLine)
                                             throws java.rmi.RemoteException

  Replaces the purchasedOrderLine at the specified position in the purchasedOrderLine list with the specified element.
  Parameters:
    `index` - index of purchasedOrderLine to replace.
    `purchasedOrderLine` - purchasedOrderLine to be stored at the specified position.
  Returns:
    the purchasedOrderLine previously at the specified position.
  Throws:
    IndexOutOfBoundsException - if the specified index is out of range (`index < 0 || index >= size()`).

### getOwner

    public Customer getOwner()
                      throws java.rmi.RemoteException

  Get the remote object reference of owner
  Returns:
    owner.

### setOwner

    public void setOwner(Customer owner)
                  throws java.rmi.RemoteException

  Set the remote object reference of owner
  Parameters:
    `owners` - owner to be added

### containsEmailKey

    public boolean containsEmailKey(java.lang.String key)
                             throws java.rmi.RemoteException

  Returns `true` if the email map contains a email for the specified key.
  Parameters:
    `key` - key whose presence in the email map is to be tested.
  Returns:
    `true` if the email map contains a email for the specified key.
  Throws:
    ClassCastException - if the key cannot be compared with the keys currently in the map.
    NullPointerException - key is `null` and the email map uses natural ordering, or its comparator does not tolerate `null` keys.

### containsEmailValue

    public boolean containsEmailValue(Email email)
                               throws java.rmi.RemoteException

  Returns `true` if the email map maps one or more keys to the specified email. This operation will probably require linear time.
  Parameters:
    `email` - value of email whose presence in the email map is to be tested.

### getEmailByKey

    public Email getEmailByKey(java.lang.String key)
                        throws java.rmi.RemoteException

  Returns the email to which the email map maps the specified key. Returns `null` if the map contains no email for this key. A return value of `null` does not necessarily indicate that the map contains no email for the key; it's also possible that the map explicitly maps the key to `null`. The `containsKey` operation may be used to distinguish these two cases.
  Parameters:
    `key` - key whose associated email is to be returned.
  Returns:
    the email to which the email map maps the specified key, or `null` if the map contains no email for the key.
  Throws:
    ClassCastException - key cannot be compared with the keys currently in the map.
    NullPointerException - key is `null` and the email map uses natural ordering, or its comparator does not tolerate `null` keys.
  See Also:
    `#containsKey(Object)`

### getEmails

    public com.sun.java.util.collections.TreeMap getEmails()
                                                    throws java.rmi.RemoteException

  Returns a copy all of the emails from the specified map to the email map. These emails replace any emails that the email map had for any of the keys currently in the specified map.
  Parameters:
    `emails` - a copy of the emails.
  Throws:
    ClassCastException - class of a key or email in the specified map prevents it from being stored in the email map.
    NullPointerException - the email map does not permit `null` keys and a specified key is `null`.

### getNumberOfEmails

    public int getNumberOfEmails()
                          throws java.rmi.RemoteException

  Returns the number of key-value mappings in the email map.
  Returns:
    the number of key-value mappings in the email map.

### isEmailsEmpty

    public boolean isEmailsEmpty()
                          throws java.rmi.RemoteException

  Returns `true` if the email map contains no key-value mappings.

  Returns:
    `true` if the email map contains no key-value mappings.

### putEmail

    public void putEmail(java.lang.String key,
                         Email email)
                  throws java.rmi.RemoteException

  Associates the specified email with the specified key in the email map. If the map previously contained a email for this key, the old email is replaced.
  Parameters:
    `key` - key with which the specified email is to be associated.
    `email` - email to be associated with the specified key.
  Throws:
    ClassCastException - key cannot be compared with the keys currently in the map.
    NullPointerException - key is `null` and the email map uses natural order, or its comparator does not tolerate `null` keys.

### putEmails

    public void putEmails(com.sun.java.util.collections.TreeMap emails)
                   throws java.rmi.RemoteException

  Copies all of the emails from the specified email map to this email map. These emails replace any emails that this email map had for any of the keys currently in the specified map.
  Parameters:
    `email` - Emails to be stored in the email map.
  Throws:
    ClassCastException - class of a key or email in the specified map prevents it from being stored in the email map.
    NullPointerException - the email map does not permit `null` keys and a specified key is `null`.

### removeAllEmails

    public void removeAllEmails()
                         throws java.rmi.RemoteException

  Removes all emails from this email map.

### removeEmailByKey

    public Email removeEmailByKey(java.lang.String key)
                           throws java.rmi.RemoteException

  Removes the email for this key from this email map if present.
  Parameters:
    `key` - key with which the specified email is associated.
  Returns:
    previous email associated with specified key, or `null` if there was no email for key. A `null` return can also indicate that the map previously associated `null` with the specified key.
  Throws:
    ClassCastException - key cannot be compared with the keys currently in the map.
    NullPointerException - key is `null` and the email map uses natural order, or its comparator does not tolerate `null` keys.

### recordPurchase

    public PurchasedOrderLine recordPurchase(Customer customer,
                                             OrderLine line)
                                      throws java.rmi.RemoteException

  This method is used to record purchases outside of this system.

### recordPurchase

    public PurchasedOrderLine recordPurchase(Customer customer,
                                             OrderLine line,
                                             PackingList packingList)
                                      throws java.rmi.RemoteException

  This method is used to record purchases made using this system. The PackingList is included so that we can track the status of this particular purchase.

### reversePurchase

    public void reversePurchase(int lineNo)
                         throws java.rmi.RemoteException

Overview | Package | Class | Tree | Deprecated | Index | Help
| bea Systems, Inc.
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

© Copyright 2000 bea Systems, Inc. All rights reserved.