public static class Storefront.Customer extends AbstractResponse<Storefront.Customer> implements Storefront.HasMetafields, Storefront.MetafieldParentResource
optimisticData, responseData| Modifier and Type | Method and Description |
|---|---|
java.lang.Boolean |
getAcceptsMarketing()
Indicates whether the customer has consented to be sent marketing material via email.
|
Storefront.MailingAddressConnection |
getAddresses()
A list of addresses for the customer.
|
DateTime |
getCreatedAt()
The date and time when the customer was created.
|
Storefront.MailingAddress |
getDefaultAddress()
The customer’s default address.
|
java.lang.String |
getDisplayName()
The customer’s name, email or phone number.
|
java.lang.String |
getEmail()
The customer’s email address.
|
java.lang.String |
getFirstName()
The customer’s first name.
|
java.lang.String |
getGraphQlTypeName() |
ID |
getId()
A unique ID for the customer.
|
java.lang.String |
getLastName()
The customer’s last name.
|
Storefront.Metafield |
getMetafield()
Returns a metafield found by namespace and key.
|
java.util.List<Storefront.Metafield> |
getMetafields()
The metafields associated with the resource matching the supplied list of namespaces and keys.
|
java.lang.String |
getNumberOfOrders()
The number of orders that the customer has made at the store in their lifetime.
|
Storefront.OrderConnection |
getOrders()
The orders associated with the customer.
|
java.lang.String |
getPhone()
The customer’s phone number.
|
java.util.List<java.lang.String> |
getTags()
A comma separated list of tags that have been added to the customer.
|
DateTime |
getUpdatedAt()
The date and time when the customer information was updated.
|
Storefront.Customer |
setAcceptsMarketing(java.lang.Boolean arg) |
Storefront.Customer |
setAddresses(Storefront.MailingAddressConnection arg) |
Storefront.Customer |
setCreatedAt(DateTime arg) |
Storefront.Customer |
setDefaultAddress(Storefront.MailingAddress arg) |
Storefront.Customer |
setDisplayName(java.lang.String arg) |
Storefront.Customer |
setEmail(java.lang.String arg) |
Storefront.Customer |
setFirstName(java.lang.String arg) |
Storefront.Customer |
setId(ID arg) |
Storefront.Customer |
setLastName(java.lang.String arg) |
Storefront.Customer |
setMetafield(Storefront.Metafield arg) |
Storefront.Customer |
setMetafields(java.util.List<Storefront.Metafield> arg) |
Storefront.Customer |
setNumberOfOrders(java.lang.String arg) |
Storefront.Customer |
setOrders(Storefront.OrderConnection arg) |
Storefront.Customer |
setPhone(java.lang.String arg) |
Storefront.Customer |
setTags(java.util.List<java.lang.String> arg) |
Storefront.Customer |
setUpdatedAt(DateTime arg) |
boolean |
unwrapsToObject(java.lang.String key) |
collectNodes, get, getFieldName, getKey, jsonAsArray, jsonAsBoolean, jsonAsDouble, jsonAsInteger, jsonAsObject, jsonAsString, withAliaspublic Customer()
public Customer(JsonObject fields)
throws SchemaViolationError
SchemaViolationErrorpublic java.lang.String getGraphQlTypeName()
getGraphQlTypeName in interface Storefront.HasMetafieldsgetGraphQlTypeName in interface Storefront.MetafieldParentResourcepublic java.lang.Boolean getAcceptsMarketing()
public Storefront.Customer setAcceptsMarketing(java.lang.Boolean arg)
public Storefront.MailingAddressConnection getAddresses()
public Storefront.Customer setAddresses(Storefront.MailingAddressConnection arg)
public DateTime getCreatedAt()
public Storefront.Customer setCreatedAt(DateTime arg)
public Storefront.MailingAddress getDefaultAddress()
public Storefront.Customer setDefaultAddress(Storefront.MailingAddress arg)
public java.lang.String getDisplayName()
public Storefront.Customer setDisplayName(java.lang.String arg)
public java.lang.String getEmail()
public Storefront.Customer setEmail(java.lang.String arg)
public java.lang.String getFirstName()
public Storefront.Customer setFirstName(java.lang.String arg)
public ID getId()
public Storefront.Customer setId(ID arg)
public java.lang.String getLastName()
public Storefront.Customer setLastName(java.lang.String arg)
public Storefront.Metafield getMetafield()
getMetafield in interface Storefront.HasMetafieldspublic Storefront.Customer setMetafield(Storefront.Metafield arg)
public java.util.List<Storefront.Metafield> getMetafields()
getMetafields in interface Storefront.HasMetafieldspublic Storefront.Customer setMetafields(java.util.List<Storefront.Metafield> arg)
public java.lang.String getNumberOfOrders()
public Storefront.Customer setNumberOfOrders(java.lang.String arg)
public Storefront.OrderConnection getOrders()
public Storefront.Customer setOrders(Storefront.OrderConnection arg)
public java.lang.String getPhone()
public Storefront.Customer setPhone(java.lang.String arg)
public java.util.List<java.lang.String> getTags()
public Storefront.Customer setTags(java.util.List<java.lang.String> arg)
public DateTime getUpdatedAt()
public Storefront.Customer setUpdatedAt(DateTime arg)
public boolean unwrapsToObject(java.lang.String key)
unwrapsToObject in class AbstractResponse<Storefront.Customer>