Class AndroidSdkUtil

java.lang.Object
com.pnfsoftware.jeb.core.units.code.android.AndroidSdkUtil

public class AndroidSdkUtil extends Object
Utility routines to retrieve the Android SDK and Android NDK locations.
  • Field Details

    • legacySdkLocationVar

      public static final String legacySdkLocationVar
      See https://developer.android.com/tools/variables
      See Also:
    • currentSdkLocationVar

      public static final String currentSdkLocationVar
      See https://developer.android.com/tools/variables
      See Also:
  • Method Details

    • locateSDK

      public static File locateSDK(boolean cached) throws IOException
      Locate the Android SDK folder.
      Parameters:
      cached - true to reuse a previously located folder
      Returns:
      the SDK folder
      Throws:
      IOException - if the SDK folder cannot be located
    • listNDKFolders

      public static SortedMap<String,File> listNDKFolders(boolean cached) throws IOException
      List Android NDK folders available under the SDK.
      Parameters:
      cached - true to reuse a previously built list
      Returns:
      a sorted map of NDK versions to folders
      Throws:
      IOException - if the SDK folder cannot be located
    • locateBestNDK

      public static File locateBestNDK(boolean cached) throws IOException
      Locate the newest Android NDK folder available under the SDK.
      Parameters:
      cached - true to reuse a previously located folder
      Returns:
      the selected NDK folder
      Throws:
      IOException - if no NDK folder can be located