Note: This release is in preview. Features described here don’t become generally available until the latest general availability date that Salesforce announces for this release. Before then, and where features are noted as beta, pilot, or developer preview, we can’t guarantee general availability within any particular time frame or at all. Make your purchase decisions only on the basis of generally available products and features.

BuyerGroupResponse Class

Contains constructors and methods to retrieve the buyer groups associated with a user.

Namespace

CommerceBuyGrp

BuyerGroupResponse Constructors

The following are constructors for BuyerGroupResponse.

BuyerGroupResponse(buyerGroupIds)

Creates a new instance of the CommerceBuyGrp.BuyerGroupResponse class using the specified buyerGroupIds payload parameter.

Signature

public BuyerGroupResponse(Set<String> buyerGroupIds)

Parameters

  • buyerGroupIds:

    Type: Set<String>

    List of buyer group IDs for a user.

BuyerGroupResponse()

Creates a new instance of the CommerceBuyGrp.BuyerGroupResponse class.

Signature

public BuyerGroupResponse()

BuyerGroupResponse Methods

The following are methods for BuyerGroupResponse.

getBuyerGroupIds()

Retrieves a list of evaluated buyer group IDs assigned to a user.

Signature

public Set<String> getBuyerGroupIds()

Return Value

Type: Set<String>

setBuyerGroupIds(buyerGroupIds)

Sets a list of evaluated buyer group IDs assigned to a user.

Signature

public void setBuyerGroupIds(Set<String> buyerGroupIds)

Parameters

  • buyerGroupIds:

    Type: Set<String>

Return Value

Type: void

setError(errorMessage, localizedErrorMessage)

Sets the error message to be returned when the evaluation of buyer group IDs fails.

Signature

public void setError(String errorMessage, String localizedErrorMessage)

Parameters

  • errorMessage:

    Type: String

    The message stating the reason for the error.

  • localizedErrorMessage:

    Type: String

    The translated error message.

Return Value

Type: void