simplex-chat-6.5.0.7
Safe HaskellNone
LanguageHaskell2010

Simplex.Chat.Types.Preferences

Documentation

data ChatFeature Source #

Instances

Instances details
FromJSON ChatFeature Source # 
Instance details

Defined in Simplex.Chat.Types.Preferences

Methods

parseJSON :: Value -> Parser ChatFeature

parseJSONList :: Value -> Parser [ChatFeature]

omittedField :: Maybe ChatFeature

ToJSON ChatFeature Source # 
Instance details

Defined in Simplex.Chat.Types.Preferences

Methods

toJSON :: ChatFeature -> Value

toEncoding :: ChatFeature -> Encoding

toJSONList :: [ChatFeature] -> Value

toEncodingList :: [ChatFeature] -> Encoding

omitField :: ChatFeature -> Bool

Show ChatFeature Source # 
Instance details

Defined in Simplex.Chat.Types.Preferences

Methods

showsPrec :: Int -> ChatFeature -> ShowS

show :: ChatFeature -> String

showList :: [ChatFeature] -> ShowS

data AChatFeature Source #

Constructors

FeatureI f => ACF (SChatFeature f) 

Instances

Instances details
Show AChatFeature Source # 
Instance details

Defined in Simplex.Chat.Types.Preferences

Methods

showsPrec :: Int -> AChatFeature -> ShowS

show :: AChatFeature -> String

showList :: [AChatFeature] -> ShowS

class PreferenceI p where Source #

Methods

getPreference :: forall (f :: ChatFeature). SChatFeature f -> p -> FeaturePreference f Source #

data Preferences Source #

Instances

Instances details
FromJSON Preferences Source # 
Instance details

Defined in Simplex.Chat.Types.Preferences

Methods

parseJSON :: Value -> Parser Preferences

parseJSONList :: Value -> Parser [Preferences]

omittedField :: Maybe Preferences

ToJSON Preferences Source # 
Instance details

Defined in Simplex.Chat.Types.Preferences

Methods

toJSON :: Preferences -> Value

toEncoding :: Preferences -> Encoding

toJSONList :: [Preferences] -> Value

toEncodingList :: [Preferences] -> Encoding

omitField :: Preferences -> Bool

Show Preferences Source # 
Instance details

Defined in Simplex.Chat.Types.Preferences

Methods

showsPrec :: Int -> Preferences -> ShowS

show :: Preferences -> String

showList :: [Preferences] -> ShowS

Eq Preferences Source # 
Instance details

Defined in Simplex.Chat.Types.Preferences

Methods

(==) :: Preferences -> Preferences -> Bool

(/=) :: Preferences -> Preferences -> Bool

HasCommands Preferences Source # 
Instance details

Defined in Simplex.Chat.Types.Preferences

PreferenceI Preferences Source # 
Instance details

Defined in Simplex.Chat.Types.Preferences

FromField Preferences Source # 
Instance details

Defined in Simplex.Chat.Types.Preferences

Methods

fromField :: FieldParser Preferences #

ToField Preferences Source # 
Instance details

Defined in Simplex.Chat.Types.Preferences

Methods

toField :: Preferences -> SQLData #

PreferenceI (Maybe Preferences) Source # 
Instance details

Defined in Simplex.Chat.Types.Preferences

class HasCommands p where Source #

Methods

commands_ :: p -> Maybe [ChatBotCommand] Source #

Instances

Instances details
HasCommands GroupPreferences Source # 
Instance details

Defined in Simplex.Chat.Types.Preferences

HasCommands Preferences Source # 
Instance details

Defined in Simplex.Chat.Types.Preferences

data GroupFeature Source #

Instances

Instances details
FromJSON GroupFeature Source # 
Instance details

Defined in Simplex.Chat.Types.Preferences

Methods

parseJSON :: Value -> Parser GroupFeature

parseJSONList :: Value -> Parser [GroupFeature]

omittedField :: Maybe GroupFeature

ToJSON GroupFeature Source # 
Instance details

Defined in Simplex.Chat.Types.Preferences

