Table of Contents

Class GastroSkyDatabaseContext

Namespace
GastroSky.Models.DatabaseContext
Assembly
GastroSky.Models.dll
public class GastroSkyDatabaseContext : DbContext, IInfrastructure<IServiceProvider>, IDbContextDependencies, IDbSetCache, IDbContextPoolable, IResettableService, IDisposable, IAsyncDisposable
Inheritance
GastroSkyDatabaseContext
Implements
Inherited Members

Constructors

GastroSkyDatabaseContext(DbContextOptions<GastroSkyDatabaseContext>, IConfiguration)

public GastroSkyDatabaseContext(DbContextOptions<GastroSkyDatabaseContext> options, IConfiguration configuration)

Parameters

options DbContextOptions<GastroSkyDatabaseContext>
configuration IConfiguration

Properties

BlacklistedEmailDomains

public DbSet<BlacklistedEmailDomain> BlacklistedEmailDomains { get; }

Property Value

DbSet<BlacklistedEmailDomain>

Boosters

public DbSet<Booster> Boosters { get; }

Property Value

DbSet<Booster>

Companies

public DbSet<Company> Companies { get; }

Property Value

DbSet<Company>

CompanySubscriptions

public DbSet<CompanySubscription> CompanySubscriptions { get; }

Property Value

DbSet<CompanySubscription>

Configuration

public DbSet<ConfigurationEntry> Configuration { get; }

Property Value

DbSet<ConfigurationEntry>

ContactCalls

public DbSet<ContactCall> ContactCalls { get; }

Property Value

DbSet<ContactCall>

Contacts

public DbSet<Contact> Contacts { get; }

Property Value

DbSet<Contact>

Countries

public DbSet<Country> Countries { get; }

Property Value

DbSet<Country>

InterestedUsers

public DbSet<InterestedUser> InterestedUsers { get; }

Property Value

DbSet<InterestedUser>

InvalidatedAuthTokens

public DbSet<InvalidatedAuthToken> InvalidatedAuthTokens { get; }

Property Value

DbSet<InvalidatedAuthToken>

KeyValuePairCache

public DbSet<KeyValuePairCacheEntry> KeyValuePairCache { get; }

Property Value

DbSet<KeyValuePairCacheEntry>

Locations

public DbSet<Location> Locations { get; }

Property Value

DbSet<Location>

MailTemplates

public DbSet<MailTemplate> MailTemplates { get; }

Property Value

DbSet<MailTemplate>

News

public DbSet<News> News { get; }

Property Value

DbSet<News>

OrderedProducts

public DbSet<OrderedProduct> OrderedProducts { get; }

Property Value

DbSet<OrderedProduct>

Orders

public DbSet<Order> Orders { get; }

Property Value

DbSet<Order>

PepperBrands

public DbSet<PepperBrand> PepperBrands { get; }

Property Value

DbSet<PepperBrand>

PostBoosters

public DbSet<PostBooster> PostBoosters { get; }

Property Value

DbSet<PostBooster>

PostImages

public DbSet<PostImage> PostImages { get; }

Property Value

DbSet<PostImage>

PostPremiumUpgrades

public DbSet<PostPremiumUpgrade> PostPremiumUpgrades { get; }

Property Value

DbSet<PostPremiumUpgrade>

Posts

public DbSet<Post> Posts { get; }

Property Value

DbSet<Post>

PremiumUpgrades

public DbSet<PremiumUpgrade> PremiumUpgrades { get; }

Property Value

DbSet<PremiumUpgrade>

Products

public DbSet<Product> Products { get; }

Property Value

DbSet<Product>

Regions

public DbSet<Region> Regions { get; }

Property Value

DbSet<Region>

SentEmails

public DbSet<SentEmail> SentEmails { get; }

Property Value

DbSet<SentEmail>

Slugs

public DbSet<Slug> Slugs { get; }

Property Value

DbSet<Slug>

SmtpCredentials

public DbSet<SmtpCredentials> SmtpCredentials { get; }

Property Value

DbSet<SmtpCredentials>

Subscriptions

public DbSet<Subscription> Subscriptions { get; }

Property Value

DbSet<Subscription>

TranslationRequests

public DbSet<TranslationRequest> TranslationRequests { get; }

Property Value

DbSet<TranslationRequest>

Translations

public DbSet<Translation> Translations { get; }

Property Value

DbSet<Translation>

Translators

public DbSet<Translator> Translators { get; }

Property Value

DbSet<Translator>

UserAgents

public DbSet<UserAgent> UserAgents { get; }

Property Value

DbSet<UserAgent>

UserClaims

public DbSet<UserClaim> UserClaims { get; }

Property Value

DbSet<UserClaim>

UserCompanies

public DbSet<UserCompany> UserCompanies { get; }

Property Value

DbSet<UserCompany>

UserFavorites

public DbSet<UserFavorite> UserFavorites { get; }

Property Value

DbSet<UserFavorite>

UserLoginAttempts

public DbSet<UserLoginAttempt> UserLoginAttempts { get; }

Property Value

DbSet<UserLoginAttempt>

UserPostInteractions

public DbSet<UserPostInteraction> UserPostInteractions { get; }

Property Value

DbSet<UserPostInteraction>

UserSubscriptions

public DbSet<UserSubscription> UserSubscriptions { get; }

Property Value

DbSet<UserSubscription>

Users

public DbSet<User> Users { get; }

Property Value

DbSet<User>

Methods

OnModelCreating(ModelBuilder)

Override this method to further configure the model that was discovered by convention from the entity types exposed in DbSet<TEntity> properties on your derived context. The resulting model may be cached and re-used for subsequent instances of your derived context.

protected override void OnModelCreating(ModelBuilder modelBuilder)

Parameters

modelBuilder ModelBuilder

The builder being used to construct the model for this context. Databases (and other extensions) typically define extension methods on this object that allow you to configure aspects of the model that are specific to a given database.

Remarks

If a model is explicitly set on the options for this context (via UseModel(IModel)) then this method will not be run. However, it will still run when creating a compiled model.

See Modeling entity types and relationships for more information and examples.