getDescription()
:
String
Returns a description text that, for example, explains the purpose of this product list.
getID()
:
String
Returns the unique system generated ID of the object.
getLastExportTime()
:
Date
Returns the date where this product list has been exported successfully the last time.
getName()
:
String
Returns the name of this product list given by its owner.
getOwner()
:
Customer
Returns the customer that created and owns the product list.
getType()
:
Number
Returns an int representing the type of object (e.g.
isAnonymous()
:
boolean
Returns true if this product list is owned by an anonymous customer.
isPublic()
:
boolean
A flag, typically used to determine if the object is searchable by other customers.
removeCoRegistrant()
:
void
Removes the ProductListRegistrant assigned to the coRegistrant attribute.
removeRegistrant()
:
void
Removes the ProductListRegistrant assigned to the registrant attribute.
setEventCity(eventCity
:
String)
:
void
Set the event city to which this product list is related.
setEventCountry(eventCountry
:
String)
:
void
Set the event country to which this product list is related.
setEventDate(eventDate
:
Date)
:
void
Set the date of the event to which this product list is related.
setEventState(eventState
:
String)
:
void
Set the event state to which this product list is related.
setEventType(eventType
:
String)
:
void
Set the event type for which this product list was created by the owner.
setPublic(flag
:
boolean)
:
void
Makes this product list visible to other customers or hides it.
createCoRegistrant
Create a ProductListRegistrant and assign it to the coRegistrant attribute
of the list. An exception is thrown if the list already has a coRegistrant
assigned to it.
Returns:
the created ProductListRegistrant instance.
Throws:
CreateException
-
if one already exists
createGiftCertificateItem
Create an item in the list that represents a gift certificate.
A list may only contain a single gift certificate, so an exception
is thrown if one already exists in the list.
Returns:
the created item.
Throws:
CreateException
-
if a gift certificate item already exists in the list.
createProductItem
Create an item in the list that references the specified product.
Parameters:
product
-
the product to use to create the list item.
Returns:
the created item.
createRegistrant
Create a ProductListRegistrant and assign it to the registrant attribute
of the list. An exception is thrown if the list already has a registrant
assigned to it.
Returns:
the created ProductListRegistrant instance.
Throws:
CreateException
-
if one already exists
getCoRegistrant
Returns the ProductListRegistrant assigned to the coRegistrant attribute or null
if this list has no co-registrant.
Returns:
the ProductListRegistrant assigned to the coRegistrant attribute or null if this list has no co-registrant.
getCurrentShippingAddress
This is a helper method typically used with an event related list.
It provides the appropriate shipping address based on the eventDate.
If the current date is after the eventDate, then the postEventShippingAddress
is returned, otherwise the shippingAddress is returned. If the eventDate
is null, then null is returned.
Returns:
the appropriate address, as described above.
getDescription
Returns a description text that, for example, explains the purpose of this product list.
Returns:
a description text explaining the purpose of this product list. Returns an empty string if the description is not set.
getEventCity
For event related uses (e.g. gift registry), this holds the event city.
Returns:
the event city. The event city or an empty string if no event city is set.
getEventCountry
For event related uses (e.g. gift registry), this holds the event country.
Returns:
the event country. The event country or an empty string if no event country is set.
getEventDate
For event related uses (e.g. gift registry), this holds the date
of the event.
Returns:
the date of the event.
getEventState
For event related uses (e.g. gift registry), this holds the event state.
Returns:
the event state. The event state or an empty string if no event state is set.
getEventType
For event related uses (e.g. gift registry), this holds the type
of event, e.g. Wedding, Baby Shower.
Returns:
the type of event. Returns an empty string, if not set.
getExportStatus
Returns:
Product list export status
getGiftCertificateItem
Returns the item in the list that represents a gift certificate.
Returns:
the gift certificate item, or null if it doesn't exist.
getID
Returns the unique system generated ID of the object.
Returns:
the ID of object.
getItem
Returns the item from the list that has the specified ID.
Parameters:
ID
-
the product list item identifier.
Returns:
the specified item, or null if it's not found in the list.
getItems
Returns a collection containing all items in the list.
getLastExportTime
getLastExportTime()
:
Date
Returns the date where this product list has been exported successfully
the last time.
Returns:
The time of the last successful export or null if this product list was not exported yet.
getName
Returns the name of this product list given by its owner.
Returns:
the name of this product list. Returns an empty string if the name is not set.
getOwner
Returns the customer that created and owns the product list.
getPostEventShippingAddress
Returns the shipping address for purchases made after the event date.
Returns:
the shipping address for purchases made after the event date. Returns null if no post-event shipping address is associated.
getProductItems
Returns a collection containing all items in the list that reference products.
Returns:
all product items.
getPublicItems
Returns a collection containing all items in the list that are flagged as public.
Returns:
all public items.
getPurchases
Returns the aggregated purchases from all the individual items.
getRegistrant
Returns the ProductListRegistrant assigned to the registrant attribute or null
if this list has no registrant.
Returns:
the ProductListRegistrant assigned to the registrant attribute or null if this list has no registrant.
getShippingAddress
Return the address that should be used as the shipping address for purchases
made from the list.
Returns:
the shipping address. The shipping address of this list or null if no address is associated.
getType
Returns an int representing the type of object (e.g. wish list,
gift registry). This is set at object creation time.
Returns:
the type of object.
isAnonymous
isAnonymous()
:
boolean
Returns true if this product list is owned by an anonymous customer.
Returns:
true if the owner of this product list is anonymous, false otherwise.
isPublic
isPublic()
:
boolean
A flag, typically used to determine if the object is searchable
by other customers.
Returns:
true if the product list is public. False otherwise.
removeCoRegistrant
removeCoRegistrant()
:
void
Removes the ProductListRegistrant assigned to the coRegistrant attribute.
removeItem
Removes the specified item from the list. This will also cause
all purchase information associated with that item to be removed.
Parameters:
item
-
The item to remove.
removeRegistrant
removeRegistrant()
:
void
Removes the ProductListRegistrant assigned to the registrant attribute.
setDescription
setDescription(description
:
String)
:
void
Set the description of this product list.
Parameters:
description
-
The description of this product list. The description can have up to 256 characters, longer descriptions get truncated. If an empty string is provided, the description gets set to null.
setEventCity
setEventCity(eventCity
:
String)
:
void
Set the event city to which this product list is related.
Parameters:
eventCity
-
The event city can have up to 256 characters, longer event city get truncated. If an empty string is provided, the event city gets set to null.
setEventCountry
setEventCountry(eventCountry
:
String)
:
void
Set the event country to which this product list is related.
Parameters:
eventCountry
-
The event country can have up to 256 characters, longer event country get truncated. If an empty string is provided, the event country gets set to null.
setEventDate
setEventDate(eventDate
:
Date)
:
void
Set the date of the event to which this product list is related.
Parameters:
eventDate
-
The event date or null if no event date should be available.
setEventState
setEventState(eventState
:
String)
:
void
Set the event state to which this product list is related.
Parameters:
eventState
-
The event state can have up to 256 characters, longer event state get truncated. If an empty string is provided, the event state gets set to null.
setEventType
setEventType(eventType
:
String)
:
void
Set the event type for which this product list was created by the owner.
Parameters:
eventType
-
The event type can have up to 256 characters, longer event type get truncated. If an empty string is provided, the event type gets set to null.
setName
Set the name of this product list.
Parameters:
name
-
The name of this product list. The name can have up to 256 characters, longer names get truncated. If an empty string is provided, the name gets set to null.
setPostEventShippingAddress
This is typically used by an event related list (e.g. gift registry) to
specify a shipping address for purchases made after the event date.
Parameters:
address
-
The shipping address.
setPublic
setPublic(flag
:
boolean)
:
void
Makes this product list visible to other customers or hides it.
Parameters:
flag
-
If true, this product list becomes visible to other customers. If false, this product list can only be seen and searched by its owner.
setShippingAddress
Associate an address, used as the shipping address for purchases
made from the list.
Parameters:
address
-
The shipping address.