本文整理汇总了Java中com.sina.weibo.sdk.api.share.SendMessageToWeiboResponse类的典型用法代码示例。如果您正苦于以下问题:Java SendMessageToWeiboResponse类的具体用法?Java SendMessageToWeiboResponse怎么用?Java SendMessageToWeiboResponse使用的例子?那么, 这里精选的类代码示例或许可以为您提供帮助。
SendMessageToWeiboResponse类属于com.sina.weibo.sdk.api.share包,在下文中一共展示了SendMessageToWeiboResponse类的1个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。
示例1: handleResult
import com.sina.weibo.sdk.api.share.SendMessageToWeiboResponse; //导入依赖的package包/类
@Override
public void handleResult(Intent intent) {
SendMessageToWeiboResponse baseResponse =
new SendMessageToWeiboResponse(intent.getExtras());
switch (baseResponse.errCode) {
case WBConstants.ErrorCode.ERR_OK:
ShareUtil.mShareListener.shareSuccess();
break;
case WBConstants.ErrorCode.ERR_FAIL:
ShareUtil.mShareListener.shareFailure(new Exception(baseResponse.errMsg));
break;
case WBConstants.ErrorCode.ERR_CANCEL:
ShareUtil.mShareListener.shareCancel();
break;
default:
ShareUtil.mShareListener.shareFailure(new Exception(baseResponse.errMsg));
}
}