Top "Nullpointerexception" questions

The Java exception thrown when an application attempts to use null in a case where an object is required.

Jackson ObjectMapper throwing NullPointerException even with NON_NULL

When the following JSON is used and either "phones" or "emailAddresses" are null, I'm getting a NullPointerException. JSON: { "item": { "messages": { "…

java json nullpointerexception jackson objectmapper
How to serialize null value when using Parcelable interface

regarding my code example down, what shold I do if one Locable's variables is null? In example, now if l.…

android nullpointerexception parcelable
Null pointer after capturing image using android camera

in my application,i am using android devices camera to capture an image. for some devices it works fine but …

android nullpointerexception image-capture
Grails get Session and Management in Service class

I have a problem with Grails Session. I was thinking about having a Service Class for my session handling. So …

session grails service nullpointerexception httpsession
How to rectify NullPointerException in v4.DrawerLayout?

I am trying to implement a navigation drawer but for some reasons am getting this null pointer exception. I have …

android nullpointerexception navigation-drawer android-actionbaractivity
Getting NullPointerException when trying to stream().filter().collect(Collectors.toList())) on Java list

I got a problem while trying to search a specific Java object in a list. Actually i got the search …

java list lambda nullpointerexception ebean
createEntityManager throws java.lang.NullPointerException at org.hibernate.engine.transaction.internal.jta.JtaStatusHelper.getStatus

I'm getting this stack trace when I deploy my hibernate app java.lang.NullPointerException at org.hibernate.engine.transaction.internal.…

hibernate jpa nullpointerexception entitymanager
What should int compareTo() return when the parameter string is null?

It is said that when input parameter is null, compareTo() should throw a NullPointerException. However, I am implementing a class …

java string null nullpointerexception compareto
Problem reloading a jar using URLClassLoader

I need to add plugin functionality to an existing application for certain parts of the application. I want to be …

java nullpointerexception urlclassloader
RuntimeException could not be mapped to a response, re-throwing to the HTTP container java.lang.NullPointerException

I am trying to validate a user record from my database using Spring Framework, RESTful Web Services and Jersey Implementation. …

spring rest nullpointerexception jersey runtimeexception