ModelSourceDependencies.With 方法
定義
重要
部分資訊涉及發行前產品,在發行之前可能會有大幅修改。 Microsoft 對此處提供的資訊,不做任何明確或隱含的瑕疵擔保。
多載
With(IModelCacheKeyFactory) |
複製此相依性參數物件,並取代一個服務。 |
With(IModelCustomizer) |
複製此相依性參數物件,並取代一個服務。 |
With(ICoreConventionSetBuilder) |
複製此相依性參數物件,並取代一個服務。 |
With(IMemoryCache) |
複製此相依性參數物件,並取代一個服務。 |
With(IModelCacheKeyFactory)
複製此相依性參數物件,並取代一個服務。
public Microsoft.EntityFrameworkCore.Infrastructure.ModelSourceDependencies With (Microsoft.EntityFrameworkCore.Infrastructure.IModelCacheKeyFactory modelCacheKeyFactory);
member this.With : Microsoft.EntityFrameworkCore.Infrastructure.IModelCacheKeyFactory -> Microsoft.EntityFrameworkCore.Infrastructure.ModelSourceDependencies
Public Function With (modelCacheKeyFactory As IModelCacheKeyFactory) As ModelSourceDependencies
參數
- modelCacheKeyFactory
- IModelCacheKeyFactory
取代此類型的目前相依性。
傳回
已取代指定服務的新參數物件。
適用於
With(IModelCustomizer)
複製此相依性參數物件,並取代一個服務。
public Microsoft.EntityFrameworkCore.Infrastructure.ModelSourceDependencies With (Microsoft.EntityFrameworkCore.Infrastructure.IModelCustomizer modelCustomizer);
member this.With : Microsoft.EntityFrameworkCore.Infrastructure.IModelCustomizer -> Microsoft.EntityFrameworkCore.Infrastructure.ModelSourceDependencies
Public Function With (modelCustomizer As IModelCustomizer) As ModelSourceDependencies
參數
- modelCustomizer
- IModelCustomizer
取代此類型的目前相依性。
傳回
已取代指定服務的新參數物件。
適用於
With(ICoreConventionSetBuilder)
複製此相依性參數物件,並取代一個服務。
public Microsoft.EntityFrameworkCore.Infrastructure.ModelSourceDependencies With (Microsoft.EntityFrameworkCore.Metadata.Conventions.Internal.ICoreConventionSetBuilder coreConventionSetBuilder);
member this.With : Microsoft.EntityFrameworkCore.Metadata.Conventions.Internal.ICoreConventionSetBuilder -> Microsoft.EntityFrameworkCore.Infrastructure.ModelSourceDependencies
Public Function With (coreConventionSetBuilder As ICoreConventionSetBuilder) As ModelSourceDependencies
參數
- coreConventionSetBuilder
- Microsoft.EntityFrameworkCore.Metadata.Conventions.Internal.ICoreConventionSetBuilder
取代此類型的目前相依性。
傳回
已取代指定服務的新參數物件。
適用於
With(IMemoryCache)
複製此相依性參數物件,並取代一個服務。
public Microsoft.EntityFrameworkCore.Infrastructure.ModelSourceDependencies With (Microsoft.Extensions.Caching.Memory.IMemoryCache memoryCache);
member this.With : Microsoft.Extensions.Caching.Memory.IMemoryCache -> Microsoft.EntityFrameworkCore.Infrastructure.ModelSourceDependencies
Public Function With (memoryCache As IMemoryCache) As ModelSourceDependencies
參數
- memoryCache
- IMemoryCache
取代此類型的目前相依性。
傳回
已取代指定服務的新參數物件。