public static IRegistryMediator Create(IEnumerable<ISemanticRegistryObserver> semanticRegistryObservers,
            ShortestPathGraphBuilder graphBuilder)
        {
            // ReSharper disable once JoinDeclarationAndInitializer
            IRegistryMediator mediator;

            semanticRegistryObservers =
                semanticRegistryObservers.Concat(new ISemanticRegistryObserver[]
                {
                    new ShortestPathGraphBuilderAdapterRegistryObserver(graphBuilder)
                });

            mediator = new ObserverRegistryMediator(semanticRegistryObservers);
            mediator = new SimplifyEnumerableOutputRegistryMediator(mediator);
            mediator = new SafetyRegistryMediator(mediator);

            return mediator;
        }
Пример #2
0
        public static IRegistryMediator Create(IEnumerable <ISemanticRegistryObserver> semanticRegistryObservers,
                                               ShortestPathGraphBuilder graphBuilder)
        {
// ReSharper disable once JoinDeclarationAndInitializer
            IRegistryMediator mediator;

            semanticRegistryObservers =
                semanticRegistryObservers.Concat(new ISemanticRegistryObserver[]
            {
                new ShortestPathGraphBuilderAdapterRegistryObserver(graphBuilder)
            });

            mediator = new ObserverRegistryMediator(semanticRegistryObservers);
            mediator = new SimplifyEnumerableOutputRegistryMediator(mediator);
            mediator = new SafetyRegistryMediator(mediator);

            return(mediator);
        }