Methods

toJSON :: GroupFeature -> Value

toEncoding :: GroupFeature -> Encoding

toJSONList :: [GroupFeature] -> Value

toEncodingList :: [GroupFeature] -> Encoding

omitField :: GroupFeature -> Bool

Show GroupFeature Source # 
Instance details

Defined in Simplex.Chat.Types.Preferences

Methods

showsPrec :: Int -> GroupFeature -> ShowS

show :: GroupFeature -> String

showList :: [GroupFeature] -> ShowS

data AGroupFeature Source #

Constructors

GroupFeatureI f => AGF (SGroupFeature f) 

Instances

Instances details
Show AGroupFeature Source # 
Instance details

Defined in Simplex.Chat.Types.Preferences

Methods

showsPrec :: Int -> AGroupFeature -> ShowS

show :: AGroupFeature -> String

showList :: [AGroupFeature] -> ShowS

data AGroupFeatureNoRole Source #

Constructors

GroupFeatureNoRoleI f => AGFNR (SGroupFeature f) 

Instances

Instances details
Show AGroupFeatureNoRole Source # 
Instance details

Defined in Simplex.Chat.Types.Preferences

Methods

showsPrec :: Int -> AGroupFeatureNoRole -> ShowS

show :: AGroupFeatureNoRole -> String

showList :: [AGroupFeatureNoRole] -> ShowS

data AGroupFeatureRole Source #

Constructors

GroupFeatureRoleI f => AGFR (SGroupFeature f) 

Instances

Instances details
Show AGroupFeatureRole Source # 
Instance details

Defined in Simplex.Chat.Types.Preferences

Methods

showsPrec :: Int -> AGroupFeatureRole -> ShowS

show :: AGroupFeatureRole -> String

showList :: [AGroupFeatureRole] -> ShowS

data GroupPreferences Source #

Instances

Instances details
FromJSON GroupPreferences Source # 
Instance details

Defined in Simplex.Chat.Types.Preferences

Methods

parseJSON :: Value -> Parser GroupPreferences

parseJSONList :: Value -> Parser [GroupPreferences]

omittedField :: Maybe GroupPreferences

ToJSON GroupPreferences Source # 
Instance details

Defined in Simplex.Chat.Types.Preferences

Show GroupPreferences Source # 
Instance details

Defined in Simplex.Chat.Types.Preferences

Methods

showsPrec :: Int -> GroupPreferences -> ShowS

show :: GroupPreferences -> String

showList :: [GroupPreferences] -> ShowS

Eq GroupPreferences Source # 
Instance details

Defined in Simplex.Chat.Types.Preferences

GroupPreferenceI GroupPreferences Source # 
Instance details

Defined in Simplex.Chat.Types.Preferences

HasCommands GroupPreferences Source # 
Instance details

Defined in Simplex.Chat.Types.Preferences

FromField GroupPreferences Source # 
Instance details

Defined in Simplex.Chat.Types.Preferences

Methods

fromField :: FieldParser GroupPreferences #

ToField GroupPreferences Source # 
Instance details

Defined in Simplex.Chat.Types.Preferences

Methods

toField :: GroupPreferences -> SQLData #

GroupPreferenceI (Maybe GroupPreferences) Source # 
Instance details

Defined in Simplex.Chat.Types.Preferences

data ChatBotCommand Source #

Constructors

CBCCommand 

Fields

CBCMenu 

Fields

Instances

Instances details
FromJSON ChatBotCommand Source # 
Instance details

Defined in Simplex.Chat.Types.Preferences

Methods

parseJSON :: Value -> Parser ChatBotCommand

parseJSONList :: Value -> Parser [ChatBotCommand]

omittedField :: Maybe ChatBotCommand

ToJSON ChatBotCommand Source # 
Instance details

Defined in Simplex.Chat.Types.Preferences

Methods

toJSON :: ChatBotCommand -> Value

toEncoding :: ChatBotCommand -> Encoding

toJSONList :: [ChatBotCommand] -> Value

