System.TypInfo.StringToSet

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

Delphi

function StringToSet(PropInfo: PPropInfo; const Value: string): Integer;
function StringToSet(TypeInfo: PTypeInfo; const Value: string): Integer;
procedure StringToSet(PropInfo: PPropInfo; const Value: string; Result: Pointer);
procedure StringToSet(TypeInfo: PTypeInfo; const Value: string; Result: Pointer);

C++

extern DELPHI_PACKAGE int __fastcall StringToSet(PPropInfo PropInfo, const System::UnicodeString Value)/* overload */;

プロパティ

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

説明

集合型のコンポーネント プロパティの集合値のビット マスクを返します。

StringToSet は、Delphi の RTTI(Run Time Type Information:実行時型情報)を利用して、コンポーネントの集合型のプロパティに対する集合インデックスのビット マスクを返します。

このプロパティは PropInfo ポインタで定義されます。(GetPropInfo および GetPropList を使うと、このようなレコードを取得することができます。)

Value では、プロパティの持つ集合値を、カンマ区切りの文字列として定義します。

返される整数値はビット マスクです。0 ビットがプロパティの 1 番目の集合値に対応します。このビットは、そのプロパティ値が Value の文字列に含まれている場合は 1 に、含まれていなければ 0 に設定されています。同様に、1 ビットは集合の 2 番目の位置に、2 ビットは 3 番目の位置にという順で対応していきます。

関連項目