System.SysUtils.TStringHelper.LastIndexOf

提供: RAD Studio API Documentation
移動先: 案内検索

Delphi

function LastIndexOf(Value: Char): Integer; overload;
function LastIndexOf(const Value: string): Integer; overload;
function LastIndexOf(Value: Char; StartIndex: Integer): Integer; overload;
function LastIndexOf(const Value: string; StartIndex: Integer): Integer; overload;
function LastIndexOf(Value: Char; StartIndex: Integer; Count: Integer): Integer; overload;
function LastIndexOf(const Value: string; StartIndex: Integer; Count: Integer): Integer; overload;

プロパティ

種類 可視性 ソース ユニット
function public System.SysUtils.pas System.SysUtils TStringHelper


説明

現在の文字列で、Value 文字列の最後のインデックスを返します。

StartIndex は、LastIndexOf メソッドが検索を開始する、この文字列におけるオフセットを示し、Count は、検索されたサブ文字列の長さを示します。

LastIndexOf オーバーロード メソッドは 6 つあり、それぞれ、この文字列において指定された文字列の最後のインデックスを取得するための、さまざまなオプションを指定することができます。

LastIndexOf に渡される Value 引数(Char または String)が文字列内で見つからなかった場合、LastIndexOf 関数は -1 を返します。

関連項目