toEncodingList :: [ChatBotCommand] -> Encoding

omitField :: ChatBotCommand -> Bool

Show ChatBotCommand Source # 
Instance details

Defined in Simplex.Chat.Types.Preferences

Methods

showsPrec :: Int -> ChatBotCommand -> ShowS

show :: ChatBotCommand -> String

showList :: [ChatBotCommand] -> ShowS

Eq ChatBotCommand Source # 
Instance details

Defined in Simplex.Chat.Types.Preferences

newtype ListDef a Source #

Constructors

ListDef [a] 

Instances

Instances details
FromJSON a => FromJSON (ListDef a) Source # 
Instance details

Defined in Simplex.Chat.Types.Preferences

Methods

parseJSON :: Value -> Parser (ListDef a)

parseJSONList :: Value -> Parser [ListDef a]

omittedField :: Maybe (ListDef a)

ToJSON a => ToJSON (ListDef a) Source # 
Instance details

Defined in Simplex.Chat.Types.Preferences

Methods

toJSON :: ListDef a -> Value

toEncoding :: ListDef a -> Encoding

toJSONList :: [ListDef a] -> Value

toEncodingList :: [ListDef a] -> Encoding

omitField :: ListDef a -> Bool

Show a => Show (ListDef a) Source # 
Instance details

Defined in Simplex.Chat.Types.Preferences

Methods

showsPrec :: Int -> ListDef a -> ShowS

show :: ListDef a -> String

showList :: [ListDef a] -> ShowS

Eq a => Eq (ListDef a) Source # 
Instance details

Defined in Simplex.Chat.Types.Preferences

Methods

(==) :: ListDef a -> ListDef a -> Bool

(/=) :: ListDef a -> ListDef a -> Bool

data FullGroupPreferences Source #

data ContactUserPreferences Source #

data ContactUserPreference p Source #

Instances

Instances details
FromJSON p => FromJSON (ContactUserPreference p) Source # 
Instance details

Defined in Simplex.Chat.Types.Preferences

Methods

parseJSON :: Value -> Parser (ContactUserPreference p)

parseJSONList :: Value -> Parser [ContactUserPreference p]

omittedField :: Maybe (ContactUserPreference p)

ToJSON p => ToJSON (ContactUserPreference p) Source # 
Instance details

Defined in Simplex.Chat.Types.Preferences

Show p => Show (ContactUserPreference p) Source # 
Instance details

Defined in Simplex.Chat.Types.Preferences

Methods

showsPrec :: Int -> ContactUserPreference p -> ShowS

show :: ContactUserPreference p -> String

showList :: [ContactUserPreference p] -> ShowS

Eq p => Eq (ContactUserPreference p) Source # 
Instance details

Defined in Simplex.Chat.Types.Preferences

data ContactUserPref p Source #

Constructors

CUPContact 

Fields

CUPUser 

Fields

Instances

Instances details
FromJSON p => FromJSON (ContactUserPref p) Source # 
Instance details

Defined in Simplex.Chat.Types.Preferences

Methods

parseJSON :: Value -> Parser (ContactUserPref p)

parseJSONList :: Value -> Parser [ContactUserPref p]

omittedField :: Maybe (ContactUserPref p)

ToJSON p => ToJSON (ContactUserPref p) Source # 
Instance details

Defined in Simplex.Chat.Types.Preferences

Methods

toJSON :: ContactUserPref p -> Value

toEncoding :: ContactUserPref p -> Encoding

toJSONList :: [ContactUserPref p] -> Value

toEncodingList :: [ContactUserPref p] -> Encoding

omitField :: ContactUserPref p -> Bool

Show p => Show (ContactUserPref p) Source # 
Instance details

Defined in Simplex.Chat.Types.Preferences

Methods

showsPrec :: Int -> ContactUserPref p -> ShowS

show :: ContactUserPref p -> String

showList :: [ContactUserPref p] -> ShowS

Eq p => Eq (ContactUserPref p) Source # 
Instance details

Defined in Simplex.Chat.Types.Preferences

Methods

