- java.lang.Object
-
- org.jline.console.CmdLine
-
@Deprecated(since="4.0") public class CmdLine extends java.lang.ObjectDeprecated.Represents a command line with its parsed components. This class stores information about a command line, including the original line, the part before and after the cursor, the parsed arguments, and the type of description that should be displayed for the command.
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static classCmdLine.DescriptionTypeDeprecated.Enumeration specifying the type of description that should be displayed for the command.
-
Constructor Summary
Constructors Constructor Description CmdLine(java.lang.String line, java.lang.String head, java.lang.String tail, java.util.List<java.lang.String> args, CmdLine.DescriptionType descType)Deprecated.Creates a new command line with the specified components.
-
Method Summary
All Methods Instance Methods Concrete Methods Deprecated Methods Modifier and Type Method Description java.util.List<java.lang.String>getArgs()Deprecated.Returns the parsed command line arguments.CmdLine.DescriptionTypegetDescriptionType()Deprecated.Returns the type of description that should be displayed for the command.java.lang.StringgetHead()Deprecated.Returns the part of the command line before the cursor, with method parameters and opening parenthesis removed.java.lang.StringgetLine()Deprecated.Returns the original command line.java.lang.StringgetTail()Deprecated.Returns the part of the command line after the cursor, with method parameters and closing parenthesis removed.
-
-
-
Constructor Detail
-
CmdLine
public CmdLine(java.lang.String line, java.lang.String head, java.lang.String tail, java.util.List<java.lang.String> args, CmdLine.DescriptionType descType)Deprecated.Creates a new command line with the specified components.- Parameters:
line- The original command linehead- The part of the command line before the cursor, with method parameters and opening parenthesis removedtail- The part of the command line after the cursor, with method parameters and closing parenthesis removedargs- The parsed command line argumentsdescType- The type of description that should be displayed for the command
-
-
Method Detail
-
getLine
public java.lang.String getLine()
Deprecated.Returns the original command line.- Returns:
- the original command line
-
getHead
public java.lang.String getHead()
Deprecated.Returns the part of the command line before the cursor, with method parameters and opening parenthesis removed.- Returns:
- the part of the command line before the cursor
-
getTail
public java.lang.String getTail()
Deprecated.Returns the part of the command line after the cursor, with method parameters and closing parenthesis removed.- Returns:
- the part of the command line after the cursor
-
getArgs
public java.util.List<java.lang.String> getArgs()
Deprecated.Returns the parsed command line arguments.- Returns:
- the parsed command line arguments
-
getDescriptionType
public CmdLine.DescriptionType getDescriptionType()
Deprecated.Returns the type of description that should be displayed for the command.- Returns:
- the type of description
-
-