Java Code Examples for com.sina.weibo.sdk.utils.Utility#parseUrl()
The following examples show how to use
com.sina.weibo.sdk.utils.Utility#parseUrl() .
You can vote up the ones you like or vote down the ones you don't like,
and go to the original project or source file by following the links above each example. You may check out the related API usage on the sidebar.
Example 1
Source File: WeiboDialog.java From MiBandDecompiled with Apache License 2.0 | 6 votes |
private void handleRedirectUrl(String s) { Bundle bundle = Utility.parseUrl(s); String s1 = bundle.getString("error"); String s2 = bundle.getString("error_code"); String s3 = bundle.getString("error_description"); if (s1 == null && s2 == null) { mListener.onComplete(bundle); return; } else { mListener.onWeiboException(new WeiboAuthException(s2, s1, s3)); return; } }
Example 2
Source File: AuthWeiboWebViewClient.java From letv with Apache License 2.0 | 5 votes |
private void handleRedirectUrl(String url) { Bundle values = Utility.parseUrl(url); String errorType = values.getString(NativeProtocol.BRIDGE_ARG_ERROR_BUNDLE); String errorCode = values.getString(NativeProtocol.BRIDGE_ARG_ERROR_CODE); String errorDescription = values.getString(NativeProtocol.BRIDGE_ARG_ERROR_DESCRIPTION); if (errorType == null && errorCode == null) { if (this.mListener != null) { this.mListener.onComplete(values); } } else if (this.mListener != null) { this.mListener.onWeiboException(new WeiboAuthException(errorCode, errorType, errorDescription)); } }