BlackBerry Dynamics for .NET Maui  12.1.1.5
Runtime library for .NET Maui applications
BBDXamarinForms.Common.Interfaces.AppKinetics.IBBDService Interface Reference

This interface is mandatory for service provider applications within the AppKinetics system. It also includes the programming interface for sending AppKinetics service responses. To utilize this programming interface, the application must meet the requirements listed under Service Provider Requirements. The functions in this interface cannot be used until BlackBerry Dynamics authorization processing is complete. More...

Public Member Functions

void BringToFront (string application)
 Bring another application to the foreground. More...
 
Task BringToFrontAsync (string application)
 Bring another application to the foreground. More...
 
void ReplyTo (string application, object parameters, BBDICCForegroundOptions option, IBBDFileEntry[] attachments, string requestId)
 Sends a response or error message. More...
 

Events

EventHandler< MessageSentEventArgsMessageSent
 
EventHandler< ReceiveMessageEventArgsReceiveMessage
 
EventHandler< ServiceReceiveAttachmentsEventArgsServiceReceiveAttachments
 
EventHandler< ServiceReceiveAttachmentFileEventArgsServiceReceiveAttachmentFile
 

Detailed Description

This interface is mandatory for service provider applications within the AppKinetics system. It also includes the programming interface for sending AppKinetics service responses. To utilize this programming interface, the application must meet the requirements listed under Service Provider Requirements. The functions in this interface cannot be used until BlackBerry Dynamics authorization processing is complete.

Service Provider Requirements

To function as an AppKinetics service provider, a BlackBerry Dynamics application must:

  • Instantiate a single object of the IBBDService.
  • Register the AppKinetics URL type on the device. This will normally be achieved by utilizing the mandatory BlackBerry Dynamics build-time configuration.

Note that an application that provides multiple services still instantiates only a single object of this class. Events of the object handle requests for all the services that the application provides.

Member Function Documentation

◆ BringToFront()

void BBDXamarinForms.Common.Interfaces.AppKinetics.IBBDService.BringToFront ( string  application)

Bring another application to the foreground.

Deprecated:
This method is deprecated and will be removed in a future release. Use BringToFrontAsync instead.

Call this function to bring another application to the foreground. This could be used when the application is a service provider, to bring the service consumer back to the foreground without sending a response.

This function cannot be used outside the context of service request processing.

Parameters
applicationString containing the native application identifier of the application to be brought to the foreground.
Exceptions
Errors.BBDServiceExceptionThrown when the specified application wasn't brought to the foreground, based on the return code from the native layer.

◆ BringToFrontAsync()

Task BBDXamarinForms.Common.Interfaces.AppKinetics.IBBDService.BringToFrontAsync ( string  application)

Bring another application to the foreground.

Call this function to bring another application to the foreground. This could be used when the application is a service provider, to bring the service consumer back to the foreground without sending a response.

This function cannot be used outside the context of service request processing.

Parameters
applicationString containing the native application identifier of the application to be brought to the foreground.
Exceptions
Errors.BBDServiceExceptionThrown when the specified application wasn't brought to the foreground, based on the return code from the native layer.

◆ ReplyTo()

void BBDXamarinForms.Common.Interfaces.AppKinetics.IBBDService.ReplyTo ( string  application,
object  parameters,
BBDICCForegroundOptions  option,
IBBDFileEntry[]  attachments,
string  requestId 
)

Sends a response or error message.

The response can include a results object and file attachments to be conveyed to the consumer application. The results object will notify the consumer of the success or failure of the request.

Parameters
applicationString containing the native application idenitifer of the consumer, as supplied in the original service request.
parametersObject for the results object.
optionBBDICCForegroundOptions specifying the foreground execution preference after delivery of the response.
attachmentsArray of IBBDFileEntry objects containing the referemces to the files in the BlackBerry Dynamics secure file system that are to be attached to the response.
requestIdString containing the identifier of the service request to which this is a response.
Exceptions
Errors.BBDServiceExceptionThrown when the response isn't accepted by the AppKinetics system.

Event Documentation

◆ MessageSent

EventHandler<MessageSentEventArgs> BBDXamarinForms.Common.Interfaces.AppKinetics.IBBDService.MessageSent

This event occurs whenever the delivery of an AppKinetics service response completes.

This event notifies the application that:

  • Any files that were attached to the service response have been copied to the secure store of the service consumer.
  • An independent copy of the parameters of the response, if any, has been made available to the service consumer.

The method that is invoked can delete or modify any of the original file attachments, and free any resources used to hold the response parameters.

◆ ReceiveMessage

EventHandler<ReceiveMessageEventArgs> BBDXamarinForms.Common.Interfaces.AppKinetics.IBBDService.ReceiveMessage

Occurs when a service request is sent to the application within the AppKinetics system. The parameters give the details of the service request.

When this event is invoked, the application must:

  1. Check that the service request is valid.
  2. Process the request, if valid.
  3. If required by the service definition or other published interface, respond to the request with a success or failure result by calling the ReplyTo method.

If the application determines that a service request is invalid then the application should return an error in the ReplyTo call. For some check failures, the application must set a particular code in the returned error.

◆ ServiceReceiveAttachmentFile

EventHandler<ServiceReceiveAttachmentFileEventArgs> BBDXamarinForms.Common.Interfaces.AppKinetics.IBBDService.ServiceReceiveAttachmentFile

Occurs when an individual file attachment is about to be received through the AppKinetics system. The path and size of the file that is about to be received are passed as parameters.

This event will be invoked once per attachment.

◆ ServiceReceiveAttachments

EventHandler<ServiceReceiveAttachmentsEventArgs> BBDXamarinForms.Common.Interfaces.AppKinetics.IBBDService.ServiceReceiveAttachments

This event occurs when file attachments are about to be received through the AppKinetics system. The number of files that are about to be received is passed as a parameter.

Occurs once per service request that has attachments.

This event isn't invoked for service requests that have no attachments.