BlackBerry

These changes are required for BlackBerry applications.

Application Changes Required for 2.1 ESD #3

There are no additional application changes required for 2.1 ESD #3. See Developer Guide: BlackBerry Object API Applications for information on developing your application.

Application Changes Required for 2.1 ESD #2

Update and rebuild your application:

  1. The Application APIs (in the Application class) are required for managing application registrations, connections, and context. Rewrite the initialization code in your application to use the Application APIs.

    For information on the Application interface, search for Application APIs in the Developer Guide for your platform.

  2. Callbacks related to application events are contained in a separate ApplicationCallback interface. Rewrite your application code to use this interface.

    For information on the ApplicationCallback interface, search for Callback and Listener APIs in the Developer Guide for your platform.

  3. Replication-based synchronization clients require two data channels: a data channel for data synchronization, and a messaging channel for sending registration and push notifications to the client. Update your port configuration for both channels. See Sybase Control Center for Sybase Unwired Platform > Administer > Unwired Server > Server Properties.
  4. To continue using server-initiated synchronization, you must write code for handling notifications. If change notifications are enabled for synchronization groups, you can implement the onSynchronize callback method to monitor this condition, and either allow or disallow default background synchronization.
    public int onSynchronize(ObjectList groups, SynchronizationContext context)
    {
      int status = context.getStatus();
      if (status == SynchronizationStatus.STARTING_ON_NOTIFICATION)
      {
        // There is changes on the synchronization group
        if (busy)
        {
          return SynchronizationAction.CANCEL;
        }
        else
        {
          return SynchronizationAction.CONTINUE;
        }
      }
    
      // return CONTINUE for all other status
      return SynchronizationAction.CONTINUE;
    }
  5. The new location of the required libraries is <UnwiredPlatform_InstallDir>\UnwiredPlatform\MobileSDK\ObjectAPI\BB.

    Rebuild your project as follows:

    1. Modify the BlackBerry project's Java build path to point to the new location for your project.
    2. Replace the old libraries, sup_client_rim.jar and UltraLiteJ.jar, with these new references:
      • sup_client2.jar – from <UnwiredPlatform_InstallDir>\MobileSDK\ObjectAPI\BB.
      • UltraLiteJ1.jar – from <UnwiredPlatform_InstallDir>\MobileSDK\ObjectAPI\BB.
    3. In Windows Explorer, copy the new required files into the BlackBerry simulator directory:
      • CommonClientLib.cod – from <UnwiredPlatform_InstallDir>\MobileSDK\ObjectAPI\BB.
      • MessagingClientLib.cod – from <UnwiredPlatform_InstallDir>\MobileSDK\ObjectAPI\BB.
      • MocaClientLib.cod.cod – from <UnwiredPlatform_InstallDir>\MobileSDK\ObjectAPI\BB.
      • sup_client2.cod.cod – from <UnwiredPlatform_InstallDir>\MobileSDK\ObjectAPI\BB.
      • UltraLiteJ12.cod – from <UnwiredPlatform_InstallDir>\MobileSDK\ObjectAPI\BB.
    4. Delete the old CommonClient.cod, sup_client_rim.cod, and UltraLiteJ.cod files.