アクション全体で変更された各フィールドの FieldInfo オブジェクトを戻します (すべての初期化フックで行われた変更を含む)。GetFieldsUpdatedThisEntireAction メソッド (バージョン 2003.03.15 で新規導入) は、アクション中に変更されたフィールドを判別するために使用するロジックで問題を解決します。
このメソッドは、アクション全体の中で変更されたフィールドのレポートを作成します。これには、BuildEntity または EditEntity の呼び出しから戻される前に変更されたフィールドをすべて含みます。 アクションの初期化中に暗黙的に変更されたフィールド (FIELD_DEFAULT_VALUE フックで設定するデフォルトの初期フィールド値を含む) がレポートされます。アクションの初期化中にフックによって変更されたフィールドもレポートされます。このメソッドは、アクションの初期化フェーズ後にフックによって変更されたフィールドをレポートします。フックのタイミングおよび実行順序については、ClearQuest® Designer の資料を参照してください。
VBScript
entity.GetFieldsUpdatedThisEntireAction
Perl
$entity->GetFieldsUpdatedThisEntireAction();
VBScript
DIM CQFieldInfo DIM CQFieldInfos DIM sessionObj set sessionObj = GetSession ' Report any fields that changed during the recent action CQFieldInfos = CQEntity.GetFieldsUpdatedThisEntireAction ' Get the list of field names returned by this function ... For Each CQFieldInfo In CQFieldInfos ' Report the fields to the user sessionObj.OutputDebugString "Field " & CQFieldInfo.GetName & " changed." Next
Perl
my(@ActualUpdatedFields); my($CQFieldInfos); my($CQEntity); # Report any fields that changed during the recent action $CQFieldInfos = $CQEntity->GetFieldsUpdatedThisEntireAction(); # Get the list of field names returned by this function ... @ActualUpdatedFields = &GetFieldNames($CQFieldInfos);