Skip to content

Platform

enum Platform
Package: dev.joid.lib.utils.platform · Module: core · Source: Platform.java

Operating system that JOID runs on, and where it keeps its cache there.

ReturnsSignatureSummary
Platformcurrent() factoryReturns the system named by the os.name property: macOS for a name with mac or darwin, Windows for a name with win, Linux otherwise.

ReturnsSignatureSummary
booleanis64Bit() staticIf true, the os.arch property names a 64-bit architecture.
FilegetCacheDir(String home, Function<String,String> environment)Returns the cache folder of the user of the folder home on this system, reading the environment variables through environment: %LOCALAPPDATA% (or AppData/Local) on Windows, Library/Caches on macOS, $XDG_CACHE_HOME (or .cache) on Linux.
ValueSummary
WINDOWSWindows.
MACOSmacOS.
LINUXLinux, and every system that is neither Windows nor macOS.

Platform current() factory

Returns the system named by the os.name property: macOS for a name with mac or darwin, Windows for a name with win, Linux otherwise.

boolean is64Bit() static

If true, the os.arch property names a 64-bit architecture.

File getCacheDir(String home, Function<String,String> environment)

Returns the cache folder of the user of the folder home on this system, reading the environment variables through environment: %LOCALAPPDATA% (or AppData/Local) on Windows, Library/Caches on macOS, $XDG_CACHE_HOME (or .cache) on Linux.

WINDOWS

Windows.

MACOS

macOS.

LINUX

Linux, and every system that is neither Windows nor macOS.


fluent returns the instance, typed for chaining · factory creates an instance · signal also accepts a value that follows signals, as a signal, an expression or a lambda (When does JOID compute this value again?) · hook called by JOID, override it · abstract you implement it · default interface method with a body · static called on the class · protected visible to subclasses

Report a problem with this page