{-# LINE 1 "src/Network/Telnet/LibTelnet/Options.hsc" #-}
{-# LANGUAGE GeneralizedNewtypeDeriving #-}

{-|
Module      : Network.Telnet.LibTelnet.Options
Description : Constants for option codes
Copyright   : (c) 2017-2019 Jack Kelly
License     : GPL-3.0-or-later
Maintainer  : jack@jackkelly.name
Stability   : experimental
Portability : non-portable

Telnet option codes. Many of these are defined in their own RFC.
<http://www.omnifarious.org/~hopper/technical/telnet-rfc.html> is a
good index of known options.
-}

module Network.Telnet.LibTelnet.Options
  ( Option(..)
  , optBinary
  , optEcho
  , optRCP
  , optSGA
  , optNAMS
  , optStatus
  , optTM
  , optRCTE
  , optNAOL
  , optNAOP
  , optNAOCRD
  , optNAOHTS
  , optNAOHTD
  , optNAOFFD
  , optNAOVTS
  , optNAOVTD
  , optNAOLFD
  , optXASCII
  , optLogout
  , optBM
  , optDET
  , optSUPDUP
  , optSUPDUPOutput
  , optSNDLOC
  , optTType
  , optEOR
  , optTUID
  , optOUTMRK
  , optTTYLOC
  , opt3270Regime
  , optX3Pad
  , optNAWS
  , optTSpeed
  , optLFlow
  , optLineMode
  , optXDISPLOC
  , optEnviron
  , optAuthentication
  , optEncrypt
  , optNewEnviron
  , optMSSP
  , optCompress2
  , optZMP
  , optEXOPL
  , optMCCP2
  ) where

import Foreign (Storable)
import Foreign.C (CUChar)



-- | Wrapper for telnet option codes.
newtype Option = Option { unOption :: CUChar } deriving (Eq, Show, Storable)
optBinary  :: Option
optBinary  = Option 0
optEcho  :: Option
optEcho  = Option 1
optRCP  :: Option
optRCP  = Option 2
optSGA  :: Option
optSGA  = Option 3
optNAMS  :: Option
optNAMS  = Option 4
optStatus  :: Option
optStatus  = Option 5
optTM  :: Option
optTM  = Option 6
optRCTE  :: Option
optRCTE  = Option 7
optNAOL  :: Option
optNAOL  = Option 8
optNAOP  :: Option
optNAOP  = Option 9
optNAOCRD  :: Option
optNAOCRD  = Option 10
optNAOHTS  :: Option
optNAOHTS  = Option 11
optNAOHTD  :: Option
optNAOHTD  = Option 12
optNAOFFD  :: Option
optNAOFFD  = Option 13
optNAOVTS  :: Option
optNAOVTS  = Option 14
optNAOVTD  :: Option
optNAOVTD  = Option 15
optNAOLFD  :: Option
optNAOLFD  = Option 16
optXASCII  :: Option
optXASCII  = Option 17
optLogout  :: Option
optLogout  = Option 18
optBM  :: Option
optBM  = Option 19
optDET  :: Option
optDET  = Option 20
optSUPDUP  :: Option
optSUPDUP  = Option 21
optSUPDUPOutput  :: Option
optSUPDUPOutput  = Option 22
optSNDLOC  :: Option
optSNDLOC  = Option 23
optTType  :: Option
optTType  = Option 24
optEOR  :: Option
optEOR  = Option 25
optTUID  :: Option
optTUID  = Option 26
optOUTMRK  :: Option
optOUTMRK  = Option 27
optTTYLOC  :: Option
optTTYLOC  = Option 28
opt3270Regime  :: Option
opt3270Regime  = Option 29
optX3Pad  :: Option
optX3Pad  = Option 30
optNAWS  :: Option
optNAWS  = Option 31
optTSpeed  :: Option
optTSpeed  = Option 32
optLFlow  :: Option
optLFlow  = Option 33
optLineMode  :: Option
optLineMode  = Option 34
optXDISPLOC  :: Option
optXDISPLOC  = Option 35
optEnviron  :: Option
optEnviron  = Option 36
optAuthentication  :: Option
optAuthentication  = Option 37
optEncrypt  :: Option
optEncrypt  = Option 38
optNewEnviron  :: Option
optNewEnviron  = Option 39
optMSSP  :: Option
optMSSP  = Option 70
optCompress2  :: Option
optCompress2  = Option 86
optZMP  :: Option
optZMP  = Option 93
optEXOPL  :: Option
optEXOPL  = Option 255
optMCCP2  :: Option
optMCCP2  = Option 86

{-# LINE 120 "src/Network/Telnet/LibTelnet/Options.hsc" #-}