Couchbase .NET SDK | 3.7.2
Search Results for

    Show / Hide Table of Contents

    Class Role

    Inheritance
    object
    Role
    Inherited Members
    object.Equals(object)
    object.Equals(object, object)
    object.GetHashCode()
    object.GetType()
    object.MemberwiseClone()
    object.ReferenceEquals(object, object)
    Namespace: Couchbase.Management.Users
    Assembly: Couchbase.NetClient.dll
    Syntax
    public class Role

    Constructors

    | Edit this page View Source

    Role(string)

    Creates a new system-wide role (not specific to a bucket)

    Declaration
    public Role(string roleName)
    Parameters
    Type Name Description
    string roleName

    symbolic name of the role

    | Edit this page View Source

    Role(string, string?)

    Creates a new role. If the bucket parameter is null, a system-wide role is created. Otherwise, the role applies to all scopes and collections within the bucket.

    Declaration
    public Role(string roleName, string? bucketName)
    Parameters
    Type Name Description
    string roleName

    symbolic name of the role.

    string bucketName

    bucket name for the role.

    | Edit this page View Source

    Role(string, string?, string?)

    Creates a new role. If the bucket parameter is null, a system-wide role is created. Otherwise, the role applies to the scope and collections in the scope and bucket.

    Declaration
    public Role(string roleName, string? bucketName, string? scopeName)
    Parameters
    Type Name Description
    string roleName
    string bucketName
    string scopeName
    | Edit this page View Source

    Role(string, string?, string?, string?)

    Creates a new role. If the bucket parameter is null, a system-wide role is created. Otherwise, the role applies to the scope and collection provided in the bucket.

    Declaration
    public Role(string roleName, string? bucketName, string? scopeName, string? collectionName)
    Parameters
    Type Name Description
    string roleName
    string bucketName
    string scopeName
    string collectionName

    Properties

    | Edit this page View Source

    Bucket

    Gives the Role access to a specific Bucket.

    Declaration
    public string? Bucket { get; }
    Property Value
    Type Description
    string
    | Edit this page View Source

    Collection

    Gives the Role access to a specific Collection. Bucket and Scope must be non-null nor a wildcard (*) for Scope to be set.Uncommitted: this feature may change in the future.

    Declaration
    public string? Collection { get; }
    Property Value
    Type Description
    string
    | Edit this page View Source

    Name

    The name of the Role.

    Declaration
    public string Name { get; }
    Property Value
    Type Description
    string
    | Edit this page View Source

    Scope

    Gives the Role access to a specific Scope. Bucket must be non-null nor a wildcard (*) for Scope to be set.

    Declaration
    public string? Scope { get; }
    Property Value
    Type Description
    string
    Remarks

    Uncommitted: this feature may change in the future.

    Methods

    | Edit this page View Source

    ToString()

    Declaration
    public override string ToString()
    Returns
    Type Description
    string
    Overrides
    object.ToString()
    • Edit this page
    • View Source
    In this article
    Back to top © 2025 Couchbase, Inc.