Package org.apache.commons.net.nntp

# Class NNTPCommand

java.lang.Object
org.apache.commons.net.nntp.NNTPCommand

public final class NNTPCommand extends Object
NNTPCommand stores a set of constants for NNTP command codes. To interpret the meaning of the codes, familiarity with RFC 977 is assumed.

- ## Field Summary

  Fields
  Modifier and Type
  Field
  Description
  `static final int`
  `ARTICLE`
  NNTP command code 0.
  `static final int`
  `AUTHINFO`
  NNTP command code 15.
  `static final int`
  `BODY`
  NNTP command code 1.
  `static final int`
  `GROUP`
  NNTP command code 2.
  `static final int`
  `HEAD`
  NNTP command code 3.
  `static final int`
  `HELP`
  NNTP command code 4.
  `static final int`
  `IHAVE`
  NNTP command code 5.
  `static final int`
  `LAST`
  NNTP command code 6.
  `static final int`
  `LIST`
  NNTP command code 7.
  `static final int`
  `NEWGROUPS`
  NNTP command code 8.
  `static final int`
  `NEWNEWS`
  NNTP command code 9.
  `static final int`
  `NEXT`
  NNTP command code 10.
  `static final int`
  `POST`
  NNTP command code 11.
  `static final int`
  `QUIT`
  NNTP command code 12.
  `static final int`
  `SLAVE`
  NNTP command code 13.
  `static final int`
  `STAT`
  NNTP command code 14.
  `static final int`
  `XHDR`
  NNTP command code 17.
  `static final int`
  `XOVER`
  NNTP command code 16.

- ## Method Summary

  Modifier and Type
  Method
  Description
  `static String`
  `getCommand(int command)`
  Gets the NNTP protocol command string corresponding to a specified command code.

  ### Methods inherited from class java.lang.Object

  `clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

- ## Field Details

  - ### ARTICLE

    public static final int ARTICLE
    NNTP command code 0.
    See Also:
      - Constant Field Values

  - ### BODY

    public static final int BODY
    NNTP command code 1.
    See Also:
      - Constant Field Values

  - ### GROUP

    public static final int GROUP
    NNTP command code 2.
    See Also:
      - Constant Field Values

  - ### HEAD

    public static final int HEAD
    NNTP command code 3.
    See Also:
      - Constant Field Values

  - ### HELP

    public static final int HELP
    NNTP command code 4.
    See Also:
      - Constant Field Values

  - ### IHAVE

    public static final int IHAVE
    NNTP command code 5.
    See Also:
      - Constant Field Values

  - ### LAST

    public static final int LAST
    NNTP command code 6.
    See Also:
      - Constant Field Values

  - ### LIST

    public static final int LIST
    NNTP command code 7.
    See Also:
      - Constant Field Values

  - ### NEWGROUPS

    public static final int NEWGROUPS
    NNTP command code 8.
    See Also:
      - Constant Field Values

  - ### NEWNEWS

    public static final int NEWNEWS
    NNTP command code 9.
    See Also:
      - Constant Field Values

  - ### NEXT

    public static final int NEXT
    NNTP command code 10.
    See Also:
      - Constant Field Values

  - ### POST

    public static final int POST
    NNTP command code 11.
    See Also:
      - Constant Field Values

  - ### QUIT

    public static final int QUIT
    NNTP command code 12.
    See Also:
      - Constant Field Values

  - ### SLAVE

    public static final int SLAVE
    NNTP command code 13.
    See Also:
      - Constant Field Values

  - ### STAT

    public static final int STAT
    NNTP command code 14.
    See Also:
      - Constant Field Values

  - ### AUTHINFO

    public static final int AUTHINFO
    NNTP command code 15.
    See Also:
      - Constant Field Values

  - ### XOVER

    public static final int XOVER
    NNTP command code 16.
    See Also:
      - Constant Field Values

  - ### XHDR

    public static final int XHDR
    NNTP command code 17.
    See Also:
      - Constant Field Values

- ## Method Details

  - ### getCommand

    public static String getCommand(int command)
    Gets the NNTP protocol command string corresponding to a specified command code.
    Parameters:
      `command` - The command code.
    Returns:
      The NNTP protcol command string corresponding to a specified command code.