You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: xml/System.IO/File.xml
+12Lines changed: 12 additions & 0 deletions
Original file line number
Diff line number
Diff line change
@@ -2518,6 +2518,8 @@ Note that if you attempt to replace a file by moving a file of the same name int
2518
2518
2519
2519
The `sourceFileName` and `destFileName` arguments can include relative or absolute path information. Relative path information is interpreted as relative to the current working directory. To obtain the current working directory, see <xref:System.IO.Directory.GetCurrentDirectory%2A>.
2520
2520
2521
+
Moving the file across disk volumes is equivalent to copying the file and deleting it from the source if the copying was successful.
2522
+
2521
2523
If you try to move a file across disk volumes and that file is in use, the file is copied to the destination, but it is not deleted from the source.
2522
2524
2523
2525
For a list of common I/O tasks, see [Common I/O Tasks](/dotnet/standard/io/common-i-o-tasks).
@@ -2534,6 +2536,10 @@ The following example moves a file.
2534
2536
</remarks>
2535
2537
<exceptioncref="T:System.IO.IOException">
2536
2538
<paramrefname="destFileName" /> already exists.
2539
+
2540
+
-or-
2541
+
2542
+
An I/O error has occurred, e.g. while copying the file across disk volumes.
@@ -2595,6 +2601,8 @@ This method works across disk volumes, and it does not throw an exception if the
2595
2601
2596
2602
The `sourceFileName` and `destFileName` arguments can include relative or absolute path information. Relative path information is interpreted as relative to the current working directory. To obtain the current working directory, see <xref:System.IO.Directory.GetCurrentDirectory%2A>.
2597
2603
2604
+
Moving the file across disk volumes is equivalent to copying the file and deleting it from the source if the copying was successful.
2605
+
2598
2606
If you try to move a file across disk volumes and that file is in use, the file is copied to the destination, but it is not deleted from the source.
2599
2607
2600
2608
For a list of common I/O tasks, see [Common I/O Tasks](/dotnet/standard/io/common-i-o-tasks).
@@ -2611,6 +2619,10 @@ The following example moves a file.
2611
2619
</remarks>
2612
2620
<exceptioncref="T:System.IO.IOException">
2613
2621
<paramrefname="destFileName" /> already exists and <paramrefname="overwrite" /> is <seelangword="false" />.
2622
+
2623
+
-or-
2624
+
2625
+
An I/O error has occurred, e.g. while copying the file across disk volumes.
Copy file name to clipboardExpand all lines: xml/System.IO/Path.xml
+2-2Lines changed: 2 additions & 2 deletions
Original file line number
Diff line number
Diff line change
@@ -58,7 +58,7 @@
58
58
59
59
## Remarks
60
60
61
-
A path is a string that provides the location of a file or directory. A path does not necessarily point to a location on disk; for example, a path might map to a location in memory or on a device. The exact format of a path is determined by the current platform. For example, on some systems, a path can start with a drive or volume letter, while this element is not present in other systems. On some systems, file paths can contain extensions, which indicate the type of information stored in the file. The format of a file name extension is platform-dependent; for example, some systems limit extensions to three characters, and others do not. The current platform also determines the set of characters used to separate the elements of a path, and the set of characters that cannot be used when specifying paths. Because of these differences, the fields of the `Path` class as well as the exact behavior of some members of the `Path` class are platform-dependent.
61
+
A path is a string that provides the location of a file or directory. A path does not necessarily point to a location on disk; for example, a path might map to a location in memory or on a device. The exact format of a path is determined by the current platform. For example, on some systems, a path can start with a drive or volume letter, while this element is not present in other systems. On some systems, file paths can contain extensions, which indicate the type of information stored in the file. The format of a file name extension is platform-dependent; for example, some systems limit extensions to three characters (such as FAT16 commonly used on smaller flash storage and older versions of ISO 9660 used on optical media), and others do not. The current platform also determines the set of characters used to separate the elements of a path, and the set of characters that cannot be used when specifying paths. Because of these differences, the fields of the `Path` class as well as the exact behavior of some members of the `Path` class are platform-dependent.
62
62
63
63
A path can contain absolute or relative location information. Absolute paths fully specify a location: the file or directory can be uniquely identified regardless of the current location. Relative paths specify a partial location: the current location is used as the starting point when locating a file specified with a relative path. To determine the current directory, call <xref:System.IO.Directory.GetCurrentDirectory%2A?displayProperty=nameWithType>.
64
64
@@ -1930,7 +1930,7 @@ Paths are resolved by calling the <xref:System.IO.Path.GetFullPath%2A> method be
1930
1930
1931
1931
# [Linux](#tab/linux)
1932
1932
1933
-
1. The path specified by the TMPDIR environment variable.
1933
+
1. The path specified by the TMPDIR environment variable. If the path is not specified in the `TMPDIR` environment variable, the default path `/tmp/` is used.
Copy file name to clipboardExpand all lines: xml/System.Net.Http/HttpClient.xml
+1-1Lines changed: 1 addition & 1 deletion
Original file line number
Diff line number
Diff line change
@@ -117,7 +117,7 @@ Starting with .NET Core 2.1, the <xref:System.Net.Http.SocketsHttpHandler?displa
117
117
- The elimination of platform dependencies, which simplifies deployment and servicing. For example, `libcurl` is no longer a dependency on .NET Core for macOS and .NET Core for Linux.
118
118
- Consistent behavior across all .NET platforms.
119
119
120
-
If this change is undesirable, on Windows you can still use <xref:System.Net.Http.WinHttpHandler> by referencing it's [NuGet package](https://www.nuget.org/packages/System.Net.Http.WinHttpHandler/) and passing it to [`HttpClient`'s constructor`](xref:System.Net.Http.HttpClient.%23ctor(System.Net.Http.HttpMessageHandler)) manually.
120
+
If this change is undesirable, on Windows you can still use <xref:System.Net.Http.WinHttpHandler> by referencing it's [NuGet package](https://www.nuget.org/packages/System.Net.Http.WinHttpHandler/) and passing it to [`HttpClient`'s constructor](xref:System.Net.Http.HttpClient.%23ctor(System.Net.Http.HttpMessageHandler)) manually.
121
121
122
122
### Configure behavior using run-time configuration options
Copy file name to clipboardExpand all lines: xml/System.Net.Http/HttpMessageHandler.xml
+1-1Lines changed: 1 addition & 1 deletion
Original file line number
Diff line number
Diff line change
@@ -245,7 +245,7 @@
245
245
## Remarks
246
246
This operation will not block. The returned <xref:System.Threading.Tasks.Task%601> object will complete once the entire response including content is read.
247
247
248
-
The <xref:System.Net.Http.HttpMessageHandler.SendAsync%2A> method is used primarily by the system. This method is called by the system one of the <xref:System.Net.Http.HttpClient.SendAsync%2A?displayProperty=nameWithType> methods is called. Most apps will never call this method.
248
+
The <xref:System.Net.Http.HttpMessageHandler.SendAsync%2A> method is used primarily by the system. This method is called by the system when one of the <xref:System.Net.Http.HttpClient.SendAsync%2A?displayProperty=nameWithType> methods is called. Most apps will never call this method.
Copy file name to clipboardExpand all lines: xml/System.Threading.Tasks/Task.xml
+2-2Lines changed: 2 additions & 2 deletions
Original file line number
Diff line number
Diff line change
@@ -119,7 +119,7 @@
119
119
120
120
<a name="WaitingForOne"></a>
121
121
## Waiting for one or more tasks to complete
122
-
Because tasks typically run asynchronously on a thread pool thread, the thread that creates and starts the task continues execution as soon as the task has been instantiated. In some cases, when the calling thread is the main application thread, the app may terminate before any the task actually begins execution. In others, your application's logic may require that the calling thread continue execution only when one or more tasks has completed execution. You can synchronize the execution of the calling thread and the asynchronous tasks it launches by calling a `Wait` method to wait for one or more tasks to complete.
122
+
Because tasks typically run asynchronously on a thread pool thread, the thread that creates and starts the task continues execution as soon as the task has been instantiated. In some cases, when the calling thread is the main application thread, the app may terminate before the task actually begins execution. In others, your application's logic may require that the calling thread continue execution only when one or more tasks have completed execution. You can synchronize the execution of the calling thread and the asynchronous tasks it launches by calling a `Wait` method to wait for one or more tasks to complete.
123
123
124
124
To wait for a single task to complete, you can call its <xref:System.Threading.Tasks.Task.Wait%2A?displayProperty=nameWithType> method. A call to the <xref:System.Threading.Tasks.Task.Wait%2A> method blocks the calling thread until the single class instance has completed execution.
125
125
@@ -135,7 +135,7 @@
135
135
136
136
You can also supply a cancellation token by calling the <xref:System.Threading.Tasks.Task.Wait%28System.Threading.CancellationToken%29> and <xref:System.Threading.Tasks.Task.Wait%28System.Int32%2CSystem.Threading.CancellationToken%29> methods. If the token's <xref:System.Threading.CancellationToken.IsCancellationRequested%2A> property is `true` or becomes `true` while the <xref:System.Threading.Tasks.Task.Wait%2A> method is executing, the method throws an <xref:System.OperationCanceledException>.
137
137
138
-
In some cases, you may want to wait for the first of a series of executing tasks to complete, but don't care which task it is. For this purpose, you can call one of the overloads of the <xref:System.Threading.Tasks.Task.WaitAny%2A?displayProperty=nameWithType> method. The following example creates three tasks, each of which sleeps for an interval determine by a random number generator. The <xref:System.Threading.Tasks.Task.WaitAny%28System.Threading.Tasks.Task%5B%5D%29> method waits for the first task to complete. The example then displays information about the status of all three tasks.
138
+
In some cases, you may want to wait for the first of a series of executing tasks to complete, but don't care which task it is. For this purpose, you can call one of the overloads of the <xref:System.Threading.Tasks.Task.WaitAny%2A?displayProperty=nameWithType> method. The following example creates three tasks, each of which sleeps for an interval determined by a random number generator. The <xref:System.Threading.Tasks.Task.WaitAny%28System.Threading.Tasks.Task%5B%5D%29> method waits for the first task to complete. The example then displays information about the status of all three tasks.
Copy file name to clipboardExpand all lines: xml/System.Threading.Tasks/ValueTask.xml
+4Lines changed: 4 additions & 0 deletions
Original file line number
Diff line number
Diff line change
@@ -64,6 +64,10 @@ Using a `ValueTask` instead of a <xref:System.Threading.Tasks.Task> introduces s
64
64
65
65
> [!NOTE]
66
66
> The use of the `ValueTask` type is supported starting with C# 7.0 and is not supported by any version of Visual Basic.
67
+
68
+
> [!NOTE]
69
+
> An instance created with the parameterless constructor or by the `default(ValueTask)` syntax (a zero-initialized structure) represents a synchronously, successfully completed operation.
Copy file name to clipboardExpand all lines: xml/System.Threading.Tasks/ValueTask`1.xml
+4Lines changed: 4 additions & 0 deletions
Original file line number
Diff line number
Diff line change
@@ -77,6 +77,10 @@ As such, the default choice for any asynchronous method should be to return a <x
77
77
78
78
> [!NOTE]
79
79
> The use of the <xref:System.Threading.Tasks.ValueTask%601> type is supported starting with C# 7.0, and is not supported by any version of Visual Basic.
80
+
81
+
> [!NOTE]
82
+
> An instance created with the parameterless constructor or by the `default(ValueTask<TResult>)` syntax (a zero-initialized structure) represents a synchronously, successfully completed operation with a result of `default(TResult)`.
0 commit comments