DataWeb
Search Results for

    Show / Hide Table of Contents

    Class Area

    Represents an area in the application.

    Inheritance
    object
    Area
    Inherited Members
    object.Equals(object)
    object.Equals(object, object)
    object.GetHashCode()
    object.GetType()
    object.ReferenceEquals(object, object)
    object.ToString()
    Namespace: DataWeb.Structure
    Assembly: DataWeb.Core.dll
    Syntax
    public sealed class Area
    Remarks

    Initializes a new instance of the Area class with the specified dependencies.

    Constructors

    Area(IReflectionService, IAppErrorService, IAuthorizationService, IAreaStore, IElementStore, ISectionStore, IViewStore)

    Represents an area in the application.

    Declaration
    public Area(IReflectionService reflectionService, IAppErrorService appErrorService, IAuthorizationService authorizationService, IAreaStore areaStore, IElementStore elementStore, ISectionStore sectionStore, IViewStore viewStore)
    Parameters
    Type Name Description
    IReflectionService reflectionService

    The IReflectionService instance used for reflection operations.

    IAppErrorService appErrorService

    The IAppErrorService instance used for error handling.

    IAuthorizationService authorizationService

    The authorization service used to check permissions.

    IAreaStore areaStore

    The store used to access area data.

    IElementStore elementStore

    The store used to access element data.

    ISectionStore sectionStore

    The store used to access section data.

    IViewStore viewStore

    The store used to access view data.

    Remarks

    Initializes a new instance of the Area class with the specified dependencies.

    Properties

    Color

    The color associated with the area.

    Declaration
    public string Color { get; set; }
    Property Value
    Type Description
    string

    IdMaster

    Gets or sets the unique identifier.

    Declaration
    public string IdMaster { get; set; }
    Property Value
    Type Description
    string

    IsCompleted

    Whether the area is completed.

    Declaration
    public bool IsCompleted { get; set; }
    Property Value
    Type Description
    bool

    Name

    The name of the area.

    Declaration
    public string Name { get; set; }
    Property Value
    Type Description
    string

    Navigation

    The navigation associated with the area.

    Declaration
    public Navigation Navigation { get; set; }
    Property Value
    Type Description
    Navigation

    Status

    The status of the area.

    Declaration
    public ItemStatus Status { get; set; }
    Property Value
    Type Description
    ItemStatus

    Title

    The title of the area.

    Declaration
    public string Title { get; set; }
    Property Value
    Type Description
    string

    Type

    The type of the area.

    Declaration
    public string Type { get; set; }
    Property Value
    Type Description
    string

    VisibleRoles

    The roles that can view the area.

    Declaration
    public List<string> VisibleRoles { get; set; }
    Property Value
    Type Description
    List<string>

    Methods

    GetAllSectionsAsync(CancellationToken)

    Asynchronously retrieves all the sections in the area.

    Declaration
    public Task<IEnumerable<Section>> GetAllSectionsAsync(CancellationToken cancellationToken = default)
    Parameters
    Type Name Description
    CancellationToken cancellationToken
    Returns
    Type Description
    Task<IEnumerable<Section>>

    An enumerable of sections in the area.

    GetUserSectionsAsync(IUser, CancellationToken)

    Asynchronously retrieves the sections in the area that are visible to the specified user.

    Declaration
    public Task<IEnumerable<Section>> GetUserSectionsAsync(IUser user, CancellationToken cancellationToken = default)
    Parameters
    Type Name Description
    IUser user

    The IUser for which to retrieve the visible sections.

    CancellationToken cancellationToken
    Returns
    Type Description
    Task<IEnumerable<Section>>

    An enumerable of the visible sections.

    Init(AreaData)

    Initializes the area with the specified data.

    Declaration
    public void Init(AreaData areaData)
    Parameters
    Type Name Description
    AreaData areaData

    The AreaData used to initialize the area.

    InitAsync(string, CancellationToken)

    Initializes the area asynchronously with the specified name.

    Declaration
    public Task InitAsync(string name, CancellationToken cancellationToken = default)
    Parameters
    Type Name Description
    string name

    The name of the area.

    CancellationToken cancellationToken
    Returns
    Type Description
    Task

    IsVisible(PermissionSet)

    Determines whether the area is visible to a user with the specified permission set.

    Declaration
    public bool IsVisible(PermissionSet permissionSet)
    Parameters
    Type Name Description
    PermissionSet permissionSet

    The PermissionSet of the user.

    Returns
    Type Description
    bool

    True if the area is visible; false otherwise.

    Extension Methods

    StructureMapperExtension.ToAreaInfo(Area)
    In this article
    Back to top Generated by DocFX