MaskingCallback
public final class SimpleMaskingCallback extends Object implements MaskingCallback
MaskingCallback
that will replace all the characters in the line with the given mask.
If the given mask is equal to LineReaderImpl.NULL_MASK
then the line will be replaced with an empty String.Constructor | Description |
---|---|
SimpleMaskingCallback(Character mask) |
Modifier and Type | Method | Description |
---|---|---|
String |
display(String line) |
Transforms the line before it is displayed so that
some parts can be hidden.
|
String |
history(String line) |
Transforms the line before storing in the history.
|
public SimpleMaskingCallback(Character mask)
public String display(String line)
MaskingCallback
display
in interface MaskingCallback
line
- the current line being editedpublic String history(String line)
MaskingCallback
history
in interface MaskingCallback
line
- the line to be added to historyCopyright © 2020. All rights reserved.