Closed Marvin-Brouwer closed 1 year ago
In addition, the converters shouldn't use the hashcode for determining if they're unique. This should just be a GUID, maybe the guid of the type could be enought for DateTimeConversion for example but otherwise just create a guid
IConverter.ConverterId
Is your feature request related to a problem? Please describe. The current implementation of the
DataNodeComparer
requires an implementer to override theobject.GetHashCode()
method. This is hidden complexity.Describe the solution you'd like Make
IDataNode
have aGetNodeHash()
method so it HAS to be implemented. Than create a default implementation on theIDataNode
sGetHashCode()
that points toGetNodeHash()
for consistency. And finally make theDataNodeComparer
useIDataNode.GetNodeHash()
where it uses theIDataNode.GetHashCode()
currently.Describe alternatives you've considered Maybe create an analyzer that warns if it's not overriden?
Additional context
-