ArgumentValidation.AcceptExistingOnly 方法
定义
重要
一些信息与预发行产品相关,相应产品在发行之前可能会进行重大修改。 对于此处提供的信息,Microsoft 不作任何明示或暗示的担保。
重载
| 名称 | 说明 |
|---|---|
| AcceptExistingOnly(Argument<DirectoryInfo>) |
配置参数以仅接受与现有目录对应的值。 |
| AcceptExistingOnly(Argument<FileInfo>) |
配置参数以仅接受与现有文件对应的值。 |
| AcceptExistingOnly(Argument<FileSystemInfo>) |
配置参数以仅接受与现有文件或目录对应的值。 |
| AcceptExistingOnly<T>(Argument<T>) |
配置参数以仅接受与现有文件或目录对应的值。 |
AcceptExistingOnly(Argument<DirectoryInfo>)
- Source:
- ArgumentValidation.cs
- Source:
- ArgumentValidation.cs
配置参数以仅接受与现有目录对应的值。
public:
[System::Runtime::CompilerServices::Extension]
static System::CommandLine::Argument<System::IO::DirectoryInfo ^> ^ AcceptExistingOnly(System::CommandLine::Argument<System::IO::DirectoryInfo ^> ^ argument);
public static System.CommandLine.Argument<System.IO.DirectoryInfo> AcceptExistingOnly(this System.CommandLine.Argument<System.IO.DirectoryInfo> argument);
static member AcceptExistingOnly : System.CommandLine.Argument<System.IO.DirectoryInfo> -> System.CommandLine.Argument<System.IO.DirectoryInfo>
<Extension()>
Public Function AcceptExistingOnly (argument As Argument(Of DirectoryInfo)) As Argument(Of DirectoryInfo)
参数
- argument
- Argument<DirectoryInfo>
要配置的参数。
返回
配置的自变量。
适用于
AcceptExistingOnly(Argument<FileInfo>)
- Source:
- ArgumentValidation.cs
- Source:
- ArgumentValidation.cs
配置参数以仅接受与现有文件对应的值。
public:
[System::Runtime::CompilerServices::Extension]
static System::CommandLine::Argument<System::IO::FileInfo ^> ^ AcceptExistingOnly(System::CommandLine::Argument<System::IO::FileInfo ^> ^ argument);
public static System.CommandLine.Argument<System.IO.FileInfo> AcceptExistingOnly(this System.CommandLine.Argument<System.IO.FileInfo> argument);
static member AcceptExistingOnly : System.CommandLine.Argument<System.IO.FileInfo> -> System.CommandLine.Argument<System.IO.FileInfo>
<Extension()>
Public Function AcceptExistingOnly (argument As Argument(Of FileInfo)) As Argument(Of FileInfo)
参数
返回
配置的自变量。
适用于
AcceptExistingOnly(Argument<FileSystemInfo>)
- Source:
- ArgumentValidation.cs
- Source:
- ArgumentValidation.cs
配置参数以仅接受与现有文件或目录对应的值。
public:
[System::Runtime::CompilerServices::Extension]
static System::CommandLine::Argument<System::IO::FileSystemInfo ^> ^ AcceptExistingOnly(System::CommandLine::Argument<System::IO::FileSystemInfo ^> ^ argument);
public static System.CommandLine.Argument<System.IO.FileSystemInfo> AcceptExistingOnly(this System.CommandLine.Argument<System.IO.FileSystemInfo> argument);
static member AcceptExistingOnly : System.CommandLine.Argument<System.IO.FileSystemInfo> -> System.CommandLine.Argument<System.IO.FileSystemInfo>
<Extension()>
Public Function AcceptExistingOnly (argument As Argument(Of FileSystemInfo)) As Argument(Of FileSystemInfo)
参数
- argument
- Argument<FileSystemInfo>
要配置的参数。
返回
配置的自变量。
适用于
AcceptExistingOnly<T>(Argument<T>)
- Source:
- ArgumentValidation.cs
- Source:
- ArgumentValidation.cs
配置参数以仅接受与现有文件或目录对应的值。
public:
generic <typename T>
where T : System::Collections::Generic::IEnumerable<System::IO::FileSystemInfo ^>[System::Runtime::CompilerServices::Extension]
static System::CommandLine::Argument<T> ^ AcceptExistingOnly(System::CommandLine::Argument<T> ^ argument);
public static System.CommandLine.Argument<T> AcceptExistingOnly<T>(this System.CommandLine.Argument<T> argument) where T : System.Collections.Generic.IEnumerable<System.IO.FileSystemInfo>;
static member AcceptExistingOnly : System.CommandLine.Argument<#seq<System.IO.FileSystemInfo>> -> System.CommandLine.Argument<#seq<System.IO.FileSystemInfo>>
<Extension()>
Public Function AcceptExistingOnly(Of T As IEnumerable(Of FileSystemInfo)) (argument As Argument(Of T)) As Argument(Of T)
类型参数
- T
参数
- argument
- Argument<T>
要配置的参数。
返回
配置的自变量。