{-# OPTIONS_GHC -Wno-unused-imports #-}
{-# OPTIONS_GHC -Wno-unused-matches #-}
{-# OPTIONS_GHC -Wno-deprecations #-}
module Language.LSP.Protocol.Internal.Types.DidChangeConfigurationParams where
import Control.DeepSeq
import Data.Hashable
import GHC.Generics
import Language.LSP.Protocol.Utils.Misc
import Prettyprinter
import qualified Data.Aeson
import qualified Data.Aeson as Aeson
import qualified Data.Row.Aeson as Aeson
import qualified Data.Row.Hashable as Hashable
import qualified Language.LSP.Protocol.Types.Common
data DidChangeConfigurationParams = DidChangeConfigurationParams
{
DidChangeConfigurationParams -> Value
_settings :: Data.Aeson.Value
}
deriving stock (Int -> DidChangeConfigurationParams -> ShowS
[DidChangeConfigurationParams] -> ShowS
DidChangeConfigurationParams -> String
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [DidChangeConfigurationParams] -> ShowS
$cshowList :: [DidChangeConfigurationParams] -> ShowS
show :: DidChangeConfigurationParams -> String
$cshow :: DidChangeConfigurationParams -> String
showsPrec :: Int -> DidChangeConfigurationParams -> ShowS
$cshowsPrec :: Int -> DidChangeConfigurationParams -> ShowS
Show, DidChangeConfigurationParams
-> DidChangeConfigurationParams -> Bool
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: DidChangeConfigurationParams
-> DidChangeConfigurationParams -> Bool
$c/= :: DidChangeConfigurationParams
-> DidChangeConfigurationParams -> Bool
== :: DidChangeConfigurationParams
-> DidChangeConfigurationParams -> Bool
$c== :: DidChangeConfigurationParams
-> DidChangeConfigurationParams -> Bool
Eq, Eq DidChangeConfigurationParams
DidChangeConfigurationParams
-> DidChangeConfigurationParams -> Bool
DidChangeConfigurationParams
-> DidChangeConfigurationParams -> Ordering
DidChangeConfigurationParams
-> DidChangeConfigurationParams -> DidChangeConfigurationParams
forall a.
Eq a
-> (a -> a -> Ordering)
-> (a -> a -> Bool)
-> (a -> a -> Bool)
-> (a -> a -> Bool)
-> (a -> a -> Bool)
-> (a -> a -> a)
-> (a -> a -> a)
-> Ord a
min :: DidChangeConfigurationParams
-> DidChangeConfigurationParams -> DidChangeConfigurationParams
$cmin :: DidChangeConfigurationParams
-> DidChangeConfigurationParams -> DidChangeConfigurationParams
max :: DidChangeConfigurationParams
-> DidChangeConfigurationParams -> DidChangeConfigurationParams
$cmax :: DidChangeConfigurationParams
-> DidChangeConfigurationParams -> DidChangeConfigurationParams
>= :: DidChangeConfigurationParams
-> DidChangeConfigurationParams -> Bool
$c>= :: DidChangeConfigurationParams
-> DidChangeConfigurationParams -> Bool
> :: DidChangeConfigurationParams
-> DidChangeConfigurationParams -> Bool
$c> :: DidChangeConfigurationParams
-> DidChangeConfigurationParams -> Bool
<= :: DidChangeConfigurationParams
-> DidChangeConfigurationParams -> Bool
$c<= :: DidChangeConfigurationParams
-> DidChangeConfigurationParams -> Bool
< :: DidChangeConfigurationParams
-> DidChangeConfigurationParams -> Bool
$c< :: DidChangeConfigurationParams
-> DidChangeConfigurationParams -> Bool
compare :: DidChangeConfigurationParams
-> DidChangeConfigurationParams -> Ordering
$ccompare :: DidChangeConfigurationParams
-> DidChangeConfigurationParams -> Ordering
Ord, forall x.
Rep DidChangeConfigurationParams x -> DidChangeConfigurationParams
forall x.
DidChangeConfigurationParams -> Rep DidChangeConfigurationParams x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x.
Rep DidChangeConfigurationParams x -> DidChangeConfigurationParams
$cfrom :: forall x.
DidChangeConfigurationParams -> Rep DidChangeConfigurationParams x
Generic)
deriving anyclass (DidChangeConfigurationParams -> ()
forall a. (a -> ()) -> NFData a
rnf :: DidChangeConfigurationParams -> ()
$crnf :: DidChangeConfigurationParams -> ()
NFData, Eq DidChangeConfigurationParams
Int -> DidChangeConfigurationParams -> Int
DidChangeConfigurationParams -> Int
forall a. Eq a -> (Int -> a -> Int) -> (a -> Int) -> Hashable a
hash :: DidChangeConfigurationParams -> Int
$chash :: DidChangeConfigurationParams -> Int
hashWithSalt :: Int -> DidChangeConfigurationParams -> Int
$chashWithSalt :: Int -> DidChangeConfigurationParams -> Int
Hashable)
deriving forall ann. [DidChangeConfigurationParams] -> Doc ann
forall ann. DidChangeConfigurationParams -> Doc ann
forall a.
(forall ann. a -> Doc ann)
-> (forall ann. [a] -> Doc ann) -> Pretty a
prettyList :: forall ann. [DidChangeConfigurationParams] -> Doc ann
$cprettyList :: forall ann. [DidChangeConfigurationParams] -> Doc ann
pretty :: forall ann. DidChangeConfigurationParams -> Doc ann
$cpretty :: forall ann. DidChangeConfigurationParams -> Doc ann
Pretty via (ViaJSON DidChangeConfigurationParams)
instance Aeson.ToJSON DidChangeConfigurationParams where
toJSON :: DidChangeConfigurationParams -> Value
toJSON (DidChangeConfigurationParams Value
arg0) = [Pair] -> Value
Aeson.object forall a b. (a -> b) -> a -> b
$ forall (t :: * -> *) a. Foldable t => t [a] -> [a]
concat forall a b. (a -> b) -> a -> b
$ [[Key
"settings" forall kv v. (KeyValue kv, ToJSON v) => Key -> v -> kv
Aeson..= Value
arg0]]
instance Aeson.FromJSON DidChangeConfigurationParams where
parseJSON :: Value -> Parser DidChangeConfigurationParams
parseJSON = forall a. String -> (Object -> Parser a) -> Value -> Parser a
Aeson.withObject String
"DidChangeConfigurationParams" forall a b. (a -> b) -> a -> b
$ \Object
arg -> Value -> DidChangeConfigurationParams
DidChangeConfigurationParams forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
<$> Object
arg forall a. FromJSON a => Object -> Key -> Parser a
Aeson..: Key
"settings"