java.lang.Object
io.github.astrapi69.file.system.SystemPropertiesExtensions
The class
SystemPropertiesExtensions
provide methods for get the common system properties-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final String
static final String
static final String
static final String
static final String
static final String
static final String
static final String
static final String
static final String
static final String
static final String
static final String
static final String
static final String
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic String
Gets the system file separator character.static String
Gets the Path used to find directories and JAR archives containing class files.static String
Gets the path of the installed java homestatic String
Gets the path for the temporary directory for javastatic String
Gets the name of JRE vendor namestatic String
Gets the name of JRE vendor urlstatic String
Gets the JRE versionstatic String
Gets the system line separator character.static String
Gets the operating system architecturestatic String
Gets the operating system namestatic String
Gets the operating system versionstatic String
Gets the system path separator character used in java.class.pathstatic String
Gets the user home directorystatic String
Gets the user namestatic String
Gets the user working directory
-
Field Details
-
OS_ARCH_PROPERTY_KEY
- See Also:
-
OS_NAME_PROPERTY_KEY
- See Also:
-
OS_VERSION_PROPERTY_KEY
- See Also:
-
USER_HOME_PROPERTY_KEY
- See Also:
-
USER_NAME_PROPERTY_KEY
- See Also:
-
USER_DIR_PROPERTY_KEY
- See Also:
-
FILE_SEPARATOR_PROPERTY_KEY
- See Also:
-
LINE_SEPARATOR_PROPERTY_KEY
- See Also:
-
PATH_SEPARATOR_PROPERTY_KEY
- See Also:
-
JAVA_IO_TMPDIR_PROPERTY_KEY
- See Also:
-
JAVA_CLASS_PATH_PROPERTY_KEY
- See Also:
-
JAVA_VENDOR_PROPERTY_KEY
- See Also:
-
JAVA_HOME_PROPERTY_KEY
- See Also:
-
JAVA_VERSION_PROPERTY_KEY
- See Also:
-
JAVA_VENDOR_URL_PROPERTY_KEY
- See Also:
-
-
Constructor Details
-
SystemPropertiesExtensions
public SystemPropertiesExtensions()
-
-
Method Details
-
getFileSeparator
Gets the system file separator character. In other words the character that separates components of a file path. This is "/" on UNIX and "\" on Windows.- Returns:
- the system file separator character
-
getJavaIoTmpdir
Gets the path for the temporary directory for java- Returns:
- the java class path
-
getJavaHome
Gets the path of the installed java home- Returns:
- the java home path
-
getJavaClassPath
Gets the Path used to find directories and JAR archives containing class files. Elements of the class path are separated by a platform-specific character specified in the path.separator property.- Returns:
- the java class path
-
getJavaVendor
Gets the name of JRE vendor name- Returns:
- the name of JRE vendor name
-
getJavaVendorUrl
Gets the name of JRE vendor url- Returns:
- the name of JRE vendor url
-
getJavaVersion
Gets the JRE version- Returns:
- the JRE version
-
getLineSeparator
Gets the system line separator character. In other words the sequence used by operating system to separate lines in text files- Returns:
- the system line separator character
-
getOsArchitecture
Gets the operating system architecture- Returns:
- the operating system architecture
-
getOsName
Gets the operating system name- Returns:
- the operating system name
-
getOsVersion
Gets the operating system version- Returns:
- the operating system version
-
getPathSeparator
Gets the system path separator character used in java.class.path- Returns:
- the system path separator character used in java.class.path
-
getUserHome
Gets the user home directory- Returns:
- the user home directory
-
getUserName
Gets the user name- Returns:
- the user name
-
getUserWorkingDirectory
Gets the user working directory- Returns:
- the user working directory
-