org.cryptomator.jfuse.mac.FuseMountImpl Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of jfuse-mac Show documentation
Show all versions of jfuse-mac Show documentation
Java FUSE bindings for macOS x86_64 and arm64
package org.cryptomator.jfuse.mac;
import org.cryptomator.jfuse.api.FuseMount;
import org.cryptomator.jfuse.mac.extr.fuse_h;
import java.lang.foreign.MemoryAddress;
record FuseMountImpl(MemoryAddress fuse, MemoryAddress ch, FuseArgs args) implements FuseMount {
@Override
public int loop() {
if (args.multiThreaded()) {
return fuse_h.fuse_loop_mt(fuse);
} else {
return fuse_h.fuse_loop(fuse);
}
}
@Override
public void unmount() {
fuse_h.fuse_exit(fuse);
fuse_h.fuse_unmount(args.mountPoint(), ch);
}
@Override
public void destroy() {
fuse_h.fuse_destroy(fuse);
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy