Resources | developer.brewmp.com Resources | developer.brewmp.com

Developer

resources

Unique IDs (UID)

In Brew MP, a unique ID is a 32-bit globally unique unsigned integer. The unique ID is stored either in a Brew MP ID (BID) file or an .idl/.h file depending on the ID type, as follows:

  • ClassID - its friendly name starts with AEECLSID. ClassIDs are used to identify three types of classes:
    • An applet class (also known as an Applet ID), which is stored in the BID file for the application.
    • An in-process class (a non-applet class that services the caller's request in the caller's process), which is stored in the .idl/.h file for the extension.
    • A service class (a Service ID), which is stored in the .idl/.h file for the service.

    The ClassID is declared through a #define statement matching it to a ClassID name used in application startup, as shown below.

    #define AEECLSID_FILEMGR 0x01001003

  • Interface ID - its friendly name starts with AEEIID and it is used to uniquely identify an interface. An interface ID is stored in .idl/.h file for the interface. For example:
    #define AEEIID_IHFont 0x0102ef8e
  • Privilege ID - its friendly name starts with AEEPRIVID. It is defined in the .h/idl file and uniquely identifies a privilege to access a resource or a group of resources. A Group ID is a legacy concept from BREW that is essentially the same as a privilege. A privilege ID is defined as follows:
     #define AEEPRIVID_DISPSETTINGS 0x0103081d

All production Brew MP applications require a ClassID. These 32-bit hexadecimal numbers are provided by the ClassID Generator available on the http://developer.brewmp.com. The ClassID Generator provides a Brew MP ClassID (BID) file containing the ClassID. For an in-process or service class, copy the ClassID to the .h/idl file for the class.

Trial IDs (local IDs) can be generated locally via the Resource Manager for use with the Brew MP Simulator. The local IDs must be changed to commercially-generated IDs using the ClassID Generator prior to testing the application on a device.

The icon that the user selects to start an application is associated with the application's ClassID (the applet ID) and is contained in the MIF. When the application is installed, its ClassID is registered with Brew MP at runtime and the icon is displayed by the application manager. When the user selects the icon from the Simulator or the device, the runtime environment matches the ClassID from the MIF to the containing application module, then loads the module and starts the applet with the assigned the ClassID. A similar process takes place with external dependencies, such as when an application calls an extension or another application.