Guava r07, GWT and javax.annotation.Nullable

前端 未结 3 1179
遥遥无期
遥遥无期 2020-12-14 17:22

I\'m trying to use Guava in a GWT project without success (a HashMultimap, to be precise). I get a never-ending list of stacktraces for classes:

  • com.google.co
3条回答
  •  孤城傲影
    2020-12-14 17:46

    As written above, the problem appears to be solved when using guava 10.0.1, which has an additional dependency on the JSR305 library.

    Alternatively, the ID of the missing library to add to Maven is com.google.code.findbugs:jsr305:1.3.9, so the build configuration should be fixed by adding the following dependency to pom.xml in the appropriate place (warning - I didn't test this):

    
        com.google.code.findbugs
        jsr305
        2.0.1
        provided
    
    

    Update: User @ips suggested adding provided since the jsr305 jar isn't needed at runtime, and updating to version 2.0.1. I know that the first change makes sense, and I guess that the version update also does. In my experience, using provided created problems for Scala, but that's a separate issue.

提交回复
热议问题