public enum TailOptionSet_cqs extends Enum<TailOptionSet_cqs> implements TailOptions
tail
command with
the following options: c
, s
, q
.
Application code does normally not directly refer to this class;
Tail.Options
should be used instead to specify command
options. See also TailOptions
for more information.
TailOptions.Default
Enum Constant and Description |
---|
Active_c
Option set with the following active options:
c . |
Active_c_long
Option set with the following active options:
c . |
Active_cq
|
Active_cq_long
|
Active_cqs
|
Active_cqs_long
|
Active_cs
|
Active_cs_long
|
Active_q
Option set with the following active options:
q . |
Active_q_long
Option set with the following active options:
q . |
Active_qs
|
Active_qs_long
|
Active_s
Option set with the following active options:
s . |
Active_s_long
Option set with the following active options:
s . |
Modifier and Type | Field and Description |
---|---|
TailOptionSet_cqs |
c
Option
"-c" : The count argument is in units of characters instead of
lines. |
TailOptionSet_cqs |
chars
Option
"--chars" : The count argument is in units of characters instead of
lines. |
TailOptionSet_cqs |
countFromStart
Option
"--countFromStart" : The count argument is relative to the beginning of the file
instead of counting from the end of the file. |
TailOptionSet_cqs |
q
Option
"-q" : Suppresses printing of headers when multiple files are being
examined. |
TailOptionSet_cqs |
s
Option
"-s" : The count argument is relative to the beginning of the file
instead of counting from the end of the file. |
TailOptionSet_cqs |
suppressHeaders
Option
"--suppressHeaders" : Suppresses printing of headers when multiple files are being
examined. |
CONVERTER, EMPTY
Modifier and Type | Method and Description |
---|---|
EnumSet<TailOption> |
asSet()
Returns the set with the active options.
|
boolean |
isSet(TailOption option)
Returns true if the specified
option is set and false otherwise |
Iterator<TailOption> |
iterator()
Returns an immutable iterator with the active options of this option set.
|
Class<TailOption> |
optionType()
Returns the option type class, usually an enum.
|
int |
size()
Returns the number of active options in this option set.
|
boolean |
useAcronymFor(TailOption option)
Returns true if the
acronym should be used in
for the specified option string representations. |
static TailOptionSet_cqs |
valueOf(String name)
Returns the enum constant of this type with the specified name.
|
static TailOptionSet_cqs[] |
values()
Returns an array containing the constants of this enum type, in
the order they are declared.
|
clone, compareTo, equals, finalize, getDeclaringClass, hashCode, name, ordinal, toString, valueOf
forEach, spliterator
public static final TailOptionSet_cqs Active_cqs
public static final TailOptionSet_cqs Active_cqs_long
public static final TailOptionSet_cqs Active_cq
public static final TailOptionSet_cqs Active_cq_long
public static final TailOptionSet_cqs Active_cs
public static final TailOptionSet_cqs Active_cs_long
public static final TailOptionSet_cqs Active_qs
public static final TailOptionSet_cqs Active_qs_long
public static final TailOptionSet_cqs Active_c
c
.public static final TailOptionSet_cqs Active_c_long
c
.public static final TailOptionSet_cqs Active_q
q
.public static final TailOptionSet_cqs Active_q_long
q
.public static final TailOptionSet_cqs Active_s
s
.public static final TailOptionSet_cqs Active_s_long
s
.public final TailOptionSet_cqs c
"-c"
: The count
argument is in units of characters instead of
lines. Starts from 1 and includes line ending characters.
The option "-c"
is equivalent to the "--
chars
"
option.
Technically speaking, this field points to a set with the options of the
current set plus the option "-c"
. If the option "-c"
is already set, the field c
points to the enum constant itself
as it already represents the current set of options.
public final TailOptionSet_cqs chars
"--chars"
: The count
argument is in units of characters instead of
lines. Starts from 1 and includes line ending characters.
The option "--chars"
is equivalent to the "-
c
"
option.
Technically speaking, this field points to a set with the options of the
current set plus the option "--chars"
. If the option "--chars"
is already set, the field chars
points to the enum constant itself
as it already represents the current set of options.
public final TailOptionSet_cqs s
"-s"
: The count
argument is relative to the beginning of the file
instead of counting from the end of the file. For instance,
tail -s 10
prints the lines starting from line 10;
tail -s 1
prints the whole file.
The option "-s"
is equivalent to the "--
countFromStart
"
option.
Technically speaking, this field points to a set with the options of the
current set plus the option "-s"
. If the option "-s"
is already set, the field s
points to the enum constant itself
as it already represents the current set of options.
public final TailOptionSet_cqs countFromStart
"--countFromStart"
: The count
argument is relative to the beginning of the file
instead of counting from the end of the file. For instance,
tail -s 10
prints the lines starting from line 10;
tail -s 1
prints the whole file.
The option "--countFromStart"
is equivalent to the "-
s
"
option.
Technically speaking, this field points to a set with the options of the
current set plus the option "--countFromStart"
. If the option "--countFromStart"
is already set, the field countFromStart
points to the enum constant itself
as it already represents the current set of options.
public final TailOptionSet_cqs q
"-q"
: Suppresses printing of headers when multiple files are being
examined.
The option "-q"
is equivalent to the "--
suppressHeaders
"
option.
Technically speaking, this field points to a set with the options of the
current set plus the option "-q"
. If the option "-q"
is already set, the field q
points to the enum constant itself
as it already represents the current set of options.
public final TailOptionSet_cqs suppressHeaders
"--suppressHeaders"
: Suppresses printing of headers when multiple files are being
examined.
The option "--suppressHeaders"
is equivalent to the "-
q
"
option.
Technically speaking, this field points to a set with the options of the
current set plus the option "--suppressHeaders"
. If the option "--suppressHeaders"
is already set, the field suppressHeaders
points to the enum constant itself
as it already represents the current set of options.
public static TailOptionSet_cqs[] values()
for (TailOptionSet_cqs c : TailOptionSet_cqs.values()) System.out.println(c);
public static TailOptionSet_cqs valueOf(String name)
name
- the name of the enum constant to be returned.IllegalArgumentException
- if this enum type has no constant with the specified nameNullPointerException
- if the argument is nullpublic Class<TailOption> optionType()
OptionSet
optionType
in interface OptionSet<TailOption>
public boolean isSet(TailOption option)
OptionSet
option
is set and false otherwiseisSet
in interface OptionSet<TailOption>
option
- the option to testoption
is set in this OptionSet
public int size()
OptionSet
size
in interface OptionSet<TailOption>
public EnumSet<TailOption> asSet()
this
option set.asSet
in interface OptionSet<TailOption>
public Iterator<TailOption> iterator()
iterator
in interface Iterable<TailOption>
iterator
in interface OptionSet<TailOption>
public boolean useAcronymFor(TailOption option)
acronym
should be used in
for the specified option
string representations.
In particular and independent from the option
argument, this
option set returns true if the last option added to this set was an
acronym, and false if it was a long option name.
For instance, the set defined as
TailOptionSet_cqs.chars.s;uses acronyms, that is, this method always returns true for the above set.
On the other hand, long option names are used and this method always returns false for the set
TailOptionSet_cqs.c.countFromStart;
Note that a repeated option is not treated as the last set option. For instance, the first and last option of the following set are equivalent and acronyms are used:
TailOptionSet_cqs.c.s.chars;
This method always returns true for the empty set with no active options.
useAcronymFor
in interface OptionSet<TailOption>
option
- the option of interest, has no impact on the result returned
by this methodCopyright © 2024. All rights reserved.