public static IConfigure UsingRavenDB(this IEventsConfiguration eventsConfiguration, Action<RegularEventStoreConfiguration> configureCallback) { eventsConfiguration.EventStoreType = typeof(EventStore); eventsConfiguration.EventSubscriptionsType = typeof(EventSubscriptions); var configuration = new RegularEventStoreConfiguration(); configureCallback(configuration); Configure.Instance.Container.Bind<IEventStoreConfiguration>(configuration); var eventSubscriptionsConfiguration = new RegularEventSubscriptionsConfiguration(); configuration.CopyTo(eventSubscriptionsConfiguration); Configure.Instance.Container.Bind<IEventSubscriptionsConfiguration>(eventSubscriptionsConfiguration); return Configure.Instance; }
public static IConfigure UsingRavenDB(this IEventsConfiguration eventsConfiguration, Action <RegularEventStoreConfiguration> configureCallback) { eventsConfiguration.EventStoreType = typeof(EventStore); eventsConfiguration.EventSubscriptionsType = typeof(EventSubscriptions); var configuration = new RegularEventStoreConfiguration(); configureCallback(configuration); Configure.Instance.Container.Bind <IEventStoreConfiguration>(configuration); var eventSubscriptionsConfiguration = new RegularEventSubscriptionsConfiguration(); configuration.CopyTo(eventSubscriptionsConfiguration); Configure.Instance.Container.Bind <IEventSubscriptionsConfiguration>(eventSubscriptionsConfiguration); return(Configure.Instance); }