com.avaya.deskphoneservices

## Class DeskPhoneServiceLibrary

- java.lang.Object
- - com.avaya.deskphoneservices.DeskPhoneServiceLibrary

-     public final class DeskPhoneServiceLibrary
      extends java.lang.Object

- - ### Method Summary

    All Methods Static Methods Concrete Methods
    Modifier and Type | Method and Description
    --- | ---
    `static DeskPhoneService` | `getDeskPhoneService()`
    `static java.lang.String` | `getDeskPhoneServicesVersion()` Get the version of DeskPhoneServices
    `static java.lang.String` | `getDetailedBuildID()` Get the details of when and where this version of the library was built.
    `static DeskPhoneService` | `initialize(android.content.Context context, DeskPhoneEventListener listener, com.avaya.clientservices.client.Client client, FeatureControl featureControl)` Initializes the DeskPhone Services library and its dependencies.
    `static void` | `setLogListener(com.avaya.clientservices.client.Client.LogListener listener)` Set an object to receive logs generated by the deskphone services library.

    - ### Methods inherited from class java.lang.Object

      `equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

- - ### Method Detail

    - #### initialize

          @Nullable
          public static DeskPhoneService initialize(android.content.Context context,
                                                              DeskPhoneEventListener listener,
                                                              com.avaya.clientservices.client.Client client,
                                                              @Nullable
                                                              FeatureControl featureControl)
                                                       throws InvalidPlatformException,
                                                              java.lang.IllegalStateException

      Initializes the DeskPhone Services library and its dependencies.

      Application should first create `Client` instance and then initialize DeskPhone services. Applications to initialize DeskPhone services from Android application's onCreate()

      Parameters:
        `context` - Android application context
        `listener` - Application's implementation of DeskPhoneEventListener
        `client` - Client SDK's `Client`
        `featureControl` - Override the aura feature's auto processing at application layer. Disabling the feature parameter in featureControl turns off auto processing for respective feature in DeskPhone services.
      Returns:
        `DeskPhoneServiceImpl` instance.
      Throws:
        `InvalidPlatformException` - If running on non desk phone platform
        `java.lang.NullPointerException` - If essential parameters are missing
        `java.lang.IllegalStateException` - If called after DeskPhone Services were already initialized
      See Also:
        `FeatureControl`

    - #### setLogListener

          public static void setLogListener(@Nullable
                                            com.avaya.clientservices.client.Client.LogListener listener)

      Set an object to receive logs generated by the deskphone services library.

      This is the same interface as used by Client Services in `Client.setLogListener(LogListener)`, so you can use the same object for handling logs from both packages.

      Parameters:
        `listener` - The new log listener. If set to `null`, deskphone services logs will resume going only to Android's logcat.

    - #### getDeskPhoneServicesVersion

          @NonNull
          public static java.lang.String getDeskPhoneServicesVersion()

      Get the version of DeskPhoneServices
      Returns:
        DeskPhoneServices version string.

    - #### getDetailedBuildID

          @NonNull
          public static java.lang.String getDetailedBuildID()

      Get the details of when and where this version of the library was built.
      Returns:
        The build ID details string.

    - #### getDeskPhoneService

          @Nullable
          public static DeskPhoneService getDeskPhoneService()