Welcome to mirror list, hosted at ThFree Co, Russian Federation.

TestMatcherFactory.cs « TestObjects « UnitTests « test « Routing « Http « src - github.com/dotnet/aspnetcore.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
blob: 9894c590f08be340079671804ca3170ba1d77ff1 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
// Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.

using Microsoft.AspNetCore.Routing.Matching;

namespace Microsoft.AspNetCore.Routing.TestObjects
{
    internal class TestMatcherFactory : MatcherFactory
    {
        private readonly bool _isHandled;

        public TestMatcherFactory(bool isHandled)
        {
            _isHandled = isHandled;
        }

        public override Matcher CreateMatcher(EndpointDataSource dataSource)
        {
            return new TestMatcher(_isHandled);
        }
    }
}