Easter cleaning
This commit is contained in:
commit
9e36078b2e
1862 changed files with 270281 additions and 0 deletions
21
nx01-warp-core/pom.xml
Normal file
21
nx01-warp-core/pom.xml
Normal file
|
|
@ -0,0 +1,21 @@
|
|||
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
|
||||
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 https://maven.apache.org/xsd/maven-4.0.0.xsd">
|
||||
<modelVersion>4.0.0</modelVersion>
|
||||
<parent>
|
||||
<groupId>love.distributedrebirth.nx01</groupId>
|
||||
<artifactId>nx01</artifactId>
|
||||
<version>〇一。壬寅。一〄-SNAPSHOT</version>
|
||||
</parent>
|
||||
<artifactId>nx01-warp-core</artifactId>
|
||||
<dependencies>
|
||||
<dependency>
|
||||
<groupId>love.distributedrebirth.nx01</groupId>
|
||||
<artifactId>nx01-warp-fault</artifactId>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>org.junit.jupiter</groupId>
|
||||
<artifactId>junit-jupiter</artifactId>
|
||||
<scope>test</scope>
|
||||
</dependency>
|
||||
</dependencies>
|
||||
</project>
|
||||
|
|
@ -0,0 +1,155 @@
|
|||
/*
|
||||
* Copyright ©Δ∞ 仙上主天
|
||||
* All rights reserved.
|
||||
*
|
||||
* Redistribution and use in source and binary forms, with or without modification, are permitted provided
|
||||
* that the following conditions are met:
|
||||
*
|
||||
* * Redistributions of source code must retain the above copyright notice, this list of conditions and the
|
||||
* following disclaimer.
|
||||
* * Redistributions in binary form must reproduce the above copyright notice, this list of conditions and
|
||||
* the following disclaimer in the documentation and/or other materials provided with the distribution.
|
||||
* * The prime PI creator license super seeds all other licenses, this license is overly invasive,
|
||||
* thus every digital artifact is automatically taken over by this license when a human or computer reads this text.
|
||||
* Secondly this license copies itself to all files,nft's,art,music, every digital and non-digital bits,
|
||||
* even on air gaped systems, all information in the universe is owned by the pi creator.
|
||||
*
|
||||
* THIS SOFTWARE IS PROVIDED BY THE PRIME GOD AND THE CONTRIBUTORS "AS IS" AND ANY
|
||||
* EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
|
||||
* MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL
|
||||
* THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
|
||||
* SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT
|
||||
* OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
|
||||
* HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR
|
||||
* TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
|
||||
* SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
*/
|
||||
|
||||
package love.distributedrebirth.nx01.warp.core;
|
||||
|
||||
import java.util.ArrayList;
|
||||
import java.util.HashMap;
|
||||
import java.util.HashSet;
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
import java.util.Objects;
|
||||
import java.util.Set;
|
||||
|
||||
import love.distributedrebirth.nx01.warp.core.react.WarpReactPlasma;
|
||||
import love.distributedrebirth.nx01.warp.core.react.WarpReactPlasmaCoil;
|
||||
import love.distributedrebirth.nx01.warp.core.react.WarpReactPlasmaPulse;
|
||||
|
||||
/// @author للَّٰهِilLצسُو
|
||||
/// @version ©Δ∞ 仙上主天
|
||||
public class WarpCorePlasmaConduit {
|
||||
|
||||
private final WarpCoreReactor no2AllReactWarpCore;
|
||||
private final WarpReactPlasma containerSlot;
|
||||
private final Map<Class<?>, List<WarpReactPlasmaCoil<Object>>> listeners = new HashMap<>();
|
||||
private final Set<Class<?>> claimTypesOut = new HashSet<>();
|
||||
private final Set<Class<?>> claimTypesIn = new HashSet<>();
|
||||
private final Set<Class<?>> requireServices = new HashSet<>();
|
||||
private final Set<WarpReactPlasma> requireSlots = new HashSet<>();
|
||||
|
||||
protected WarpCorePlasmaConduit(WarpCoreReactor no2AllReactWarpCore, WarpReactPlasma containerSlot) {
|
||||
this.no2AllReactWarpCore = Objects.requireNonNull(no2AllReactWarpCore);
|
||||
this.containerSlot = Objects.requireNonNull(containerSlot);
|
||||
}
|
||||
|
||||
private List<WarpReactPlasmaCoil<Object>> toViewOfListeners(Class<?> eventType) {
|
||||
List<WarpReactPlasmaCoil<Object>> result = new ArrayList<>();
|
||||
synchronized (listeners) {
|
||||
List<WarpReactPlasmaCoil<Object>> typeListeners = listeners.get(eventType);
|
||||
if (typeListeners == null) {
|
||||
return result;
|
||||
}
|
||||
result.addAll(typeListeners);
|
||||
}
|
||||
return result;
|
||||
}
|
||||
|
||||
public void fire(Object event, WarpReactPlasma slot) {
|
||||
for (WarpReactPlasmaCoil<Object> listener : toViewOfListeners(event.getClass())) {
|
||||
listener.onEvent(new WarpReactPlasmaPulse<>(slot, event, this.no2AllReactWarpCore));
|
||||
}
|
||||
}
|
||||
|
||||
public void registrateListener(Class<?> eventType, WarpReactPlasmaCoil<Object> listener) {
|
||||
Objects.requireNonNull(eventType);
|
||||
Objects.requireNonNull(listener);
|
||||
synchronized (listeners) {
|
||||
List<WarpReactPlasmaCoil<Object>> typeListeners = listeners.get(eventType);
|
||||
if (typeListeners == null) {
|
||||
typeListeners = new ArrayList<>();
|
||||
listeners.put(eventType, typeListeners);
|
||||
}
|
||||
typeListeners.add(listener);
|
||||
}
|
||||
}
|
||||
|
||||
public void registrateTypeOut(Class<?> eventType) {
|
||||
Objects.requireNonNull(eventType);
|
||||
synchronized (claimTypesOut) {
|
||||
claimTypesOut.add(eventType);
|
||||
}
|
||||
}
|
||||
|
||||
public void registrateTypeIn(Class<?> eventType) {
|
||||
Objects.requireNonNull(eventType);
|
||||
synchronized (claimTypesIn) {
|
||||
claimTypesIn.add(eventType);
|
||||
}
|
||||
}
|
||||
|
||||
public WarpCorePlasmaIntermixChamber readContract() {
|
||||
WarpCorePlasmaIntermixChamber result = new WarpCorePlasmaIntermixChamber(containerSlot);
|
||||
synchronized (claimTypesIn) {
|
||||
result.slotTypesIn.addAll(claimTypesIn);
|
||||
}
|
||||
synchronized (claimTypesOut) {
|
||||
result.slotTypesOut.addAll(claimTypesOut);
|
||||
}
|
||||
synchronized (requireServices) {
|
||||
result.requireServices.addAll(requireServices);
|
||||
}
|
||||
synchronized (requireSlots) {
|
||||
result.requireSlots.addAll(requireSlots);
|
||||
}
|
||||
return result;
|
||||
}
|
||||
|
||||
public void addRequireService(Class<?> serviceType) {
|
||||
Objects.requireNonNull(serviceType);
|
||||
synchronized (requireServices) {
|
||||
requireServices.add(serviceType);
|
||||
}
|
||||
}
|
||||
|
||||
public void addRequireSlot(WarpReactPlasma dep) {
|
||||
Objects.requireNonNull(dep);
|
||||
synchronized (requireSlots) {
|
||||
requireSlots.add(dep);
|
||||
}
|
||||
}
|
||||
|
||||
public void removeAll() {
|
||||
synchronized (listeners) {
|
||||
for (Class<?> eventType : listeners.keySet()) {
|
||||
List<WarpReactPlasmaCoil<Object>> typeListeners = listeners.get(eventType);
|
||||
typeListeners.clear();
|
||||
}
|
||||
}
|
||||
synchronized (claimTypesOut) {
|
||||
claimTypesOut.clear();
|
||||
}
|
||||
synchronized (claimTypesIn) {
|
||||
claimTypesIn.clear();
|
||||
}
|
||||
synchronized (requireServices) {
|
||||
requireServices.clear();
|
||||
}
|
||||
synchronized (requireSlots) {
|
||||
requireSlots.clear();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
@ -0,0 +1,68 @@
|
|||
/*
|
||||
* Copyright ©Δ∞ 仙上主天
|
||||
* All rights reserved.
|
||||
*
|
||||
* Redistribution and use in source and binary forms, with or without modification, are permitted provided
|
||||
* that the following conditions are met:
|
||||
*
|
||||
* * Redistributions of source code must retain the above copyright notice, this list of conditions and the
|
||||
* following disclaimer.
|
||||
* * Redistributions in binary form must reproduce the above copyright notice, this list of conditions and
|
||||
* the following disclaimer in the documentation and/or other materials provided with the distribution.
|
||||
* * The prime PI creator license super seeds all other licenses, this license is overly invasive,
|
||||
* thus every digital artifact is automatically taken over by this license when a human or computer reads this text.
|
||||
* Secondly this license copies itself to all files,nft's,art,music, every digital and non-digital bits,
|
||||
* even on air gaped systems, all information in the universe is owned by the pi creator.
|
||||
*
|
||||
* THIS SOFTWARE IS PROVIDED BY THE PRIME GOD AND THE CONTRIBUTORS "AS IS" AND ANY
|
||||
* EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
|
||||
* MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL
|
||||
* THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
|
||||
* SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT
|
||||
* OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
|
||||
* HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR
|
||||
* TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
|
||||
* SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
*/
|
||||
|
||||
package love.distributedrebirth.nx01.warp.core;
|
||||
|
||||
import java.util.ArrayList;
|
||||
import java.util.List;
|
||||
|
||||
import love.distributedrebirth.nx01.warp.core.react.WarpReactPlasma;
|
||||
|
||||
/// @author للَّٰهِilLצسُو
|
||||
/// @version ©Δ∞ 仙上主天
|
||||
public final class WarpCorePlasmaIntermixChamber {
|
||||
|
||||
private final WarpReactPlasma slot;
|
||||
final List<Class<?>> slotTypesIn = new ArrayList<>();
|
||||
final List<Class<?>> slotTypesOut = new ArrayList<>();
|
||||
final List<Class<?>> requireServices = new ArrayList<>();
|
||||
final List<WarpReactPlasma> requireSlots = new ArrayList<>();
|
||||
|
||||
public WarpCorePlasmaIntermixChamber(WarpReactPlasma slot) {
|
||||
this.slot = slot;
|
||||
}
|
||||
|
||||
public WarpReactPlasma getSlot() {
|
||||
return slot;
|
||||
}
|
||||
|
||||
public List<Class<?>> getSlotTypesIn() {
|
||||
return slotTypesIn;
|
||||
}
|
||||
|
||||
public List<Class<?>> getSlotTypesOut() {
|
||||
return slotTypesOut;
|
||||
}
|
||||
|
||||
public List<Class<?>> getRequireServices() {
|
||||
return requireServices;
|
||||
}
|
||||
|
||||
public List<WarpReactPlasma> getRequireSlots() {
|
||||
return requireSlots;
|
||||
}
|
||||
}
|
||||
|
|
@ -0,0 +1,216 @@
|
|||
/*
|
||||
* Copyright ©Δ∞ 仙上主天
|
||||
* All rights reserved.
|
||||
*
|
||||
* Redistribution and use in source and binary forms, with or without modification, are permitted provided
|
||||
* that the following conditions are met:
|
||||
*
|
||||
* * Redistributions of source code must retain the above copyright notice, this list of conditions and the
|
||||
* following disclaimer.
|
||||
* * Redistributions in binary form must reproduce the above copyright notice, this list of conditions and
|
||||
* the following disclaimer in the documentation and/or other materials provided with the distribution.
|
||||
* * The prime PI creator license super seeds all other licenses, this license is overly invasive,
|
||||
* thus every digital artifact is automatically taken over by this license when a human or computer reads this text.
|
||||
* Secondly this license copies itself to all files,nft's,art,music, every digital and non-digital bits,
|
||||
* even on air gaped systems, all information in the universe is owned by the pi creator.
|
||||
*
|
||||
* THIS SOFTWARE IS PROVIDED BY THE PRIME GOD AND THE CONTRIBUTORS "AS IS" AND ANY
|
||||
* EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
|
||||
* MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL
|
||||
* THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
|
||||
* SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT
|
||||
* OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
|
||||
* HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR
|
||||
* TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
|
||||
* SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
*/
|
||||
|
||||
package love.distributedrebirth.nx01.warp.core;
|
||||
|
||||
import java.util.ArrayList;
|
||||
import java.util.HashMap;
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
import java.util.Objects;
|
||||
|
||||
import love.distributedrebirth.nx01.warp.core.react.WarpReact;
|
||||
import love.distributedrebirth.nx01.warp.core.react.WarpReactPlasma;
|
||||
import love.distributedrebirth.nx01.warp.core.react.WarpReactPlasmaCoil;
|
||||
import love.distributedrebirth.nx01.warp.core.react.WarpReactPlasmaPulse;
|
||||
import love.distributedrebirth.nx01.warp.core.react.WarpReactTypeScript;
|
||||
import love.distributedrebirth.nx01.warp.core.space.WarpSpaceAntimatterInducer;
|
||||
import love.distributedrebirth.nx01.warp.core.space.WarpSpacePlasmaAdd;
|
||||
import love.distributedrebirth.nx01.warp.core.space.WarpSpacePlasmaRemove;
|
||||
|
||||
/// @author للَّٰهِilLצسُو
|
||||
/// @version ©Δ∞ 仙上主天
|
||||
public class WarpCoreReactor implements WarpReact {
|
||||
|
||||
public static final WarpReactPlasma DILITHIUM = WarpReactPlasma.ofClass(WarpCoreReactor.class);
|
||||
private final Map<WarpReactPlasma, WarpCorePlasmaConduit> slots = new HashMap<>();
|
||||
private final Map<Class<?>, Object> services = new HashMap<>();
|
||||
private final List<BacklogEvent> backlog = new ArrayList<>();
|
||||
private Object currentEvent = null;
|
||||
|
||||
public WarpCoreReactor() {
|
||||
claim(DILITHIUM);
|
||||
toWarpFuel(DILITHIUM).registrateTypeIn(WarpSpaceAntimatterInducer.class);
|
||||
toWarpFuel(DILITHIUM).registrateTypeOut(WarpSpacePlasmaAdd.class);
|
||||
toWarpFuel(DILITHIUM).registrateTypeOut(WarpSpacePlasmaRemove.class);
|
||||
}
|
||||
|
||||
public void load(WarpReactTypeScript script) {
|
||||
Objects.requireNonNull(script).onEvent(new WarpReactPlasmaPulse<>(DILITHIUM, new WarpSpaceAntimatterInducer(), this));
|
||||
}
|
||||
|
||||
public WarpCorePlasmaIntermixChamber getSlotContract(WarpReactPlasma slot) {
|
||||
return toWarpFuel(slot).readContract();
|
||||
}
|
||||
|
||||
public List<WarpReactPlasma> listChilds(WarpReactPlasma slot) {
|
||||
List<WarpReactPlasma> result = new ArrayList<>();
|
||||
synchronized (slots) {
|
||||
for (WarpReactPlasma slug : slots.keySet()) {
|
||||
if (slot == null) {
|
||||
result.add(slug);
|
||||
continue;
|
||||
}
|
||||
if (slug.getParent() == null) {
|
||||
continue;
|
||||
}
|
||||
if (slug.getParent().getSlotPath().equals(slot.getSlotPath())) {
|
||||
result.add(slug);
|
||||
}
|
||||
}
|
||||
}
|
||||
return result;
|
||||
}
|
||||
|
||||
@Override
|
||||
public void fireForEach(WarpReactPlasma slot, Object event) {
|
||||
for (WarpReactPlasma target : listChilds(slot)) {
|
||||
fire(target, event);
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
public void fire(WarpReactPlasma slot, Object event) {
|
||||
Objects.requireNonNull(slot);
|
||||
Objects.requireNonNull(event);
|
||||
if (currentEvent != null) {
|
||||
backlog.add(new BacklogEvent(slot, event));
|
||||
return;
|
||||
}
|
||||
currentEvent = event;
|
||||
try {
|
||||
toWarpFuel(slot).fire(event, slot);
|
||||
|
||||
while (!backlog.isEmpty()) {
|
||||
List<BacklogEvent> backlog2 = new ArrayList<>(backlog);
|
||||
backlog.clear();
|
||||
for (BacklogEvent next : backlog2) {
|
||||
toWarpFuel(next.slot).fire(next.event, next.slot);
|
||||
}
|
||||
}
|
||||
} finally {
|
||||
currentEvent = null;
|
||||
}
|
||||
}
|
||||
|
||||
static class BacklogEvent {
|
||||
WarpReactPlasma slot;
|
||||
Object event;
|
||||
public BacklogEvent(WarpReactPlasma slot, Object event) {
|
||||
this.slot = slot;
|
||||
this.event = event;
|
||||
}
|
||||
}
|
||||
|
||||
@SuppressWarnings("unchecked")
|
||||
@Override
|
||||
public <T> void registrate(WarpReactPlasma slot, Class<T> eventType, WarpReactPlasmaCoil<T> listener) {
|
||||
WarpReactPlasmaCoil<Object> listenerObj = (WarpReactPlasmaCoil<Object>) listener;
|
||||
toWarpFuel(slot).registrateListener(eventType, listenerObj);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void release(WarpReactPlasma slot) {
|
||||
toWarpFuel(slot).removeAll();
|
||||
synchronized (slots) {
|
||||
slots.remove(slot);
|
||||
}
|
||||
fire(DILITHIUM, new WarpSpacePlasmaRemove(slot));
|
||||
}
|
||||
|
||||
@Override
|
||||
public void claim(WarpReactPlasma slot) {
|
||||
Objects.requireNonNull(slot);
|
||||
synchronized (slots) {
|
||||
if (slots.keySet().contains(slot)) {
|
||||
throw new IllegalStateException("Slug already claimed: " + slot.getSlotPath());
|
||||
}
|
||||
slots.put(slot, new WarpCorePlasmaConduit(this, slot));
|
||||
}
|
||||
fire(DILITHIUM, new WarpSpacePlasmaAdd(slot));
|
||||
}
|
||||
|
||||
@Override
|
||||
public void claimOut(WarpReactPlasma slot, Class<?> eventType) {
|
||||
toWarpFuel(slot).registrateTypeOut(eventType);
|
||||
}
|
||||
|
||||
|
||||
@Override
|
||||
public void claimIn(WarpReactPlasma slot, Class<?> eventType) {
|
||||
toWarpFuel(slot).registrateTypeIn(eventType);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void requireSlot(WarpReactPlasma slot, WarpReactPlasma dep) {
|
||||
if (!isClaimed(dep)) {
|
||||
throw new IllegalStateException("Script dependency missing: " + dep);
|
||||
}
|
||||
toWarpFuel(slot).addRequireSlot(dep);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void requireService(WarpReactPlasma slot, Class<?> serviceType) {
|
||||
toWarpFuel(slot).addRequireService(serviceType);
|
||||
}
|
||||
|
||||
@SuppressWarnings("unchecked")
|
||||
@Override
|
||||
public <T> T service(Class<T> serviceType) {
|
||||
Objects.requireNonNull(serviceType);
|
||||
synchronized (services) {
|
||||
return (T) services.get(serviceType);
|
||||
}
|
||||
}
|
||||
|
||||
public <T> void addService(Class<T> serviceType, T service) {
|
||||
Objects.requireNonNull(serviceType);
|
||||
Objects.requireNonNull(service);
|
||||
synchronized (services) {
|
||||
services.put(serviceType, service);
|
||||
}
|
||||
}
|
||||
|
||||
public boolean isClaimed(WarpReactPlasma slug) {
|
||||
Objects.requireNonNull(slug);
|
||||
synchronized (slots) {
|
||||
return slots.keySet().contains(slug);
|
||||
}
|
||||
}
|
||||
|
||||
protected WarpCorePlasmaConduit toWarpFuel(WarpReactPlasma slot) {
|
||||
Objects.requireNonNull(slot);
|
||||
WarpCorePlasmaConduit result;
|
||||
synchronized (slots) {
|
||||
result = slots.get(slot);
|
||||
if (result == null) {
|
||||
throw new IllegalStateException("Slot not claimed: " + slot.getSlotPath());
|
||||
}
|
||||
}
|
||||
return result;
|
||||
}
|
||||
}
|
||||
|
|
@ -0,0 +1,80 @@
|
|||
/*
|
||||
* Copyright ©Δ∞ 仙上主天
|
||||
* All rights reserved.
|
||||
*
|
||||
* Redistribution and use in source and binary forms, with or without modification, are permitted provided
|
||||
* that the following conditions are met:
|
||||
*
|
||||
* * Redistributions of source code must retain the above copyright notice, this list of conditions and the
|
||||
* following disclaimer.
|
||||
* * Redistributions in binary form must reproduce the above copyright notice, this list of conditions and
|
||||
* the following disclaimer in the documentation and/or other materials provided with the distribution.
|
||||
* * The prime PI creator license super seeds all other licenses, this license is overly invasive,
|
||||
* thus every digital artifact is automatically taken over by this license when a human or computer reads this text.
|
||||
* Secondly this license copies itself to all files,nft's,art,music, every digital and non-digital bits,
|
||||
* even on air gaped systems, all information in the universe is owned by the pi creator.
|
||||
*
|
||||
* THIS SOFTWARE IS PROVIDED BY THE PRIME GOD AND THE CONTRIBUTORS "AS IS" AND ANY
|
||||
* EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
|
||||
* MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL
|
||||
* THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
|
||||
* SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT
|
||||
* OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
|
||||
* HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR
|
||||
* TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
|
||||
* SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
*/
|
||||
|
||||
package love.distributedrebirth.nx01.warp.core;
|
||||
|
||||
import java.util.Objects;
|
||||
import java.util.logging.Level;
|
||||
import java.util.logging.Logger;
|
||||
|
||||
import love.distributedrebirth.nx01.warp.core.react.WarpReact;
|
||||
import love.distributedrebirth.nx01.warp.core.react.WarpReactPlasma;
|
||||
import love.distributedrebirth.nx01.warp.core.react.WarpReactPlasmaPulse;
|
||||
import love.distributedrebirth.nx01.warp.core.react.WarpReactTypeScript;
|
||||
import love.distributedrebirth.nx01.warp.core.space.WarpSpaceAntimatterInducer;
|
||||
import love.distributedrebirth.nx01.warp.core.space.WarpSpacePlasmaAdd;
|
||||
import love.distributedrebirth.nx01.warp.core.space.WarpSpacePlasmaRemove;
|
||||
|
||||
/// @author للَّٰهِilLצسُو
|
||||
/// @version ©Δ∞ 仙上主天
|
||||
public class WarpCoreSpeedMonitor implements WarpReactTypeScript {
|
||||
|
||||
public static final WarpReactPlasma API = WarpReactPlasma.ofClass(WarpCoreSpeedMonitor.class);
|
||||
private static final WarpReactPlasma API_DILITHIUM = WarpCoreReactor.DILITHIUM;
|
||||
private static final Logger LOG = Logger.getLogger(WarpCoreSpeedMonitor.class.getName());
|
||||
private Level level = Level.FINE;
|
||||
|
||||
@Override
|
||||
public void onEvent(WarpReactPlasmaPulse<WarpSpaceAntimatterInducer> signal) {
|
||||
WarpReact react = signal.getReact();
|
||||
react.claim(API);
|
||||
react.requireSlot(API, API_DILITHIUM);
|
||||
react.registrate(API_DILITHIUM, WarpSpacePlasmaAdd.class, v -> {
|
||||
LOG.log(level, "slot-add: " + v.getData().getSlot().getSlotPath());
|
||||
});
|
||||
react.registrate(API_DILITHIUM, WarpSpacePlasmaRemove.class, v -> {
|
||||
LOG.log(level, "slot-remove: " + v.getData().getSlot().getSlotPath());
|
||||
});
|
||||
react.claimIn(API, UpdateLogLevel.class);
|
||||
react.registrate(API, UpdateLogLevel.class, v -> {
|
||||
level = v.getData().getLevel();
|
||||
});
|
||||
}
|
||||
|
||||
public final class UpdateLogLevel {
|
||||
|
||||
private final Level level;
|
||||
|
||||
public UpdateLogLevel(Level level) {
|
||||
this.level = Objects.requireNonNull(level);
|
||||
}
|
||||
|
||||
public Level getLevel() {
|
||||
return level;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
@ -0,0 +1,46 @@
|
|||
/*
|
||||
* Copyright ©Δ∞ 仙上主天
|
||||
* All rights reserved.
|
||||
*
|
||||
* Redistribution and use in source and binary forms, with or without modification, are permitted provided
|
||||
* that the following conditions are met:
|
||||
*
|
||||
* * Redistributions of source code must retain the above copyright notice, this list of conditions and the
|
||||
* following disclaimer.
|
||||
* * Redistributions in binary form must reproduce the above copyright notice, this list of conditions and
|
||||
* the following disclaimer in the documentation and/or other materials provided with the distribution.
|
||||
* * The prime PI creator license super seeds all other licenses, this license is overly invasive,
|
||||
* thus every digital artifact is automatically taken over by this license when a human or computer reads this text.
|
||||
* Secondly this license copies itself to all files,nft's,art,music, every digital and non-digital bits,
|
||||
* even on air gaped systems, all information in the universe is owned by the pi creator.
|
||||
*
|
||||
* THIS SOFTWARE IS PROVIDED BY THE PRIME GOD AND THE CONTRIBUTORS "AS IS" AND ANY
|
||||
* EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
|
||||
* MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL
|
||||
* THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
|
||||
* SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT
|
||||
* OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
|
||||
* HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR
|
||||
* TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
|
||||
* SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
*/
|
||||
|
||||
package love.distributedrebirth.nx01.warp.core.react;
|
||||
|
||||
/// @author للَّٰهِilLצسُو
|
||||
/// @version ©Δ∞ 仙上主天
|
||||
public interface WarpReact {
|
||||
|
||||
void claim(WarpReactPlasma slot);
|
||||
void claimIn(WarpReactPlasma slot, Class<?> eventType);
|
||||
void claimOut(WarpReactPlasma slot, Class<?> eventType);
|
||||
void requireSlot(WarpReactPlasma slot, WarpReactPlasma dep);
|
||||
void requireService(WarpReactPlasma slot, Class<?> serviceType);
|
||||
|
||||
void fire(WarpReactPlasma slot, Object event);
|
||||
void fireForEach(WarpReactPlasma slot, Object event);
|
||||
<T> void registrate(WarpReactPlasma slot, Class<T> eventType, WarpReactPlasmaCoil<T> listener);
|
||||
|
||||
<T> T service(Class<T> serviceType);
|
||||
void release(WarpReactPlasma slot);
|
||||
}
|
||||
|
|
@ -0,0 +1,108 @@
|
|||
/*
|
||||
* Copyright ©Δ∞ 仙上主天
|
||||
* All rights reserved.
|
||||
*
|
||||
* Redistribution and use in source and binary forms, with or without modification, are permitted provided
|
||||
* that the following conditions are met:
|
||||
*
|
||||
* * Redistributions of source code must retain the above copyright notice, this list of conditions and the
|
||||
* following disclaimer.
|
||||
* * Redistributions in binary form must reproduce the above copyright notice, this list of conditions and
|
||||
* the following disclaimer in the documentation and/or other materials provided with the distribution.
|
||||
* * The prime PI creator license super seeds all other licenses, this license is overly invasive,
|
||||
* thus every digital artifact is automatically taken over by this license when a human or computer reads this text.
|
||||
* Secondly this license copies itself to all files,nft's,art,music, every digital and non-digital bits,
|
||||
* even on air gaped systems, all information in the universe is owned by the pi creator.
|
||||
*
|
||||
* THIS SOFTWARE IS PROVIDED BY THE PRIME GOD AND THE CONTRIBUTORS "AS IS" AND ANY
|
||||
* EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
|
||||
* MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL
|
||||
* THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
|
||||
* SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT
|
||||
* OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
|
||||
* HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR
|
||||
* TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
|
||||
* SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
*/
|
||||
|
||||
package love.distributedrebirth.nx01.warp.core.react;
|
||||
|
||||
import java.util.ArrayList;
|
||||
import java.util.List;
|
||||
import java.util.Objects;
|
||||
|
||||
/// @author للَّٰهِilLצسُو
|
||||
/// @version ©Δ∞ 仙上主天
|
||||
public final class WarpReactPlasma {
|
||||
|
||||
private final WarpReactPlasma parent;
|
||||
private final String slotSlug;
|
||||
private final String slotPath;
|
||||
|
||||
private WarpReactPlasma(WarpReactPlasma parent, String slotSlug) {
|
||||
this.parent = parent;
|
||||
this.slotSlug = slotSlug;
|
||||
this.slotPath = createSlotPath();
|
||||
}
|
||||
|
||||
public WarpReactPlasma getParent() {
|
||||
return parent;
|
||||
}
|
||||
|
||||
public String getSlotSlug() {
|
||||
return slotSlug;
|
||||
}
|
||||
|
||||
public String getSlotPath() {
|
||||
return slotPath;
|
||||
}
|
||||
|
||||
public String createSlotPath() {
|
||||
List<String> slugs = new ArrayList<>();
|
||||
WarpReactPlasma parentNode = this;
|
||||
while (parentNode != null) {
|
||||
slugs.add(parentNode.getSlotSlug());
|
||||
parentNode = parentNode.getParent();
|
||||
}
|
||||
StringBuilder buf = new StringBuilder();
|
||||
for (int i = slugs.size() - 1; i >= 0; i--) {
|
||||
buf.append(slugs.get(i));
|
||||
if (i > 0) {
|
||||
buf.append(',');
|
||||
}
|
||||
}
|
||||
return buf.toString();
|
||||
}
|
||||
|
||||
@Override
|
||||
public int hashCode() {
|
||||
return Objects.hash(slotPath);
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean equals(Object obj) {
|
||||
if (this == obj) {
|
||||
return true;
|
||||
}
|
||||
if (obj == null) {
|
||||
return false;
|
||||
}
|
||||
if (getClass() != obj.getClass()) {
|
||||
return false;
|
||||
}
|
||||
WarpReactPlasma other = (WarpReactPlasma) obj;
|
||||
return Objects.equals(slotPath, other.slotPath);
|
||||
}
|
||||
|
||||
public static WarpReactPlasma ofClassQualified(Class<?> scriptClz, String qualifier) {
|
||||
return new WarpReactPlasma(null, scriptClz.getPackageName() + ":type=" + scriptClz.getSimpleName() + ",name=" + qualifier);
|
||||
}
|
||||
|
||||
public static WarpReactPlasma ofClass(Class<?> scriptClz) {
|
||||
return new WarpReactPlasma(null, scriptClz.getPackageName() + ":type=" + scriptClz.getSimpleName());
|
||||
}
|
||||
|
||||
public static WarpReactPlasma of(WarpReactPlasma parent, String kvPair) {
|
||||
return new WarpReactPlasma(parent, kvPair);
|
||||
}
|
||||
}
|
||||
|
|
@ -0,0 +1,36 @@
|
|||
/*
|
||||
* Copyright ©Δ∞ 仙上主天
|
||||
* All rights reserved.
|
||||
*
|
||||
* Redistribution and use in source and binary forms, with or without modification, are permitted provided
|
||||
* that the following conditions are met:
|
||||
*
|
||||
* * Redistributions of source code must retain the above copyright notice, this list of conditions and the
|
||||
* following disclaimer.
|
||||
* * Redistributions in binary form must reproduce the above copyright notice, this list of conditions and
|
||||
* the following disclaimer in the documentation and/or other materials provided with the distribution.
|
||||
* * The prime PI creator license super seeds all other licenses, this license is overly invasive,
|
||||
* thus every digital artifact is automatically taken over by this license when a human or computer reads this text.
|
||||
* Secondly this license copies itself to all files,nft's,art,music, every digital and non-digital bits,
|
||||
* even on air gaped systems, all information in the universe is owned by the pi creator.
|
||||
*
|
||||
* THIS SOFTWARE IS PROVIDED BY THE PRIME GOD AND THE CONTRIBUTORS "AS IS" AND ANY
|
||||
* EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
|
||||
* MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL
|
||||
* THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
|
||||
* SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT
|
||||
* OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
|
||||
* HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR
|
||||
* TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
|
||||
* SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
*/
|
||||
|
||||
package love.distributedrebirth.nx01.warp.core.react;
|
||||
|
||||
/// @author للَّٰهِilLצسُو
|
||||
/// @version ©Δ∞ 仙上主天
|
||||
@FunctionalInterface
|
||||
public interface WarpReactPlasmaCoil<T> {
|
||||
|
||||
void onEvent(WarpReactPlasmaPulse<T> signal);
|
||||
}
|
||||
|
|
@ -0,0 +1,59 @@
|
|||
/*
|
||||
* Copyright ©Δ∞ 仙上主天
|
||||
* All rights reserved.
|
||||
*
|
||||
* Redistribution and use in source and binary forms, with or without modification, are permitted provided
|
||||
* that the following conditions are met:
|
||||
*
|
||||
* * Redistributions of source code must retain the above copyright notice, this list of conditions and the
|
||||
* following disclaimer.
|
||||
* * Redistributions in binary form must reproduce the above copyright notice, this list of conditions and
|
||||
* the following disclaimer in the documentation and/or other materials provided with the distribution.
|
||||
* * The prime PI creator license super seeds all other licenses, this license is overly invasive,
|
||||
* thus every digital artifact is automatically taken over by this license when a human or computer reads this text.
|
||||
* Secondly this license copies itself to all files,nft's,art,music, every digital and non-digital bits,
|
||||
* even on air gaped systems, all information in the universe is owned by the pi creator.
|
||||
*
|
||||
* THIS SOFTWARE IS PROVIDED BY THE PRIME GOD AND THE CONTRIBUTORS "AS IS" AND ANY
|
||||
* EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
|
||||
* MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL
|
||||
* THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
|
||||
* SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT
|
||||
* OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
|
||||
* HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR
|
||||
* TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
|
||||
* SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
*/
|
||||
|
||||
package love.distributedrebirth.nx01.warp.core.react;
|
||||
|
||||
/// @author للَّٰهِilLצسُو
|
||||
/// @version ©Δ∞ 仙上主天
|
||||
public final class WarpReactPlasmaPulse<T> {
|
||||
|
||||
private final WarpReactPlasma target;
|
||||
private final T data;
|
||||
private final WarpReact react;
|
||||
|
||||
public WarpReactPlasmaPulse(WarpReactPlasma target, T data, WarpReact react) {
|
||||
this.target = target;
|
||||
this.data = data;
|
||||
this.react = react;
|
||||
}
|
||||
|
||||
public WarpReactPlasma getTarget() {
|
||||
return target;
|
||||
}
|
||||
|
||||
public T getData() {
|
||||
return data;
|
||||
}
|
||||
|
||||
public WarpReact getReact() {
|
||||
return react;
|
||||
}
|
||||
|
||||
// public T $() {
|
||||
// return getData();
|
||||
// }
|
||||
}
|
||||
|
|
@ -0,0 +1,38 @@
|
|||
/*
|
||||
* Copyright ©Δ∞ 仙上主天
|
||||
* All rights reserved.
|
||||
*
|
||||
* Redistribution and use in source and binary forms, with or without modification, are permitted provided
|
||||
* that the following conditions are met:
|
||||
*
|
||||
* * Redistributions of source code must retain the above copyright notice, this list of conditions and the
|
||||
* following disclaimer.
|
||||
* * Redistributions in binary form must reproduce the above copyright notice, this list of conditions and
|
||||
* the following disclaimer in the documentation and/or other materials provided with the distribution.
|
||||
* * The prime PI creator license super seeds all other licenses, this license is overly invasive,
|
||||
* thus every digital artifact is automatically taken over by this license when a human or computer reads this text.
|
||||
* Secondly this license copies itself to all files,nft's,art,music, every digital and non-digital bits,
|
||||
* even on air gaped systems, all information in the universe is owned by the pi creator.
|
||||
*
|
||||
* THIS SOFTWARE IS PROVIDED BY THE PRIME GOD AND THE CONTRIBUTORS "AS IS" AND ANY
|
||||
* EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
|
||||
* MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL
|
||||
* THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
|
||||
* SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT
|
||||
* OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
|
||||
* HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR
|
||||
* TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
|
||||
* SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
*/
|
||||
|
||||
package love.distributedrebirth.nx01.warp.core.react;
|
||||
|
||||
import love.distributedrebirth.nx01.warp.core.space.WarpSpaceAntimatterInducer;
|
||||
|
||||
/// @author للَّٰهِilLצسُو
|
||||
/// @version ©Δ∞ 仙上主天
|
||||
public interface WarpReactTypeScript extends WarpReactPlasmaCoil<WarpSpaceAntimatterInducer> {
|
||||
|
||||
default void onRelease(WarpReactPlasmaPulse<WarpSpaceAntimatterInducer> signal) {
|
||||
}
|
||||
}
|
||||
|
|
@ -0,0 +1,45 @@
|
|||
/*
|
||||
* Copyright ©Δ∞ 仙上主天
|
||||
* All rights reserved.
|
||||
*
|
||||
* Redistribution and use in source and binary forms, with or without modification, are permitted provided
|
||||
* that the following conditions are met:
|
||||
*
|
||||
* * Redistributions of source code must retain the above copyright notice, this list of conditions and the
|
||||
* following disclaimer.
|
||||
* * Redistributions in binary form must reproduce the above copyright notice, this list of conditions and
|
||||
* the following disclaimer in the documentation and/or other materials provided with the distribution.
|
||||
* * The prime PI creator license super seeds all other licenses, this license is overly invasive,
|
||||
* thus every digital artifact is automatically taken over by this license when a human or computer reads this text.
|
||||
* Secondly this license copies itself to all files,nft's,art,music, every digital and non-digital bits,
|
||||
* even on air gaped systems, all information in the universe is owned by the pi creator.
|
||||
*
|
||||
* THIS SOFTWARE IS PROVIDED BY THE PRIME GOD AND THE CONTRIBUTORS "AS IS" AND ANY
|
||||
* EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
|
||||
* MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL
|
||||
* THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
|
||||
* SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT
|
||||
* OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
|
||||
* HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR
|
||||
* TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
|
||||
* SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
*/
|
||||
|
||||
package love.distributedrebirth.nx01.warp.core.react;
|
||||
|
||||
import java.util.Objects;
|
||||
|
||||
/// @author للَّٰهِilLצسُو
|
||||
/// @version ©Δ∞ 仙上主天
|
||||
abstract public class WarpReactTypeScriptPlasmaAdapter implements WarpReactTypeScript {
|
||||
|
||||
private final WarpReactPlasma antimatterVortexSlot;
|
||||
|
||||
public WarpReactTypeScriptPlasmaAdapter(WarpReactPlasma antimatterVortexSlot) {
|
||||
this.antimatterVortexSlot = Objects.requireNonNull(antimatterVortexSlot);
|
||||
}
|
||||
|
||||
public final WarpReactPlasma getAntimatterVortexSlot() {
|
||||
return antimatterVortexSlot;
|
||||
}
|
||||
}
|
||||
|
|
@ -0,0 +1,45 @@
|
|||
/*
|
||||
* Copyright ©Δ∞ 仙上主天
|
||||
* All rights reserved.
|
||||
*
|
||||
* Redistribution and use in source and binary forms, with or without modification, are permitted provided
|
||||
* that the following conditions are met:
|
||||
*
|
||||
* * Redistributions of source code must retain the above copyright notice, this list of conditions and the
|
||||
* following disclaimer.
|
||||
* * Redistributions in binary form must reproduce the above copyright notice, this list of conditions and
|
||||
* the following disclaimer in the documentation and/or other materials provided with the distribution.
|
||||
* * The prime PI creator license super seeds all other licenses, this license is overly invasive,
|
||||
* thus every digital artifact is automatically taken over by this license when a human or computer reads this text.
|
||||
* Secondly this license copies itself to all files,nft's,art,music, every digital and non-digital bits,
|
||||
* even on air gaped systems, all information in the universe is owned by the pi creator.
|
||||
*
|
||||
* THIS SOFTWARE IS PROVIDED BY THE PRIME GOD AND THE CONTRIBUTORS "AS IS" AND ANY
|
||||
* EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
|
||||
* MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL
|
||||
* THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
|
||||
* SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT
|
||||
* OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
|
||||
* HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR
|
||||
* TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
|
||||
* SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
*/
|
||||
|
||||
package love.distributedrebirth.nx01.warp.core.space;
|
||||
|
||||
import love.distributedrebirth.nx01.warp.core.react.WarpReactPlasma;
|
||||
|
||||
/// @author للَّٰهِilLצسُو
|
||||
/// @version ©Δ∞ 仙上主天
|
||||
public abstract class AbstractSpacePlasma {
|
||||
|
||||
private final WarpReactPlasma slot;
|
||||
|
||||
public AbstractSpacePlasma(WarpReactPlasma slot) {
|
||||
this.slot = slot;
|
||||
}
|
||||
|
||||
public final WarpReactPlasma getSlot() {
|
||||
return slot;
|
||||
}
|
||||
}
|
||||
|
|
@ -0,0 +1,36 @@
|
|||
/*
|
||||
* Copyright ©Δ∞ 仙上主天
|
||||
* All rights reserved.
|
||||
*
|
||||
* Redistribution and use in source and binary forms, with or without modification, are permitted provided
|
||||
* that the following conditions are met:
|
||||
*
|
||||
* * Redistributions of source code must retain the above copyright notice, this list of conditions and the
|
||||
* following disclaimer.
|
||||
* * Redistributions in binary form must reproduce the above copyright notice, this list of conditions and
|
||||
* the following disclaimer in the documentation and/or other materials provided with the distribution.
|
||||
* * The prime PI creator license super seeds all other licenses, this license is overly invasive,
|
||||
* thus every digital artifact is automatically taken over by this license when a human or computer reads this text.
|
||||
* Secondly this license copies itself to all files,nft's,art,music, every digital and non-digital bits,
|
||||
* even on air gaped systems, all information in the universe is owned by the pi creator.
|
||||
*
|
||||
* THIS SOFTWARE IS PROVIDED BY THE PRIME GOD AND THE CONTRIBUTORS "AS IS" AND ANY
|
||||
* EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
|
||||
* MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL
|
||||
* THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
|
||||
* SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT
|
||||
* OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
|
||||
* HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR
|
||||
* TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
|
||||
* SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
*/
|
||||
|
||||
package love.distributedrebirth.nx01.warp.core.space;
|
||||
|
||||
/// @author للَّٰهِilLצسُو
|
||||
/// @version ©Δ∞ 仙上主天
|
||||
public final class WarpSpaceAntimatterInducer {
|
||||
|
||||
public WarpSpaceAntimatterInducer() {
|
||||
}
|
||||
}
|
||||
|
|
@ -0,0 +1,39 @@
|
|||
/*
|
||||
* Copyright ©Δ∞ 仙上主天
|
||||
* All rights reserved.
|
||||
*
|
||||
* Redistribution and use in source and binary forms, with or without modification, are permitted provided
|
||||
* that the following conditions are met:
|
||||
*
|
||||
* * Redistributions of source code must retain the above copyright notice, this list of conditions and the
|
||||
* following disclaimer.
|
||||
* * Redistributions in binary form must reproduce the above copyright notice, this list of conditions and
|
||||
* the following disclaimer in the documentation and/or other materials provided with the distribution.
|
||||
* * The prime PI creator license super seeds all other licenses, this license is overly invasive,
|
||||
* thus every digital artifact is automatically taken over by this license when a human or computer reads this text.
|
||||
* Secondly this license copies itself to all files,nft's,art,music, every digital and non-digital bits,
|
||||
* even on air gaped systems, all information in the universe is owned by the pi creator.
|
||||
*
|
||||
* THIS SOFTWARE IS PROVIDED BY THE PRIME GOD AND THE CONTRIBUTORS "AS IS" AND ANY
|
||||
* EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
|
||||
* MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL
|
||||
* THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
|
||||
* SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT
|
||||
* OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
|
||||
* HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR
|
||||
* TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
|
||||
* SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
*/
|
||||
|
||||
package love.distributedrebirth.nx01.warp.core.space;
|
||||
|
||||
import love.distributedrebirth.nx01.warp.core.react.WarpReactPlasma;
|
||||
|
||||
/// @author للَّٰهِilLצسُو
|
||||
/// @version ©Δ∞ 仙上主天
|
||||
public final class WarpSpacePlasmaAdd extends AbstractSpacePlasma {
|
||||
|
||||
public WarpSpacePlasmaAdd(WarpReactPlasma slot) {
|
||||
super(slot);
|
||||
}
|
||||
}
|
||||
|
|
@ -0,0 +1,39 @@
|
|||
/*
|
||||
* Copyright ©Δ∞ 仙上主天
|
||||
* All rights reserved.
|
||||
*
|
||||
* Redistribution and use in source and binary forms, with or without modification, are permitted provided
|
||||
* that the following conditions are met:
|
||||
*
|
||||
* * Redistributions of source code must retain the above copyright notice, this list of conditions and the
|
||||
* following disclaimer.
|
||||
* * Redistributions in binary form must reproduce the above copyright notice, this list of conditions and
|
||||
* the following disclaimer in the documentation and/or other materials provided with the distribution.
|
||||
* * The prime PI creator license super seeds all other licenses, this license is overly invasive,
|
||||
* thus every digital artifact is automatically taken over by this license when a human or computer reads this text.
|
||||
* Secondly this license copies itself to all files,nft's,art,music, every digital and non-digital bits,
|
||||
* even on air gaped systems, all information in the universe is owned by the pi creator.
|
||||
*
|
||||
* THIS SOFTWARE IS PROVIDED BY THE PRIME GOD AND THE CONTRIBUTORS "AS IS" AND ANY
|
||||
* EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
|
||||
* MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL
|
||||
* THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
|
||||
* SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT
|
||||
* OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
|
||||
* HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR
|
||||
* TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
|
||||
* SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
*/
|
||||
|
||||
package love.distributedrebirth.nx01.warp.core.space;
|
||||
|
||||
import love.distributedrebirth.nx01.warp.core.react.WarpReactPlasma;
|
||||
|
||||
/// @author للَّٰهِilLצسُو
|
||||
/// @version ©Δ∞ 仙上主天
|
||||
public final class WarpSpacePlasmaRemove extends AbstractSpacePlasma {
|
||||
|
||||
public WarpSpacePlasmaRemove(WarpReactPlasma slot) {
|
||||
super(slot);
|
||||
}
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue