Why there is collision between @Nullable annotation and real explanation?
See original GitHub issueHello. Inspection warns me about possible NPE on insertedId() in the chain of
return storIo
.put()
.object(table)
.prepare()
.executeAsBlocking()
.insertedId(); // Here is possible NPE
When i follow to the source i see @Nullable
annotation and @return non-null results of Put Operation.
explanation. So, how one can interpret it?
/**
* Executes Put Operation immediately in current thread.
* <p>
* Notice: This is blocking I/O operation that should not be executed on the Main Thread,
* it can cause ANR (Activity Not Responding dialog), block the UI and drop animations frames.
* So please, call this method on some background thread. See {@link WorkerThread}.
*
* @return non-null results of Put Operation.
*/
@WorkerThread
@Nullable
public final Result executeAsBlocking() {
return buildChain(storIOSQLite.interceptors(), getRealCallInterceptor())
.proceed(this);
}
Issue Analytics
- State:
- Created 6 years ago
- Comments:5 (2 by maintainers)
Top Results From Across the Web
What's the meaning of java.util.@Nullable? - Stack Overflow
It is a compile-time error if an annotation of type T applies to a type (or any part of a type) in a...
Read more >null | The Object Teams Blog
I.e., if your code consistently uses null annotations, and has passed analysis without warnings, can we be sure that NPEs can only ever...
Read more >@Nullable and @NotNull | IntelliJ IDEA Documentation
@Nullable and @NotNull annotations let you check nullability of a variable, parameter, or return value. They help you control contracts ...
Read more >Null-Coalescing Operator in C# - GeeksforGeeks
In C#, ?? operator is known as Null-coalescing operator. It will return the value of its left-hand operand if it is not null....
Read more >Nullable reference types - Microsoft Learn
In a nullable oblivious context, all reference types were nullable. Nullable reference types refers to a group of features enabled in a nullable ......
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
We can, we can remove nullability annotation from interceptor to leave it undefined
On Thu, Dec 7, 2017 at 1:07 AM Dmitrii Nikitin notifications@github.com wrote:
Closed with #864