UrlResolverType() public method

public UrlResolverType ( ) : Type
return System.Type
Example #1
0
        public DocProject(DocSettings settings)
        {
            Port        = PortFinder.FindPort(5050);
            BaseAddress = "http://localhost:" + Port;

            _settings = settings;

            ReadTopics();


            _container = new Container(_ =>
            {
                _.For <ISampleCache>().Use(this);
                _.For <DocProject>().Use(this);
                _.AddRegistry <SampleRegistry>();
                _.AddRegistry <TransformationRegistry>();

                _.For(typeof(IUrlResolver)).Use(settings.UrlResolverType());

                _.ForSingletonOf <ICommandUsageCache>().Use <CommandUsageCache>();

                _.For <DocSettings>().Use(settings);
                _.For <Topic>().Use(Topic);
            });
        }
Example #2
0
        public DocProject(DocSettings settings)
        {
            var port = PortFinder.FindPort(5000);
            BaseAddress = "http://localhost:" + port;

            _settings = settings;
            ReadTopics();


            _container = new Container(_ =>
            {
                _.For<ISampleCache>().Use(this);
                _.For<DocProject>().Use(this);
                _.AddRegistry<SampleRegistry>();
                _.AddRegistry<TransformationRegistry>();

                _.For(typeof(IUrlResolver)).Use(settings.UrlResolverType());

                _.ForSingletonOf<ICommandUsageCache>().Use<CommandUsageCache>();

                _.For<DocSettings>().Use(settings);
                _.For<Topic>().Use(Topic);
            });
        }