Skip to content

Commit

Permalink
Port long member remarks (#9577)
Browse files Browse the repository at this point in the history
  • Loading branch information
gewarren authored Feb 1, 2024
1 parent 4d32d4d commit 6481f01
Show file tree
Hide file tree
Showing 294 changed files with 9,003 additions and 21,870 deletions.
4 changes: 0 additions & 4 deletions includes/provider-string-format.md

This file was deleted.

7 changes: 7 additions & 0 deletions includes/remarks/System.Threading/WaitHandle/exit-context.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
## Exiting the context

The `exitContext` parameter has no effect unless this method is called from inside a nondefault managed context. The managed context can be nondefault if your thread is inside a call to an instance of a class derived from <xref:System.ContextBoundObject>. Even if you're currently executing a method on a class that isn't derived from <xref:System.ContextBoundObject>, like <xref:System.String>, you can be in a nondefault context if a <xref:System.ContextBoundObject> is on your stack in the current application domain.

When your code is executing in a nondefault context, specifying `true` for `exitContext` causes the thread to exit the nondefault managed context (that is, to transition to the default context) before executing this method. The thread returns to the original nondefault context after the call to this method completes.

Exiting the context can be useful when the context-bound class has the <xref:System.Runtime.Remoting.Contexts.SynchronizationAttribute> attribute. In that case, all calls to members of the class are automatically synchronized, and the synchronization domain is the entire body of code for the class. If code in the call stack of a member calls this method and specifies `true` for `exitContext`, the thread exits the synchronization domain, which allows a thread that's blocked on a call to any member of the object to proceed. When this method returns, the thread that made the call must wait to reenter the synchronization domain.
4 changes: 4 additions & 0 deletions includes/remarks/System/String/provider-string-format.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@

However, when calling the `String.Format` method, it's not necessary to focus on the particular overload that you want to call. Instead, you can call the method with an object that provides culture-sensitive or custom formatting and a [composite format string](/dotnet/standard/base-types/composite-formatting) that includes one or more format items. You assign each format item a numeric index; the first index starts at 0. In addition to the initial string, your method call should have as many additional arguments as it has index values. For example, a string whose format items have indexes of 0 and 1 should have 2 arguments; one with indexes 0 through 5 should have 6 arguments. The language compiler will then resolve your method call to a particular overload of the `String.Format` method.

For more detailed documentation on using the `String.Format` method, see [Get started with the String.Format method](/dotnet/fundamentals/runtime-libraries/system-string-format#get-started-with-the-stringformat-method) and [Which method do I call?](/dotnet/fundamentals/runtime-libraries/system-string-format#which-method-do-i-call).
4 changes: 4 additions & 0 deletions includes/remarks/System/String/simple-string-format.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@

However, when calling the `String.Format` method, it's not necessary to focus on the particular overload that you want to call. Instead, you can call the method with a [composite format string](/dotnet/standard/base-types/composite-formatting) that includes one or more format items. You assign each format item a numeric index; the first index starts at 0. In addition to the initial string, your method call should have as many additional arguments as it has index values. For example, a string whose format items have indexes of 0 and 1 should have 2 arguments; one with indexes 0 through 5 should have 6 arguments. The language compiler will then resolve your method call to a particular overload of the `String.Format` method.

For more detailed documentation on using the `String.Format` method, see [Get started with the String.Format method](/dotnet/fundamentals/runtime-libraries/system-string-format#get-started-with-the-stringformat-method) and [Which method do I call?](/dotnet/fundamentals/runtime-libraries/system-string-format#which-method-do-i-call).
4 changes: 0 additions & 4 deletions includes/simple-string-format.md

This file was deleted.

This file was deleted.

This file was deleted.

This file was deleted.

This file was deleted.

This file was deleted.

This file was deleted.

This file was deleted.

This file was deleted.

This file was deleted.

This file was deleted.

This file was deleted.

Loading

0 comments on commit 6481f01

Please sign in to comment.