public EntityValueTypeMergingStrategiesManager(IEntityMetamodel metamodel, IValueTypeMergingStrategiesFactory strategiesesFactory) { _metamodel = metamodel; _strategiesesFactory = strategiesesFactory; _strategieTypes = new ConcurrentDictionary <Type, ValueTypeMergingStrategy>(); }
public void InitializeTest() { var metamodelProvider = new ImperativeMetamodelProvider(); var serializerMock = new Mock <IStorageValueSerializer>(); metamodelProvider.UseSerializer <SerializableTestType>(serializerMock.Object); _metamodel = new EntityMetamodelImpl(metamodelProvider); }
/// <summary> /// Configures metamodel with the given <paramref name="provider"/> /// </summary> /// <param name="provider">Metamodel provider</param> public static void Configure(IMetamodelProvider provider) { if (provider == null) { throw new ArgumentNullException(nameof(provider)); } if (_isConfigured) { throw new InvalidOperationException("Metamodel has already been configured"); } Instance = new EntityMetamodelImpl(provider); _isConfigured = true; }
static EntityMetamodel() { Instance = new EntityMetamodelImpl(new AnnotationsBasedMetamodelProvider()); }
public static void Configure(IEntityMetamodel metamodel, IValueTypeMergingStrategiesFactory strategiesFactory) { Instance = new EntityValueTypeMergingStrategiesManager(metamodel, strategiesFactory); }
public StorageValueConvertersFactory(IEntityMetamodel metamodel) { _metamodel = metamodel; }