module GitHub.Data.Comments where

import GitHub.Data.Definitions
import GitHub.Data.Id          (Id)
import GitHub.Data.URL         (URL)
import GitHub.Internal.Prelude
import Prelude ()

data Comment = Comment
    { Comment -> Maybe Int
commentPosition  :: !(Maybe Int)
    , Comment -> Maybe Int
commentLine      :: !(Maybe Int)
    , Comment -> Text
commentBody      :: !Text
    , Comment -> Maybe Text
commentCommitId  :: !(Maybe Text)
    , Comment -> UTCTime
commentUpdatedAt :: !UTCTime
    , Comment -> Maybe URL
commentHtmlUrl   :: !(Maybe URL)
    , Comment -> URL
commentUrl       :: !URL
    , Comment -> Maybe UTCTime
commentCreatedAt :: !(Maybe UTCTime)
    , Comment -> Maybe Text
commentPath      :: !(Maybe Text)
    , Comment -> SimpleUser
commentUser      :: !SimpleUser
    , Comment -> Id Comment
commentId        :: !(Id Comment)
    }
  deriving (Int -> Comment -> ShowS
[Comment] -> ShowS
Comment -> String
(Int -> Comment -> ShowS)
-> (Comment -> String) -> ([Comment] -> ShowS) -> Show Comment
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
$cshowsPrec :: Int -> Comment -> ShowS
showsPrec :: Int -> Comment -> ShowS
$cshow :: Comment -> String
show :: Comment -> String
$cshowList :: [Comment] -> ShowS
showList :: [Comment] -> ShowS
Show, Typeable Comment
Typeable Comment =>
(forall (c :: * -> *).
 (forall d b. Data d => c (d -> b) -> d -> c b)
 -> (forall g. g -> c g) -> Comment -> c Comment)
-> (forall (c :: * -> *).
    (forall b r. Data b => c (b -> r) -> c r)
    -> (forall r. r -> c r) -> Constr -> c Comment)
-> (Comment -> Constr)
-> (Comment -> DataType)
-> (forall (t :: * -> *) (c :: * -> *).
    Typeable t =>
    (forall d. Data d => c (t d)) -> Maybe (c Comment))
-> (forall (t :: * -> * -> *) (c :: * -> *).
    Typeable t =>
    (forall d e. (Data d, Data e) => c (t d e)) -> Maybe (c Comment))
-> ((forall b. Data b => b -> b) -> Comment -> Comment)
-> (forall r r'.
    (r -> r' -> r)
    -> r -> (forall d. Data d => d -> r') -> Comment -> r)
-> (forall r r'.
    (r' -> r -> r)
    -> r -> (forall d. Data d => d -> r') -> Comment -> r)
-> (forall u. (forall d. Data d => d -> u) -> Comment -> [u])
-> (forall u. Int -> (forall d. Data d => d -> u) -> Comment -> u)
-> (forall (m :: * -> *).
    Monad m =>
    (forall d. Data d => d -> m d) -> Comment -> m Comment)
-> (forall (m :: * -> *).
    MonadPlus m =>
    (forall d. Data d => d -> m d) -> Comment -> m Comment)
-> (forall (m :: * -> *).
    MonadPlus m =>
    (forall d. Data d => d -> m d) -> Comment -> m Comment)
-> Data Comment
Comment -> Constr
Comment -> DataType
(forall b. Data b => b -> b) -> Comment -> Comment
forall a.
Typeable a =>
(forall (c :: * -> *).
 (forall d b. Data d => c (d -> b) -> d -> c b)
 -> (forall g. g -> c g) -> a -> c a)
-> (forall (c :: * -> *).
    (forall b r. Data b => c (b -> r) -> c r)
    -> (forall r. r -> c r) -> Constr -> c a)
-> (a -> Constr)
-> (a -> DataType)
-> (forall (t :: * -> *) (c :: * -> *).
    Typeable t =>
    (forall d. Data d => c (t d)) -> Maybe (c a))
-> (forall (t :: * -> * -> *) (c :: * -> *).
    Typeable t =>
    (forall d e. (Data d, Data e) => c (t d e)) -> Maybe (c a))
-> ((forall b. Data b => b -> b) -> a -> a)
-> (forall r r'.
    (r -> r' -> r) -> r -> (forall d. Data d => d -> r') -> a -> r)
-> (forall r r'.
    (r' -> r -> r) -> r -> (forall d. Data d => d -> r') -> a -> r)
-> (forall u. (forall d. Data d => d -> u) -> a -> [u])
-> (forall u. Int -> (forall d. Data d => d -> u) -> a -> u)
-> (forall (m :: * -> *).
    Monad m =>
    (forall d. Data d => d -> m d) -> a -> m a)
-> (forall (m :: * -> *).
    MonadPlus m =>
    (forall d. Data d => d -> m d) -> a -> m a)
-> (forall (m :: * -> *).
    MonadPlus m =>
    (forall d. Data d => d -> m d) -> a -> m a)
-> Data a
forall u. Int -> (forall d. Data d => d -> u) -> Comment -> u
forall u. (forall d. Data d => d -> u) -> Comment -> [u]
forall r r'.
(r -> r' -> r)
-> r -> (forall d. Data d => d -> r') -> Comment -> r
forall r r'.
(r' -> r -> r)
-> r -> (forall d. Data d => d -> r') -> Comment -> r
forall (m :: * -> *).
Monad m =>
(forall d. Data d => d -> m d) -> Comment -> m Comment
forall (m :: * -> *).
MonadPlus m =>
(forall d. Data d => d -> m d) -> Comment -> m Comment
forall (c :: * -> *).
(forall b r. Data b => c (b -> r) -> c r)
-> (forall r. r -> c r) -> Constr -> c Comment
forall (c :: * -> *).
(forall d b. Data d => c (d -> b) -> d -> c b)
-> (forall g. g -> c g) -> Comment -> c Comment
forall (t :: * -> *) (c :: * -> *).
Typeable t =>
(forall d. Data d => c (t d)) -> Maybe (c Comment)
forall (t :: * -> * -> *) (c :: * -> *).
Typeable t =>
(forall d e. (Data d, Data e) => c (t d e)) -> Maybe (c Comment)
$cgfoldl :: forall (c :: * -> *).
(forall d b. Data d => c (d -> b) -> d -> c b)
-> (forall g. g -> c g) -> Comment -> c Comment
gfoldl :: forall (c :: * -> *).
(forall d b. Data d => c (d -> b) -> d -> c b)
-> (forall g. g -> c g) -> Comment -> c Comment
$cgunfold :: forall (c :: * -> *).
(forall b r. Data b => c (b -> r) -> c r)
-> (forall r. r -> c r) -> Constr -> c Comment
gunfold :: forall (c :: * -> *).
(forall b r. Data b => c (b -> r) -> c r)
-> (forall r. r -> c r) -> Constr -> c Comment
$ctoConstr :: Comment -> Constr
toConstr :: Comment -> Constr
$cdataTypeOf :: Comment -> DataType
dataTypeOf :: Comment -> DataType
$cdataCast1 :: forall (t :: * -> *) (c :: * -> *).
Typeable t =>
(forall d. Data d => c (t d)) -> Maybe (c Comment)
dataCast1 :: forall (t :: * -> *) (c :: * -> *).
Typeable t =>
(forall d. Data d => c (t d)) -> Maybe (c Comment)
$cdataCast2 :: forall (t :: * -> * -> *) (c :: * -> *).
Typeable t =>
(forall d e. (Data d, Data e) => c (t d e)) -> Maybe (c Comment)
dataCast2 :: forall (t :: * -> * -> *) (c :: * -> *).
Typeable t =>
(forall d e. (Data d, Data e) => c (t d e)) -> Maybe (c Comment)
$cgmapT :: (forall b. Data b => b -> b) -> Comment -> Comment
gmapT :: (forall b. Data b => b -> b) -> Comment -> Comment
$cgmapQl :: forall r r'.
(r -> r' -> r)
-> r -> (forall d. Data d => d -> r') -> Comment -> r
gmapQl :: forall r r'.
(r -> r' -> r)
-> r -> (forall d. Data d => d -> r') -> Comment -> r
$cgmapQr :: forall r r'.
(r' -> r -> r)
-> r -> (forall d. Data d => d -> r') -> Comment -> r
gmapQr :: forall r r'.
(r' -> r -> r)
-> r -> (forall d. Data d => d -> r') -> Comment -> r
$cgmapQ :: forall u. (forall d. Data d => d -> u) -> Comment -> [u]
gmapQ :: forall u. (forall d. Data d => d -> u) -> Comment -> [u]
$cgmapQi :: forall u. Int -> (forall d. Data d => d -> u) -> Comment -> u
gmapQi :: forall u. Int -> (forall d. Data d => d -> u) -> Comment -> u
$cgmapM :: forall (m :: * -> *).
Monad m =>
(forall d. Data d => d -> m d) -> Comment -> m Comment
gmapM :: forall (m :: * -> *).
Monad m =>
(forall d. Data d => d -> m d) -> Comment -> m Comment
$cgmapMp :: forall (m :: * -> *).
MonadPlus m =>
(forall d. Data d => d -> m d) -> Comment -> m Comment
gmapMp :: forall (m :: * -> *).
MonadPlus m =>
(forall d. Data d => d -> m d) -> Comment -> m Comment
$cgmapMo :: forall (m :: * -> *).
MonadPlus m =>
(forall d. Data d => d -> m d) -> Comment -> m Comment
gmapMo :: forall (m :: * -> *).
MonadPlus m =>
(forall d. Data d => d -> m d) -> Comment -> m Comment
Data, Typeable, Comment -> Comment -> Bool
(Comment -> Comment -> Bool)
-> (Comment -> Comment -> Bool) -> Eq Comment
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
$c== :: Comment -> Comment -> Bool
== :: Comment -> Comment -> Bool
$c/= :: Comment -> Comment -> Bool
/= :: Comment -> Comment -> Bool
Eq, Eq Comment
Eq Comment =>
(Comment -> Comment -> Ordering)
-> (Comment -> Comment -> Bool)
-> (Comment -> Comment -> Bool)
-> (Comment -> Comment -> Bool)
-> (Comment -> Comment -> Bool)
-> (Comment -> Comment -> Comment)
-> (Comment -> Comment -> Comment)
-> Ord Comment
Comment -> Comment -> Bool
Comment -> Comment -> Ordering
Comment -> Comment -> Comment
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 :: Comment -> Comment -> Ordering
compare :: Comment -> Comment -> Ordering
$c< :: Comment -> Comment -> Bool
< :: Comment -> Comment -> Bool
$c<= :: Comment -> Comment -> Bool
<= :: Comment -> Comment -> Bool
$c> :: Comment -> Comment -> Bool
> :: Comment -> Comment -> Bool
$c>= :: Comment -> Comment -> Bool
>= :: Comment -> Comment -> Bool
$cmax :: Comment -> Comment -> Comment
max :: Comment -> Comment -> Comment
$cmin :: Comment -> Comment -> Comment
min :: Comment -> Comment -> Comment
Ord, (forall x. Comment -> Rep Comment x)
-> (forall x. Rep Comment x -> Comment) -> Generic Comment
forall x. Rep Comment x -> Comment
forall x. Comment -> Rep Comment x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cfrom :: forall x. Comment -> Rep Comment x
from :: forall x. Comment -> Rep Comment x
$cto :: forall x. Rep Comment x -> Comment
to :: forall x. Rep Comment x -> Comment
Generic)

instance NFData Comment where rnf :: Comment -> ()
rnf = Comment -> ()
forall a. (Generic a, GNFData (Rep a)) => a -> ()
genericRnf
instance Binary Comment

instance FromJSON Comment where
    parseJSON :: Value -> Parser Comment
parseJSON = String -> (Object -> Parser Comment) -> Value -> Parser Comment
forall a. String -> (Object -> Parser a) -> Value -> Parser a
withObject String
"Comment" ((Object -> Parser Comment) -> Value -> Parser Comment)
-> (Object -> Parser Comment) -> Value -> Parser Comment
forall a b. (a -> b) -> a -> b
$ \Object
o -> Maybe Int
-> Maybe Int
-> Text
-> Maybe Text
-> UTCTime
-> Maybe URL
-> URL
-> Maybe UTCTime
-> Maybe Text
-> SimpleUser
-> Id Comment
-> Comment
Comment
        (Maybe Int
 -> Maybe Int
 -> Text
 -> Maybe Text
 -> UTCTime
 -> Maybe URL
 -> URL
 -> Maybe UTCTime
 -> Maybe Text
 -> SimpleUser
 -> Id Comment
 -> Comment)
-> Parser (Maybe Int)
-> Parser
     (Maybe Int
      -> Text
      -> Maybe Text
      -> UTCTime
      -> Maybe URL
      -> URL
      -> Maybe UTCTime
      -> Maybe Text
      -> SimpleUser
      -> Id Comment
      -> Comment)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
<$> Object
o Object -> Key -> Parser (Maybe Int)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
.:? Key
"position"
        Parser
  (Maybe Int
   -> Text
   -> Maybe Text
   -> UTCTime
   -> Maybe URL
   -> URL
   -> Maybe UTCTime
   -> Maybe Text
   -> SimpleUser
   -> Id Comment
   -> Comment)
-> Parser (Maybe Int)
-> Parser
     (Text
      -> Maybe Text
      -> UTCTime
      -> Maybe URL
      -> URL
      -> Maybe UTCTime
      -> Maybe Text
      -> SimpleUser
      -> Id Comment
      -> Comment)
forall a b. Parser (a -> b) -> Parser a -> Parser b
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
<*> Object
o Object -> Key -> Parser (Maybe Int)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
.:? Key
"line"
        Parser
  (Text
   -> Maybe Text
   -> UTCTime
   -> Maybe URL
   -> URL
   -> Maybe UTCTime
   -> Maybe Text
   -> SimpleUser
   -> Id Comment
   -> Comment)
-> Parser Text
-> Parser
     (Maybe Text
      -> UTCTime
      -> Maybe URL
      -> URL
      -> Maybe UTCTime
      -> Maybe Text
      -> SimpleUser
      -> Id Comment
      -> Comment)
forall a b. Parser (a -> b) -> Parser a -> Parser b
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
<*> Object
o Object -> Key -> Parser Text
forall a. FromJSON a => Object -> Key -> Parser a
.: Key
"body"
        Parser
  (Maybe Text
   -> UTCTime
   -> Maybe URL
   -> URL
   -> Maybe UTCTime
   -> Maybe Text
   -> SimpleUser
   -> Id Comment
   -> Comment)
-> Parser (Maybe Text)
-> Parser
     (UTCTime
      -> Maybe URL
      -> URL
      -> Maybe UTCTime
      -> Maybe Text
      -> SimpleUser
      -> Id Comment
      -> Comment)
forall a b. Parser (a -> b) -> Parser a -> Parser b
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
<*> Object
o Object -> Key -> Parser (Maybe Text)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
.:? Key
"commit_id"
        Parser
  (UTCTime
   -> Maybe URL
   -> URL
   -> Maybe UTCTime
   -> Maybe Text
   -> SimpleUser
   -> Id Comment
   -> Comment)
-> Parser UTCTime
-> Parser
     (Maybe URL
      -> URL
      -> Maybe UTCTime
      -> Maybe Text
      -> SimpleUser
      -> Id Comment
      -> Comment)
forall a b. Parser (a -> b) -> Parser a -> Parser b
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
<*> Object
o Object -> Key -> Parser UTCTime
forall a. FromJSON a => Object -> Key -> Parser a
.: Key
"updated_at"
        Parser
  (Maybe URL
   -> URL
   -> Maybe UTCTime
   -> Maybe Text
   -> SimpleUser
   -> Id Comment
   -> Comment)
-> Parser (Maybe URL)
-> Parser
     (URL
      -> Maybe UTCTime
      -> Maybe Text
      -> SimpleUser
      -> Id Comment
      -> Comment)
forall a b. Parser (a -> b) -> Parser a -> Parser b
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
<*> Object
o Object -> Key -> Parser (Maybe URL)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
.:? Key
"html_url"
        Parser
  (URL
   -> Maybe UTCTime
   -> Maybe Text
   -> SimpleUser
   -> Id Comment
   -> Comment)
-> Parser URL
-> Parser
     (Maybe UTCTime
      -> Maybe Text -> SimpleUser -> Id Comment -> Comment)
forall a b. Parser (a -> b) -> Parser a -> Parser b
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
<*> Object
o Object -> Key -> Parser URL
forall a. FromJSON a => Object -> Key -> Parser a
.: Key
"url"
        Parser
  (Maybe UTCTime
   -> Maybe Text -> SimpleUser -> Id Comment -> Comment)
-> Parser (Maybe UTCTime)
-> Parser (Maybe Text -> SimpleUser -> Id Comment -> Comment)
forall a b. Parser (a -> b) -> Parser a -> Parser b
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
<*> Object
o Object -> Key -> Parser (Maybe UTCTime)
forall a. FromJSON a => Object -> Key -> Parser a
.: Key
"created_at"
        Parser (Maybe Text -> SimpleUser -> Id Comment -> Comment)
-> Parser (Maybe Text)
-> Parser (SimpleUser -> Id Comment -> Comment)
forall a b. Parser (a -> b) -> Parser a -> Parser b
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
<*> Object
o Object -> Key -> Parser (Maybe Text)
forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
.:? Key
"path"
        Parser (SimpleUser -> Id Comment -> Comment)
-> Parser SimpleUser -> Parser (Id Comment -> Comment)
forall a b. Parser (a -> b) -> Parser a -> Parser b
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
<*> Object
o Object -> Key -> Parser SimpleUser
forall a. FromJSON a => Object -> Key -> Parser a
.: Key
"user"
        Parser (Id Comment -> Comment)
-> Parser (Id Comment) -> Parser Comment
forall a b. Parser (a -> b) -> Parser a -> Parser b
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
<*> Object
o Object -> Key -> Parser (Id Comment)
forall a. FromJSON a => Object -> Key -> Parser a
.: Key
"id"

data NewComment = NewComment
    { NewComment -> Text
newCommentBody :: !Text
    }
  deriving (Int -> NewComment -> ShowS
[NewComment] -> ShowS
NewComment -> String
(Int -> NewComment -> ShowS)
-> (NewComment -> String)
-> ([NewComment] -> ShowS)
-> Show NewComment
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
$cshowsPrec :: Int -> NewComment -> ShowS
showsPrec :: Int -> NewComment -> ShowS
$cshow :: NewComment -> String
show :: NewComment -> String
$cshowList :: [NewComment] -> ShowS
showList :: [NewComment] -> ShowS
Show, Typeable NewComment
Typeable NewComment =>
(forall (c :: * -> *).
 (forall d b. Data d => c (d -> b) -> d -> c b)
 -> (forall g. g -> c g) -> NewComment -> c NewComment)
-> (forall (c :: * -> *).
    (forall b r. Data b => c (b -> r) -> c r)
    -> (forall r. r -> c r) -> Constr -> c NewComment)
-> (NewComment -> Constr)
-> (NewComment -> DataType)
-> (forall (t :: * -> *) (c :: * -> *).
    Typeable t =>
    (forall d. Data d => c (t d)) -> Maybe (c NewComment))
-> (forall (t :: * -> * -> *) (c :: * -> *).
    Typeable t =>
    (forall d e. (Data d, Data e) => c (t d e))
    -> Maybe (c NewComment))
-> ((forall b. Data b => b -> b) -> NewComment -> NewComment)
-> (forall r r'.
    (r -> r' -> r)
    -> r -> (forall d. Data d => d -> r') -> NewComment -> r)
-> (forall r r'.
    (r' -> r -> r)
    -> r -> (forall d. Data d => d -> r') -> NewComment -> r)
-> (forall u. (forall d. Data d => d -> u) -> NewComment -> [u])
-> (forall u.
    Int -> (forall d. Data d => d -> u) -> NewComment -> u)
-> (forall (m :: * -> *).
    Monad m =>
    (forall d. Data d => d -> m d) -> NewComment -> m NewComment)
-> (forall (m :: * -> *).
    MonadPlus m =>
    (forall d. Data d => d -> m d) -> NewComment -> m NewComment)
-> (forall (m :: * -> *).
    MonadPlus m =>
    (forall d. Data d => d -> m d) -> NewComment -> m NewComment)
-> Data NewComment
NewComment -> Constr
NewComment -> DataType
(forall b. Data b => b -> b) -> NewComment -> NewComment
forall a.
Typeable a =>
(forall (c :: * -> *).
 (forall d b. Data d => c (d -> b) -> d -> c b)
 -> (forall g. g -> c g) -> a -> c a)
-> (forall (c :: * -> *).
    (forall b r. Data b => c (b -> r) -> c r)
    -> (forall r. r -> c r) -> Constr -> c a)
-> (a -> Constr)
-> (a -> DataType)
-> (forall (t :: * -> *) (c :: * -> *).
    Typeable t =>
    (forall d. Data d => c (t d)) -> Maybe (c a))
-> (forall (t :: * -> * -> *) (c :: * -> *).
    Typeable t =>
    (forall d e. (Data d, Data e) => c (t d e)) -> Maybe (c a))
-> ((forall b. Data b => b -> b) -> a -> a)
-> (forall r r'.
    (r -> r' -> r) -> r -> (forall d. Data d => d -> r') -> a -> r)
-> (forall r r'.
    (r' -> r -> r) -> r -> (forall d. Data d => d -> r') -> a -> r)
-> (forall u. (forall d. Data d => d -> u) -> a -> [u])
-> (forall u. Int -> (forall d. Data d => d -> u) -> a -> u)
-> (forall (m :: * -> *).
    Monad m =>
    (forall d. Data d => d -> m d) -> a -> m a)
-> (forall (m :: * -> *).
    MonadPlus m =>
    (forall d. Data d => d -> m d) -> a -> m a)
-> (forall (m :: * -> *).
    MonadPlus m =>
    (forall d. Data d => d -> m d) -> a -> m a)
-> Data a
forall u. Int -> (forall d. Data d => d -> u) -> NewComment -> u
forall u. (forall d. Data d => d -> u) -> NewComment -> [u]
forall r r'.
(r -> r' -> r)
-> r -> (forall d. Data d => d -> r') -> NewComment -> r
forall r r'.
(r' -> r -> r)
-> r -> (forall d. Data d => d -> r') -> NewComment -> r
forall (m :: * -> *).
Monad m =>
(forall d. Data d => d -> m d) -> NewComment -> m NewComment
forall (m :: * -> *).
MonadPlus m =>
(forall d. Data d => d -> m d) -> NewComment -> m NewComment
forall (c :: * -> *).
(forall b r. Data b => c (b -> r) -> c r)
-> (forall r. r -> c r) -> Constr -> c NewComment
forall (c :: * -> *).
(forall d b. Data d => c (d -> b) -> d -> c b)
-> (forall g. g -> c g) -> NewComment -> c NewComment
forall (t :: * -> *) (c :: * -> *).
Typeable t =>
(forall d. Data d => c (t d)) -> Maybe (c NewComment)
forall (t :: * -> * -> *) (c :: * -> *).
Typeable t =>
(forall d e. (Data d, Data e) => c (t d e)) -> Maybe (c NewComment)
$cgfoldl :: forall (c :: * -> *).
(forall d b. Data d => c (d -> b) -> d -> c b)
-> (forall g. g -> c g) -> NewComment -> c NewComment
gfoldl :: forall (c :: * -> *).
(forall d b. Data d => c (d -> b) -> d -> c b)
-> (forall g. g -> c g) -> NewComment -> c NewComment
$cgunfold :: forall (c :: * -> *).
(forall b r. Data b => c (b -> r) -> c r)
-> (forall r. r -> c r) -> Constr -> c NewComment
gunfold :: forall (c :: * -> *).
(forall b r. Data b => c (b -> r) -> c r)
-> (forall r. r -> c r) -> Constr -> c NewComment
$ctoConstr :: NewComment -> Constr
toConstr :: NewComment -> Constr
$cdataTypeOf :: NewComment -> DataType
dataTypeOf :: NewComment -> DataType
$cdataCast1 :: forall (t :: * -> *) (c :: * -> *).
Typeable t =>
(forall d. Data d => c (t d)) -> Maybe (c NewComment)
dataCast1 :: forall (t :: * -> *) (c :: * -> *).
Typeable t =>
(forall d. Data d => c (t d)) -> Maybe (c NewComment)
$cdataCast2 :: forall (t :: * -> * -> *) (c :: * -> *).
Typeable t =>
(forall d e. (Data d, Data e) => c (t d e)) -> Maybe (c NewComment)
dataCast2 :: forall (t :: * -> * -> *) (c :: * -> *).
Typeable t =>
(forall d e. (Data d, Data e) => c (t d e)) -> Maybe (c NewComment)
$cgmapT :: (forall b. Data b => b -> b) -> NewComment -> NewComment
gmapT :: (forall b. Data b => b -> b) -> NewComment -> NewComment
$cgmapQl :: forall r r'.
(r -> r' -> r)
-> r -> (forall d. Data d => d -> r') -> NewComment -> r
gmapQl :: forall r r'.
(r -> r' -> r)
-> r -> (forall d. Data d => d -> r') -> NewComment -> r
$cgmapQr :: forall r r'.
(r' -> r -> r)
-> r -> (forall d. Data d => d -> r') -> NewComment -> r
gmapQr :: forall r r'.
(r' -> r -> r)
-> r -> (forall d. Data d => d -> r') -> NewComment -> r
$cgmapQ :: forall u. (forall d. Data d => d -> u) -> NewComment -> [u]
gmapQ :: forall u. (forall d. Data d => d -> u) -> NewComment -> [u]
$cgmapQi :: forall u. Int -> (forall d. Data d => d -> u) -> NewComment -> u
gmapQi :: forall u. Int -> (forall d. Data d => d -> u) -> NewComment -> u
$cgmapM :: forall (m :: * -> *).
Monad m =>
(forall d. Data d => d -> m d) -> NewComment -> m NewComment
gmapM :: forall (m :: * -> *).
Monad m =>
(forall d. Data d => d -> m d) -> NewComment -> m NewComment
$cgmapMp :: forall (m :: * -> *).
MonadPlus m =>
(forall d. Data d => d -> m d) -> NewComment -> m NewComment
gmapMp :: forall (m :: * -> *).
MonadPlus m =>
(forall d. Data d => d -> m d) -> NewComment -> m NewComment
$cgmapMo :: forall (m :: * -> *).
MonadPlus m =>
(forall d. Data d => d -> m d) -> NewComment -> m NewComment
gmapMo :: forall (m :: * -> *).
MonadPlus m =>
(forall d. Data d => d -> m d) -> NewComment -> m NewComment
Data, Typeable, NewComment -> NewComment -> Bool
(NewComment -> NewComment -> Bool)
-> (NewComment -> NewComment -> Bool) -> Eq NewComment
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
$c== :: NewComment -> NewComment -> Bool
== :: NewComment -> NewComment -> Bool
$c/= :: NewComment -> NewComment -> Bool
/= :: NewComment -> NewComment -> Bool
Eq, Eq NewComment
Eq NewComment =>
(NewComment -> NewComment -> Ordering)
-> (NewComment -> NewComment -> Bool)
-> (NewComment -> NewComment -> Bool)
-> (NewComment -> NewComment -> Bool)
-> (NewComment -> NewComment -> Bool)
-> (NewComment -> NewComment -> NewComment)
-> (NewComment -> NewComment -> NewComment)
-> Ord NewComment
NewComment -> NewComment -> Bool
NewComment -> NewComment -> Ordering
NewComment -> NewComment -> NewComment
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 :: NewComment -> NewComment -> Ordering
compare :: NewComment -> NewComment -> Ordering
$c< :: NewComment -> NewComment -> Bool
< :: NewComment -> NewComment -> Bool
$c<= :: NewComment -> NewComment -> Bool
<= :: NewComment -> NewComment -> Bool
$c> :: NewComment -> NewComment -> Bool
> :: NewComment -> NewComment -> Bool
$c>= :: NewComment -> NewComment -> Bool
>= :: NewComment -> NewComment -> Bool
$cmax :: NewComment -> NewComment -> NewComment
max :: NewComment -> NewComment -> NewComment
$cmin :: NewComment -> NewComment -> NewComment
min :: NewComment -> NewComment -> NewComment
Ord, (forall x. NewComment -> Rep NewComment x)
-> (forall x. Rep NewComment x -> NewComment) -> Generic NewComment
forall x. Rep NewComment x -> NewComment
forall x. NewComment -> Rep NewComment x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cfrom :: forall x. NewComment -> Rep NewComment x
from :: forall x. NewComment -> Rep NewComment x
$cto :: forall x. Rep NewComment x -> NewComment
to :: forall x. Rep NewComment x -> NewComment
Generic)

instance NFData NewComment where rnf :: NewComment -> ()
rnf = NewComment -> ()
forall a. (Generic a, GNFData (Rep a)) => a -> ()
genericRnf
instance Binary NewComment

instance ToJSON NewComment where
    toJSON :: NewComment -> Value
toJSON (NewComment Text
b) = [Pair] -> Value
object [ Key
"body" Key -> Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Key -> v -> kv
forall v. ToJSON v => Key -> v -> Pair
.= Text
b ]

data EditComment = EditComment
    { EditComment -> Text
editCommentBody :: !Text
    }
  deriving (Int -> EditComment -> ShowS
[EditComment] -> ShowS
EditComment -> String
(Int -> EditComment -> ShowS)
-> (EditComment -> String)
-> ([EditComment] -> ShowS)
-> Show EditComment
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
$cshowsPrec :: Int -> EditComment -> ShowS
showsPrec :: Int -> EditComment -> ShowS
$cshow :: EditComment -> String
show :: EditComment -> String
$cshowList :: [EditComment] -> ShowS
showList :: [EditComment] -> ShowS
Show, Typeable EditComment
Typeable EditComment =>
(forall (c :: * -> *).
 (forall d b. Data d => c (d -> b) -> d -> c b)
 -> (forall g. g -> c g) -> EditComment -> c EditComment)
-> (forall (c :: * -> *).
    (forall b r. Data b => c (b -> r) -> c r)
    -> (forall r. r -> c r) -> Constr -> c EditComment)
-> (EditComment -> Constr)
-> (EditComment -> DataType)
-> (forall (t :: * -> *) (c :: * -> *).
    Typeable t =>
    (forall d. Data d => c (t d)) -> Maybe (c EditComment))
-> (forall (t :: * -> * -> *) (c :: * -> *).
    Typeable t =>
    (forall d e. (Data d, Data e) => c (t d e))
    -> Maybe (c EditComment))
-> ((forall b. Data b => b -> b) -> EditComment -> EditComment)
-> (forall r r'.
    (r -> r' -> r)
    -> r -> (forall d. Data d => d -> r') -> EditComment -> r)
-> (forall r r'.
    (r' -> r -> r)
    -> r -> (forall d. Data d => d -> r') -> EditComment -> r)
-> (forall u. (forall d. Data d => d -> u) -> EditComment -> [u])
-> (forall u.
    Int -> (forall d. Data d => d -> u) -> EditComment -> u)
-> (forall (m :: * -> *).
    Monad m =>
    (forall d. Data d => d -> m d) -> EditComment -> m EditComment)
-> (forall (m :: * -> *).
    MonadPlus m =>
    (forall d. Data d => d -> m d) -> EditComment -> m EditComment)
-> (forall (m :: * -> *).
    MonadPlus m =>
    (forall d. Data d => d -> m d) -> EditComment -> m EditComment)
-> Data EditComment
EditComment -> Constr
EditComment -> DataType
(forall b. Data b => b -> b) -> EditComment -> EditComment
forall a.
Typeable a =>
(forall (c :: * -> *).
 (forall d b. Data d => c (d -> b) -> d -> c b)
 -> (forall g. g -> c g) -> a -> c a)
-> (forall (c :: * -> *).
    (forall b r. Data b => c (b -> r) -> c r)
    -> (forall r. r -> c r) -> Constr -> c a)
-> (a -> Constr)
-> (a -> DataType)
-> (forall (t :: * -> *) (c :: * -> *).
    Typeable t =>
    (forall d. Data d => c (t d)) -> Maybe (c a))
-> (forall (t :: * -> * -> *) (c :: * -> *).
    Typeable t =>
    (forall d e. (Data d, Data e) => c (t d e)) -> Maybe (c a))
-> ((forall b. Data b => b -> b) -> a -> a)
-> (forall r r'.
    (r -> r' -> r) -> r -> (forall d. Data d => d -> r') -> a -> r)
-> (forall r r'.
    (r' -> r -> r) -> r -> (forall d. Data d => d -> r') -> a -> r)
-> (forall u. (forall d. Data d => d -> u) -> a -> [u])
-> (forall u. Int -> (forall d. Data d => d -> u) -> a -> u)
-> (forall (m :: * -> *).
    Monad m =>
    (forall d. Data d => d -> m d) -> a -> m a)
-> (forall (m :: * -> *).
    MonadPlus m =>
    (forall d. Data d => d -> m d) -> a -> m a)
-> (forall (m :: * -> *).
    MonadPlus m =>
    (forall d. Data d => d -> m d) -> a -> m a)
-> Data a
forall u. Int -> (forall d. Data d => d -> u) -> EditComment -> u
forall u. (forall d. Data d => d -> u) -> EditComment -> [u]
forall r r'.
(r -> r' -> r)
-> r -> (forall d. Data d => d -> r') -> EditComment -> r
forall r r'.
(r' -> r -> r)
-> r -> (forall d. Data d => d -> r') -> EditComment -> r
forall (m :: * -> *).
Monad m =>
(forall d. Data d => d -> m d) -> EditComment -> m EditComment
forall (m :: * -> *).
MonadPlus m =>
(forall d. Data d => d -> m d) -> EditComment -> m EditComment
forall (c :: * -> *).
(forall b r. Data b => c (b -> r) -> c r)
-> (forall r. r -> c r) -> Constr -> c EditComment
forall (c :: * -> *).
(forall d b. Data d => c (d -> b) -> d -> c b)
-> (forall g. g -> c g) -> EditComment -> c EditComment
forall (t :: * -> *) (c :: * -> *).
Typeable t =>
(forall d. Data d => c (t d)) -> Maybe (c EditComment)
forall (t :: * -> * -> *) (c :: * -> *).
Typeable t =>
(forall d e. (Data d, Data e) => c (t d e))
-> Maybe (c EditComment)
$cgfoldl :: forall (c :: * -> *).
(forall d b. Data d => c (d -> b) -> d -> c b)
-> (forall g. g -> c g) -> EditComment -> c EditComment
gfoldl :: forall (c :: * -> *).
(forall d b. Data d => c (d -> b) -> d -> c b)
-> (forall g. g -> c g) -> EditComment -> c EditComment
$cgunfold :: forall (c :: * -> *).
(forall b r. Data b => c (b -> r) -> c r)
-> (forall r. r -> c r) -> Constr -> c EditComment
gunfold :: forall (c :: * -> *).
(forall b r. Data b => c (b -> r) -> c r)
-> (forall r. r -> c r) -> Constr -> c EditComment
$ctoConstr :: EditComment -> Constr
toConstr :: EditComment -> Constr
$cdataTypeOf :: EditComment -> DataType
dataTypeOf :: EditComment -> DataType
$cdataCast1 :: forall (t :: * -> *) (c :: * -> *).
Typeable t =>
(forall d. Data d => c (t d)) -> Maybe (c EditComment)
dataCast1 :: forall (t :: * -> *) (c :: * -> *).
Typeable t =>
(forall d. Data d => c (t d)) -> Maybe (c EditComment)
$cdataCast2 :: forall (t :: * -> * -> *) (c :: * -> *).
Typeable t =>
(forall d e. (Data d, Data e) => c (t d e))
-> Maybe (c EditComment)
dataCast2 :: forall (t :: * -> * -> *) (c :: * -> *).
Typeable t =>
(forall d e. (Data d, Data e) => c (t d e))
-> Maybe (c EditComment)
$cgmapT :: (forall b. Data b => b -> b) -> EditComment -> EditComment
gmapT :: (forall b. Data b => b -> b) -> EditComment -> EditComment
$cgmapQl :: forall r r'.
(r -> r' -> r)
-> r -> (forall d. Data d => d -> r') -> EditComment -> r
gmapQl :: forall r r'.
(r -> r' -> r)
-> r -> (forall d. Data d => d -> r') -> EditComment -> r
$cgmapQr :: forall r r'.
(r' -> r -> r)
-> r -> (forall d. Data d => d -> r') -> EditComment -> r
gmapQr :: forall r r'.
(r' -> r -> r)
-> r -> (forall d. Data d => d -> r') -> EditComment -> r
$cgmapQ :: forall u. (forall d. Data d => d -> u) -> EditComment -> [u]
gmapQ :: forall u. (forall d. Data d => d -> u) -> EditComment -> [u]
$cgmapQi :: forall u. Int -> (forall d. Data d => d -> u) -> EditComment -> u
gmapQi :: forall u. Int -> (forall d. Data d => d -> u) -> EditComment -> u
$cgmapM :: forall (m :: * -> *).
Monad m =>
(forall d. Data d => d -> m d) -> EditComment -> m EditComment
gmapM :: forall (m :: * -> *).
Monad m =>
(forall d. Data d => d -> m d) -> EditComment -> m EditComment
$cgmapMp :: forall (m :: * -> *).
MonadPlus m =>
(forall d. Data d => d -> m d) -> EditComment -> m EditComment
gmapMp :: forall (m :: * -> *).
MonadPlus m =>
(forall d. Data d => d -> m d) -> EditComment -> m EditComment
$cgmapMo :: forall (m :: * -> *).
MonadPlus m =>
(forall d. Data d => d -> m d) -> EditComment -> m EditComment
gmapMo :: forall (m :: * -> *).
MonadPlus m =>
(forall d. Data d => d -> m d) -> EditComment -> m EditComment
Data, Typeable, EditComment -> EditComment -> Bool
(EditComment -> EditComment -> Bool)
-> (EditComment -> EditComment -> Bool) -> Eq EditComment
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
$c== :: EditComment -> EditComment -> Bool
== :: EditComment -> EditComment -> Bool
$c/= :: EditComment -> EditComment -> Bool
/= :: EditComment -> EditComment -> Bool
Eq, Eq EditComment
Eq EditComment =>
(EditComment -> EditComment -> Ordering)
-> (EditComment -> EditComment -> Bool)
-> (EditComment -> EditComment -> Bool)
-> (EditComment -> EditComment -> Bool)
-> (EditComment -> EditComment -> Bool)
-> (EditComment -> EditComment -> EditComment)
-> (EditComment -> EditComment -> EditComment)
-> Ord EditComment
EditComment -> EditComment -> Bool
EditComment -> EditComment -> Ordering
EditComment -> EditComment -> EditComment
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 :: EditComment -> EditComment -> Ordering
compare :: EditComment -> EditComment -> Ordering
$c< :: EditComment -> EditComment -> Bool
< :: EditComment -> EditComment -> Bool
$c<= :: EditComment -> EditComment -> Bool
<= :: EditComment -> EditComment -> Bool
$c> :: EditComment -> EditComment -> Bool
> :: EditComment -> EditComment -> Bool
$c>= :: EditComment -> EditComment -> Bool
>= :: EditComment -> EditComment -> Bool
$cmax :: EditComment -> EditComment -> EditComment
max :: EditComment -> EditComment -> EditComment
$cmin :: EditComment -> EditComment -> EditComment
min :: EditComment -> EditComment -> EditComment
Ord, (forall x. EditComment -> Rep EditComment x)
-> (forall x. Rep EditComment x -> EditComment)
-> Generic EditComment
forall x. Rep EditComment x -> EditComment
forall x. EditComment -> Rep EditComment x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cfrom :: forall x. EditComment -> Rep EditComment x
from :: forall x. EditComment -> Rep EditComment x
$cto :: forall x. Rep EditComment x -> EditComment
to :: forall x. Rep EditComment x -> EditComment
Generic)

instance NFData EditComment where rnf :: EditComment -> ()
rnf = EditComment -> ()
forall a. (Generic a, GNFData (Rep a)) => a -> ()
genericRnf
instance Binary EditComment

instance ToJSON EditComment where
    toJSON :: EditComment -> Value
toJSON (EditComment Text
b) = [Pair] -> Value
object [ Key
"body" Key -> Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Key -> v -> kv
forall v. ToJSON v => Key -> v -> Pair
.= Text
b ]

data NewPullComment = NewPullComment
    { NewPullComment -> Text
newPullCommentCommit   :: !Text
    , NewPullComment -> Text
newPullCommentPath     :: !Text
    , NewPullComment -> Int
newPullCommentPosition :: !Int
    , NewPullComment -> Text
newPullCommentBody     :: !Text
    }
  deriving (Int -> NewPullComment -> ShowS
[NewPullComment] -> ShowS
NewPullComment -> String
(Int -> NewPullComment -> ShowS)
-> (NewPullComment -> String)
-> ([NewPullComment] -> ShowS)
-> Show NewPullComment
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
$cshowsPrec :: Int -> NewPullComment -> ShowS
showsPrec :: Int -> NewPullComment -> ShowS
$cshow :: NewPullComment -> String
show :: NewPullComment -> String
$cshowList :: [NewPullComment] -> ShowS
showList :: [NewPullComment] -> ShowS
Show, Typeable NewPullComment
Typeable NewPullComment =>
(forall (c :: * -> *).
 (forall d b. Data d => c (d -> b) -> d -> c b)
 -> (forall g. g -> c g) -> NewPullComment -> c NewPullComment)
-> (forall (c :: * -> *).
    (forall b r. Data b => c (b -> r) -> c r)
    -> (forall r. r -> c r) -> Constr -> c NewPullComment)
-> (NewPullComment -> Constr)
-> (NewPullComment -> DataType)
-> (forall (t :: * -> *) (c :: * -> *).
    Typeable t =>
    (forall d. Data d => c (t d)) -> Maybe (c NewPullComment))
-> (forall (t :: * -> * -> *) (c :: * -> *).
    Typeable t =>
    (forall d e. (Data d, Data e) => c (t d e))
    -> Maybe (c NewPullComment))
-> ((forall b. Data b => b -> b)
    -> NewPullComment -> NewPullComment)
-> (forall r r'.
    (r -> r' -> r)
    -> r -> (forall d. Data d => d -> r') -> NewPullComment -> r)
-> (forall r r'.
    (r' -> r -> r)
    -> r -> (forall d. Data d => d -> r') -> NewPullComment -> r)
-> (forall u.
    (forall d. Data d => d -> u) -> NewPullComment -> [u])
-> (forall u.
    Int -> (forall d. Data d => d -> u) -> NewPullComment -> u)
-> (forall (m :: * -> *).
    Monad m =>
    (forall d. Data d => d -> m d)
    -> NewPullComment -> m NewPullComment)
-> (forall (m :: * -> *).
    MonadPlus m =>
    (forall d. Data d => d -> m d)
    -> NewPullComment -> m NewPullComment)
-> (forall (m :: * -> *).
    MonadPlus m =>
    (forall d. Data d => d -> m d)
    -> NewPullComment -> m NewPullComment)
-> Data NewPullComment
NewPullComment -> Constr
NewPullComment -> DataType
(forall b. Data b => b -> b) -> NewPullComment -> NewPullComment
forall a.
Typeable a =>
(forall (c :: * -> *).
 (forall d b. Data d => c (d -> b) -> d -> c b)
 -> (forall g. g -> c g) -> a -> c a)
-> (forall (c :: * -> *).
    (forall b r. Data b => c (b -> r) -> c r)
    -> (forall r. r -> c r) -> Constr -> c a)
-> (a -> Constr)
-> (a -> DataType)
-> (forall (t :: * -> *) (c :: * -> *).
    Typeable t =>
    (forall d. Data d => c (t d)) -> Maybe (c a))
-> (forall (t :: * -> * -> *) (c :: * -> *).
    Typeable t =>
    (forall d e. (Data d, Data e) => c (t d e)) -> Maybe (c a))
-> ((forall b. Data b => b -> b) -> a -> a)
-> (forall r r'.
    (r -> r' -> r) -> r -> (forall d. Data d => d -> r') -> a -> r)
-> (forall r r'.
    (r' -> r -> r) -> r -> (forall d. Data d => d -> r') -> a -> r)
-> (forall u. (forall d. Data d => d -> u) -> a -> [u])
-> (forall u. Int -> (forall d. Data d => d -> u) -> a -> u)
-> (forall (m :: * -> *).
    Monad m =>
    (forall d. Data d => d -> m d) -> a -> m a)
-> (forall (m :: * -> *).
    MonadPlus m =>
    (forall d. Data d => d -> m d) -> a -> m a)
-> (forall (m :: * -> *).
    MonadPlus m =>
    (forall d. Data d => d -> m d) -> a -> m a)
-> Data a
forall u.
Int -> (forall d. Data d => d -> u) -> NewPullComment -> u
forall u. (forall d. Data d => d -> u) -> NewPullComment -> [u]
forall r r'.
(r -> r' -> r)
-> r -> (forall d. Data d => d -> r') -> NewPullComment -> r
forall r r'.
(r' -> r -> r)
-> r -> (forall d. Data d => d -> r') -> NewPullComment -> r
forall (m :: * -> *).
Monad m =>
(forall d. Data d => d -> m d)
-> NewPullComment -> m NewPullComment
forall (m :: * -> *).
MonadPlus m =>
(forall d. Data d => d -> m d)
-> NewPullComment -> m NewPullComment
forall (c :: * -> *).
(forall b r. Data b => c (b -> r) -> c r)
-> (forall r. r -> c r) -> Constr -> c NewPullComment
forall (c :: * -> *).
(forall d b. Data d => c (d -> b) -> d -> c b)
-> (forall g. g -> c g) -> NewPullComment -> c NewPullComment
forall (t :: * -> *) (c :: * -> *).
Typeable t =>
(forall d. Data d => c (t d)) -> Maybe (c NewPullComment)
forall (t :: * -> * -> *) (c :: * -> *).
Typeable t =>
(forall d e. (Data d, Data e) => c (t d e))
-> Maybe (c NewPullComment)
$cgfoldl :: forall (c :: * -> *).
(forall d b. Data d => c (d -> b) -> d -> c b)
-> (forall g. g -> c g) -> NewPullComment -> c NewPullComment
gfoldl :: forall (c :: * -> *).
(forall d b. Data d => c (d -> b) -> d -> c b)
-> (forall g. g -> c g) -> NewPullComment -> c NewPullComment
$cgunfold :: forall (c :: * -> *).
(forall b r. Data b => c (b -> r) -> c r)
-> (forall r. r -> c r) -> Constr -> c NewPullComment
gunfold :: forall (c :: * -> *).
(forall b r. Data b => c (b -> r) -> c r)
-> (forall r. r -> c r) -> Constr -> c NewPullComment
$ctoConstr :: NewPullComment -> Constr
toConstr :: NewPullComment -> Constr
$cdataTypeOf :: NewPullComment -> DataType
dataTypeOf :: NewPullComment -> DataType
$cdataCast1 :: forall (t :: * -> *) (c :: * -> *).
Typeable t =>
(forall d. Data d => c (t d)) -> Maybe (c NewPullComment)
dataCast1 :: forall (t :: * -> *) (c :: * -> *).
Typeable t =>
(forall d. Data d => c (t d)) -> Maybe (c NewPullComment)
$cdataCast2 :: forall (t :: * -> * -> *) (c :: * -> *).
Typeable t =>
(forall d e. (Data d, Data e) => c (t d e))
-> Maybe (c NewPullComment)
dataCast2 :: forall (t :: * -> * -> *) (c :: * -> *).
Typeable t =>
(forall d e. (Data d, Data e) => c (t d e))
-> Maybe (c NewPullComment)
$cgmapT :: (forall b. Data b => b -> b) -> NewPullComment -> NewPullComment
gmapT :: (forall b. Data b => b -> b) -> NewPullComment -> NewPullComment
$cgmapQl :: forall r r'.
(r -> r' -> r)
-> r -> (forall d. Data d => d -> r') -> NewPullComment -> r
gmapQl :: forall r r'.
(r -> r' -> r)
-> r -> (forall d. Data d => d -> r') -> NewPullComment -> r
$cgmapQr :: forall r r'.
(r' -> r -> r)
-> r -> (forall d. Data d => d -> r') -> NewPullComment -> r
gmapQr :: forall r r'.
(r' -> r -> r)
-> r -> (forall d. Data d => d -> r') -> NewPullComment -> r
$cgmapQ :: forall u. (forall d. Data d => d -> u) -> NewPullComment -> [u]
gmapQ :: forall u. (forall d. Data d => d -> u) -> NewPullComment -> [u]
$cgmapQi :: forall u.
Int -> (forall d. Data d => d -> u) -> NewPullComment -> u
gmapQi :: forall u.
Int -> (forall d. Data d => d -> u) -> NewPullComment -> u
$cgmapM :: forall (m :: * -> *).
Monad m =>
(forall d. Data d => d -> m d)
-> NewPullComment -> m NewPullComment
gmapM :: forall (m :: * -> *).
Monad m =>
(forall d. Data d => d -> m d)
-> NewPullComment -> m NewPullComment
$cgmapMp :: forall (m :: * -> *).
MonadPlus m =>
(forall d. Data d => d -> m d)
-> NewPullComment -> m NewPullComment
gmapMp :: forall (m :: * -> *).
MonadPlus m =>
(forall d. Data d => d -> m d)
-> NewPullComment -> m NewPullComment
$cgmapMo :: forall (m :: * -> *).
MonadPlus m =>
(forall d. Data d => d -> m d)
-> NewPullComment -> m NewPullComment
gmapMo :: forall (m :: * -> *).
MonadPlus m =>
(forall d. Data d => d -> m d)
-> NewPullComment -> m NewPullComment
Data, Typeable, NewPullComment -> NewPullComment -> Bool
(NewPullComment -> NewPullComment -> Bool)
-> (NewPullComment -> NewPullComment -> Bool) -> Eq NewPullComment
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
$c== :: NewPullComment -> NewPullComment -> Bool
== :: NewPullComment -> NewPullComment -> Bool
$c/= :: NewPullComment -> NewPullComment -> Bool
/= :: NewPullComment -> NewPullComment -> Bool
Eq, Eq NewPullComment
Eq NewPullComment =>
(NewPullComment -> NewPullComment -> Ordering)
-> (NewPullComment -> NewPullComment -> Bool)
-> (NewPullComment -> NewPullComment -> Bool)
-> (NewPullComment -> NewPullComment -> Bool)
-> (NewPullComment -> NewPullComment -> Bool)
-> (NewPullComment -> NewPullComment -> NewPullComment)
-> (NewPullComment -> NewPullComment -> NewPullComment)
-> Ord NewPullComment
NewPullComment -> NewPullComment -> Bool
NewPullComment -> NewPullComment -> Ordering
NewPullComment -> NewPullComment -> NewPullComment
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 :: NewPullComment -> NewPullComment -> Ordering
compare :: NewPullComment -> NewPullComment -> Ordering
$c< :: NewPullComment -> NewPullComment -> Bool
< :: NewPullComment -> NewPullComment -> Bool
$c<= :: NewPullComment -> NewPullComment -> Bool
<= :: NewPullComment -> NewPullComment -> Bool
$c> :: NewPullComment -> NewPullComment -> Bool
> :: NewPullComment -> NewPullComment -> Bool
$c>= :: NewPullComment -> NewPullComment -> Bool
>= :: NewPullComment -> NewPullComment -> Bool
$cmax :: NewPullComment -> NewPullComment -> NewPullComment
max :: NewPullComment -> NewPullComment -> NewPullComment
$cmin :: NewPullComment -> NewPullComment -> NewPullComment
min :: NewPullComment -> NewPullComment -> NewPullComment
Ord, (forall x. NewPullComment -> Rep NewPullComment x)
-> (forall x. Rep NewPullComment x -> NewPullComment)
-> Generic NewPullComment
forall x. Rep NewPullComment x -> NewPullComment
forall x. NewPullComment -> Rep NewPullComment x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cfrom :: forall x. NewPullComment -> Rep NewPullComment x
from :: forall x. NewPullComment -> Rep NewPullComment x
$cto :: forall x. Rep NewPullComment x -> NewPullComment
to :: forall x. Rep NewPullComment x -> NewPullComment
Generic)

instance NFData NewPullComment where rnf :: NewPullComment -> ()
rnf = NewPullComment -> ()
forall a. (Generic a, GNFData (Rep a)) => a -> ()
genericRnf
instance Binary NewPullComment

instance ToJSON NewPullComment where
    toJSON :: NewPullComment -> Value
toJSON (NewPullComment Text
c Text
path Int
pos Text
b) =
        [Pair] -> Value
object [ Key
"body" Key -> Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Key -> v -> kv
forall v. ToJSON v => Key -> v -> Pair
.= Text
b
               , Key
"commit_id" Key -> Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Key -> v -> kv
forall v. ToJSON v => Key -> v -> Pair
.= Text
c
               , Key
"path" Key -> Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Key -> v -> kv
forall v. ToJSON v => Key -> v -> Pair
.= Text
path
               , Key
"position" Key -> Int -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Key -> v -> kv
forall v. ToJSON v => Key -> v -> Pair
.= Int
pos
               ]

data PullCommentReply = PullCommentReply
    { PullCommentReply -> Text
pullCommentReplyBody     :: Text
    }
  deriving (Int -> PullCommentReply -> ShowS
[PullCommentReply] -> ShowS
PullCommentReply -> String
(Int -> PullCommentReply -> ShowS)
-> (PullCommentReply -> String)
-> ([PullCommentReply] -> ShowS)
-> Show PullCommentReply
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
$cshowsPrec :: Int -> PullCommentReply -> ShowS
showsPrec :: Int -> PullCommentReply -> ShowS
$cshow :: PullCommentReply -> String
show :: PullCommentReply -> String
$cshowList :: [PullCommentReply] -> ShowS
showList :: [PullCommentReply] -> ShowS
Show, Typeable PullCommentReply
Typeable PullCommentReply =>
(forall (c :: * -> *).
 (forall d b. Data d => c (d -> b) -> d -> c b)
 -> (forall g. g -> c g) -> PullCommentReply -> c PullCommentReply)
-> (forall (c :: * -> *).
    (forall b r. Data b => c (b -> r) -> c r)
    -> (forall r. r -> c r) -> Constr -> c PullCommentReply)
-> (PullCommentReply -> Constr)
-> (PullCommentReply -> DataType)
-> (forall (t :: * -> *) (c :: * -> *).
    Typeable t =>
    (forall d. Data d => c (t d)) -> Maybe (c PullCommentReply))
-> (forall (t :: * -> * -> *) (c :: * -> *).
    Typeable t =>
    (forall d e. (Data d, Data e) => c (t d e))
    -> Maybe (c PullCommentReply))
-> ((forall b. Data b => b -> b)
    -> PullCommentReply -> PullCommentReply)
-> (forall r r'.
    (r -> r' -> r)
    -> r -> (forall d. Data d => d -> r') -> PullCommentReply -> r)
-> (forall r r'.
    (r' -> r -> r)
    -> r -> (forall d. Data d => d -> r') -> PullCommentReply -> r)
-> (forall u.
    (forall d. Data d => d -> u) -> PullCommentReply -> [u])
-> (forall u.
    Int -> (forall d. Data d => d -> u) -> PullCommentReply -> u)
-> (forall (m :: * -> *).
    Monad m =>
    (forall d. Data d => d -> m d)
    -> PullCommentReply -> m PullCommentReply)
-> (forall (m :: * -> *).
    MonadPlus m =>
    (forall d. Data d => d -> m d)
    -> PullCommentReply -> m PullCommentReply)
-> (forall (m :: * -> *).
    MonadPlus m =>
    (forall d. Data d => d -> m d)
    -> PullCommentReply -> m PullCommentReply)
-> Data PullCommentReply
PullCommentReply -> Constr
PullCommentReply -> DataType
(forall b. Data b => b -> b)
-> PullCommentReply -> PullCommentReply
forall a.
Typeable a =>
(forall (c :: * -> *).
 (forall d b. Data d => c (d -> b) -> d -> c b)
 -> (forall g. g -> c g) -> a -> c a)
-> (forall (c :: * -> *).
    (forall b r. Data b => c (b -> r) -> c r)
    -> (forall r. r -> c r) -> Constr -> c a)
-> (a -> Constr)
-> (a -> DataType)
-> (forall (t :: * -> *) (c :: * -> *).
    Typeable t =>
    (forall d. Data d => c (t d)) -> Maybe (c a))
-> (forall (t :: * -> * -> *) (c :: * -> *).
    Typeable t =>
    (forall d e. (Data d, Data e) => c (t d e)) -> Maybe (c a))
-> ((forall b. Data b => b -> b) -> a -> a)
-> (forall r r'.
    (r -> r' -> r) -> r -> (forall d. Data d => d -> r') -> a -> r)
-> (forall r r'.
    (r' -> r -> r) -> r -> (forall d. Data d => d -> r') -> a -> r)
-> (forall u. (forall d. Data d => d -> u) -> a -> [u])
-> (forall u. Int -> (forall d. Data d => d -> u) -> a -> u)
-> (forall (m :: * -> *).
    Monad m =>
    (forall d. Data d => d -> m d) -> a -> m a)
-> (forall (m :: * -> *).
    MonadPlus m =>
    (forall d. Data d => d -> m d) -> a -> m a)
-> (forall (m :: * -> *).
    MonadPlus m =>
    (forall d. Data d => d -> m d) -> a -> m a)
-> Data a
forall u.
Int -> (forall d. Data d => d -> u) -> PullCommentReply -> u
forall u. (forall d. Data d => d -> u) -> PullCommentReply -> [u]
forall r r'.
(r -> r' -> r)
-> r -> (forall d. Data d => d -> r') -> PullCommentReply -> r
forall r r'.
(r' -> r -> r)
-> r -> (forall d. Data d => d -> r') -> PullCommentReply -> r
forall (m :: * -> *).
Monad m =>
(forall d. Data d => d -> m d)
-> PullCommentReply -> m PullCommentReply
forall (m :: * -> *).
MonadPlus m =>
(forall d. Data d => d -> m d)
-> PullCommentReply -> m PullCommentReply
forall (c :: * -> *).
(forall b r. Data b => c (b -> r) -> c r)
-> (forall r. r -> c r) -> Constr -> c PullCommentReply
forall (c :: * -> *).
(forall d b. Data d => c (d -> b) -> d -> c b)
-> (forall g. g -> c g) -> PullCommentReply -> c PullCommentReply
forall (t :: * -> *) (c :: * -> *).
Typeable t =>
(forall d. Data d => c (t d)) -> Maybe (c PullCommentReply)
forall (t :: * -> * -> *) (c :: * -> *).
Typeable t =>
(forall d e. (Data d, Data e) => c (t d e))
-> Maybe (c PullCommentReply)
$cgfoldl :: forall (c :: * -> *).
(forall d b. Data d => c (d -> b) -> d -> c b)
-> (forall g. g -> c g) -> PullCommentReply -> c PullCommentReply
gfoldl :: forall (c :: * -> *).
(forall d b. Data d => c (d -> b) -> d -> c b)
-> (forall g. g -> c g) -> PullCommentReply -> c PullCommentReply
$cgunfold :: forall (c :: * -> *).
(forall b r. Data b => c (b -> r) -> c r)
-> (forall r. r -> c r) -> Constr -> c PullCommentReply
gunfold :: forall (c :: * -> *).
(forall b r. Data b => c (b -> r) -> c r)
-> (forall r. r -> c r) -> Constr -> c PullCommentReply
$ctoConstr :: PullCommentReply -> Constr
toConstr :: PullCommentReply -> Constr
$cdataTypeOf :: PullCommentReply -> DataType
dataTypeOf :: PullCommentReply -> DataType
$cdataCast1 :: forall (t :: * -> *) (c :: * -> *).
Typeable t =>
(forall d. Data d => c (t d)) -> Maybe (c PullCommentReply)
dataCast1 :: forall (t :: * -> *) (c :: * -> *).
Typeable t =>
(forall d. Data d => c (t d)) -> Maybe (c PullCommentReply)
$cdataCast2 :: forall (t :: * -> * -> *) (c :: * -> *).
Typeable t =>
(forall d e. (Data d, Data e) => c (t d e))
-> Maybe (c PullCommentReply)
dataCast2 :: forall (t :: * -> * -> *) (c :: * -> *).
Typeable t =>
(forall d e. (Data d, Data e) => c (t d e))
-> Maybe (c PullCommentReply)
$cgmapT :: (forall b. Data b => b -> b)
-> PullCommentReply -> PullCommentReply
gmapT :: (forall b. Data b => b -> b)
-> PullCommentReply -> PullCommentReply
$cgmapQl :: forall r r'.
(r -> r' -> r)
-> r -> (forall d. Data d => d -> r') -> PullCommentReply -> r
gmapQl :: forall r r'.
(r -> r' -> r)
-> r -> (forall d. Data d => d -> r') -> PullCommentReply -> r
$cgmapQr :: forall r r'.
(r' -> r -> r)
-> r -> (forall d. Data d => d -> r') -> PullCommentReply -> r
gmapQr :: forall r r'.
(r' -> r -> r)
-> r -> (forall d. Data d => d -> r') -> PullCommentReply -> r
$cgmapQ :: forall u. (forall d. Data d => d -> u) -> PullCommentReply -> [u]
gmapQ :: forall u. (forall d. Data d => d -> u) -> PullCommentReply -> [u]
$cgmapQi :: forall u.
Int -> (forall d. Data d => d -> u) -> PullCommentReply -> u
gmapQi :: forall u.
Int -> (forall d. Data d => d -> u) -> PullCommentReply -> u
$cgmapM :: forall (m :: * -> *).
Monad m =>
(forall d. Data d => d -> m d)
-> PullCommentReply -> m PullCommentReply
gmapM :: forall (m :: * -> *).
Monad m =>
(forall d. Data d => d -> m d)
-> PullCommentReply -> m PullCommentReply
$cgmapMp :: forall (m :: * -> *).
MonadPlus m =>
(forall d. Data d => d -> m d)
-> PullCommentReply -> m PullCommentReply
gmapMp :: forall (m :: * -> *).
MonadPlus m =>
(forall d. Data d => d -> m d)
-> PullCommentReply -> m PullCommentReply
$cgmapMo :: forall (m :: * -> *).
MonadPlus m =>
(forall d. Data d => d -> m d)
-> PullCommentReply -> m PullCommentReply
gmapMo :: forall (m :: * -> *).
MonadPlus m =>
(forall d. Data d => d -> m d)
-> PullCommentReply -> m PullCommentReply
Data, Typeable, PullCommentReply -> PullCommentReply -> Bool
(PullCommentReply -> PullCommentReply -> Bool)
-> (PullCommentReply -> PullCommentReply -> Bool)
-> Eq PullCommentReply
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
$c== :: PullCommentReply -> PullCommentReply -> Bool
== :: PullCommentReply -> PullCommentReply -> Bool
$c/= :: PullCommentReply -> PullCommentReply -> Bool
/= :: PullCommentReply -> PullCommentReply -> Bool
Eq, Eq PullCommentReply
Eq PullCommentReply =>
(PullCommentReply -> PullCommentReply -> Ordering)
-> (PullCommentReply -> PullCommentReply -> Bool)
-> (PullCommentReply -> PullCommentReply -> Bool)
-> (PullCommentReply -> PullCommentReply -> Bool)
-> (PullCommentReply -> PullCommentReply -> Bool)
-> (PullCommentReply -> PullCommentReply -> PullCommentReply)
-> (PullCommentReply -> PullCommentReply -> PullCommentReply)
-> Ord PullCommentReply
PullCommentReply -> PullCommentReply -> Bool
PullCommentReply -> PullCommentReply -> Ordering
PullCommentReply -> PullCommentReply -> PullCommentReply
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 :: PullCommentReply -> PullCommentReply -> Ordering
compare :: PullCommentReply -> PullCommentReply -> Ordering
$c< :: PullCommentReply -> PullCommentReply -> Bool
< :: PullCommentReply -> PullCommentReply -> Bool
$c<= :: PullCommentReply -> PullCommentReply -> Bool
<= :: PullCommentReply -> PullCommentReply -> Bool
$c> :: PullCommentReply -> PullCommentReply -> Bool
> :: PullCommentReply -> PullCommentReply -> Bool
$c>= :: PullCommentReply -> PullCommentReply -> Bool
>= :: PullCommentReply -> PullCommentReply -> Bool
$cmax :: PullCommentReply -> PullCommentReply -> PullCommentReply
max :: PullCommentReply -> PullCommentReply -> PullCommentReply
$cmin :: PullCommentReply -> PullCommentReply -> PullCommentReply
min :: PullCommentReply -> PullCommentReply -> PullCommentReply
Ord, (forall x. PullCommentReply -> Rep PullCommentReply x)
-> (forall x. Rep PullCommentReply x -> PullCommentReply)
-> Generic PullCommentReply
forall x. Rep PullCommentReply x -> PullCommentReply
forall x. PullCommentReply -> Rep PullCommentReply x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cfrom :: forall x. PullCommentReply -> Rep PullCommentReply x
from :: forall x. PullCommentReply -> Rep PullCommentReply x
$cto :: forall x. Rep PullCommentReply x -> PullCommentReply
to :: forall x. Rep PullCommentReply x -> PullCommentReply
Generic)

instance NFData PullCommentReply where rnf :: PullCommentReply -> ()
rnf = PullCommentReply -> ()
forall a. (Generic a, GNFData (Rep a)) => a -> ()
genericRnf

instance ToJSON PullCommentReply where
    toJSON :: PullCommentReply -> Value
toJSON (PullCommentReply Text
b) =
        [Pair] -> Value
object [ Key
"body" Key -> Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Key -> v -> kv
forall v. ToJSON v => Key -> v -> Pair
.= Text
b
               ]