package com.ea.nimble; import com.ea.nimble.IHttpRequest; import com.ea.nimble.Log; import java.io.ByteArrayOutputStream; import java.net.URL; import java.util.HashMap; /* loaded from: classes2.dex */ public class HttpRequest implements IHttpRequest { private static int DEFAULT_NETWORK_TIMEOUT = 30; public ByteArrayOutputStream data; public HashMap headers; public IHttpRequest.Method method; public boolean runInBackground; public String targetFilePath; public double timeout; public URL url; public HttpRequest() { this.url = null; this.method = IHttpRequest.Method.GET; this.data = new ByteArrayOutputStream(); this.headers = new HashMap<>(); this.timeout = DEFAULT_NETWORK_TIMEOUT; this.targetFilePath = null; } public HttpRequest(URL url) { this(); this.url = url; } @Override // com.ea.nimble.IHttpRequest public URL getUrl() { Log.Helper.LOGPUBLICFUNC(this); return this.url; } @Override // com.ea.nimble.IHttpRequest public IHttpRequest.Method getMethod() { Log.Helper.LOGPUBLICFUNC(this); return this.method; } @Override // com.ea.nimble.IHttpRequest public byte[] getData() { Log.Helper.LOGPUBLICFUNC(this); return this.data.toByteArray(); } @Override // com.ea.nimble.IHttpRequest public HashMap getHeaders() { Log.Helper.LOGPUBLICFUNC(this); return this.headers; } @Override // com.ea.nimble.IHttpRequest public double getTimeout() { Log.Helper.LOGPUBLICFUNC(this); return this.timeout; } @Override // com.ea.nimble.IHttpRequest public String getTargetFilePath() { Log.Helper.LOGPUBLICFUNC(this); return this.targetFilePath; } @Override // com.ea.nimble.IHttpRequest public boolean getRunInBackground() { Log.Helper.LOGPUBLICFUNC(this); return this.runInBackground; } }