android.location.Address
withのインスタンスIntent
を別のアクティビティに配置することは可能ですか?
Address current_location;
つまり、意図を持って current_location を直接配置しようとしています。
IntentName.putExtra("current_location",current_location);
またはバンドルによって間接的に:
Bundle b = new Bundle(); b.put....("current_location",current_location); IntentName.put(b);
上記の戦略のいずれも「Address」をサポートしていない場合、Address インスタンスを別のアクティビティに渡すための最良の方法は何ですか? 私が宣言するならば、
public static Address current_location;
別のアクティビティからアクセスしようとすると、Android が current_location データを保持するという保証はありません。それとも私が間違っていますか?
このような状況では、どのようなアプローチを取るべきでしょうか?