NoIssue: Lots of API additions
This commit is contained in:
@@ -29,6 +29,7 @@ repositories {
|
||||
|
||||
dependencies {
|
||||
compileOnly("org.jetbrains:annotations:26.0.2-1")
|
||||
implementation("com.r35157.libs:valuetypes-basic-api:0.1-dev")
|
||||
}
|
||||
|
||||
java {
|
||||
|
||||
6
src/main/java/com/r35157/nenjim/hubd/Id.java
Normal file
6
src/main/java/com/r35157/nenjim/hubd/Id.java
Normal file
@@ -0,0 +1,6 @@
|
||||
package com.r35157.nenjim.hubd;
|
||||
|
||||
/**
|
||||
* Id is the super tag for all kinds of id value types.
|
||||
*/
|
||||
public interface Id {}
|
||||
@@ -0,0 +1,8 @@
|
||||
package com.r35157.nenjim.hubd;
|
||||
|
||||
import org.jetbrains.annotations.NotNull;
|
||||
|
||||
public record NenjimDependency(
|
||||
@NotNull NenjimJournalId dependencyId
|
||||
) {
|
||||
}
|
||||
@@ -1,9 +1,17 @@
|
||||
package com.r35157.nenjim.hubd;
|
||||
|
||||
import org.jetbrains.annotations.NotNull;
|
||||
|
||||
public interface NenjimHub {
|
||||
/**
|
||||
* A no-operation (noop). This method is suppoted to do nothing.
|
||||
*/
|
||||
void noop();
|
||||
|
||||
/**
|
||||
*
|
||||
* @param journal
|
||||
*/
|
||||
void monitorJournal(@NotNull NenjimJournal journal);
|
||||
}
|
||||
|
||||
|
||||
16
src/main/java/com/r35157/nenjim/hubd/NenjimJournal.java
Normal file
16
src/main/java/com/r35157/nenjim/hubd/NenjimJournal.java
Normal file
@@ -0,0 +1,16 @@
|
||||
package com.r35157.nenjim.hubd;
|
||||
|
||||
import org.jetbrains.annotations.NotNull;
|
||||
|
||||
import java.util.Set;
|
||||
|
||||
/**
|
||||
* A Nenjim Journal is a manifest that describes a Nenjim component and its dependencies.
|
||||
* It lists the required dependent modules with version constraints and enough metadata (e.g. checksums/signatures)
|
||||
* for Nenjim to resolve, verify, and cache the correct artifacts.
|
||||
*/
|
||||
public record NenjimJournal (
|
||||
@NotNull NenjimJournalId id,
|
||||
@NotNull String name,
|
||||
@NotNull Set<NenjimRelease> releases
|
||||
) implements Id {}
|
||||
@@ -0,0 +1,7 @@
|
||||
package com.r35157.nenjim.hubd;
|
||||
|
||||
import org.jetbrains.annotations.NotNull;
|
||||
|
||||
public record NenjimJournalId(
|
||||
@NotNull String value
|
||||
) implements Id {}
|
||||
8
src/main/java/com/r35157/nenjim/hubd/NenjimRelease.java
Normal file
8
src/main/java/com/r35157/nenjim/hubd/NenjimRelease.java
Normal file
@@ -0,0 +1,8 @@
|
||||
package com.r35157.nenjim.hubd;
|
||||
|
||||
import com.r35157.libs.valuetypes.basic.SemanticVersion;
|
||||
import org.jetbrains.annotations.NotNull;
|
||||
|
||||
public record NenjimRelease(
|
||||
@NotNull SemanticVersion version
|
||||
) {}
|
||||
Reference in New Issue
Block a user