Code example for HttpHost

0
     * @param host  the hostname of the HTTP proxy 
     * @param port  the port of the HTTP proxy server 
     * @return  this 
     */ 
    public C2DMServiceBuilder withHttpProxy(String host, int port) {
        this.proxy = new HttpHost(host, port);
        return this;
    } 
 
    /** 
     * Specify the service URI to post Google C2DM request to. 
     * 
     * This method should be used only for testing.  By default, the 
     * notifications are posted to 
     * {@linkplain https://android.apis.google.com/c2dm/send}, as specified 
     * by the Google C2DM. 
     */ 
    public C2DMServiceBuilder withServiceUri(String serviceUri) {
        this.serviceUri = serviceUri;
        return this;
    }