You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@commons.apache.org by "Chen Guoping (Jira)" <ji...@apache.org> on 2020/03/07 01:39:00 UTC
[jira] [Commented] (COLLECTIONS-749) Better documentation needed
for HashFunctionIdentity.Signedness
[ https://issues.apache.org/jira/browse/COLLECTIONS-749?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17053841#comment-17053841 ]
Chen Guoping commented on COLLECTIONS-749:
------------------------------------------
Thanks to Alex Herbert. This issue maybe fixed by the pull +https://github.com/apache/commons-collections/pull/133/commits/24ad759b3100ef2026381fcb4065613a9dff6117+
> Better documentation needed for HashFunctionIdentity.Signedness
> ---------------------------------------------------------------
>
> Key: COLLECTIONS-749
> URL: https://issues.apache.org/jira/browse/COLLECTIONS-749
> Project: Commons Collections
> Issue Type: Improvement
> Components: Collection
> Affects Versions: 4.5
> Reporter: Claude Warren
> Priority: Minor
>
> From Alex Herbert:
> HashFunctionIdentity.Signedness
>
> This is not fully documented as to what the sign applies to. There is no
> javadoc on the enum values for SIGNED and UNSIGNED. The current javadoc
> states "Identifies the signedness of the calculations for this function".
>
> I assume this applies to the Hash computation in 'long
> HashFunction.apply(byte[], int)'
>
> Does this mean the hash algorithm has a variant that can treat the
> bytes/seed as signed or unsigned. If so which one because 2 enum values
> cannot cover all 4 possibilities. Since there is no javadoc it is
> unclear exactly what this property is supposed to indicate.
--
This message was sent by Atlassian Jira
(v8.3.4#803005)