ios - Is it possible to ship an IOS app with different data on each app?
问题描述
I am creating an IOS app using swift. I am wondering if it is possible to add different data to each app that is downloaded.
Say I have an app on the App Store:
User 1 downloads the app and the array "fruits" is set to:
["banana", "apple", "orange"]
but if user 2 downloads the same app the array would be set differently:
["pineapple", "strawberry", "mango"]
and user 3
["blueberry", "peach", "watermelon"]
I know this is easily possibly by downloading the array of fruits, but I am looking to do this without connecting to the internet or exposing the entire list of fruits (e.g. having all of the fruits and then choosing them randomly)
解决方案
答案是——不,你不能。
应用商店上的应用就像一个盒子。每个用户都得到同一个盒子。但是,正如 Shantanu 所提到的,您可以显示一个随机子集。话虽如此,它并不能起到在被阻止的 URL 中找出工作 URL 的目的。如果您打算向用户显示可访问的 Url,那么您只需遍历主列表并检查哪些是可访问的。例如,如果您总共有 10 个网址,则首先 ping 以检查它是否可以访问。如果没有,则转到下一个。随机化可能无助于实现这一目标。
推荐阅读
- flutter - Flutter PageController AnimateToPage 破坏了应用程序
- c# - 有没有办法在 Blazor 中检查 url 是否有路由约束?
- python - C-FIND 研究按患者 ID 和日期
- python - 如何使用循环将元素附加到列表中?
- postgresql - 重用存储在 PostgreSQL 和 SSRS 中的参数时出错
- json - 如何在 Azure SQL 中生成 JSON 值数组
- html - 将图像向右对齐但不移动整个部分
- r - 有条件地删除数据框中的列?
- javascript - 如何将 javascript 文件/函数 API 正确导入 React.js 应用程序?
- bash - 使用 tar 压缩并验证,然后上传到 S3 并验证