Package dev.enola.common.linereader
Record Class ExecutionContextImpl
java.lang.Object
java.lang.Record
dev.enola.common.linereader.ExecutionContextImpl
- All Implemented Interfaces:
ExecutionContext
public record ExecutionContextImpl(ImmutableMap<String,String> environment, InputStream input, OutputStream output, OutputStream error, Charset inputCharset, Charset outputCharset, Charset errorCharset)
extends Record
implements ExecutionContext
-
Constructor Summary
ConstructorsConstructorDescriptionExecutionContextImpl(ImmutableMap<String, String> environment, InputStream input, OutputStream output, OutputStream error, Charset inputCharset, Charset outputCharset, Charset errorCharset) Creates an instance of aExecutionContextImplrecord class. -
Method Summary
Modifier and TypeMethodDescriptionReturns the value of theenvironmentrecord component.final booleanIndicates whether some other object is "equal to" this one.error()Returns the value of theerrorrecord component.Returns the value of theerrorCharsetrecord component.final inthashCode()Returns a hash code value for this object.input()Returns the value of theinputrecord component.Returns the value of theinputCharsetrecord component.output()Returns the value of theoutputrecord component.Returns the value of theoutputCharsetrecord component.final StringtoString()Returns a string representation of this record class.
-
Constructor Details
-
ExecutionContextImpl
public ExecutionContextImpl(ImmutableMap<String, String> environment, InputStream input, OutputStream output, OutputStream error, Charset inputCharset, Charset outputCharset, Charset errorCharset) Creates an instance of aExecutionContextImplrecord class.- Parameters:
environment- the value for theenvironmentrecord componentinput- the value for theinputrecord componentoutput- the value for theoutputrecord componenterror- the value for theerrorrecord componentinputCharset- the value for theinputCharsetrecord componentoutputCharset- the value for theoutputCharsetrecord componenterrorCharset- the value for theerrorCharsetrecord component
-
-
Method Details
-
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
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). -
environment
Returns the value of theenvironmentrecord component.- Specified by:
environmentin interfaceExecutionContext- Returns:
- the value of the
environmentrecord component
-
input
Returns the value of theinputrecord component.- Specified by:
inputin interfaceExecutionContext- Returns:
- the value of the
inputrecord component
-
output
Returns the value of theoutputrecord component.- Specified by:
outputin interfaceExecutionContext- Returns:
- the value of the
outputrecord component
-
error
Returns the value of theerrorrecord component.- Specified by:
errorin interfaceExecutionContext- Returns:
- the value of the
errorrecord component
-
inputCharset
Returns the value of theinputCharsetrecord component.- Specified by:
inputCharsetin interfaceExecutionContext- Returns:
- the value of the
inputCharsetrecord component
-
outputCharset
Returns the value of theoutputCharsetrecord component.- Specified by:
outputCharsetin interfaceExecutionContext- Returns:
- the value of the
outputCharsetrecord component
-
errorCharset
Returns the value of theerrorCharsetrecord component.- Specified by:
errorCharsetin interfaceExecutionContext- Returns:
- the value of the
errorCharsetrecord component
-