onebeyond/onebeyond-studio-core

View on GitHub
src/OneBeyond.Studio.DataAccess.EFCore/Projections/ProjectionContext.cs

Summary

Maintainability
A
40 mins
Test Coverage
using AutoMapper;
using EnsureThat;
using Microsoft.EntityFrameworkCore;

namespace OneBeyond.Studio.DataAccess.EFCore.Projections;

public sealed record ProjectionContext
{
    internal ProjectionContext(
        DbContext dbContext,
        IConfigurationProvider mapperConfigurationProvider)
    {
        EnsureArg.IsNotNull(dbContext, nameof(dbContext));
        EnsureArg.IsNotNull(mapperConfigurationProvider, nameof(mapperConfigurationProvider));

        DbContext = dbContext;
        MapperConfigurationProvider = mapperConfigurationProvider;
    }

    public DbContext DbContext { get; }
    public IConfigurationProvider MapperConfigurationProvider { get; }
}