{-# LANGUAGE GeneralizedNewtypeDeriving #-} {-| Module : Network.Telnet.LibTelnet.Iac Description : Constants for interpret-as-command (IAC) codes Copyright : (c) 2017-2021 Jack Kelly License : GPL-3.0-or-later Maintainer : jack@jackkelly.name Stability : experimental Portability : non-portable Telnet interpret-as-command (IAC) codes. See for the meaning of many of these. -} module Network.Telnet.LibTelnet.Iac ( Iac(..) , iacNull , iacIac , iacDont , iacDo , iacWont , iacWill , iacSB , iacGA , iacEL , iacEC , iacAYT , iacAO , iacIP , iacBreak , iacDM , iacNOP , iacSE , iacEOR , iacAbort , iacSusp , iacEOF ) where import Foreign (Storable) import Foreign.C (CUChar) #include -- | Wrapper for telnet commands and special values. newtype Iac = Iac { unIac :: CUChar } deriving (Eq, Show, Storable) #{enum Iac, Iac , iacNull = 0 , iacIac = TELNET_IAC , iacDont = TELNET_DONT , iacDo = TELNET_DO , iacWont = TELNET_WONT , iacWill = TELNET_WILL , iacSB = TELNET_SB , iacGA = TELNET_GA , iacEL = TELNET_EL , iacEC = TELNET_EC , iacAYT = TELNET_AYT , iacAO = TELNET_AO , iacIP = TELNET_IP , iacBreak = TELNET_BREAK , iacDM = TELNET_DM , iacNOP = TELNET_NOP , iacSE = TELNET_SE , iacEOR = TELNET_EOR , iacAbort = TELNET_ABORT , iacSusp = TELNET_SUSP , iacEOF = TELNET_EOF }