-
Notifications
You must be signed in to change notification settings - Fork 112
/
IActionConstraint.xml
145 lines (139 loc) · 9.13 KB
/
IActionConstraint.xml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
<Type Name="IActionConstraint" FullName="Microsoft.AspNetCore.Mvc.ActionConstraints.IActionConstraint">
<TypeSignature Language="C++ CLI" Value="public interface class IActionConstraint : Microsoft::AspNetCore::Mvc::ActionConstraints::IActionConstraintMetadata" />
<TypeSignature Language="C#" Value="public interface IActionConstraint : Microsoft.AspNetCore.Mvc.ActionConstraints.IActionConstraintMetadata" />
<TypeSignature Language="ILAsm" Value=".class public interface auto ansi abstract IActionConstraint implements class Microsoft.AspNetCore.Mvc.ActionConstraints.IActionConstraintMetadata" FrameworkAlternate="aspnetcore-1.0;aspnetcore-1.1;aspnetcore-2.0;aspnetcore-2.1;aspnetcore-2.2;aspnetcore-3.0;aspnetcore-3.1;aspnetcore-5.0;aspnetcore-6.0;aspnetcore-7.0" />
<TypeSignature Language="DocId" Value="T:Microsoft.AspNetCore.Mvc.ActionConstraints.IActionConstraint" />
<TypeSignature Language="VB.NET" Value="Public Interface IActionConstraint
Implements IActionConstraintMetadata" />
<TypeSignature Language="F#" Value="type IActionConstraint = interface
 interface IActionConstraintMetadata" />
<TypeSignature Language="ILAsm" Value=".class public interface auto ansi abstract beforefieldinit IActionConstraint implements class Microsoft.AspNetCore.Mvc.ActionConstraints.IActionConstraintMetadata" FrameworkAlternate="aspnetcore-8.0;aspnetcore-9.0" />
<AssemblyInfo>
<AssemblyName>Microsoft.AspNetCore.Mvc.Abstractions</AssemblyName>
<AssemblyVersion>1.0.0.0</AssemblyVersion>
<AssemblyVersion>1.1.0.0</AssemblyVersion>
<AssemblyVersion>2.0.0.0</AssemblyVersion>
<AssemblyVersion>2.1.0.0</AssemblyVersion>
<AssemblyVersion>2.2.0.0</AssemblyVersion>
<AssemblyVersion>3.0.0.0</AssemblyVersion>
<AssemblyVersion>3.1.0.0</AssemblyVersion>
<AssemblyVersion>5.0.0.0</AssemblyVersion>
<AssemblyVersion>6.0.0.0</AssemblyVersion>
<AssemblyVersion>7.0.0.0</AssemblyVersion>
<AssemblyVersion>8.0.0.0</AssemblyVersion>
<AssemblyVersion>9.0.0.0</AssemblyVersion>
</AssemblyInfo>
<Interfaces>
<Interface>
<InterfaceName>Microsoft.AspNetCore.Mvc.ActionConstraints.IActionConstraintMetadata</InterfaceName>
</Interface>
</Interfaces>
<Docs>
<summary>
Supports conditional logic to determine whether or not an associated action is valid to be selected
for the given request.
</summary>
<remarks>
Action constraints have the secondary effect of making an action with a constraint applied a better
match than one without.
Consider two actions, 'A' and 'B' with the same action and controller name. Action 'A' only allows the
HTTP POST method (via a constraint) and action 'B' has no constraints.
If an incoming request is a POST, then 'A' is considered the best match because it both matches and
has a constraint. If an incoming request uses any other verb, 'A' will not be valid for selection
due to it's constraint, so 'B' is the best match.
Action constraints are also grouped according to their order value. Any constraints with the same
group value are considered to be part of the same application policy, and will be executed in the
same stage.
Stages run in ascending order based on the value of <see cref="P:Microsoft.AspNetCore.Mvc.ActionConstraints.IActionConstraint.Order" />. Given a set of actions which
are candidates for selection, the next stage to run is the lowest value of <see cref="P:Microsoft.AspNetCore.Mvc.ActionConstraints.IActionConstraint.Order" /> for any
constraint of any candidate which is greater than the order of the last stage.
Once the stage order is identified, each action has all of its constraints in that stage executed.
If any constraint does not match, then that action is not a candidate for selection. If any actions
with constraints in the current state are still candidates, then those are the 'best' actions and this
process will repeat with the next stage on the set of 'best' actions. If after processing the
subsequent stages of the 'best' actions no candidates remain, this process will repeat on the set of
'other' candidate actions from this stage (those without a constraint).
</remarks>
</Docs>
<Members>
<Member MemberName="Accept">
<MemberSignature Language="C++ CLI" Value="public:
 bool Accept(Microsoft::AspNetCore::Mvc::ActionConstraints::ActionConstraintContext ^ context);" />
