ranger-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Abhay Kulkarni (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (RANGER-1628) Good coding practice suggested by static code analysis
Date Mon, 05 Jun 2017 21:24:04 GMT

    [ https://issues.apache.org/jira/browse/RANGER-1628?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16037618#comment-16037618
] 

Abhay Kulkarni commented on RANGER-1628:
----------------------------------------

More commit details:

Project: http://git-wip-us.apache.org/repos/asf/ranger/repo
Commit: http://git-wip-us.apache.org/repos/asf/ranger/commit/2a5b55e1
Tree: http://git-wip-us.apache.org/repos/asf/ranger/tree/2a5b55e1
Diff: http://git-wip-us.apache.org/repos/asf/ranger/diff/2a5b55e1

Branch: refs/heads/master
Commit: 2a5b55e1bbae108432c20a5977f8ce4fe757b5a0

> Good coding practice suggested by static code analysis
> ------------------------------------------------------
>
>                 Key: RANGER-1628
>                 URL: https://issues.apache.org/jira/browse/RANGER-1628
>             Project: Ranger
>          Issue Type: Bug
>          Components: Ranger
>    Affects Versions: 1.0.0
>            Reporter: Abhay Kulkarni
>            Assignee: Abhay Kulkarni
>             Fix For: 1.0.0
>
>
> When sorting collection of objects, it is better to provide a specific Comparator to
Collections.sort() API than to have the class of the object implement Comparable interface.
It gives more flexibility of sorting and does not require more stringent requirements such
as implementing hashCode() and equals() APIs for the object's class.



--
This message was sent by Atlassian JIRA
(v6.3.15#6346)

Mime
View raw message