001package org.unix4j.unix.wc;
002
003import org.unix4j.unix.Wc;
004
005/**
006 * Options for the {@link Wc wc} command with the 
007 * the following options: 
008 * <p>
009 * <table>
010 * <tr valign="top"><td width="10px"></td><td nowrap="nowrap">{@code -l}</td><td>&nbsp;&nbsp;</td><td nowrap="nowrap">{@code --lines}</td><td>&nbsp;</td><td>Executes a count of lines and writes this count to the output.</td></tr>
011 * <tr valign="top"><td width="10px"></td><td nowrap="nowrap">{@code -w}</td><td>&nbsp;&nbsp;</td><td nowrap="nowrap">{@code --words}</td><td>&nbsp;</td><td>Executes a count of words and writes this count to the output. A
012                        word is a non-zero-length string of characters delimited by white
013                        space as defined by {@link Character#isWhitespace(char)}.</td></tr>
014 * <tr valign="top"><td width="10px"></td><td nowrap="nowrap">{@code -m}</td><td>&nbsp;&nbsp;</td><td nowrap="nowrap">{@code --chars}</td><td>&nbsp;</td><td>Executes a count of chars and writes this count to the output.</td></tr>
015 * </table>
016 * <p>
017 * This class serves as entry point to every possible set of {@code wc} options
018 * defined as an enum constant. With this explicit expansion of all possible 
019 * option combinations, options can be passed to the command in a very compact 
020 * form, such as:
021 * <pre>
022 * wc(Wc.Options.l, ...);
023 * wc(Wc.Options.l.w, ...);
024 * ...
025 * wc(Wc.Options.l.w.m, ...);
026 * </pre>
027 */
028public final class WcOptionSets {
029        /**
030         * The singleton instance.
031         */
032        public static final WcOptionSets INSTANCE = new WcOptionSets();
033        
034        /**
035         * Option {@code "-m"}: Executes a count of chars and writes this count to the output.
036         * <p>
037         * The option {@code "-m"} is equivalent to the {@code "--}{@link #chars chars}{@code "} option.
038         */
039        public final WcOptionSet_lmw m = WcOptionSet_lmw.Active_m;  
040        /**
041         * Option {@code "--chars"}: Executes a count of chars and writes this count to the output.
042         * <p>
043         * The option {@code "--chars"} is equivalent to the {@code "-}{@link #m m}{@code "} option.
044         */
045        public final WcOptionSet_lmw chars = WcOptionSet_lmw.Active_m_long;  
046        /**
047         * Option {@code "-l"}: Executes a count of lines and writes this count to the output.
048         * <p>
049         * The option {@code "-l"} is equivalent to the {@code "--}{@link #lines lines}{@code "} option.
050         */
051        public final WcOptionSet_lmw l = WcOptionSet_lmw.Active_l;  
052        /**
053         * Option {@code "--lines"}: Executes a count of lines and writes this count to the output.
054         * <p>
055         * The option {@code "--lines"} is equivalent to the {@code "-}{@link #l l}{@code "} option.
056         */
057        public final WcOptionSet_lmw lines = WcOptionSet_lmw.Active_l_long;  
058        /**
059         * Option {@code "-w"}: Executes a count of words and writes this count to the output. A
060                        word is a non-zero-length string of characters delimited by white
061                        space as defined by {@link Character#isWhitespace(char)}.
062         * <p>
063         * The option {@code "-w"} is equivalent to the {@code "--}{@link #words words}{@code "} option.
064         */
065        public final WcOptionSet_lmw w = WcOptionSet_lmw.Active_w;  
066        /**
067         * Option {@code "--words"}: Executes a count of words and writes this count to the output. A
068                        word is a non-zero-length string of characters delimited by white
069                        space as defined by {@link Character#isWhitespace(char)}.
070         * <p>
071         * The option {@code "--words"} is equivalent to the {@code "-}{@link #w w}{@code "} option.
072         */
073        public final WcOptionSet_lmw words = WcOptionSet_lmw.Active_w_long;  
074        
075}