cocoon-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "ASF GitHub Bot (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (COCOON-2360) Inconsistent method names
Date Sun, 22 Apr 2018 08:30:00 GMT

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

ASF GitHub Bot commented on COCOON-2360:
----------------------------------------

GitHub user BruceKuiLiu opened a pull request:

    https://github.com/apache/cocoon/pull/5

    COCOON-2360: Change the inconsistent method name.

    The method is named as "select".
    "select" is prone to mean that something will be selected.
    But this method actually checks whether the expression is contained or not.
    So, rename it as "contains" should be more clearly and intuitively.

You can merge this pull request into a Git repository by running:

    $ git pull https://github.com/BruceKuiLiu/cocoon trunk

Alternatively you can review and apply these changes as the patch at:

    https://github.com/apache/cocoon/pull/5.patch

To close this pull request, make a commit to your master/trunk branch
with (at least) the following in the commit message:

    This closes #5
    
----
commit c6889d0c6298076a315fc6dab4700ebb79248662
Author: Kui LIU <brucekuiliu@...>
Date:   2018-04-22T08:27:39Z

    COCOON-2360: Change the inconsistent method name.
    
    The method is named as "select".
    "select" is prone to mean that something will be selected.
    But this method actually checks whether the expression is contained or not.
    So, rename it as "contains" should be more clearly and intuitively.

----


> Inconsistent method names
> -------------------------
>
>                 Key: COCOON-2360
>                 URL: https://issues.apache.org/jira/browse/COCOON-2360
>             Project: Cocoon
>          Issue Type: Improvement
>          Components: Blocks: (Undefined)
>            Reporter: KuiLIU
>            Priority: Major
>
> The following method is named as "select".
> "select" is prone to mean that something will be selected.
> But this method actually checks whether the expression is contained or not.
> So, rename it as "contains" should be more clearly and intuitively.
>     public boolean select( String expression ) {
>         return this.set.contains( expression );
>     }



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

Mime
View raw message