<MemberSignature Language="C#" Value="public bool Accept (Microsoft.AspNetCore.Mvc.ActionConstraints.ActionConstraintContext context);" />
<MemberSignature Language="ILAsm" Value=".method public hidebysig newslot virtual instance bool Accept(class Microsoft.AspNetCore.Mvc.ActionConstraints.ActionConstraintContext context) cil managed" />
<MemberSignature Language="DocId" Value="M:Microsoft.AspNetCore.Mvc.ActionConstraints.IActionConstraint.Accept(Microsoft.AspNetCore.Mvc.ActionConstraints.ActionConstraintContext)" />
<MemberSignature Language="VB.NET" Value="Public Function Accept (context As ActionConstraintContext) As Boolean" />
<MemberSignature Language="F#" Value="abstract member Accept : Microsoft.AspNetCore.Mvc.ActionConstraints.ActionConstraintContext -> bool" Usage="iActionConstraint.Accept context" />
<MemberType>Method</MemberType>
<AssemblyInfo>
<AssemblyName>Microsoft.AspNetCore.Mvc.Abstractions</AssemblyName>
<AssemblyVersion>1.0.0.0</AssemblyVersion>
<AssemblyVersion>1.1.0.0</AssemblyVersion>
<AssemblyVersion>2.0.0.0</AssemblyVersion>
<AssemblyVersion>2.1.0.0</AssemblyVersion>
<AssemblyVersion>2.2.0.0</AssemblyVersion>
<AssemblyVersion>3.0.0.0</AssemblyVersion>
<AssemblyVersion>3.1.0.0</AssemblyVersion>
<AssemblyVersion>5.0.0.0</AssemblyVersion>
<AssemblyVersion>6.0.0.0</AssemblyVersion>
<AssemblyVersion>7.0.0.0</AssemblyVersion>
<AssemblyVersion>8.0.0.0</AssemblyVersion>
<AssemblyVersion>9.0.0.0</AssemblyVersion>
</AssemblyInfo>
<Attributes>
<Attribute FrameworkAlternate="aspnetcore-8.0;aspnetcore-9.0">
<AttributeName Language="C#">[System.Runtime.CompilerServices.NullableContext(1)]</AttributeName>
<AttributeName Language="F#">[<System.Runtime.CompilerServices.NullableContext(1)>]</AttributeName>
</Attribute>
</Attributes>
<ReturnValue>
<ReturnType>System.Boolean</ReturnType>
</ReturnValue>
<Parameters>
<Parameter Name="context" Type="Microsoft.AspNetCore.Mvc.ActionConstraints.ActionConstraintContext" />
</Parameters>
<Docs>
<param name="context">The <see cref="T:Microsoft.AspNetCore.Mvc.ActionConstraints.ActionConstraintContext" />.</param>
<summary>
Determines whether an action is a valid candidate for selection.
</summary>
<returns>True if the action is valid for selection, otherwise false.</returns>
<remarks>To be added.</remarks>
</Docs>
</Member>
<Member MemberName="Order">
<MemberSignature Language="C++ CLI" Value="public:
 property int Order { int get(); };" />
<MemberSignature Language="C#" Value="public int Order { get; }" />
<MemberSignature Language="ILAsm" Value=".property instance int32 Order" />
<MemberSignature Language="DocId" Value="P:Microsoft.AspNetCore.Mvc.ActionConstraints.IActionConstraint.Order" />
<MemberSignature Language="VB.NET" Value="Public ReadOnly Property Order As Integer" />
<MemberSignature Language="F#" Value="member this.Order : int" Usage="Microsoft.AspNetCore.Mvc.ActionConstraints.IActionConstraint.Order" />
<MemberType>Property</MemberType>
<AssemblyInfo>
<AssemblyName>Microsoft.AspNetCore.Mvc.Abstractions</AssemblyName>
<AssemblyVersion>1.0.0.0</AssemblyVersion>
<AssemblyVersion>1.1.0.0</AssemblyVersion>
<AssemblyVersion>2.0.0.0</AssemblyVersion>
<AssemblyVersion>2.1.0.0</AssemblyVersion>
<AssemblyVersion>2.2.0.0</AssemblyVersion>
<AssemblyVersion>3.0.0.0</AssemblyVersion>
<AssemblyVersion>3.1.0.0</AssemblyVersion>
<AssemblyVersion>5.0.0.0</AssemblyVersion>
<AssemblyVersion>6.0.0.0</AssemblyVersion>
<AssemblyVersion>7.0.0.0</AssemblyVersion>
<AssemblyVersion>8.0.0.0</AssemblyVersion>
<AssemblyVersion>9.0.0.0</AssemblyVersion>
</AssemblyInfo>
<ReturnValue>
<ReturnType>System.Int32</ReturnType>
</ReturnValue>
<Docs>
<summary>
The constraint order.
</summary>
<value>To be added.</value>
<remarks>
Constraints are grouped into stages by the value of <see cref="P:Microsoft.AspNetCore.Mvc.ActionConstraints.IActionConstraint.Order" />. See remarks on
<see cref="T:Microsoft.AspNetCore.Mvc.ActionConstraints.IActionConstraint" />.
</remarks>
</Docs>
</Member>
</Members>
</Type>