本文整理匯總了Java中android.os.Bundle.EMPTY屬性的典型用法代碼示例。如果您正苦於以下問題:Java Bundle.EMPTY屬性的具體用法?Java Bundle.EMPTY怎麽用?Java Bundle.EMPTY使用的例子?那麽, 這裏精選的屬性代碼示例或許可以為您提供幫助。您也可以進一步了解該屬性所在類android.os.Bundle
的用法示例。
在下文中一共展示了Bundle.EMPTY屬性的6個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的Java代碼示例。
示例1: mapToBundle
@NonNull
@CheckResult
static Bundle mapToBundle(@NonNull Map<String, String> map) {
final int mapSize = map.size();
if (mapSize == 0) {
return Bundle.EMPTY;
}
final Bundle bundle = new Bundle(mapSize);
for (String key : map.keySet()) {
bundle.putString(key, map.get(key));
}
return bundle;
}
示例2: AuthorizationManager
/**
* Create a new Auth Manager based on the supplied product id
*
* This will throw an error if our assets/api_key.txt file, our package name, and our signing key don't match the product ID, this is
* a common sticking point for the application not working
* @param context
* @param productId
*/
public AuthorizationManager(@NotNull Context context, @NotNull String productId){
mContext = context;
mProductId = productId;
try {
mAuthManager = new AmazonAuthorizationManager(mContext, Bundle.EMPTY);
}catch(IllegalArgumentException e){
//This error will be thrown if the main project doesn't have the assets/api_key.txt file in it--this contains the security credentials from Amazon
Util.showAuthToast(mContext, "APIKey is incorrect or does not exist.");
Log.e(TAG, "Unable to Use Amazon Authorization Manager. APIKey is incorrect or does not exist. Does assets/api_key.txt exist in the main application?", e);
}
}
開發者ID:vaibhavs4424,項目名稱:AI-Powered-Intelligent-Banking-Platform,代碼行數:20,代碼來源:AuthorizationManager.java
示例3: e
public static Bundle e(Context context) {
ApplicationInfo b = b(context);
return (b == null || b.metaData == null) ? Bundle.EMPTY : b.metaData;
}
示例4: onReceiver
public Bundle onReceiver(Bundle bundle){
return Bundle.EMPTY;
}
示例5: handle
@Override
public Bundle handle(Bundle bundle) {
Parcel data = Parcel.obtain();
Parcel reply = Parcel.obtain();
data.writeBundle(bundle);
try {
mRemoteCallback.transact(ServiceContext.CALLBACK, data, reply, 0);
Bundle result = reply.readBundle();
return result;
} catch (RemoteException e) {
e.printStackTrace();
} finally {
data.recycle();
reply.recycle();
}
return Bundle.EMPTY;
}
示例6: ScrapeDetailResult
public ScrapeDetailResult(BaseTags tag, boolean isMovie, Bundle extras, ScrapeStatus status, Throwable reason) {
super(checkStatus(tag, status), reason);
this.tag = tag;
this.isMovie = isMovie;
this.extras = extras != null ? extras : Bundle.EMPTY;
}