(==) :: ContactUserPref p -> ContactUserPref p -> Bool

(/=) :: ContactUserPref p -> ContactUserPref p -> Bool

data VoicePreference Source #

Constructors

VoicePreference 

Instances

Instances details
FromJSON VoicePreference Source # 
Instance details

Defined in Simplex.Chat.Types.Preferences

Methods

parseJSON :: Value -> Parser VoicePreference

parseJSONList :: Value -> Parser [VoicePreference]

omittedField :: Maybe VoicePreference

ToJSON VoicePreference Source # 
Instance details

Defined in Simplex.Chat.Types.Preferences

Show VoicePreference Source # 
Instance details

Defined in Simplex.Chat.Types.Preferences

Methods

showsPrec :: Int -> VoicePreference -> ShowS

show :: VoicePreference -> String

showList :: [VoicePreference] -> ShowS

Eq VoicePreference Source # 
Instance details

Defined in Simplex.Chat.Types.Preferences

HasField "allow" VoicePreference FeatureAllowed Source # 
Instance details

Defined in Simplex.Chat.Types.Preferences

data FilesPreference Source #

Constructors

FilesPreference 

Instances

Instances details
FromJSON FilesPreference Source # 
Instance details

Defined in Simplex.Chat.Types.Preferences

Methods

parseJSON :: Value -> Parser FilesPreference

parseJSONList :: Value -> Parser [FilesPreference]

omittedField :: Maybe FilesPreference

ToJSON FilesPreference Source # 
Instance details

Defined in Simplex.Chat.Types.Preferences

Show FilesPreference Source # 
Instance details

Defined in Simplex.Chat.Types.Preferences

Methods

showsPrec :: Int -> FilesPreference -> ShowS

show :: FilesPreference -> String

showList :: [FilesPreference] -> ShowS

Eq FilesPreference Source # 
Instance details

Defined in Simplex.Chat.Types.Preferences

HasField "allow" FilesPreference FeatureAllowed Source # 
Instance details

Defined in Simplex.Chat.Types.Preferences

data CallsPreference Source #

Constructors

CallsPreference 

Instances

Instances details
FromJSON CallsPreference Source # 
Instance details

Defined in Simplex.Chat.Types.Preferences

Methods

parseJSON :: Value -> Parser CallsPreference

parseJSONList :: Value -> Parser [CallsPreference]

omittedField :: Maybe CallsPreference

ToJSON CallsPreference Source # 
Instance details

Defined in Simplex.Chat.Types.Preferences

Show CallsPreference Source # 
Instance details

Defined in Simplex.Chat.Types.Preferences

Methods

showsPrec :: Int -> CallsPreference -> ShowS

show :: CallsPreference -> String

showList :: [CallsPreference] -> ShowS

Eq CallsPreference Source # 
Instance details

Defined in Simplex.Chat.Types.Preferences

HasField "allow" CallsPreference FeatureAllowed Source # 
Instance details

Defined in Simplex.Chat.Types.Preferences

class (Eq (FeaturePreference f), HasField "allow" (FeaturePreference f) FeatureAllowed) => FeatureI (f :: ChatFeature) where Source #

Associated Types

type FeaturePreference (f :: ChatFeature) = (p :: Type) | p -> f Source #

Instances

Instances details
FeatureI 'CFCalls Source # 
Instance details

Defined in Simplex.Chat.Types.Preferences

Associated Types

type FeaturePreference 'CFCalls 
Instance details

Defined in Simplex.Chat.Types.Preferences

FeatureI 'CFFiles Source # 
Instance details

Defined in Simplex.Chat.Types.Preferences

Associated Types

type FeaturePreference 'CFFiles 
Instance details

Defined in Simplex.Chat.Types.Preferences

FeatureI 'CFFullDelete Source # 
Instance details

Defined in Simplex.Chat.Types.Preferences

FeatureI 'CFReactions Source # 
Instance details

Defined in Simplex.Chat.Types.Preferences

FeatureI 'CFSessions Source # 
Instance details

Defined in Simplex.Chat.Types.Preferences

