Assuming you're using the android-async-http
library then PersistentCookieStore
is persistent so it stores any Cookies you add to it in Shared Preferences. This means if you create instances of it in different Activities they will all have access to the same cookies.
In other words, if you write cookies to an instance of PersistentCookieStore
in Login.java
they will be available to a different instance of PersistentCookieStore
in MainActivity.java
.