Welcome to the Treehouse Community
Want to collaborate on code errors? Have bugs you need feedback on? Looking for an extra set of eyes on your latest project? Get support with fellow developers, designers, and programmers of all backgrounds and skill levels here with the Treehouse Community! While you're at it, check out some resources Treehouse students have shared here.
Looking to learn something new?
Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and join thousands of Treehouse students and alumni in the community today.
Start your free trialAdnan Nazir
Courses Plus Student 607 Points"type 'javax.security.auth.callback.Callback' does not have type parameters
I set up up the activeListing method with the callback included like so ... Callback callback ... but under I am getting the error "type 'javax.security.auth.callback.Callback' does not have type parameters". Did I import callback from the wrong package? I tried importing the one from com.squareup.picasso, but it gives me the same error about it not having type parameters. Any help would be appreciated, thanks
NOTE: When i import "import retrofit.Callback;" then we have multiple choices which one to select? I already import this "import javax.security.auth.callback.Callback;"
1 Answer
Kourosh Raeen
23,733 PointsThe Api.java file should look like this:
package googleplayservices.samples.android.treehouse.com.recommendations.api;
import googleplayservices.samples.android.treehouse.com.recommendations.model.ActiveListings;
import retrofit.Callback;
import retrofit.http.GET;
import retrofit.http.Query;
public interface Api {
@GET("/listings/active")
void activeListings(@Query("includes") String includes,
Callback<ActiveListings> callback);
}