Database design, start callback-based implementation planning

This commit is contained in:
William committed 2022-05-21 02:53:58 +01:00
1 parent 0446db39c5
commit 8e7d5e74a0
17 files changed
+672 -92

No files matched your search

@@ -2,26 +2,40 @@ package net.william278.huskhomes.position;
import org.jetbrains.annotations.NotNull;
import java.time.Instant;
/**
* Represents metadata about a {@link Position}, used in {@link SavedPosition} implementations
*/
public class PositionMeta {
/**
* The name of this position
* The name of a position
*/
@NotNull
public String name;
/**
* A description of this position
* A description of a position
*/
@NotNull
public String description;
/**
* The epoch timestamp of a position's creation
*/
public long timestamp;
public PositionMeta(@NotNull String name, @NotNull String description, long timestamp) {
this.name = name;
this.description = description;
this.timestamp = timestamp;
}
public PositionMeta(@NotNull String name, @NotNull String description) {
this.name = name;
this.description = description;
this.timestamp = Instant.now().getEpochSecond();
}
}