java.lang.Object
java.lang.Record
org.elasticsearch.cli.ProcessInfo
- Record Components:
sysprops
- System properties passed to the JVMenvVars
- Environment variables of the processworkingDir
- The working directory of the process
public record ProcessInfo(Map<String,String> sysprops, Map<String,String> envVars, Path workingDir)
extends Record
A holder for information about a CLI process.
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionenvVars()
Returns the value of theenvVars
record component.final boolean
Indicates whether some other object is "equal to" this one.static ProcessInfo
Return process info for the current JVM.final int
hashCode()
Returns a hash code value for this object.sysprops()
Returns the value of thesysprops
record component.final String
toString()
Returns a string representation of this record class.Returns the value of theworkingDir
record component.
-
Constructor Details
-
ProcessInfo
Creates an instance of aProcessInfo
record class.- Parameters:
sysprops
- the value for thesysprops
record componentenvVars
- the value for theenvVars
record componentworkingDir
- the value for theworkingDir
record component
-
-
Method Details
-
fromSystem
Return process info for the current JVM. -
toString
Returns a string representation of this record class. The representation contains the name of the class, followed by the name and value of each of the record components. -
hashCode
public final int hashCode()Returns a hash code value for this object. The value is derived from the hash code of each of the record components. -
equals
Indicates whether some other object is "equal to" this one. The objects are equal if the other object is of the same class and if all the record components are equal. All components in this record class are compared withObjects::equals(Object,Object)
. -
sysprops
Returns the value of thesysprops
record component.- Returns:
- the value of the
sysprops
record component
-
envVars
Returns the value of theenvVars
record component.- Returns:
- the value of the
envVars
record component
-
workingDir
Returns the value of theworkingDir
record component.- Returns:
- the value of the
workingDir
record component
-