-- | This module exports the input classification type to avoid import
-- cycles between other modules that need this.
{-# LANGUAGE StrictData #-}
module Graphics.Vty.Input.Classify.Types
  ( KClass(..)
  )
where

import Graphics.Vty.Input.Events

import Data.ByteString.Char8 (ByteString)

data KClass
    = Valid Event ByteString
    -- ^ A valid event was parsed. Any unused characters from the input
    -- stream are also provided.
    | Invalid
    -- ^ The input characters did not represent a valid event.
    | Prefix
    -- ^ The input characters form the prefix of a valid event character
    -- sequence.
    | Chunk
    -- ^ The input characters are either start of a bracketed paste chunk
    -- or in the middle of a bracketed paste chunk.
    deriving(Int -> KClass -> ShowS
[KClass] -> ShowS
KClass -> String
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [KClass] -> ShowS
$cshowList :: [KClass] -> ShowS
show :: KClass -> String
$cshow :: KClass -> String
showsPrec :: Int -> KClass -> ShowS
$cshowsPrec :: Int -> KClass -> ShowS
Show, KClass -> KClass -> Bool
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: KClass -> KClass -> Bool
$c/= :: KClass -> KClass -> Bool
== :: KClass -> KClass -> Bool
$c== :: KClass -> KClass -> Bool
Eq)