File tree Expand file tree Collapse file tree 2 files changed +17
-0
lines changed
src/main/java/com/cryptlex/lexfloatclient Expand file tree Collapse file tree 2 files changed +17
-0
lines changed Original file line number Diff line number Diff line change @@ -318,6 +318,21 @@ public static int GetFloatingClientMeterAttributeUses(String name) throws LexFlo
318
318
throw new LexFloatClientException (status );
319
319
}
320
320
321
+ /**
322
+ * Sends the request to lease the license from the LexFloatServer for offline usage.
323
+ * The maximum value of lease duration is configured in the config.yml of LexFloatServer.
324
+ *
325
+ * @param leaseDuration value of the lease duration.
326
+ * @throws LexFloatClientException
327
+ */
328
+ public static void RequestOfflineFloatingLicense (int leaseDuration ) throws LexFloatClientException {
329
+ int status ;
330
+ status = LexFloatClientNative .RequestOfflineFloatingLicense (leaseDuration );
331
+ if (LF_OK != status ) {
332
+ throw new LexFloatClientException (status );
333
+ }
334
+ }
335
+
321
336
/**
322
337
* Sends the request to lease the license from the LexFloatServer
323
338
*
Original file line number Diff line number Diff line change @@ -65,6 +65,8 @@ public interface CallbackType extends Callback {
65
65
66
66
public static native int GetFloatingClientMeterAttributeUses (WString name , IntByReference uses );
67
67
68
+ public static native int RequestOfflineFloatingLicense (int leaseDuration );
69
+
68
70
public static native int RequestFloatingLicense ();
69
71
70
72
public static native int DropFloatingLicense ();
You can’t perform that action at this time.
0 commit comments