IsOriginal

説明

この Entity には重複があるが、それ自体は重複でない場合、True を戻します。

このメソッドは、Entity オブジェクトが真のオリジナルであるかどうか、つまり、それ自体が重複でないオブジェクトであるかどうかをレポートします。このメソッドから True が戻される場合、IsDuplicate メソッドは False、HasDuplicates メソッドは True を戻す必要があります。Entity オブジェクトには、オリジナルと見なされる、少なくとも 1 つの重複が必要です。

構文

VBScript

entity.IsOriginal 

Perl

$entity->IsOriginal(); 
識別子
説明
entity
Entity オブジェクトは、ユーザー データ レコードを表します。構文のこの部分を省略すると、フック内では、現在のデータ レコードに対応する Entity オブジェクトが想定されます (VBScript のみ)。
戻り値
このオブジェクトには重複があるが、それ自体は別の Entity オブジェクトの重複としてマークされていない場合は True の Boolean。

VBScript

'Display a window indicating the IDs of the
' the duplicates of this record
If entity.IsOriginal Then
   ' Get the ID of this record
   originalID = entity.GetDisplayName

   ' Display the IDs of its duplicates
   duplicateLinkList = entity.GetDuplicates
   For Each duplicateLink In duplicateLinkList
      duplicateObj = duplicateLink.GetChildEntity
      duplicateID = duplicateObj.GetDisplayName
      OutputDebugString "Parent ID:" & originalID & _
            " child Id:" & duplicateID 
   Next 
End If 

Perl

# Display a window indicating the IDs of the

# the duplicates of this record

if ($entity->IsOriginal())

 {

 # Get the ID of this record

 $originalID = $entity->GetDisplayName();

   # Find out how many duplicates there
   # are so the for loop can iterate them. 
   # Display the IDs of its duplicates

   $duplicateLinkList = $entity->GetDuplicates();

   $numdups = $duplicateLinkList->Count();

   for ($x = 0; $x < $numdups ; $x++)

  {

   $duplicateLink = $duplicateLinkList->Item($x);
   $duplicateObj = $duplicateLink->GetChildEntity();
   $duplicateID = $duplicateObj->GetDisplayName();
   $session->OutputDebugString("Parent ID: ".$originalID." child
      Id:".$duplicateID);

  }

 } 

フィードバック