CustomFields: overload AttributeDefinition::Fingerprint

SVN:trunk[3997]
This commit is contained in:
Romain Quetiez
2016-04-15 09:05:39 +00:00
parent c32ef34307
commit 21564ff340
2 changed files with 17 additions and 0 deletions

View File

@@ -6644,6 +6644,17 @@ class AttributeCustomFields extends AttributeDefinition
return $oHandler->WriteValues($oHostObject, $aValues);
}
/**
* The part of the current attribute in the object's signature, for the supplied value
* @param $value The value of this attribute for the object
* @return string The "signature" for this field/attribute
*/
public function Fingerprint($value)
{
$oHandler = $this->GetHandler($value->GetValues());
return $oHandler->GetValueFingerprint();
}
/**
* Check the validity of the data
* @param DBObject $oHostObject

View File

@@ -131,4 +131,10 @@ abstract class CustomFieldsHandler
* @return bool
*/
abstract public function CompareValues($aValuesA, $aValuesB);
/**
* String representation of the value, must depend solely on the semantics
* @return string
*/
abstract public function GetValueFingerprint();
}