# Shared

public class Shared

Provides access to a single, shared instance of the LicenseManager.

#### Since

4.2.0

## Properties

allocations
Link copied to clipboard
private final List<String> allocations

List of Nix device allocation codes associated with the current license.

allowedDeviceTypes
Link copied to clipboard
private final Set<DeviceType> allowedDeviceTypes

Set of device types supported by the current license.

expiry
Link copied to clipboard
private final Date expiry

Expiry date for the current license.

features
Link copied to clipboard
private final Set<LicenseFeature> features

Set of features enabled by the current license.

INSTANCE
Link copied to clipboard
public final static LicenseManager.Shared INSTANCE
libraryVersion
Link copied to clipboard
private final String libraryVersion

Current version of the Nix Universal SDK.

state
Link copied to clipboard
private final LicenseManagerState state

Describes the current state of the LicenseManager. Nix Universal SDK functions are available only if license is active (i.e. - the state is LicenseManagerState.ACTIVE)

uuid
Link copied to clipboard
private final String uuid

Vendor identifier for the current license.

## Functions

activate
Link copied to clipboard
public final LicenseManagerState activate(Context context, String options, String signature)

Activates a license. The options and signature parameters must exactly match the values provided in the SDK license. Calling this function invalidates any currently active license.

deactivate
Link copied to clipboard
public final Unit deactivate()

Deactivates the current license.

getAllocations
Link copied to clipboard
public final List<String> getAllocations()
getAllowedDeviceTypes
Link copied to clipboard
public final Set<DeviceType> getAllowedDeviceTypes()
getExpiry
Link copied to clipboard
public final Date getExpiry()
getFeatures
Link copied to clipboard
public final Set<LicenseFeature> getFeatures()
getLibraryVersion
Link copied to clipboard
public final String getLibraryVersion()
getState
Link copied to clipboard
public final LicenseManagerState getState()
getUuid
Link copied to clipboard
public final String getUuid()
isDeviceTypeSupported
Link copied to clipboard
public final Boolean isDeviceTypeSupported(DeviceType type)

Helper to check if a particular DeviceType is supported by the current license.

isFeatureEnabled
Link copied to clipboard
public final Boolean isFeatureEnabled(LicenseFeature feature)

Helper to check if a particular LicenseFeature is enabled by the current license.