public static class TTY.Filter extends Object
TTY
.Modifier and Type | Field and Description |
---|---|
private LogStream |
previous |
private Thread |
thread |
Constructor and Description |
---|
Filter()
Creates an object that will suppress
TTY for the current thread. |
Filter(String filter,
Object object)
Creates an object that will suppress
TTY for the current thread if the given
filter does not match the given object. |
Modifier and Type | Method and Description |
---|---|
void |
remove()
Reverts the suppression state of
TTY to how it was before this object was
constructed. |
public Filter(String filter, Object object)
TTY
for the current thread if the given
filter does not match the given object. To revert the suppression state to how it was
before this call, the remove()
method must be called on the suppression object.filter
- the pattern for matching. If null
, then the match is successful. If
it starts with "~", then a regular expression
match is performed where
the regular expression is specified by filter
without the "~" prefix.
Otherwise, a simple substring match
is performed where filter
is the substring used.object
- an object whose string value is matched
against filter
public Filter()