If we do, then it at least puts Java SE 8 and Optional very much in
question, the two try to scratch the same itch;-)

You are right, there has been little activity putting life back into any of
these annotations and despite the underlying compiler has some further
annotation support now in SE 8 (JSR 308) nobody cares and nobody uses it,
especially Oracle or others who could have used this JSR/annotation to
facilitate 308. So far it's a "Compiler Zombie" barely ever used outside a
very small niche of "wacky academics";-)

Werner

On Thu, Jan 22, 2015 at 10:41 AM, Mark Struberg <[email protected]> wrote:

> I don't understand why we need javax.annotation.CheckForNull?
>
> This JSR is dormant and not widely adopted. It didn't even get officially
> released, right?
>
> LieGrue,
> strub
>
>
>
>
> > On Wednesday, 21 January 2015, 22:19, "[email protected]" <
> [email protected]> wrote:
> > > Repository: incubator-tamaya
> > Updated Branches:
> >   refs/heads/master ebe237cb9 -> 3ca337ebe
> >
> >
> > BooleanConverter returns now null if it is not able to convert a
> property.
> >
> >
> > Project: http://git-wip-us.apache.org/repos/asf/incubator-tamaya/repo
> > Commit:
> http://git-wip-us.apache.org/repos/asf/incubator-tamaya/commit/3ca337eb
> > Tree:
> http://git-wip-us.apache.org/repos/asf/incubator-tamaya/tree/3ca337eb
> > Diff:
> http://git-wip-us.apache.org/repos/asf/incubator-tamaya/diff/3ca337eb
> >
> > Branch: refs/heads/master
> > Commit: 3ca337ebe22b75d32332aac211efd3e418163af3
> > Parents: ebe237c
> > Author: Oliver B. Fischer <[email protected]>
> > Authored: Wed Jan 21 22:17:41 2015 +0100
> > Committer: Oliver B. Fischer <[email protected]>
> > Committed: Wed Jan 21 22:17:41 2015 +0100
> >
> > ----------------------------------------------------------------------
> > java8/core/pom.xml                                            | 5 +++++
> > .../tamaya/core/internal/converters/BooleanConverter.java     | 5 ++++-
> > pom.xml                                                       | 7 +++++++
> > 3 files changed, 16 insertions(+), 1 deletion(-)
> > ----------------------------------------------------------------------
> >
> >
> >
> http://git-wip-us.apache.org/repos/asf/incubator-tamaya/blob/3ca337eb/java8/core/pom.xml
> > ----------------------------------------------------------------------
> > diff --git a/java8/core/pom.xml b/java8/core/pom.xml
> > index 029b2ff..d9be79f 100644
> > --- a/java8/core/pom.xml
> > +++ b/java8/core/pom.xml
> > @@ -38,6 +38,11 @@ under the License.
> >          </dependency>
> >
> >          <dependency>
> > +            <groupId>com.google.code.findbugs</groupId>
> > +            <artifactId>annotations</artifactId>
> > +        </dependency>
> > +
> > +        <dependency>
> >              <groupId>junit</groupId>
> >              <artifactId>junit</artifactId>
> >          </dependency>
> >
> >
> http://git-wip-us.apache.org/repos/asf/incubator-tamaya/blob/3ca337eb/java8/core/src/main/java/org/apache/tamaya/core/internal/converters/BooleanConverter.java
> > ----------------------------------------------------------------------
> > diff --git
> >
> a/java8/core/src/main/java/org/apache/tamaya/core/internal/converters/BooleanConverter.java
> >
> b/java8/core/src/main/java/org/apache/tamaya/core/internal/converters/BooleanConverter.java
> > index a9cb5ad..76fd4d7 100644
> > ---
> >
> a/java8/core/src/main/java/org/apache/tamaya/core/internal/converters/BooleanConverter.java
> > +++
> >
> b/java8/core/src/main/java/org/apache/tamaya/core/internal/converters/BooleanConverter.java
> > @@ -20,6 +20,7 @@ package org.apache.tamaya.core.internal.converters;
> >
> > import org.apache.tamaya.spi.PropertyConverter;
> >
> > +import javax.annotation.CheckForNull;
> > import java.util.Locale;
> > import java.util.Objects;
> > import java.util.logging.Logger;
> > @@ -32,6 +33,7 @@ public class BooleanConverter implements
> > PropertyConverter<Boolean> {
> >      private Logger LOG = Logger.getLogger(getClass().getName());
> >
> >      @Override
> > +    @CheckForNull
> >      public Boolean convert(String value) {
> >          String ignoreCaseValue = Objects.requireNonNull(value)
> >                                          .trim()
> > @@ -51,6 +53,7 @@ public class BooleanConverter implements
> > PropertyConverter<Boolean> {
> >              default:
> >                  LOG.warning("Unknown boolean value encountered: " +
> > value);
> >          }
> > -        return Boolean.FALSE;
> > +
> > +        return null;
> >      }
> > }
> >
> >
> http://git-wip-us.apache.org/repos/asf/incubator-tamaya/blob/3ca337eb/pom.xml
> > ----------------------------------------------------------------------
> > diff --git a/pom.xml b/pom.xml
> > index 8f1f46f..384bf2e 100644
> > --- a/pom.xml
> > +++ b/pom.xml
> > @@ -215,6 +215,13 @@ under the License.
> >                  <version>${junit.version}</version>
> >                  <scope>test</scope>
> >              </dependency>
> > +
> > +            <dependency>
> > +                <groupId>com.google.code.findbugs</groupId>
> > +                <artifactId>annotations</artifactId>
> > +                <version>${findbugs.version}</version>
> > +            </dependency>
> > +
> >              <dependency>
> >                  <groupId>org.hamcrest</groupId>
> >                  <artifactId>hamcrest-core</artifactId>
> >
>

Reply via email to