Update example
This commit is contained in:
parent
767646feae
commit
1b482b93e2
@ -16,6 +16,7 @@ import oshi.hardware.HardwareAbstractionLayer;
|
|||||||
import oshi.software.os.OperatingSystem;
|
import oshi.software.os.OperatingSystem;
|
||||||
|
|
||||||
import java.io.IOException;
|
import java.io.IOException;
|
||||||
|
import java.time.LocalDateTime;
|
||||||
import java.time.OffsetDateTime;
|
import java.time.OffsetDateTime;
|
||||||
import java.time.format.DateTimeFormatter;
|
import java.time.format.DateTimeFormatter;
|
||||||
import java.util.Date;
|
import java.util.Date;
|
||||||
|
@ -1,11 +1,17 @@
|
|||||||
package me.braydon.example;
|
package me.braydon.example;
|
||||||
|
|
||||||
|
import java.time.Instant;
|
||||||
|
import java.time.temporal.ChronoField;
|
||||||
|
import java.time.temporal.TemporalField;
|
||||||
|
import java.util.Date;
|
||||||
|
import java.util.concurrent.TimeUnit;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @author Braydon
|
* @author Braydon
|
||||||
*/
|
*/
|
||||||
public final class Main {
|
public final class Main {
|
||||||
public static void main(String[] args) {
|
public static void main(String[] args) {
|
||||||
LicenseExample.LicenseResponse response = LicenseExample.check("C45E-40F6-924C-753B", "CloudSpigot");
|
LicenseExample.LicenseResponse response = LicenseExample.check("XXXX-XXXX-XXXX-XXXX", "Example");
|
||||||
if (!response.isValid()) { // License isn't valid
|
if (!response.isValid()) { // License isn't valid
|
||||||
System.err.println("Invalid license: " + response.getError());
|
System.err.println("Invalid license: " + response.getError());
|
||||||
return;
|
return;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user