FeatureI 'CFTimedMessages Source # 
Instance details

Defined in Simplex.Chat.Types.Preferences

FeatureI 'CFVoice Source # 
Instance details

Defined in Simplex.Chat.Types.Preferences

Associated Types

type FeaturePreference 'CFVoice 
Instance details

Defined in Simplex.Chat.Types.Preferences

data GroupPreference Source #

Instances

Instances details
FromJSON GroupPreference Source # 
Instance details

Defined in Simplex.Chat.Types.Preferences

Methods

parseJSON :: Value -> Parser GroupPreference

parseJSONList :: Value -> Parser [GroupPreference]

omittedField :: Maybe GroupPreference

ToJSON GroupPreference Source # 
Instance details

Defined in Simplex.Chat.Types.Preferences

Show GroupPreference Source # 
Instance details

Defined in Simplex.Chat.Types.Preferences

Methods

showsPrec :: Int -> GroupPreference -> ShowS

show :: GroupPreference -> String

showList :: [GroupPreference] -> ShowS

Eq GroupPreference Source # 
Instance details

Defined in Simplex.Chat.Types.Preferences

HasField "enable" GroupPreference GroupFeatureEnabled Source # 
Instance details

Defined in Simplex.Chat.Types.Preferences

data TimedMessagesGroupPreference Source #

Constructors

TimedMessagesGroupPreference 

Fields

data DirectMessagesGroupPreference Source #

Instances

Instances details
FromJSON DirectMessagesGroupPreference Source # 
Instance details

Defined in Simplex.Chat.Types.Preferences

ToJSON DirectMessagesGroupPreference Source # 
Instance details

Defined in Simplex.Chat.Types.Preferences

Show DirectMessagesGroupPreference Source # 
Instance details

Defined in Simplex.Chat.Types.Preferences

Eq DirectMessagesGroupPreference Source # 
Instance details

Defined in Simplex.Chat.Types.Preferences

HasField "enable" DirectMessagesGroupPreference GroupFeatureEnabled Source # 
Instance details

Defined in Simplex.Chat.Types.Preferences

HasField "role" DirectMessagesGroupPreference (Maybe GroupMemberRole) Source # 
Instance details

Defined in Simplex.Chat.Types.Preferences

data FullDeleteGroupPreference Source #

Instances

Instances details
FromJSON FullDeleteGroupPreference Source # 
Instance details

Defined in Simplex.Chat.Types.Preferences

ToJSON FullDeleteGroupPreference Source # 
Instance details

Defined in Simplex.Chat.Types.Preferences

Show FullDeleteGroupPreference Source # 
Instance details

Defined in Simplex.Chat.Types.Preferences

Eq FullDeleteGroupPreference Source # 
Instance details

Defined in Simplex.Chat.Types.Preferences

HasField "enable" FullDeleteGroupPreference GroupFeatureEnabled Source # 
Instance details

Defined in Simplex.Chat.Types.Preferences

HasField "role" FullDeleteGroupPreference (Maybe GroupMemberRole) Source # 
Instance details

Defined in Simplex.Chat.Types.Preferences

data VoiceGroupPreference Source #

Instances

Instances details
FromJSON VoiceGroupPreference Source # 
Instance details

Defined in Simplex.Chat.Types.Preferences

ToJSON VoiceGroupPreference Source # 
Instance details

Defined in Simplex.Chat.Types.Preferences

Show VoiceGroupPreference Source # 
Instance details

Defined in Simplex.Chat.Types.Preferences

Methods

showsPrec :: Int -> VoiceGroupPreference -> ShowS

show :: VoiceGroupPreference -> String

showList :: [VoiceGroupPreference] -> ShowS

Eq VoiceGroupPreference Source # 
Instance details

Defined in Simplex.Chat.Types.Preferences

HasField "enable" VoiceGroupPreference GroupFeatureEnabled Source # 
Instance details

Defined in Simplex.Chat.Types.Preferences

HasField "role" VoiceGroupPreference (Maybe GroupMemberRole) Source # 
Instance details

