mirror of
https://github.com/VolmitSoftware/Iris.git
synced 2026-11-27 00:04:42 +00:00
Baseline IrisApi draft before stage-graph redesign
This commit is contained in:
commit
9043d93fbd
91 files changed
+4045
No files matched your search
@@ -0,0 +1,21 @@
|
||||
package com.volmit.host;
|
||||
|
||||
import com.volmit.mantle.MantleCodec;
|
||||
import com.volmit.mantle.MantleKey;
|
||||
import com.volmit.mantle.MantleLifetime;
|
||||
import java.util.Objects;
|
||||
|
||||
public record MantleRegistration<T>(
|
||||
MantleKey<T> key,
|
||||
MantleLifetime lifetime,
|
||||
MantleCodec<T> codec,
|
||||
int version) {
|
||||
public MantleRegistration {
|
||||
Objects.requireNonNull(key, "key");
|
||||
Objects.requireNonNull(lifetime, "lifetime");
|
||||
Objects.requireNonNull(codec, "codec");
|
||||
if (version < 0) {
|
||||
throw new IllegalArgumentException("Negative mantle codec version");
|
||||
}
|
||||
}
|
||||
}
|
||||
Reference in new issue
Block a user