public THttpRequest createUserShow() { List<NameValuePair> list = new LinkedList<NameValuePair>(); // list.add(new BasicNameValuePair("access_token", mChannel.getAccessToken())); THttpRequest request = new THttpRequest( mChannel.getUserShowUrl() + "?" + URLEncodedUtils.format(list, "utf-8"), THttpMethod.GET); request.addHeader("Authorization", "OAuth2 " + mChannel.getAccessToken()); return request; }
public boolean shouldNotify() { if (mParentRequest != null) { return mParentRequest.shouldNotify(); } return mNotified.compareAndSet(true, false); }
public HttpCache getHttpCache() { if (mParentRequest != null) { return mParentRequest.getHttpCache(); } return mHttpCache; }
public StoreTmpFileInfo getStoreTmpFileInfo() { if (mParentRequest != null) { return mParentRequest.getStoreTmpFileInfo(); } return mStoreTmpFileInfo; }
public THttpRequest requestNextRequest(int defaultSize) { if (mParentRequest != null) { return mParentRequest.requestNextRequest(defaultSize); } THttpRequest request = null; if (mStoreTmpFileInfo != null) { long[] seeks = mStoreTmpFileInfo.requestNextFragement(defaultSize); if (seeks != null) { request = new THttpRequest(this); request.mRangeStart = seeks[0]; request.mRangeEnd = seeks[1]; } } return request; }
public NioListener getNioListener() { if (mParentRequest != null) { return mParentRequest.getNioListener(); } return mNioListener; }
public boolean isCacheDatabase() { if (mParentRequest != null) { return mParentRequest.isCacheDatabase(); } return isState(STATE_CACHE_DATABASE); }
public boolean isCacheFile() { if (mParentRequest != null) { return mParentRequest.isCacheFile(); } return isState(STATE_CACHE_FILE); }
public boolean isCancel() { return mParentRequest == null ? isState(STATE_CANCELED) : mParentRequest.isCancel(); }