@nevis-security/nevis-mobile-authentication-sdk-react
Version:
React Native plugin for Nevis Mobile Authentication SDK. Supports only mobile.
59 lines (54 loc) • 1.83 kB
JavaScript
Object.defineProperty(exports, "__esModule", {
value: true
});
exports.IOSMetaDataImpl = exports.IOSMetaData = void 0;
var _Version = require("./Version");
/**
* Copyright © 2024 Nevis Security AG. All rights reserved.
*/
/**
* The object containing information about the
* native iOS Nevis Mobile Authentication SDK.
*/
class IOSMetaData {
/**
* The current version of the Nevis Mobile Authentication SDK.
*/
/**
* The FacetId used by the Nevis Mobile Authentication SDK.
*/
/**
* Default constructor for {@link IOSMetaData}.
*
* @param mobileAuthenticationVersion the current version of the Nevis Mobile Authentication SDK.
* @param applicationFacetId the FacetId used by the Nevis Mobile Authentication SDK.
* @returns an {@link IOSMetaData} instance.
*/
static create(mobileAuthenticationVersion, applicationFacetId) {
return new IOSMetaDataImpl(mobileAuthenticationVersion, applicationFacetId);
}
/**
* Alternate constructor that creates a {@link IOSMetaData} from a json.
*
* @param json contains the source for instance creation.
* @returns a {@link IOSMetaData} instance.
*/
static fromJson(json) {
return IOSMetaDataImpl.fromJson(json);
}
}
exports.IOSMetaData = IOSMetaData;
class IOSMetaDataImpl extends IOSMetaData {
constructor(mobileAuthenticationVersion, applicationFacetId) {
super();
this.mobileAuthenticationVersion = mobileAuthenticationVersion;
this.applicationFacetId = applicationFacetId;
}
static fromJson(json) {
const mobileAuthenticationVersion = _Version.Version.fromJson(json.mobileAuthenticationVersion);
return new IOSMetaDataImpl(mobileAuthenticationVersion, json.applicationFacetId);
}
}
exports.IOSMetaDataImpl = IOSMetaDataImpl;
//# sourceMappingURL=IOSMetaData.js.map
;