MetaData class abstract

The object containing information about the Nevis Mobile Authentication SDK.

Usage example:

  import 'dart:io' show Platform;

  Future<String> sdkVersion() async {
    Version? version;
    if (Platform.isIOS) {
      final metaData = await MetaData.iosMetaData;
      version = metaData?.mobileAuthenticationVersion;
    } else if (Platform.isAndroid) {
      final metaData = await MetaData.androidMetaData;
      version = metaData?.mobileAuthenticationVersion;
    }

    return version?.formatted() ?? "Unknown";
  }

  extension VersionExtension on Version {
    String formatted() {
      return "Nevis Mobile Authentication SDK $major.$minor.$patch.$buildNumber";
    }
  }

Constructors

MetaData()

Properties

hashCode int
The hash code for this object.
no setterinherited
runtimeType Type
A representation of the runtime type of the object.
no setterinherited

Methods

noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toString() String
A string representation of this object.
inherited

Operators

operator ==(Object other) bool
The equality operator.
inherited

Static Properties

androidMetaData Future<AndroidMetaData?>
The object containing information about Nevis Mobile Authentication SDK for Android.
no setter
iosMetaData Future<IosMetaData?>
The object containing information about Nevis Mobile Authentication SDK for iOS.
no setter