Table of Contents

Class ContactGroupMemberInfoProvider

Namespace
CMS.ContactManagement
Assembly
CMS.ContactManagement.dll

Class providing ContactGroupMemberInfo management.

[ProviderInterface(typeof(IContactGroupMemberInfoProvider))]
[Obsolete("Use CMS.DataEngine.IInfoProvider<ContactGroupMemberInfo> instead. Use CMS.DataEngine.InfoProviderExtensions for additional methods for individual objects retrieval. To get an instance of the interface's implementation use dependency injection or access the instance directly via the CMS.DataEngine.Provider<ContactGroupMemberInfo>.Instance property. When faking metadata in CMS.Tests.UnitTests using Fake() use the obsolete provider class until fully removed.")]
[ObsoleteSince(30, 0)]
public class ContactGroupMemberInfoProvider : AbstractInfoProvider<ContactGroupMemberInfo, ContactGroupMemberInfoProvider>, IInfoProvider, ICustomizableProvider, IBulkOperationProvider, IWebFarmProvider, IInfoValidator<ContactGroupMemberInfo>, IInfoByGuidProvider<ContactGroupMemberInfo>, IInfoByNameProvider<ContactGroupMemberInfo>, IBulkInfoProvider<ContactGroupMemberInfo>, IContactGroupMemberInfoProvider, IInfoProvider<ContactGroupMemberInfo>, IInfoByIdProvider<ContactGroupMemberInfo>
Inheritance
object
ContactGroupMemberInfoProvider
Implements
Inherited Members
Extension Methods

Methods

Add(int, int, ContactGroupMemberTypeEnum, MemberAddedHowEnum)

Creates ContactGroupMemberInfo binding.

[Obsolete("Use CMS.ContactManagement.ContactGroupMemberInfoProviderExtensions.Add(this IInfoProvider<ContactGroupMemberInfo>, int, int, ContactGroupMemberTypeEnum, MemberAddedHowEnum) instead.")]
[ObsoleteSince(29, 0)]
public virtual void Add(int contactGroupId, int relatedObjectId, ContactGroupMemberTypeEnum memberType, MemberAddedHowEnum addedHow)

Parameters

contactGroupId int

Contact group ID.

relatedObjectId int

Related object ID.

memberType ContactGroupMemberTypeEnum

Member type.

addedHow MemberAddedHowEnum

Possible types of contact addition into contact group.

DeleteContactGroupMembers(string, int, bool, bool)

Deletes relationships between specified contact groups and related objects (contact, account) defined in where condition.

[Obsolete("Method is no longer used by the system and will be removed.")]
[ObsoleteSince(29, 7)]
public static void DeleteContactGroupMembers(string where, int contactGroupID, bool deletingAccount, bool removeAccount)

Parameters

where string

Where condition

contactGroupID int

Current groupID. Used only when deleting accounts and removing its contacts.

deletingAccount bool

Indicates if deleting accounts. If TRUE then also contacts will be removed as well.

removeAccount bool

If TRUE then account will be deleted, not only its contacts. Applicable only when deleting accounts.

DeleteContactGroupMembersInternal(string)

Deletes relationships between specified contact groups and related objects (contact, account) defined in where condition.

[Obsolete("Method is no longer used by the system and will be removed.")]
[ObsoleteSince(29, 7)]
protected virtual void DeleteContactGroupMembersInternal(string where)

Parameters

where string

Where condition

Get(int, int, ContactGroupMemberTypeEnum)

Gets an instance of the ContactGroupMemberInfo binding structure.

[Obsolete("Use Get() and parametrized ObjectQuery to get the ContactGroupMemberInfo with specified ContactGroupMemberContactGroupID, ContactGroupMemberRelatedID and ContactGroupMemberType.")]
[ObsoleteSince(29, 0)]
public virtual ContactGroupMemberInfo Get(int contactGroupId, int relatedObjectId, ContactGroupMemberTypeEnum memberType)

Parameters

contactGroupId int

Contact group ID.

relatedObjectId int

Related object ID.

memberType ContactGroupMemberTypeEnum

Member type.

Returns

ContactGroupMemberInfo

Returns an instance of ContactGroupMemberInfo corresponding to given identifiers or null.

GetAsync(int, int, ContactGroupMemberTypeEnum, CancellationToken?)

Asynchronously gets an instance of the ContactGroupMemberInfo binding structure.

[Obsolete("Use Get() and parametrized ObjectQuery to get the ContactGroupMemberInfo with specified ContactGroupMemberContactGroupID, ContactGroupMemberRelatedID and ContactGroupMemberType.")]
[ObsoleteSince(29, 0)]
public virtual Task<ContactGroupMemberInfo> GetAsync(int contactGroupId, int relatedObjectId, ContactGroupMemberTypeEnum memberType, CancellationToken? cancellationToken = null)

Parameters

contactGroupId int

Contact group ID.

relatedObjectId int

Related object ID.

memberType ContactGroupMemberTypeEnum

Member type.

cancellationToken CancellationToken?

The cancellation instruction.

Returns

Task<ContactGroupMemberInfo>

Returns a task returning either an instance of ContactGroupMemberInfo corresponding to given identifiers or null.

GetContactGroupMembers(int)

Gets contacts in a given contact group.

[Obsolete("Use CMS.ContactManagement.ContactGroupMemberInfoProviderExtensions.GetContactsByContactGroup(this IInfoProvider<ContactGroupMemberInfo>, int) instead.")]
[ObsoleteSince(30, 0)]
public static ObjectQuery<ContactGroupMemberInfo> GetContactGroupMembers(int contactGroupId)

Parameters

contactGroupId int

Contact group ID

Returns

ObjectQuery<ContactGroupMemberInfo>

GetNumberOfContactsInGroup(int)

Returns number of contacts in specified contact group.

[Obsolete("Use CMS.ContactManagement.ContactGroupMemberInfoProviderExtensions.GetContactsInContactGroupCount(this IInfoProvider<ContactGroupMemberInfo>, int) instead.")]
[ObsoleteSince(30, 0)]
public static int GetNumberOfContactsInGroup(int contactGroupId)

Parameters

contactGroupId int

Contact group ID

Returns

int

GetNumberOfContactsInGroupInternal(int)

Returns number of contacts in specified contact group.

[Obsolete("Use CMS.ContactManagement.ContactGroupMemberInfoProviderExtensions.GetContactsInContactGroupCount(this IInfoProvider<ContactGroupMemberInfo>, int) instead.")]
[ObsoleteSince(30, 0)]
protected virtual int GetNumberOfContactsInGroupInternal(int contactGroupId)

Parameters

contactGroupId int

Contact group ID

Returns

int

Remove(int, int, ContactGroupMemberTypeEnum)

Deletes ContactGroupMemberInfo binding.

[Obsolete("Get the ContactGroupMemberInfo with specified ContactGroupID, RelatedID and Type using Get() and delete the binding using Delete(ContactGroupMemberInfo).")]
[ObsoleteSince(29, 0)]
public virtual void Remove(int contactGroupId, int relatedObjectId, ContactGroupMemberTypeEnum memberType)

Parameters

contactGroupId int

Contact group ID.

relatedObjectId int

Related object ID.

memberType ContactGroupMemberTypeEnum

Member type.