Code example for AuthScope

0
 
    private static final String SCHEME = "https";
    private static final String PINBOARD_AUTHORITY = "api.pinboard.in";
    private static final int PORT = 443;
  
    private static final AuthScope SCOPE = new AuthScope(PINBOARD_AUTHORITY, PORT);
 
    /** 
     * Attempts to authenticate to Pinboard using a legacy Pinboard account. 
     *  
     * @param username The user's username. 
     * @param password The user's password. 
     * @param handler The hander instance from the calling UI thread. 
     * @param context The context of the calling Activity. 
     * @return The boolean result indicating whether the user was 
     *         successfully authenticated. 
     */ 
    public static boolean pinboardAuthenticate(String username, String password) {
        final HttpResponse resp;
         
Connect your IDE to all the code out there  Get Codota for Java