See: Description
| Interface | Description |
|---|---|
| FieldTrustedSource |
Represents a Field trusted source configuration.
|
| Source |
Represents a Source in Trusted source configuration.
|
| SurvivorField |
Represents a Survivor field configuration.
|
| SurvivorFunctionSpec |
Accessor for the configuration.
|
| SurvivorshipFunctionOnField |
Provides new survivorship functions on a field.
|
| SurvivorshipFunctionOnRecord |
Provides new survivorship functions on a record.
|
| TableTrustedSource |
Provides an accessor for the trusted source configuration parameters.
|
| TrustedSourceConfiguration |
Represents the Trusted source configuration.
|
| Class | Description |
|---|---|
| SurvivorshipValue |
Represents the survivorship value and the primary key of a record.
|
| Suspect |
Represents a Suspect record with matching score.
|
| Exception | Description |
|---|---|
| SurvivorshipException |
Exception class for Survivorship operations.
|
Provides classes and interfaces needed to define survivorship configuration.
Definition class:
public final class TestFieldTrustedSourceImpl implements FieldTrustedSource
{
private final SchemaNode field;
private final Source source;
private final int trustedLevel;
public TestFieldTrustedSourceImpl(String code, SchemaNode field, Source source, int trustedLevel)
{
this.field = field;
this.source = source;
this.trustedLevel = trustedLevel;
}
public SchemaNode getField()
{
return this.field;
}
public Source getSource()
{
return this.source;
}
public int getTrustedLevel()
{
return this.trustedLevel;
}
}
Function class:
public final class TestSurvivorshipFunctionOnField implements SurvivorshipFunctionOnField
{
public Object getValue(SurvivorFunctionSpec spec) throws SurvivorshipException
{
SchemaNode field = spec.getSurvivorField().getField();
List<FieldTrustedSource> fieldTrustedSources = spec.getTrustedSourceConfiguration().getFieldTrustedSources();
SchemaNode sourceField = spec.getTrustedSourceConfiguration().getSourceField();
if (sourceField == null)
{
return null;
}
Adaptation survivorRecord = spec.getSurvivorRecord();
Object fieldValue = survivorRecord.get(field);
return fieldValue;
}
public SurvivorshipValue getSurvivorshipValue(SurvivorFunctionSpec spec)
throws SurvivorshipException
{
return null;
}
}
Definition class:
public final class TestTableTrustedSourceImpl implements TableTrustedSource
{
private final Source source;
private final int trustedLevel;
public TestTableTrustedSourceImpl(Source source, int trustedLevel)
{
this.source = source;
this.trustedLevel = trustedLevel;
}
public Source getSource()
{
return this.source;
}
public int getTrustedLevel()
{
return this.trustedLevel;
}
}
Function class:
public final class TestSurvivorshipFunctionOnRecord implements SurvivorshipFunctionOnRecord
{
public Adaptation getRecord(SurvivorFunctionSpec spec) throws SurvivorshipException
{
List<TableTrustedSource> tableTrustedSources = spec.getTrustedSourceConfiguration().getTableTrustedSources();
SchemaNode sourceField = spec.getTrustedSourceConfiguration().getSourceField();
if (sourceField == null)
{
return spec.getSurvivorRecord();
}
List<Suspect> suspects = spec.getSuspects();
if (suspects.isEmpty())
{
return null;
}
return null;
}
}