Class EfCoreShortenedUrlRepository
Inheritance
EfCoreShortenedUrlRepository
Implements
Inherited Members
EfCoreRepository<ICmsKitProDbContext, ShortenedUrl, Guid>.DeleteAsync(Guid, bool, CancellationToken)
Namespace: Volo.CmsKit.UrlShorting
Assembly: Volo.CmsKit.Pro.EntityFrameworkCore.dll
Syntax
public class EfCoreShortenedUrlRepository : EfCoreRepository<ICmsKitProDbContext, ShortenedUrl, Guid>, IServiceProviderAccessor, IUnitOfWorkEnabled, IUnitOfWorkManagerAccessor, IEfCoreRepository<ShortenedUrl, Guid>, IEfCoreRepository<ShortenedUrl>, IRepository<ShortenedUrl, Guid>, IRepository<ShortenedUrl>, IReadOnlyRepository<ShortenedUrl, Guid>, IReadOnlyRepository<ShortenedUrl>, IBasicRepository<ShortenedUrl, Guid>, ISupportsExplicitLoading<ShortenedUrl>, IShortenedUrlRepository, IBasicRepository<ShortenedUrl, Guid>, IBasicRepository<ShortenedUrl>, IReadOnlyBasicRepository<ShortenedUrl, Guid>, IReadOnlyBasicRepository<ShortenedUrl>, IRepository
Constructors
EfCoreShortenedUrlRepository(IDbContextProvider<ICmsKitProDbContext>)
Declaration
public EfCoreShortenedUrlRepository(IDbContextProvider<ICmsKitProDbContext> dbContextProvider)
Parameters
Type | Name | Description |
---|---|---|
IDbContextProvider<ICmsKitProDbContext> | dbContextProvider |
Methods
FindBySourceUrlAsync(string, CancellationToken)
Declaration
public virtual Task<ShortenedUrl> FindBySourceUrlAsync(string sourceUrl, CancellationToken cancellationToken = default)
Parameters
Type | Name | Description |
---|---|---|
string | sourceUrl | |
CancellationToken | cancellationToken |
Returns
Type | Description |
---|---|
Task<ShortenedUrl> |
GetAllRegexAsync(CancellationToken)
Declaration
public Task<List<ShortenedUrl>> GetAllRegexAsync(CancellationToken cancellationToken = default)
Parameters
Type | Name | Description |
---|---|---|
CancellationToken | cancellationToken |
Returns
Type | Description |
---|---|
Task<List<ShortenedUrl>> |
GetCountAsync(string, CancellationToken)
Declaration
public virtual Task<long> GetCountAsync(string filter = null, CancellationToken cancellationToken = default)
Parameters
Type | Name | Description |
---|---|---|
string | filter | |
CancellationToken | cancellationToken |
Returns
Type | Description |
---|---|
Task<long> |
GetListAsync(string, string, int, int, CancellationToken)
Declaration
public virtual Task<List<ShortenedUrl>> GetListAsync(string filter = null, string sorting = null, int skipCount = 0, int maxResultCount = 2147483647, CancellationToken cancellationToken = default)
Parameters
Type | Name | Description |
---|---|---|
string | filter | |
string | sorting | |
int | skipCount | |
int | maxResultCount | |
CancellationToken | cancellationToken |
Returns
Type | Description |
---|---|
Task<List<ShortenedUrl>> |