Program Structure for Groups
Programs using the group facility follow this template.
- Determine the group name and property values.
(See also, Restrictions on Names.)
- Subscribe to ordinal update advisories.
Content matchers can filter for these advisories by matching the string value
ORDINAL_UPDATEin thenamefield, and the group name in thegroupfield.The
ordinalfield contains the group member’s new ordinal.The subscriber callback must change the operating role of the application process according to the new ordinal.
- Join the group, using the join API call.
- Explicitly leave the group, using the leave API call.
Programs must leave all groups before closing the realm object.