Class Vendor

java.lang.Object
com.broadleafcommerce.vendor.domain.Vendor
All Implemented Interfaces:
com.broadleafcommerce.data.tracking.core.ContextStateAware, Serializable

public class Vendor extends Object implements Serializable, com.broadleafcommerce.data.tracking.core.ContextStateAware
A domain representing a Vendor.
Author:
Jon Fleschler (jfleschler)
See Also:
  • Constructor Details

    • Vendor

      public Vendor()
  • Method Details

    • getAttribute

      public <T> T getAttribute(String name)
    • getId

      public String getId()
      The context ID of the vendor.
      Returns:
      the context ID of the vendor
    • getName

      public String getName()
      A unique name for the vendor.
      Returns:
      a unique name for the vendor
    • getVendorRef

      public String getVendorRef()
      A unique reference key used throughout the system to associate data to the vendor. This cannot be changed once set.
      Returns:
      a unique reference key for the vendor
    • getAddress

      public Address getAddress()
      The primary address associated with this vendor.
      Returns:
      The primary address associated with this vendor.
    • getPrimaryContact

      public Contact getPrimaryContact()
      The primary contact associated with this vendor.
      Returns:
      The primary contact associated with this vendor.
    • getAdditionalContacts

      public List<Contact> getAdditionalContacts()
      Additional contacts associated with the vendor.
      Returns:
      additional contacts associated with the vendor
    • getAttributes

      public Map<String,Attribute> getAttributes()
      Dynamic attributes that are a part of the vendor. This is an admin-entered concept
      Returns:
      dynamic attributes that are a part of the vendor
    • getDefaultLocale

      public String getDefaultLocale()
      By default, TenantServices will create a vendor catalog upon notice of a new vendor being created. This field is used to inform the default locale to set on that catalog.

      This must match a valid IETF BCP 47 language tag format.

      Returns:
      the IETF BCP 47 language tag of the locale
      See Also:
    • getDefaultCurrency

      public String getDefaultCurrency()
      By default, TenantServices will create a vendor catalog upon notice of a new vendor being created. This field is used to inform the default currency to set on that catalog.
      Returns:
      the ISO 4217 code of the currency
    • getContextState

      public com.broadleafcommerce.data.tracking.core.filtering.business.domain.ContextState getContextState()
      A subset of Tracking information to expose the context state for this object.
      Specified by:
      getContextState in interface com.broadleafcommerce.data.tracking.core.ContextStateAware
      Returns:
      a subset of Tracking information to expose the context state for this object
    • setId

      public void setId(String id)
      The context ID of the vendor.
      Parameters:
      id - the context ID of the vendor
    • setName

      public void setName(String name)
      A unique name for the vendor.
      Parameters:
      name - a unique name for the vendor
    • setVendorRef

      public void setVendorRef(String vendorRef)
      A unique reference key used throughout the system to associate data to the vendor. This cannot be changed once set.
      Parameters:
      vendorRef - a unique reference key for the vendor
    • setAddress

      public void setAddress(Address address)
      The primary address associated with this vendor.
      Parameters:
      address - The primary address associated with this vendor.
    • setPrimaryContact

      public void setPrimaryContact(Contact primaryContact)
      The primary contact associated with this vendor.
      Parameters:
      primaryContact - The primary contact associated with this vendor.
    • setAdditionalContacts

      public void setAdditionalContacts(List<Contact> additionalContacts)
      Additional contacts associated with the vendor.
      Parameters:
      additionalContacts - additional contacts associated with the vendor
    • setAttributes

      public void setAttributes(Map<String,Attribute> attributes)
      Dynamic attributes that are a part of the vendor. This is an admin-entered concept
      Parameters:
      attributes - dynamic attributes that are a part of the vendor
    • setDefaultLocale

      public void setDefaultLocale(String defaultLocale)
      By default, TenantServices will create a vendor catalog upon notice of a new vendor being created. This field is used to inform the default locale to set on that catalog.

      This must match a valid IETF BCP 47 language tag format.

      Parameters:
      defaultLocale - the IETF BCP 47 language tag of the locale
      See Also:
    • setDefaultCurrency

      public void setDefaultCurrency(String defaultCurrency)
      By default, TenantServices will create a vendor catalog upon notice of a new vendor being created. This field is used to inform the default currency to set on that catalog.
      Parameters:
      defaultCurrency - the ISO 4217 code of the currency
    • setContextState

      public void setContextState(com.broadleafcommerce.data.tracking.core.filtering.business.domain.ContextState contextState)
      A subset of Tracking information to expose the context state for this object.
      Specified by:
      setContextState in interface com.broadleafcommerce.data.tracking.core.ContextStateAware
      Parameters:
      contextState - a subset of Tracking information to expose the context state for this object
    • equals

      public boolean equals(Object o)
      Overrides:
      equals in class Object
    • canEqual

      protected boolean canEqual(Object other)
    • hashCode

      public int hashCode()
      Overrides:
      hashCode in class Object
    • toString

      public String toString()
      Overrides:
      toString in class Object