cxf-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Colm O hEigeartaigh (JIRA)" <j...@apache.org>
Subject [jira] [Updated] (CXF-7059) ClientImpl.getBooleanValue() will return null for String values
Date Fri, 16 Sep 2016 09:10:20 GMT

     [ https://issues.apache.org/jira/browse/CXF-7059?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]

Colm O hEigeartaigh updated CXF-7059:
-------------------------------------
    Fix Version/s: 3.0.11
                   3.1.8
                   3.2.0

> ClientImpl.getBooleanValue() will return null for String values
> ---------------------------------------------------------------
>
>                 Key: CXF-7059
>                 URL: https://issues.apache.org/jira/browse/CXF-7059
>             Project: CXF
>          Issue Type: Bug
>          Components: JAX-RS
>    Affects Versions: 3.1.7
>            Reporter: Andy McCright
>            Assignee: Colm O hEigeartaigh
>            Priority: Minor
>             Fix For: 3.2.0, 3.1.8, 3.0.11
>
>   Original Estimate: 24h
>  Remaining Estimate: 24h
>
> The getBooleanValue(Object o) method looks like this:
>     private static Boolean getBooleanValue(Object o) {
>         return o instanceof Boolean ? (Boolean)o : o instanceof Boolean ? Boolean.valueOf(o.toString())
: null;
>     }
> If o is not an instance of Boolean, it checks to see if it is a Boolean again.  Instead,
it should get to see if it is an instance of String like the getIntValue method:
>     private static Integer getIntValue(Object o) {
>         return o instanceof Integer ? (Integer)o : o instanceof String ? Integer.valueOf(o.toString())
: null;
>     }



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Mime
View raw message