在Android的应用程序之间的导航 [英] Navigate between applications at android

查看:138
本文介绍了在Android的应用程序之间的导航的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我有4个不同的应用程序。
一个是登录和其他三个应用程序,会去登录,如果没有授权。
登录应用程序应该从其他应用获取包名称。根据收到的名称,它将再次重新启动应用程序。我不知道我该怎么做。

I am having 4 different applications. One is a login and other three are apps that will go to login if not authorized. Login app should get the package name from the other apps. According to the name received, it should again relaunch the application. I've no idea how can I do it.

推荐答案

我认为你需要做以下的东西。

I think you need to do following stuff.

App1的::验证用户

App2的任何::应​​用

程序App3 ::任何应用


  1. 为应用程序的授权设计内容提供商。内容提供者将程序App1的一个组成部分。

  2. 其他应用程序将查询内容提供商知道APP2 / APP3的用户是否被授权或不?

  3. 如果没有,那么应用程序将触发一个意图作为startActivityForResult对APP代表其他应用程序进行登录操作。我们需要发送用户凭据,包名等的意图。

  4. 我们需要定义在startActivityForResult登录操作即适当的请求和响应codeS。

  5. App1的存储用户身份验证数据对每包(即应用)

  6. 我们需要照顾这里主要的是应该何时刷新App1的是存储反目package.This主要取决于你的需求的用户身份验证数据。

您可能需要添加更多的用例按照你的要求。

You might need to add some more use cases as per you requirements.

这篇关于在Android的应用程序之间的导航的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