Class CustomerGroup
dw.customer
Class CustomerGroup
CustomerGroups provide a means to segment customers by various criteria. A merchant can then provide different site experiences (e.g. promotions, prices, sorting rules) to each customer segment. Customer groups can consist of either an explicit list of customers or a business rule that dynamically determines whether a customer is a member. The former type is called "explicit" and the latter type is called "dynamic".
  • Explicit customer group: Consists of an explicit list of customers. Only registered customers can be member of such a group. isRuleBased==false.
  • Dynamic customer group: Memberships are evaluated by a business rule that is attached to the customer group. Registered as well as anonymous customers can be member of such a group. isRuleBased==true.

Note: this class might allow access to sensitive personal and private information, depending on how you segment your customers and the names given to your custoemer groups. Pay attention to appropriate legal and regulatory requirements when developing with this data.

Properties
description  :  String  (Read Only)
Gets the value of the description of the customer group.
ID  :  String  (Read Only)
The unique ID of the customer group.
ruleBased  :  boolean  (Read Only)
Returns true if the group determines the membership of customers based on rules. Returns false if the group provides explicit assignement of customers.
Constructor Summary
This class does not have a constructor, so you cannot create it directly.
Method Summary
assignCustomer(customer : Customer) : void
Assigns the specified customer to this group.
getDescription() : String
Gets the value of the description of the customer group.
getID() : String
Returns the unique ID of the customer group.
isRuleBased() : boolean
Returns true if the group determines the membership of customers based on rules.
unassignCustomer(customer : Customer) : void
Unassigns the specified customer from this group.
Methods inherited from class ExtensibleObject
Methods inherited from class PersistentObject
Method Detail
assignCustomer
assignCustomer(customer : Customer) : void
Assigns the specified customer to this group.
The customer must be registered and the group must not be rule-based.
Parameters:
customer - Registered customer, must not be null.

getDescription
getDescription() : String
Gets the value of the description of the customer group.
Returns:
the description of the customer group

getID
getID() : String
Returns the unique ID of the customer group.
Returns:
The unique semantic ID of the customer group.

isRuleBased
isRuleBased() : boolean
Returns true if the group determines the membership of customers based on rules. Returns false if the group provides explicit assignement of customers.
Returns:
True, if the customer group is rule based.

unassignCustomer
unassignCustomer(customer : Customer) : void
Unassigns the specified customer from this group.
The customer must be registered and the group must not be rule-based.
Parameters:
customer - Registered customer, must not be null.