Defined in Simplex.Chat.Types.Preferences

data FilesGroupPreference Source #

Instances

Instances details
FromJSON FilesGroupPreference Source # 
Instance details

Defined in Simplex.Chat.Types.Preferences

ToJSON FilesGroupPreference Source # 
Instance details

Defined in Simplex.Chat.Types.Preferences

Show FilesGroupPreference Source # 
Instance details

Defined in Simplex.Chat.Types.Preferences

Methods

showsPrec :: Int -> FilesGroupPreference -> ShowS

show :: FilesGroupPreference -> String

showList :: [FilesGroupPreference] -> ShowS

Eq FilesGroupPreference Source # 
Instance details

Defined in Simplex.Chat.Types.Preferences

HasField "enable" FilesGroupPreference GroupFeatureEnabled Source # 
Instance details

Defined in Simplex.Chat.Types.Preferences

HasField "role" FilesGroupPreference (Maybe GroupMemberRole) Source # 
Instance details

Defined in Simplex.Chat.Types.Preferences

data SimplexLinksGroupPreference Source #

Instances

Instances details
FromJSON SimplexLinksGroupPreference Source # 
Instance details

Defined in Simplex.Chat.Types.Preferences

ToJSON SimplexLinksGroupPreference Source # 
Instance details

Defined in Simplex.Chat.Types.Preferences

Show SimplexLinksGroupPreference Source # 
Instance details

Defined in Simplex.Chat.Types.Preferences

Eq SimplexLinksGroupPreference Source # 
Instance details

Defined in Simplex.Chat.Types.Preferences

HasField "enable" SimplexLinksGroupPreference GroupFeatureEnabled Source # 
Instance details

Defined in Simplex.Chat.Types.Preferences

HasField "role" SimplexLinksGroupPreference (Maybe GroupMemberRole) Source # 
Instance details

Defined in Simplex.Chat.Types.Preferences

data SessionsGroupPreference Source #

Instances

Instances details
FromJSON SessionsGroupPreference Source # 
Instance details

Defined in Simplex.Chat.Types.Preferences

ToJSON SessionsGroupPreference Source # 
Instance details

Defined in Simplex.Chat.Types.Preferences

Show SessionsGroupPreference Source # 
Instance details

Defined in Simplex.Chat.Types.Preferences

Eq SessionsGroupPreference Source # 
Instance details

Defined in Simplex.Chat.Types.Preferences

HasField "enable" SessionsGroupPreference GroupFeatureEnabled Source # 
Instance details

Defined in Simplex.Chat.Types.Preferences

HasField "role" SessionsGroupPreference (Maybe GroupMemberRole) Source # 
Instance details

Defined in Simplex.Chat.Types.Preferences

class (Eq (GroupFeaturePreference f), HasField "enable" (GroupFeaturePreference f) GroupFeatureEnabled) => GroupFeatureI (f :: GroupFeature) where Source #

Associated Types

type GroupFeaturePreference (f :: GroupFeature) = (p :: Type) | p -> f Source #

Instances

Instances details
GroupFeatureI 'GFDirectMessages Source # 
Instance details

Defined in Simplex.Chat.Types.Preferences

GroupFeatureI 'GFFiles Source # 
Instance details

Defined in Simplex.Chat.Types.Preferences

GroupFeatureI 'GFFullDelete Source # 
Instance details

Defined in Simplex.Chat.Types.Preferences

GroupFeatureI 'GFHistory Source # 
Instance details

Defined in Simplex.Chat.Types.Preferences

GroupFeatureI 'GFReactions Source # 
Instance details

Defined in Simplex.Chat.Types.Preferences

GroupFeatureI 'GFReports Source # 
Instance details

Defined in Simplex.Chat.Types.Preferences

GroupFeatureI 'GFSessions Source # 
Instance details

Defined in Simplex.Chat.Types.Preferences

GroupFeatureI 'GFSimplexLinks Source # 
Instance details

Defined in Simplex.Chat.Types.Preferences

