Class Platform2

  • public final class Platform2
    extends Object
    This class provides basic information about the Clover device on which the app is currently running.

    This class is a replacement for the com.clover.sdk.util.Platform class. The previous class required applications to be recompiled with the latest version for each new device release. This class will function properly on future devices. In some cases this class may be a near drop-in replacement for the old Platform class.

    Some features have been removed compared to the previous class. In particular the Feature.BATTERY was unclear since devices such as Station 2018 which can function for a limited time on battery power but lack certain abilities such as ethernet and printing when running on battery.

    It is recommended you read for more information about developing compatible apps. However please be aware that Clover devices are technically not "Android Compatible" since they are not CTS qualified; though we strive to make them as compatible as possible. Clover devices do not have the Google Play Store, Google APIs or Google services.

    Here are some additional links that may help when developing compatible apps:

    • Method Detail

      • isClover

        public static boolean isClover()
        Returns true when running on Clover hardware.
      • supportsFeature

        public static boolean supportsFeature​(Context context,
                                              Platform2.Feature f)
        Return true if the specified feature is supported on this device.
      • defaultOrientation

        public static Platform2.Orientation defaultOrientation​(Context context)
        Get the default orientation under which this device is normally used. This method does not return the current orientation!