1

我一直在阅读 BBM SDK 示例和开发指南。对于使用 BBM 平台服务的应用程序,它应该首先注册(这是对 RIM 服务器的调用以请求访问):

BBMPlatformManager.register(BBMPlatformApplication)

的实例BBMPlatformApplication作为参数传递。在示例中,创建了一个实例,将 UUID 字符串参数传递给构造函数:

    /**
     * An UUID is used to uniquely identify the application in the test environment
     * before the application is available in AppWorld. If the application exists in
     * AppWorld, the UUID will not be used to identify the application.
     *
     * To run this app, you should generate a different UUID, because there is a
     * limit to the number of users who can share the same UUID.
     * Search for "UUID Generator" on the web for instructions to generate a UUID.
     *
     * For instance, browse to:
     *     http://www.uuidgenerator.com/
     * and copy a UUID in the 8-4-4-4-12 format on the left side of the page.
     */
    private static final String UUID = "";


    /**
     * BBMPlatformApplication serves to provide certain properties of the application
     * to the BBM Social Platform. It is used as a parameter inBBMPlatformManager.register().
     *
     * If your application wants to be invoked in a non-default way, e.g. when
     * you have multiple entry points, you need to subclass from BBMPlatformApplication
     * and override certain methods.
     */
    private final BBMPlatformApplication _bbmApp = new BBMPlatformApplication(UUID);

阅读评论,似乎只有在为“测试环境”编译时才需要 UUID(我猜这意味着并发用户数量有限)。但是,它没有解释如何为将要在 App World 中发布的应用程序实例化该类。

在线开发指南示例中,BBMPlatformApplication被扩展,并再次在构造函数中将 UUID 传递给 super:

private class MyBBMAppPlugin extends BBMPlatformApplication
{
    public MyBBMAppPlugin()
    {
        super( "Insert your UUID here" );
    }
}

App World 环境是否需要 UUID?如果有,提交应用后如何获取?

谢谢。

4

1 回答 1

2

UUID 用于唯一标识测试/预生产环境中的应用程序。将应用程序上传到 BlackBerry App World 后,将不再使用它。更改 UUID 可以让您在彼此隔离的情况下执行应用程序测试。

此信息来自http://devblog.blackberry.com/2012/05/bbm-uuid/

于 2012-08-10T10:13:53.863 回答