Class ConsoleEngine.ExecutionResult

java.lang.Object
org.jline.console.ConsoleEngine.ExecutionResult
Enclosing interface:
ConsoleEngine

public static class ConsoleEngine.ExecutionResult extends Object
Class representing the result of executing a command.

An ExecutionResult encapsulates the status code and result value of a command execution.

  • Field Summary

    Fields
    Modifier and Type
    Field
    Description
    (package private) final Object
    The result value of the command execution
    (package private) final int
    The status code of the command execution
  • Constructor Summary

    Constructors
    Constructor
    Description
    ExecutionResult(int status, Object result)
    Creates a new execution result with the specified status code and result value.
  • Method Summary

    Modifier and Type
    Method
    Description
    Returns the result value of the command execution.
    int
    Returns the status code of the command execution.

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Field Details

    • status

      final int status
      The status code of the command execution
    • result

      final Object result
      The result value of the command execution
  • Constructor Details

    • ExecutionResult

      public ExecutionResult(int status, Object result)
      Creates a new execution result with the specified status code and result value.
      Parameters:
      status - the status code of the command execution
      result - the result value of the command execution
  • Method Details

    • status

      public int status()
      Returns the status code of the command execution.
      Returns:
      the status code
    • result

      public Object result()
      Returns the result value of the command execution.
      Returns:
      the result value