{- ORMOLU_DISABLE -}
{- HLINT ignore -}
-- THIS IS A GENERATED FILE, DO NOT EDIT

{-# OPTIONS_GHC -Wno-unused-imports #-}
{-# OPTIONS_GHC -Wno-unused-matches #-}
{-# OPTIONS_GHC -Wno-deprecations #-}
module Language.LSP.Protocol.Internal.Types.GlobPattern where

import Control.DeepSeq
import Data.Hashable
import GHC.Generics
import Language.LSP.Protocol.Utils.Misc
import Prettyprinter
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.Internal.Types.Pattern
import qualified Language.LSP.Protocol.Internal.Types.RelativePattern
import qualified Language.LSP.Protocol.Types.Common

{-|
The glob pattern. Either a string pattern or a relative pattern.

@since 3.17.0
-}
newtype GlobPattern = GlobPattern (Language.LSP.Protocol.Internal.Types.Pattern.Pattern Language.LSP.Protocol.Types.Common.|? Language.LSP.Protocol.Internal.Types.RelativePattern.RelativePattern)
  deriving newtype ([GlobPattern] -> Value
[GlobPattern] -> Encoding
GlobPattern -> Bool
GlobPattern -> Value
GlobPattern -> Encoding
(GlobPattern -> Value)
-> (GlobPattern -> Encoding)
-> ([GlobPattern] -> Value)
-> ([GlobPattern] -> Encoding)
-> (GlobPattern -> Bool)
-> ToJSON GlobPattern
forall a.
(a -> Value)
-> (a -> Encoding)
-> ([a] -> Value)
-> ([a] -> Encoding)
-> (a -> Bool)
-> ToJSON a
$ctoJSON :: GlobPattern -> Value
toJSON :: GlobPattern -> Value
$ctoEncoding :: GlobPattern -> Encoding
toEncoding :: GlobPattern -> Encoding
$ctoJSONList :: [GlobPattern] -> Value
toJSONList :: [GlobPattern] -> Value
$ctoEncodingList :: [GlobPattern] -> Encoding
toEncodingList :: [GlobPattern] -> Encoding
$comitField :: GlobPattern -> Bool
omitField :: GlobPattern -> Bool
Aeson.ToJSON, Maybe GlobPattern
Value -> Parser [GlobPattern]
Value -> Parser GlobPattern
(Value -> Parser GlobPattern)
-> (Value -> Parser [GlobPattern])
-> Maybe GlobPattern
-> FromJSON GlobPattern
forall a.
(Value -> Parser a)
-> (Value -> Parser [a]) -> Maybe a -> FromJSON a
$cparseJSON :: Value -> Parser GlobPattern
parseJSON :: Value -> Parser GlobPattern
$cparseJSONList :: Value -> Parser [GlobPattern]
parseJSONList :: Value -> Parser [GlobPattern]
$comittedField :: Maybe GlobPattern
omittedField :: Maybe GlobPattern
Aeson.FromJSON)
  deriving stock (Int -> GlobPattern -> ShowS
[GlobPattern] -> ShowS
GlobPattern -> String
(Int -> GlobPattern -> ShowS)
-> (GlobPattern -> String)
-> ([GlobPattern] -> ShowS)
-> Show GlobPattern
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
$cshowsPrec :: Int -> GlobPattern -> ShowS
showsPrec :: Int -> GlobPattern -> ShowS
$cshow :: GlobPattern -> String
show :: GlobPattern -> String
$cshowList :: [GlobPattern] -> ShowS
showList :: [GlobPattern] -> ShowS
Show, GlobPattern -> GlobPattern -> Bool
(GlobPattern -> GlobPattern -> Bool)
-> (GlobPattern -> GlobPattern -> Bool) -> Eq GlobPattern
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
$c== :: GlobPattern -> GlobPattern -> Bool
== :: GlobPattern -> GlobPattern -> Bool
$c/= :: GlobPattern -> GlobPattern -> Bool
/= :: GlobPattern -> GlobPattern -> Bool
Eq, Eq GlobPattern
Eq GlobPattern =>
(GlobPattern -> GlobPattern -> Ordering)
-> (GlobPattern -> GlobPattern -> Bool)
-> (GlobPattern -> GlobPattern -> Bool)
-> (GlobPattern -> GlobPattern -> Bool)
-> (GlobPattern -> GlobPattern -> Bool)
-> (GlobPattern -> GlobPattern -> GlobPattern)
-> (GlobPattern -> GlobPattern -> GlobPattern)
-> Ord GlobPattern
GlobPattern -> GlobPattern -> Bool
GlobPattern -> GlobPattern -> Ordering
GlobPattern -> GlobPattern -> GlobPattern
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
$ccompare :: GlobPattern -> GlobPattern -> Ordering
compare :: GlobPattern -> GlobPattern -> Ordering
$c< :: GlobPattern -> GlobPattern -> Bool
< :: GlobPattern -> GlobPattern -> Bool
$c<= :: GlobPattern -> GlobPattern -> Bool
<= :: GlobPattern -> GlobPattern -> Bool
$c> :: GlobPattern -> GlobPattern -> Bool
> :: GlobPattern -> GlobPattern -> Bool
$c>= :: GlobPattern -> GlobPattern -> Bool
>= :: GlobPattern -> GlobPattern -> Bool
$cmax :: GlobPattern -> GlobPattern -> GlobPattern
max :: GlobPattern -> GlobPattern -> GlobPattern
$cmin :: GlobPattern -> GlobPattern -> GlobPattern
min :: GlobPattern -> GlobPattern -> GlobPattern
Ord, (forall x. GlobPattern -> Rep GlobPattern x)
-> (forall x. Rep GlobPattern x -> GlobPattern)
-> Generic GlobPattern
forall x. Rep GlobPattern x -> GlobPattern
forall x. GlobPattern -> Rep GlobPattern x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cfrom :: forall x. GlobPattern -> Rep GlobPattern x
from :: forall x. GlobPattern -> Rep GlobPattern x
$cto :: forall x. Rep GlobPattern x -> GlobPattern
to :: forall x. Rep GlobPattern x -> GlobPattern
Generic)
  deriving anyclass (GlobPattern -> ()
(GlobPattern -> ()) -> NFData GlobPattern
forall a. (a -> ()) -> NFData a
$crnf :: GlobPattern -> ()
rnf :: GlobPattern -> ()
NFData, Eq GlobPattern
Eq GlobPattern =>
(Int -> GlobPattern -> Int)
-> (GlobPattern -> Int) -> Hashable GlobPattern
Int -> GlobPattern -> Int
GlobPattern -> Int
forall a. Eq a => (Int -> a -> Int) -> (a -> Int) -> Hashable a
$chashWithSalt :: Int -> GlobPattern -> Int
hashWithSalt :: Int -> GlobPattern -> Int
$chash :: GlobPattern -> Int
hash :: GlobPattern -> Int
Hashable)
  deriving (forall ann. GlobPattern -> Doc ann)
-> (forall ann. [GlobPattern] -> Doc ann) -> Pretty GlobPattern
forall ann. [GlobPattern] -> Doc ann
forall ann. GlobPattern -> Doc ann
forall a.
(forall ann. a -> Doc ann)
-> (forall ann. [a] -> Doc ann) -> Pretty a
$cpretty :: forall ann. GlobPattern -> Doc ann
pretty :: forall ann. GlobPattern -> Doc ann
$cprettyList :: forall ann. [GlobPattern] -> Doc ann
prettyList :: forall ann. [GlobPattern] -> Doc ann
Pretty via (ViaJSON GlobPattern)