java.lang.NullPointerException: Cannot invoke “com.Service.getById(String)” because “this.Service” is null
I am trying to create a java application that can send HTTP requests and is connected to a database using Jersey framework. I have written the DAO,Service and Controller classes but I am getting this error “java.lang.NullPointerException: Cannot invoke “com.Service.getById(String)” because “this.Service” is null.