2022-07-25 18:02:39 +05:00
|
|
|
|
using AsbCloudDb.Model.WITS;
|
2022-05-06 10:58:52 +05:00
|
|
|
|
using Microsoft.EntityFrameworkCore;
|
2021-09-29 09:59:10 +05:00
|
|
|
|
using Microsoft.EntityFrameworkCore.Infrastructure;
|
2021-05-17 12:53:30 +05:00
|
|
|
|
using System;
|
2021-04-02 17:28:07 +05:00
|
|
|
|
using System.Threading;
|
|
|
|
|
using System.Threading.Tasks;
|
|
|
|
|
|
|
|
|
|
namespace AsbCloudDb.Model
|
|
|
|
|
{
|
2022-04-11 18:00:34 +05:00
|
|
|
|
public interface IAsbCloudDbContext : IDisposable
|
2021-04-02 17:28:07 +05:00
|
|
|
|
{
|
2022-05-06 10:58:52 +05:00
|
|
|
|
DbSet<Cluster> Clusters { get; }
|
|
|
|
|
DbSet<Company> Companies { get; }
|
2022-07-25 18:02:39 +05:00
|
|
|
|
DbSet<DailyReport.DailyReport> DailyReports { get; }
|
2022-05-06 10:58:52 +05:00
|
|
|
|
DbSet<Deposit> Deposits { get; }
|
|
|
|
|
DbSet<DetectedOperation> DetectedOperations { get; }
|
|
|
|
|
DbSet<DrillFlowChart> DrillFlowChart { get; }
|
|
|
|
|
DbSet<DrillingProgramPart> DrillingProgramParts { get; }
|
|
|
|
|
DbSet<DrillParams> DrillParams { get; }
|
|
|
|
|
DbSet<FileCategory> FileCategories { get; }
|
|
|
|
|
DbSet<FileInfo> Files { get; }
|
|
|
|
|
DbSet<FileMark> FileMarks { get; }
|
|
|
|
|
DbSet<Measure> Measures { get; }
|
|
|
|
|
DbSet<MeasureCategory> MeasureCategories { get; }
|
|
|
|
|
DbSet<Permission> Permissions { get; }
|
|
|
|
|
DbSet<RelationCompanyWell> RelationCompaniesWells { get; }
|
|
|
|
|
DbSet<RelationUserDrillingProgramPart> RelationDrillingProgramPartUsers { get; }
|
|
|
|
|
DbSet<RelationUserRolePermission> RelationUserRolePermissions { get; }
|
|
|
|
|
DbSet<RelationUserUserRole> RelationUserUserRoles { get; }
|
|
|
|
|
DbSet<ReportProperty> ReportProperties { get; }
|
|
|
|
|
DbSet<Telemetry> Telemetries { get; }
|
|
|
|
|
DbSet<TelemetryDataSaub> TelemetryDataSaub { get; }
|
|
|
|
|
DbSet<TelemetryDataSaubStat> TelemetryDataSaubStats { get; }
|
|
|
|
|
DbSet<TelemetryDataSpin> TelemetryDataSpin { get; }
|
|
|
|
|
DbSet<TelemetryEvent> TelemetryEvents { get; }
|
|
|
|
|
DbSet<TelemetryMessage> TelemetryMessages { get; }
|
|
|
|
|
DbSet<TelemetryUser> TelemetryUsers { get; }
|
|
|
|
|
DbSet<User> Users { get; }
|
|
|
|
|
DbSet<UserRole> UserRoles { get; }
|
|
|
|
|
DbSet<Well> Wells { get; }
|
|
|
|
|
DbSet<WellComposite> WellComposites { get; }
|
|
|
|
|
DbSet<WellOperation> WellOperations { get; }
|
|
|
|
|
DbSet<WellOperationCategory> WellOperationCategories { get; }
|
|
|
|
|
DbSet<WellSectionType> WellSectionTypes { get; }
|
|
|
|
|
DbSet<WellType> WellTypes { get; }
|
2022-05-22 21:18:43 +05:00
|
|
|
|
DbSet<Driller> Drillers { get; }
|
2022-05-26 13:28:16 +05:00
|
|
|
|
DbSet<Schedule> Schedule { get; }
|
2022-06-07 16:24:05 +05:00
|
|
|
|
DbSet<OperationValue> OperationValues { get; }
|
2022-09-05 09:13:45 +05:00
|
|
|
|
DbSet<WellFinalDocuments> WellFinalDocuments { get; }
|
2022-05-06 10:58:52 +05:00
|
|
|
|
|
|
|
|
|
DbSet<Record1> Record1 { get; }
|
|
|
|
|
DbSet<Record7> Record7 { get; }
|
|
|
|
|
DbSet<Record8> Record8 { get; }
|
|
|
|
|
DbSet<Record50> Record50 { get; }
|
|
|
|
|
DbSet<Record60> Record60 { get; }
|
|
|
|
|
DbSet<Record61> Record61 { get; }
|
2021-09-29 09:59:10 +05:00
|
|
|
|
|
|
|
|
|
DatabaseFacade Database { get; }
|
2022-05-06 10:58:52 +05:00
|
|
|
|
|
2022-07-04 17:33:32 +05:00
|
|
|
|
Task<int> RefreshMaterializedViewAsync(string mwName, CancellationToken token);
|
|
|
|
|
Task<int> RefreshMaterializedViewAsync<TEntity>(CancellationToken token) where TEntity : class;
|
2021-04-02 17:28:07 +05:00
|
|
|
|
int SaveChanges();
|
|
|
|
|
int SaveChanges(bool acceptAllChangesOnSuccess);
|
|
|
|
|
Task<int> SaveChangesAsync(CancellationToken cancellationToken);
|
2021-08-09 14:39:56 +05:00
|
|
|
|
DbSet<TEntity> Set<TEntity>(string name) where TEntity : class;
|
|
|
|
|
DbSet<TEntity> Set<TEntity>() where TEntity : class;
|
|
|
|
|
|
2021-04-02 17:28:07 +05:00
|
|
|
|
}
|
|
|
|
|
}
|