Warning: file_get_contents(/data/phpspider/zhask/data//catemap/3/android/214.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
是否可以使用Android API使用自定义表单创建google帐户?_Android_Account_Accountmanager - Fatal编程技术网

是否可以使用Android API使用自定义表单创建google帐户?

是否可以使用Android API使用自定义表单创建google帐户?,android,account,accountmanager,Android,Account,Accountmanager,我正在为新固件开发欢迎应用程序。 此应用程序将在出厂重置后立即运行。 我想知道是否有办法为联系人和呼叫者同步创建一个google帐户(如果新用户还没有)。 我有SimpleSyncAdapter示例,我很难弄清楚如何将其与自定义活动表单一起使用,这将是教程/欢迎应用程序的一个步骤。在google示例中,AuthenticatorActivity启动一个AuthenticationService,该服务实例化身份验证类 身份验证类具有以下方法: public Bundle addAccount(A

我正在为新固件开发欢迎应用程序。 此应用程序将在出厂重置后立即运行。 我想知道是否有办法为联系人和呼叫者同步创建一个google帐户(如果新用户还没有)。 我有SimpleSyncAdapter示例,我很难弄清楚如何将其与自定义活动表单一起使用,这将是教程/欢迎应用程序的一个步骤。在google示例中,AuthenticatorActivity启动一个AuthenticationService,该服务实例化身份验证类

身份验证类具有以下方法:

public Bundle addAccount(AccountAuthenticatorResponse response, String accountType,
    String authTokenType, String[] requiredFeatures, Bundle options) {

    final Intent intent = new Intent(mContext, AuthenticatorActivity.class);
    intent.putExtra(AuthenticatorActivity.PARAM_AUTHTOKEN_TYPE, authTokenType);
    intent.putExtra(AccountManager.KEY_ACCOUNT_AUTHENTICATOR_RESPONSE, response);
    final Bundle bundle = new Bundle();
    bundle.putParcelable(AccountManager.KEY_INTENT, intent);
    return bundle;
}
但我无法在AccountActivity中实例化扩展AbstractAccountAuthenticator的身份验证类。另外,我不确定这是否对我有帮助。我不清楚这种方法的作用

有人能解释一下吗


谢谢大家!

查看此网页:

查看此网页:

是的,您不能创建普通的@gmail.com电子邮件,可能也是为了防止垃圾邮件。因此。。。我需要有一个谷歌Aps专业或教育帐户为该项目,以创建自定义的谷歌帐户创建和认证屏幕?有一个谷歌应用程序的免费版本,但是,它限制为50个用户(如果im正确),只要看看这里:真的,你不能创建正常的@gmail.com电子邮件,可能也是为了防止垃圾邮件。所以。。。我需要有一个谷歌Aps专业或教育帐户为该项目,以创建自定义谷歌帐户创建和认证屏幕?有一个谷歌应用程序的免费版本,但是,它限制为50个用户(如果im正确),只需看看这里: