本文整理汇总了Java中com.github.obsessive.simplifyreader.api.ApiConstants类的典型用法代码示例。如果您正苦于以下问题:Java ApiConstants类的具体用法?Java ApiConstants怎么用?Java ApiConstants使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。
ApiConstants类属于com.github.obsessive.simplifyreader.api包,在下文中一共展示了ApiConstants类的6个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。
示例1: getVideosListUrl
import com.github.obsessive.simplifyreader.api.ApiConstants; //导入依赖的package包/类
public String getVideosListUrl(String category, int pageNum) {
StringBuffer sb = new StringBuffer();
sb.append(ApiConstants.Urls.YOUKU_VIDEOS_URLS);
sb.append("?keyword=");
try {
sb.append(URLEncoder.encode(category, "UTF-8"));
} catch (UnsupportedEncodingException e) {
e.printStackTrace();
}
sb.append("&page=");
sb.append(pageNum);
sb.append("&count=");
sb.append(PAGE_LIMIT);
sb.append("&public_type=all&paid=0&period=today&orderby=published&client_id=6ecd6970268b4c53");
return sb.toString().trim();
}
示例2: onFirstUserVisible
import com.github.obsessive.simplifyreader.api.ApiConstants; //导入依赖的package包/类
@Override
protected void onFirstUserVisible() {
mCurrentPage = 0;
mImagesListPresenter = new ImagesListPresenterImpl(mContext, this);
if (NetUtils.isNetworkConnected(mContext)) {
if (null != mSwipeRefreshLayout) {
mSwipeRefreshLayout.postDelayed(new Runnable() {
@Override
public void run() {
mImagesListPresenter.loadListData(TAG_LOG, Constants.EVENT_REFRESH_DATA, mCurrentImagesCategory,
mCurrentPage, false);
}
}, ApiConstants.Integers.PAGE_LAZY_LOAD_DELAY_TIME_MS);
}
} else {
toggleNetworkError(true, new View.OnClickListener() {
@Override
public void onClick(View v) {
mImagesListPresenter.loadListData(TAG_LOG, Constants.EVENT_REFRESH_DATA, mCurrentImagesCategory,
mCurrentPage, false);
}
});
}
}
示例3: onFirstUserVisible
import com.github.obsessive.simplifyreader.api.ApiConstants; //导入依赖的package包/类
@Override
protected void onFirstUserVisible() {
mCurrentPage = 1;
mVideosListPresenter = new VideosListPresenterImpl(mContext, this);
if (NetUtils.isNetworkConnected(mContext)) {
if (null != mSwipeRefreshLayout) {
mSwipeRefreshLayout.postDelayed(new Runnable() {
@Override
public void run() {
mVideosListPresenter.loadListData(TAG_LOG, Constants.EVENT_REFRESH_DATA, mCurrentVideosCategory,
mCurrentPage, false);
}
}, ApiConstants.Integers.PAGE_LAZY_LOAD_DELAY_TIME_MS);
}
} else {
toggleNetworkError(true, new View.OnClickListener() {
@Override
public void onClick(View v) {
mVideosListPresenter.loadListData(TAG_LOG, Constants.EVENT_REFRESH_DATA, mCurrentVideosCategory,
mCurrentPage, false);
}
});
}
}
示例4: getVideoUserUrl
import com.github.obsessive.simplifyreader.api.ApiConstants; //导入依赖的package包/类
public String getVideoUserUrl(int userId) {
StringBuffer sb = new StringBuffer();
sb.append(ApiConstants.Urls.YOUKU_USER_URLS);
sb.append("?user_id=");
sb.append(userId);
sb.append("&client_id=6ecd6970268b4c53");
return sb.toString().trim();
}
示例5: getDoubanPlayListUrl
import com.github.obsessive.simplifyreader.api.ApiConstants; //导入依赖的package包/类
public String getDoubanPlayListUrl(String channelId) {
StringBuffer sb = new StringBuffer();
sb.append(ApiConstants.Urls.DOUBAN_PLAY_LIST_URLS);
sb.append("?channel=");
sb.append(channelId);
sb.append("&app_name=radio_android&version=100&type=&sid=0");
return sb.toString().trim();
}
示例6: onCreate
import com.github.obsessive.simplifyreader.api.ApiConstants; //导入依赖的package包/类
@Override
public void onCreate() {
super.onCreate();
MobclickAgent.setDebugMode(true);
MobclickAgent.updateOnlineConfig(this);
MobclickAgent.openActivityDurationTrack(false);
UmengUpdateAgent.update(this);
VolleyHelper.getInstance().init(this);
ImageLoader.getInstance().init(ImageLoaderHelper.getInstance(this).getImageLoaderConfiguration(ApiConstants.Paths.IMAGE_LOADER_CACHE_PATH));
}