org.wso2.carbon.device.mgt.mobile.windows.api.common.util

## Class DeviceUtil

- java.lang.Object
- - org.wso2.carbon.device.mgt.mobile.windows.api.common.util.DeviceUtil

-     public class DeviceUtil
      extends Object

  Class for generate random token for XCEP and WSTEP.

- - ### Constructor Summary

    Constructors
    Constructor and Description
    `DeviceUtil()`

  - ### Method Summary

    Methods
    Modifier and Type | Method and Description
    --- | ---
    `static String` | `generateRandomToken()`
    `static org.wso2.carbon.device.mgt.mobile.windows.impl.dto.MobileCacheEntry` | `getTokenEntry(String token)`
    `static org.wso2.carbon.device.mgt.mobile.windows.impl.dto.MobileCacheEntry` | `getTokenEntryFromDeviceId(String deviceId)`
    `static void` | `persistChallengeToken(String token, String deviceID, String username)`
    `static void` | `removeTokenEntry(String token)`

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

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

- - ### Constructor Detail

    - #### DeviceUtil

          public DeviceUtil()

  - ### Method Detail

    - #### generateRandomToken

          public static String generateRandomToken()

    - #### persistChallengeToken

          public static void persistChallengeToken(String token,
                                   String deviceID,
                                   String username)
                                            throws WindowsDeviceEnrolmentException

      Throws:
        `WindowsDeviceEnrolmentException`

    - #### getTokenEntry

          public static org.wso2.carbon.device.mgt.mobile.windows.impl.dto.MobileCacheEntry getTokenEntry(String token)
                                                                                                   throws WindowsDeviceEnrolmentException

      Throws:
        `WindowsDeviceEnrolmentException`

    - #### getTokenEntryFromDeviceId

          public static org.wso2.carbon.device.mgt.mobile.windows.impl.dto.MobileCacheEntry getTokenEntryFromDeviceId(String deviceId)
                                                                                                               throws WindowsDeviceEnrolmentException

      Throws:
        `WindowsDeviceEnrolmentException`

    - #### removeTokenEntry

          public static void removeTokenEntry(String token)

Copyright © 2017 WSO2. All rights reserved.