GroupFeatureI 'GFTimedMessages Source # 
Instance details

Defined in Simplex.Chat.Types.Preferences

GroupFeatureI 'GFVoice Source # 
Instance details

Defined in Simplex.Chat.Types.Preferences

groupPrefStateText :: HasField "enable" p GroupFeatureEnabled => GroupFeature -> p -> Maybe Int -> Maybe GroupMemberRole -> Text Source #

groupParamText_ :: GroupFeature -> Maybe Int -> Text Source #

timedTTLText :: Int -> Text Source #

data FeatureAllowed Source #

Constructors

FAAlways 
FAYes 
FANo 

Instances

Instances details
FromJSON FeatureAllowed Source # 
Instance details

Defined in Simplex.Chat.Types.Preferences

Methods

parseJSON :: Value -> Parser FeatureAllowed

parseJSONList :: Value -> Parser [FeatureAllowed]

omittedField :: Maybe FeatureAllowed

ToJSON FeatureAllowed Source # 
Instance details

Defined in Simplex.Chat.Types.Preferences

Methods

toJSON :: FeatureAllowed -> Value

toEncoding :: FeatureAllowed -> Encoding

toJSONList :: [FeatureAllowed] -> Value

toEncodingList :: [FeatureAllowed] -> Encoding

omitField :: FeatureAllowed -> Bool

Show FeatureAllowed Source # 
Instance details

Defined in Simplex.Chat.Types.Preferences

Methods

showsPrec :: Int -> FeatureAllowed -> ShowS

show :: FeatureAllowed -> String

showList :: [FeatureAllowed] -> ShowS

Eq FeatureAllowed Source # 
Instance details

Defined in Simplex.Chat.Types.Preferences

StrEncoding FeatureAllowed Source # 
Instance details

Defined in Simplex.Chat.Types.Preferences

Methods

strEncode :: FeatureAllowed -> ByteString

strDecode :: ByteString -> Either String FeatureAllowed

strP :: Parser FeatureAllowed

FromField FeatureAllowed Source # 
Instance details

Defined in Simplex.Chat.Types.Preferences

Methods

fromField :: FieldParser FeatureAllowed #

ToField FeatureAllowed Source # 
Instance details

Defined in Simplex.Chat.Types.Preferences

Methods

toField :: FeatureAllowed -> SQLData #

HasField "allow" CallsPreference FeatureAllowed Source # 
Instance details

Defined in Simplex.Chat.Types.Preferences

HasField "allow" FilesPreference FeatureAllowed Source # 
Instance details

Defined in Simplex.Chat.Types.Preferences

HasField "allow" FullDeletePreference FeatureAllowed Source # 
Instance details

Defined in Simplex.Chat.Types.Preferences

HasField "allow" ReactionsPreference FeatureAllowed Source # 
Instance details

Defined in Simplex.Chat.Types.Preferences

HasField "allow" SessionsPreference FeatureAllowed Source # 
Instance details

Defined in Simplex.Chat.Types.Preferences

HasField "allow" TimedMessagesPreference FeatureAllowed Source # 
Instance details

Defined in Simplex.Chat.Types.Preferences

HasField "allow" VoicePreference FeatureAllowed Source # 
Instance details

Defined in Simplex.Chat.Types.Preferences

data GroupFeatureEnabled Source #

Constructors

FEOn 
FEOff 

Instances

Instances details
FromJSON GroupFeatureEnabled Source # 
Instance details

Defined in Simplex.Chat.Types.Preferences

ToJSON GroupFeatureEnabled Source # 
Instance details

Defined in Simplex.Chat.Types.Preferences

Show GroupFeatureEnabled Source # 
Instance details

Defined in Simplex.Chat.Types.Preferences

Methods

showsPrec :: Int -> GroupFeatureEnabled -> ShowS

show :: GroupFeatureEnabled -> String

showList :: [GroupFeatureEnabled] -> ShowS

Eq GroupFeatureEnabled Source # 
Instance details

Defined in Simplex.Chat.Types.Preferences

StrEncoding GroupFeatureEnabled Source # 
Instance details

