android - Shopify 客户登录

标签 android authentication shopify verification

我是 shopify 的新手 我正在 Android 应用程序中处理 shopify 的客户登录。 我想在登录之前检查用户的凭据。 那么有什么办法可以做到吗?

最佳答案

如果第一次登录用户名,密码存储在sharedprefrences中,则您使用了共享prefrences,下次检查从共享prefrences获取数据。

公共(public)类首选项{ 静态上下文 mContext;

public static void setPreferences(Context context, String key, String value) {
    mContext = context;
    SharedPreferences.Editor editor = mContext.getSharedPreferences(
            "ParkZap", Context.MODE_PRIVATE).edit();
    editor.putString(key, value);
    editor.commit();
}

public static String getPreferences(Context context, String key) {
    mContext = context;
    SharedPreferences prefs = mContext.getSharedPreferences("ParkZap",
            Context.MODE_PRIVATE);
    String position = prefs.getString(key, "");
    return position;
}

关于android - Shopify 客户登录,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/34489011/

相关文章:

javascript - 链接重定向协助

php - 订单/地址未使用 Shopify API 在 MySql 数据库上同步

android - Xamarin和Titanium Appcelerator?

Android Thread、AsyncTask 与从 BLE onCharacteristicChanged() 调用的 IntentService

wcf - (WCF)如何在我的服务中获取登录客户端的用户名?

authentication - 不记名 token 如何在 Web API 2 中的服务器端存储?

javascript - 跨页面传递信息

Android浏览器自动下载图片

android - 应用程序关闭时如何获取android通知?

java - Spring 安全。添加用户登录限制