# ApplicationFramework
TKLCAF
TDF

# TDF_ComparisonTool Class Reference

This class provides services to compare sets of
information. The use of this tool can works after
a copy, acted by a CopyTool.
* Compare(...) compares two DataSet and returns
the result.
* SourceUnbound(...) builds the difference between
a relocation dictionnary and a source set of
information.
* TargetUnbound(...) does the same between a
relocation dictionnary and a target set of
information.
* Cut(aDataSet, anLabel) removes a set of
attributes.
* IsSelfContained(...) returns true if all the
labels of the attributes of the given DataSet are
descendant of the given label.
.

`#include <TDF_ComparisonTool.hxx>`

## Public Member Functions

void * | operator new (size_t, void *anAddress)
void * | operator new (size_t size)
void | operator delete (void *anAddress)

## Static Public Member Functions

static Standard_EXPORT void | Compare (const Handle(TDF_DataSet)&aSourceDataSet, const Handle(TDF_DataSet)&aTargetDataSet, const TDF_IDFilter &aFilter, const Handle(TDF_RelocationTable)&aRelocationTable)
| Compares <asourcedataset> with <atargetdataset>, updating <arelocationtable> with labels and attributes found in both sets. .
static Standard_EXPORT Standard_Boolean | SourceUnbound (const Handle(TDF_DataSet)&aRefDataSet, const Handle(TDF_RelocationTable)&aRelocationTable, const TDF_IDFilter &aFilter, const Handle(TDF_DataSet)&aDiffDataSet, const Standard_Integer anOption=2)
| Finds from <arefdataset> all the keys not bound into <arelocationtable> and put them into <adiffdataset>. Returns True if the difference contains at least one key. (A key is a source object). <anoption> may take the following values: 1 : labels treatment only; 2 : attributes treatment only (default value); 3 : both labels & attributes treatment. .
static Standard_EXPORT Standard_Boolean | TargetUnbound (const Handle(TDF_DataSet)&aRefDataSet, const Handle(TDF_RelocationTable)&aRelocationTable, const TDF_IDFilter &aFilter, const Handle(TDF_DataSet)&aDiffDataSet, const Standard_Integer anOption=2)
| Substracts from <arefdataset> all the items bound into <arelocationtable>. The result is put into <adiffdataset>. Returns True if the difference contains at least one item. (An item is a target object). <anoption> may take the following values: 1 : labels treatment only; 2 : attributes treatment only(default value); 3 : both labels & attributes treatment. .
static Standard_EXPORT void | Cut (const Handle(TDF_DataSet)&aDataSet)
| Removes attributes from <adataset>. .
static Standard_EXPORT Standard_Boolean | IsSelfContained (const TDF_Label &aLabel, const Handle(TDF_DataSet)&aDataSet)
| Returns true if all the labels of <adataset> are descendant of <alabel>. .

## Static Private Member Functions

static Standard_EXPORT void | Compare (const TDF_Label &aSrcLabel, const TDF_Label &aTrgLabel, const Handle(TDF_DataSet)&aSourceDataSet, const Handle(TDF_DataSet)&aTargetDataSet, const TDF_IDFilter &aFilter, const Handle(TDF_RelocationTable)&aRelocationTable)
| Internal comparison method used by Compare(...). .
static Standard_EXPORT Standard_Boolean | Unbound (const Handle(TDF_DataSet)&aRefDataSet, const Handle(TDF_RelocationTable)&aRelocationTable, const TDF_IDFilter &aFilter, const Handle(TDF_DataSet)&aDiffDataSet, const Standard_Integer anOption, const Standard_Boolean theSource)
| Internal function used by SourceUnbound() and TargetUnbound(). .

## Member Function Documentation

static Standard_EXPORT void TDF_ComparisonTool::Compare | ( | const TDF_Label & | aSrcLabel,
|  | const TDF_Label & | aTrgLabel,
|  | const Handle(TDF_DataSet)& | aSourceDataSet,
|  | const Handle(TDF_DataSet)& | aTargetDataSet,
|  | const TDF_IDFilter & | aFilter,
|  | const Handle(TDF_RelocationTable)& | aRelocationTable
| ) | `[static, private]`

static Standard_EXPORT void TDF_ComparisonTool::Compare | ( | const Handle(TDF_DataSet)& | aSourceDataSet,
|  | const Handle(TDF_DataSet)& | aTargetDataSet,
|  | const TDF_IDFilter & | aFilter,
|  | const Handle(TDF_RelocationTable)& | aRelocationTable
| ) | `[static]`

static Standard_EXPORT void TDF_ComparisonTool::Cut | ( | const Handle(TDF_DataSet)& | aDataSet | ) | `[static]`

static Standard_EXPORT Standard_Boolean TDF_ComparisonTool::IsSelfContained | ( | const TDF_Label & | aLabel,
|  | const Handle(TDF_DataSet)& | aDataSet
| ) | `[static]`

void TDF_ComparisonTool::operator delete | ( | void * | anAddress | ) | `[inline]`

void* TDF_ComparisonTool::operator new | ( | size_t | size | ) | `[inline]`

void* TDF_ComparisonTool::operator new | ( | size_t | ,
|  | void * | anAddress
| ) | `[inline]`

static Standard_EXPORT Standard_Boolean TDF_ComparisonTool::SourceUnbound | ( | const Handle(TDF_DataSet)& | aRefDataSet,
|  | const Handle(TDF_RelocationTable)& | aRelocationTable,
|  | const TDF_IDFilter & | aFilter,
|  | const Handle(TDF_DataSet)& | aDiffDataSet,
|  | const Standard_Integer | anOption = `2`
| ) | `[static]`

static Standard_EXPORT Standard_Boolean TDF_ComparisonTool::TargetUnbound | ( | const Handle(TDF_DataSet)& | aRefDataSet,
|  | const Handle(TDF_RelocationTable)& | aRelocationTable,
|  | const TDF_IDFilter & | aFilter,
|  | const Handle(TDF_DataSet)& | aDiffDataSet,
|  | const Standard_Integer | anOption = `2`
| ) | `[static]`

static Standard_EXPORT Standard_Boolean TDF_ComparisonTool::Unbound | ( | const Handle(TDF_DataSet)& | aRefDataSet,
|  | const Handle(TDF_RelocationTable)& | aRelocationTable,
|  | const TDF_IDFilter & | aFilter,
|  | const Handle(TDF_DataSet)& | aDiffDataSet,
|  | const Standard_Integer | anOption,
|  | const Standard_Boolean | theSource
| ) | `[static, private]`

The documentation for this class was generated from the following file:

- TDF_ComparisonTool.hxx