diff --git a/java/org/contikios/cooja/contikimote/ContikiMoteType.java b/java/org/contikios/cooja/contikimote/ContikiMoteType.java index a850b3b30..aa45e53a2 100644 --- a/java/org/contikios/cooja/contikimote/ContikiMoteType.java +++ b/java/org/contikios/cooja/contikimote/ContikiMoteType.java @@ -48,7 +48,6 @@ import org.contikios.cooja.AbstractionLevelDescription; import org.contikios.cooja.ClassDescription; import org.contikios.cooja.Cooja; -import org.contikios.cooja.CoreComm; import org.contikios.cooja.Mote; import org.contikios.cooja.MoteInterface; import org.contikios.cooja.ProjectConfig; diff --git a/java/org/contikios/cooja/CoreComm.java b/java/org/contikios/cooja/contikimote/CoreComm.java similarity index 94% rename from java/org/contikios/cooja/CoreComm.java rename to java/org/contikios/cooja/contikimote/CoreComm.java index 3f6c62836..127482859 100644 --- a/java/org/contikios/cooja/CoreComm.java +++ b/java/org/contikios/cooja/contikimote/CoreComm.java @@ -26,7 +26,7 @@ * */ -package org.contikios.cooja; +package org.contikios.cooja.contikimote; import java.io.File; import java.lang.foreign.FunctionDescriptor; @@ -41,7 +41,7 @@ */ // Do not bother end-user with warnings about internal Cooja details. @SuppressWarnings("preview") -public class CoreComm { +class CoreComm { private final SymbolLookup symbols; private final MethodHandle coojaTick; /** @@ -50,7 +50,7 @@ public class CoreComm { * @param scope Scope to load the library file in * @param libFile Library file */ - public CoreComm(SegmentScope scope, File libFile) { + CoreComm(SegmentScope scope, File libFile) { symbols = SymbolLookup.libraryLookup(libFile.getAbsolutePath(), scope); var linker = Linker.nativeLinker(); coojaTick = linker.downcallHandle(symbols.find("cooja_tick").get(), @@ -68,7 +68,7 @@ public CoreComm(SegmentScope scope, File libFile) { /** * Ticks a mote once. */ - public void tick() { + void tick() { try { coojaTick.invokeExact(); } catch (Throwable e) { @@ -79,7 +79,7 @@ public void tick() { /** * Returns the absolute memory address of the reference variable. */ - public long getReferenceAddress() { + long getReferenceAddress() { return symbols.find("referenceVar").get().address(); } }