com.ibm.commerce.giftcenter.context

Interface GiftCenterContext

  • All Superinterfaces:
    Context, java.io.Serializable
    All Known Implementing Classes:
    GiftCenterContextImpl


    public interface GiftCenterContext
    extends Context
    The context contains the following information for managing gift lists:
    • A list of external identifiers for gift lists the user has accessed with a gift giver relationship
    • A list of external identifiers for gift lists the user has accessed with a co-registrant relationship
    • The unique identifier of the gift list that is being completed
    • Field Summary

      Fields 
      Modifier and Type Field and Description
      static java.lang.String CONTEXT_NAME
      The name that will identify this context in the CTXDATA table.
      static java.lang.String COPYRIGHT
      IBM copyright notice field.
      static java.lang.Integer COREGISTRANT_TYPE
      The constant that refers to users who are co-registrants.
      static java.lang.Integer GIFT_GIVER
      The constant that refers to users who are gift givers.
      static java.lang.Integer REGISTRANT_TYPE
      The constant that refers to users who are registrants.
      static java.lang.String SER_ELEMENT_SEP
      The delimiter used in Vector and HashMap string representation.
      static java.lang.String SER_KEY_SEP
      The delimiter used in the key-value of the HashMap string representation.
    • Field Detail

      • COPYRIGHT

        static final java.lang.String COPYRIGHT
        IBM copyright notice field.
        See Also:
        Constant Field Values
      • CONTEXT_NAME

        static final java.lang.String CONTEXT_NAME
        The name that will identify this context in the CTXDATA table.
        See Also:
        Constant Field Values
      • SER_ELEMENT_SEP

        static final java.lang.String SER_ELEMENT_SEP
        The delimiter used in Vector and HashMap string representation.
        See Also:
        Constant Field Values
      • SER_KEY_SEP

        static final java.lang.String SER_KEY_SEP
        The delimiter used in the key-value of the HashMap string representation.
        See Also:
        Constant Field Values
      • REGISTRANT_TYPE

        static final java.lang.Integer REGISTRANT_TYPE
        The constant that refers to users who are registrants.
      • COREGISTRANT_TYPE

        static final java.lang.Integer COREGISTRANT_TYPE
        The constant that refers to users who are co-registrants.
      • GIFT_GIVER

        static final java.lang.Integer GIFT_GIVER
        The constant that refers to users who are gift givers.
    • Method Detail

      • getGiftListExtIdsAccessed

        java.util.Vector getGiftListExtIdsAccessed()
        Returns a list of external identifiers for gift lists that the user has accessed with either the gift giver relationship or the co-registrant relationship. For external identifiers for gift lists with which the user has a registrant relationship, use the getGiftRegistriesOwnedByUser and getWishListsOwnedByUser methods.
        Returns:
        A list of gift list external identifiers.
      • getGiftListRelationship

        java.lang.Integer getGiftListRelationship(java.lang.String externalId)
        Returns the relationship a user has to a gift list that was accessed.
        Parameters:
        externalId - The gift list identifier for which the relationship value must be returned.
        Returns:
        The user's relationship value with the gift list.
      • getGiftListExtIdsByCoRegistrantRelationship

        java.util.Vector getGiftListExtIdsByCoRegistrantRelationship()
        Returns a list of external identifiers for gift lists that the user has a co-registrant relationship with.
        Returns:
        A list of gift list external identifiers.
      • getGiftListExtIdsByGiftGiverRelationship

        java.util.Vector getGiftListExtIdsByGiftGiverRelationship()
        Returns a list of external identifiers for gift lists that the user has a gift giver relationship with.
        Returns:
        A list of gift list external identifiers.
      • getGiftListBeingCompleted

        java.lang.String getGiftListBeingCompleted()
        Returns the unique identifier for the gift list that the user is currently completing.
        Returns:
        The unique identifier for the gift list that the user is currently completing.
      • getGiftRegistiesOwnedByUser

        java.util.Vector getGiftRegistiesOwnedByUser()
        Returns a vector of external identifiers for gift registries the user owns, if the user is not a guest or generic user. For guest and generic users, this method returns an empty vector.
        Returns:
        A vector of external identifiers for gift registries the user owns in the context. If the user is a guest or generic user, the vector is empty.
      • getWishListsOwnedByUser

        java.util.Vector getWishListsOwnedByUser()
        Returns a vector of external identifiers for wish lists the user owns, if the user is not a guest or generic user. For guest and generic users, this method returns an empty vector.
        Returns:
        A vector of external identifiers for wish lists the user owns in the context. If the user is a guest or generic user, the vector is empty.
      • addToGiftListExtIdAccessedWithGiftGiverRelationship

        void addToGiftListExtIdAccessedWithGiftGiverRelationship(java.lang.String externalId)
        Adds a gift list external identifier value to the list of identifiers for gift lists the user has accessed with a gift giver relationship. If the user accesses a new gift list, this method is called to store this information. If the user previously accessed the gift list with a relationship higher than gift giver, for example, registrant, the method does not change the user's relationship with the gift list.
        Parameters:
        externalId - The gift list external identifier that will be added to the list.
      • addToGiftListExtIdAccessedWithCoRegistrantRelationship

        void addToGiftListExtIdAccessedWithCoRegistrantRelationship(java.lang.String externalId)
        Adds a gift list external identifier value to the list of identifiers for gift lists the user has accessed with a co-registrant relationship. If the user accesses a new gift list, this method is called to store this information. If the user owns the gift list, this method does not update the context.
        Parameters:
        externalId - The gift list external identifier that will be added to the list.
      • addToGiftListExtIdAccessed

        void addToGiftListExtIdAccessed(java.lang.String externalId,
                                        java.lang.Integer relationship)
        Adds a gift list external identifier value to the list of identifiers for gift lists the user has accessed. If the user accesses a new gift list, this method is called to store this information. The relationship parameter is the user authentication relationship the user has with the gift list.
        Parameters:
        externalId - The gift list external identifier that will be added to the list.
        relationship - The relationship the user has with the gift list.
      • setGiftListBeingCompleted

        void setGiftListBeingCompleted(java.lang.String aGiftListBeingCompleted)
        Sets the unique identifier for the gift list that the user is currently completing.
        Parameters:
        aGiftListBeingCompleted - The unique identifier for the gift list that the user is currently completing.
      • removeGiftListExtIdAccessed

        void removeGiftListExtIdAccessed(java.lang.String externalId)
        Removes a gift list external identifier from the list of accessed gift lists for this user.
        Parameters:
        externalId - The gift list external identifier that must be removed.
      • removeAllAccessedGiftListExtIds

        void removeAllAccessedGiftListExtIds()
        Removes all gift list external identifiers from the list of accessed gift lists for this user.