Defined in Simplex.Chat.Types.Preferences

Methods

strEncode :: GroupFeatureEnabled -> ByteString

strDecode :: ByteString -> Either String GroupFeatureEnabled

strP :: Parser GroupFeatureEnabled

FromField GroupFeatureEnabled Source # 
Instance details

Defined in Simplex.Chat.Types.Preferences

Methods

fromField :: FieldParser GroupFeatureEnabled #

ToField GroupFeatureEnabled Source # 
Instance details

Defined in Simplex.Chat.Types.Preferences

Methods

toField :: GroupFeatureEnabled -> SQLData #

HasField "enable" DirectMessagesGroupPreference GroupFeatureEnabled Source # 
Instance details

Defined in Simplex.Chat.Types.Preferences

HasField "enable" FilesGroupPreference GroupFeatureEnabled Source # 
Instance details

Defined in Simplex.Chat.Types.Preferences

HasField "enable" FullDeleteGroupPreference GroupFeatureEnabled Source # 
Instance details

Defined in Simplex.Chat.Types.Preferences

HasField "enable" GroupPreference GroupFeatureEnabled Source # 
Instance details

Defined in Simplex.Chat.Types.Preferences

HasField "enable" HistoryGroupPreference GroupFeatureEnabled Source # 
Instance details

Defined in Simplex.Chat.Types.Preferences

HasField "enable" ReactionsGroupPreference GroupFeatureEnabled Source # 
Instance details

Defined in Simplex.Chat.Types.Preferences

HasField "enable" ReportsGroupPreference GroupFeatureEnabled Source # 
Instance details

Defined in Simplex.Chat.Types.Preferences

HasField "enable" SessionsGroupPreference GroupFeatureEnabled Source # 
Instance details

Defined in Simplex.Chat.Types.Preferences

HasField "enable" SimplexLinksGroupPreference GroupFeatureEnabled Source # 
Instance details

Defined in Simplex.Chat.Types.Preferences

HasField "enable" TimedMessagesGroupPreference GroupFeatureEnabled Source # 
Instance details

Defined in Simplex.Chat.Types.Preferences

HasField "enable" VoiceGroupPreference GroupFeatureEnabled Source # 
Instance details

Defined in Simplex.Chat.Types.Preferences

data PrefEnabled Source #

Constructors

PrefEnabled 

Fields

Instances

Instances details
FromJSON PrefEnabled Source # 
Instance details

Defined in Simplex.Chat.Types.Preferences

Methods

parseJSON :: Value -> Parser PrefEnabled

parseJSONList :: Value -> Parser [PrefEnabled]

omittedField :: Maybe PrefEnabled

ToJSON PrefEnabled Source # 
Instance details

Defined in Simplex.Chat.Types.Preferences

Methods

toJSON :: PrefEnabled -> Value

toEncoding :: PrefEnabled -> Encoding

toJSONList :: [PrefEnabled] -> Value

toEncodingList :: [PrefEnabled] -> Encoding

omitField :: PrefEnabled -> Bool

Show PrefEnabled Source # 
Instance details

Defined in Simplex.Chat.Types.Preferences

Methods

showsPrec :: Int -> PrefEnabled -> ShowS

show :: PrefEnabled -> String

showList :: [PrefEnabled] -> ShowS

Eq PrefEnabled Source # 
Instance details

Defined in Simplex.Chat.Types.Preferences

Methods

(==) :: PrefEnabled -> PrefEnabled -> Bool

(/=) :: PrefEnabled -> PrefEnabled -> Bool

prefStateText :: ChatFeature -> FeatureAllowed -> Maybe Int -> Text Source #

featureStateText :: ChatFeature -> PrefEnabled -> Maybe Int -> Text Source #

paramText_ :: ChatFeature -> Maybe Int -> Text Source #

prefEnabledToText :: ChatFeature -> PrefEnabled -> Maybe Int -> Text Source #

preferenceText :: forall (f :: ChatFeature). FeatureI f => FeaturePreference f -> Text Source #