Search Results for

    Show / Hide Table of Contents

    Class LocationRepository

    Inheritance
    object
    LocationRepository
    Implements
    ILocationRepository
    Inherited Members
    object.Equals(object)
    object.Equals(object, object)
    object.GetHashCode()
    object.GetType()
    object.MemberwiseClone()
    object.ReferenceEquals(object, object)
    object.ToString()
    Namespace: OEMS.Core.Infrastructure.Repositories
    Assembly: OEMS.Core.dll
    Syntax
    public class LocationRepository : ILocationRepository

    Constructors

    LocationRepository(IDbContextFactory<OEMSDBContext>)

    Declaration
    public LocationRepository(IDbContextFactory<OEMSDBContext> contextFactory)
    Parameters
    Type Name Description
    IDbContextFactory<OEMSDBContext> contextFactory

    Methods

    AddAsync(Location)

    Legt eine neue Location an.

    Declaration
    public Task AddAsync(Location location)
    Parameters
    Type Name Description
    Location location
    Returns
    Type Description
    Task

    CheckIfEventAtLocation(Guid, Guid)

    Checks if any event is already assigned to the location. OrgId to connect the two objects since both have them. Returns a tuple with a boolean indicating if any event is found and a list of event names, to enable checking which events are assigned.

    Declaration
    public Task<(bool, List<string>)> CheckIfEventAtLocation(Guid orgId, Guid locationId)
    Parameters
    Type Name Description
    Guid orgId
    Guid locationId
    Returns
    Type Description
    Task<(bool hasAny, List<string> eventNames)>

    CheckLocationNamesForDuplicates(string)

    Checks if location name already exists for the given organization.

    Declaration
    public Task<bool> CheckLocationNamesForDuplicates(string name)
    Parameters
    Type Name Description
    string name
    Returns
    Type Description
    Task<bool>

    DeleteAsync(Guid)

    Löscht eine Location per Id.

    Declaration
    public Task DeleteAsync(Guid id)
    Parameters
    Type Name Description
    Guid id
    Returns
    Type Description
    Task

    GetAllAsync()

    Liefert alle Locations zurück.

    Declaration
    public Task<IEnumerable<Location>> GetAllAsync()
    Returns
    Type Description
    Task<IEnumerable<Location>>

    GetAllByOrganizationAsync(Guid)

    Liefert alle Locations einer Organisation zurück.

    Declaration
    public Task<IEnumerable<Location>> GetAllByOrganizationAsync(Guid organizationId)
    Parameters
    Type Name Description
    Guid organizationId
    Returns
    Type Description
    Task<IEnumerable<Location>>

    GetByIdAsync(Guid)

    Liefert eine Location per Id oder null.

    Declaration
    public Task<Location> GetByIdAsync(Guid id)
    Parameters
    Type Name Description
    Guid id
    Returns
    Type Description
    Task<Location>

    UpdateAsync(Location)

    Aktualisiert eine bestehende Location.

    Declaration
    public Task UpdateAsync(Location location)
    Parameters
    Type Name Description
    Location location
    Returns
    Type Description
    Task

    Implements

    ILocationRepository
    In this article
    Back to top Generated by DocFX