com.google.sitebricks.client.CommonsWeb Maven / Gradle / Ivy
package com.google.sitebricks.client;
import com.google.inject.Inject;
import com.google.inject.Provider;
import net.jcip.annotations.Immutable;
import java.util.Map;
/**
* @author Dhanji R. Prasanna ([email protected])
*/
@Immutable
class CommonsWeb implements Web {
private final Provider builder;
@Inject
public CommonsWeb(Provider builder) {
this.builder = builder;
}
public FormatBuilder clientOf(String url) {
return builder.get().clientOf(url, null);
}
public FormatBuilder clientOf(String url, Map headers) {
return builder.get().clientOf(url, headers);
}
}