Search Results for

    Show / Hide Table of Contents
    View Source

    Interface IMemberGroupRepository

    Represents a repository for IMemberGroup entities.

    Namespace: Umbraco.Cms.Core.Persistence.Repositories
    Assembly: Umbraco.Core.dll
    Syntax
    public interface IMemberGroupRepository : IReadWriteQueryRepository<int, IMemberGroup>, IReadRepository<int, IMemberGroup>, IWriteRepository<IMemberGroup>, IQueryRepository<IMemberGroup>, IRepository

    Methods

    View Source

    AssignRoles(int[], string[])

    Assigns roles to the specified members.

    Declaration
    void AssignRoles(int[] memberIds, string[] roleNames)
    Parameters
    Type Name Description
    int[] memberIds

    The identifiers of the members.

    string[] roleNames

    The names of the roles to assign.

    View Source

    CreateIfNotExists(string)

    Creates the new member group if it doesn't already exist

    Declaration
    IMemberGroup? CreateIfNotExists(string roleName)
    Parameters
    Type Name Description
    string roleName
    Returns
    Type Description
    IMemberGroup
    View Source

    DissociateRoles(int[], string[])

    Dissociates roles from the specified members.

    Declaration
    void DissociateRoles(int[] memberIds, string[] roleNames)
    Parameters
    Type Name Description
    int[] memberIds

    The identifiers of the members.

    string[] roleNames

    The names of the roles to dissociate.

    View Source

    Get(Guid)

    Gets a member group by it's uniqueId

    Declaration
    IMemberGroup? Get(Guid uniqueId)
    Parameters
    Type Name Description
    Guid uniqueId
    Returns
    Type Description
    IMemberGroup
    View Source

    GetByName(string?)

    Gets a member group by it's name

    Declaration
    IMemberGroup? GetByName(string? name)
    Parameters
    Type Name Description
    string name
    Returns
    Type Description
    IMemberGroup
    View Source

    GetMemberGroupsForMember(int)

    Returns the member groups for a given member

    Declaration
    IEnumerable<IMemberGroup> GetMemberGroupsForMember(int memberId)
    Parameters
    Type Name Description
    int memberId
    Returns
    Type Description
    IEnumerable<IMemberGroup>
    View Source

    GetMemberGroupsForMember(string?)

    Returns the member groups for a given member

    Declaration
    IEnumerable<IMemberGroup> GetMemberGroupsForMember(string? username)
    Parameters
    Type Name Description
    string username
    Returns
    Type Description
    IEnumerable<IMemberGroup>
    View Source

    ReplaceRoles(int[], string[])

    Replaces the roles for the specified members.

    Declaration
    void ReplaceRoles(int[] memberIds, string[] roleNames)
    Parameters
    Type Name Description
    int[] memberIds

    The identifiers of the members.

    string[] roleNames

    The names of the roles to assign.

    • View Source
    In this article
    Back to top Copyright © 2016-present Umbraco
    Generated by DocFX