System.SysUtils.IncludeTrailingPathDelimiter
Delphi
function IncludeTrailingPathDelimiter(const S: string): string;
C++
extern DELPHI_PACKAGE System::UnicodeString __fastcall IncludeTrailingPathDelimiter(const System::UnicodeString S)/* overload */;
プロパティ
| 種類 | 可視性 | ソース | ユニット | 親 |
|---|---|---|---|---|
| function | public | System.SysUtils.pas System.SysUtils.hpp |
System.SysUtils | System.SysUtils |
説明
パス名が必ず区切り記号で終わるようにします。
IncludeTrailingPathDelimiter は、パス名が必ず末尾の区切り文字(PathDelim - Windows の場合「\」で、それ以外は 「/」)で終わるようにします。 S の最後の文字が区切り文字だった場合、変更せずにそのまま返されます。そうでなければ、区切り文字が追加して S は返されます。
メモ: IncludeTrailingPathDelimiter は、マルチバイト文字セット(MBCS)で動作します。
| プラットフォーム | 入力例(S) | 出力 |
|---|---|---|
| Windows | C:\Your\Input\Path | C:\Your\Input\Path\ |
| C:\Your\Input\Path\ | C:\Your\Input\Path\ | |
| OS X iOS Android Linux |
/Your/Input/Path | /Your/Input/Path/ |
| /Your/Input/Path/ | /Your/Input/Path/ |