Method HasMultiExtension
HasMultiExtension(string)
Determines whether the file name ends with the specified multi-extension, which has one or more parts (e.g. ".gz" or ".tar.gz").
Case is ignored on every platform.
Declaration
bool HasMultiExtension(string extension)
Parameters
| Type | Name | Description |
|---|---|---|
| string | extension | The multi-extension, starting with a dot '.' character (e.g. |
Returns
| Type | Description |
|---|---|
| bool | true if the file name ends with the extension, otherwise false. A file name that is the extension,
such as |
Remarks
Extension is an empty string when the file name has no extension.
Exceptions
| Type | Condition |
|---|---|
| ArgumentException | The extension is empty, isn't shaped as described for |