Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commitaa8e833

Browse files
committed
Update MethodBinder.cs
1 parent77e9bcb commitaa8e833

File tree

1 file changed

+16
-0
lines changed

1 file changed

+16
-0
lines changed

‎src/runtime/MethodBinder.cs

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,16 @@ namespace Python.Runtime
1010
{
1111
usingMaybeMethodBase=MaybeMethodBase<MethodBase>;
1212

13+
/// <summary>
14+
/// Delegate for custom coercion logic during Python method binding.
15+
/// </summary>
16+
/// <param name="arguments">A dictionary containing the Python arguments passed to the method.</param>
17+
/// <param name="methods">An array of method overloads being considered for binding.</param>
18+
/// <param name="foundBinding">
19+
/// A reference to the method that was successfully bound. This can be modified by the delegate
20+
/// to override the default binding logic. The delegate can set this to null to disable the method call
21+
/// and report an error.
22+
/// </param>
1323
publicdelegatevoidMethodBinderCoerceBindDelegate(
1424
Dictionary<string,PyObject>arguments,
1525
MethodBase[]methods,
@@ -1088,8 +1098,14 @@ static internal class ParameterInfoExtensions
10881098
}
10891099
}
10901100

1101+
/// <summary>
1102+
/// Provides events related to method binding in the MethodBinder class.
1103+
/// </summary>
10911104
publicstaticclassMethodBinderEvents
10921105
{
1106+
/// <summary>
1107+
/// Event triggered to allow custom coercion logic during method binding.
1108+
/// </summary>
10931109
publicstaticMethodBinderCoerceBindDelegate?CoerceBind;
10941110
}
10951111
}

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp