{- |
Copyright  : Will Thompson, Iñaki García Etxebarria and Jonas Platte
License    : LGPL-2.1
Maintainer : Iñaki García Etxebarria (inaki@blueleaf.cc)

Represents the options used when creating a 'GI.Ggit.Objects.Diff.Diff'.
-}

#define ENABLE_OVERLOADING (MIN_VERSION_haskell_gi_overloading(1,0,0) \
       && !defined(__HADDOCK_VERSION__))

module GI.Ggit.Objects.DiffOptions
    (

-- * Exported types
    DiffOptions(..)                         ,
    IsDiffOptions                           ,
    toDiffOptions                           ,
    noDiffOptions                           ,


 -- * Methods
-- ** getFlags #method:getFlags#

#if ENABLE_OVERLOADING
    DiffOptionsGetFlagsMethodInfo           ,
#endif
    diffOptionsGetFlags                     ,


-- ** getNContextLines #method:getNContextLines#

#if ENABLE_OVERLOADING
    DiffOptionsGetNContextLinesMethodInfo   ,
#endif
    diffOptionsGetNContextLines             ,


-- ** getNInterhunkLines #method:getNInterhunkLines#

#if ENABLE_OVERLOADING
    DiffOptionsGetNInterhunkLinesMethodInfo ,
#endif
    diffOptionsGetNInterhunkLines           ,


-- ** getNewPrefix #method:getNewPrefix#

#if ENABLE_OVERLOADING
    DiffOptionsGetNewPrefixMethodInfo       ,
#endif
    diffOptionsGetNewPrefix                 ,


-- ** getOldPrefix #method:getOldPrefix#

#if ENABLE_OVERLOADING
    DiffOptionsGetOldPrefixMethodInfo       ,
#endif
    diffOptionsGetOldPrefix                 ,


-- ** getPathspec #method:getPathspec#

#if ENABLE_OVERLOADING
    DiffOptionsGetPathspecMethodInfo        ,
#endif
    diffOptionsGetPathspec                  ,


-- ** new #method:new#

    diffOptionsNew                          ,


-- ** setFlags #method:setFlags#

#if ENABLE_OVERLOADING
    DiffOptionsSetFlagsMethodInfo           ,
#endif
    diffOptionsSetFlags                     ,


-- ** setNContextLines #method:setNContextLines#

#if ENABLE_OVERLOADING
    DiffOptionsSetNContextLinesMethodInfo   ,
#endif
    diffOptionsSetNContextLines             ,


-- ** setNInterhunkLines #method:setNInterhunkLines#

#if ENABLE_OVERLOADING
    DiffOptionsSetNInterhunkLinesMethodInfo ,
#endif
    diffOptionsSetNInterhunkLines           ,


-- ** setNewPrefix #method:setNewPrefix#

#if ENABLE_OVERLOADING
    DiffOptionsSetNewPrefixMethodInfo       ,
#endif
    diffOptionsSetNewPrefix                 ,


-- ** setOldPrefix #method:setOldPrefix#

#if ENABLE_OVERLOADING
    DiffOptionsSetOldPrefixMethodInfo       ,
#endif
    diffOptionsSetOldPrefix                 ,


-- ** setPathspec #method:setPathspec#

#if ENABLE_OVERLOADING
    DiffOptionsSetPathspecMethodInfo        ,
#endif
    diffOptionsSetPathspec                  ,




 -- * Properties
-- ** flags #attr:flags#
{- | The diff option flags.
-}
#if ENABLE_OVERLOADING
    DiffOptionsFlagsPropertyInfo            ,
#endif
    constructDiffOptionsFlags               ,
#if ENABLE_OVERLOADING
    diffOptionsFlags                        ,
#endif
    getDiffOptionsFlags                     ,
    setDiffOptionsFlags                     ,


-- ** nContextLines #attr:nContextLines#
{- | /No description available in the introspection data./
-}
#if ENABLE_OVERLOADING
    DiffOptionsNContextLinesPropertyInfo    ,
#endif
    constructDiffOptionsNContextLines       ,
#if ENABLE_OVERLOADING
    diffOptionsNContextLines                ,
#endif
    getDiffOptionsNContextLines             ,
    setDiffOptionsNContextLines             ,


-- ** nInterhunkLines #attr:nInterhunkLines#
{- | /No description available in the introspection data./
-}
#if ENABLE_OVERLOADING
    DiffOptionsNInterhunkLinesPropertyInfo  ,
#endif
    constructDiffOptionsNInterhunkLines     ,
#if ENABLE_OVERLOADING
    diffOptionsNInterhunkLines              ,
#endif
    getDiffOptionsNInterhunkLines           ,
    setDiffOptionsNInterhunkLines           ,


-- ** newPrefix #attr:newPrefix#
{- | /No description available in the introspection data./
-}
#if ENABLE_OVERLOADING
    DiffOptionsNewPrefixPropertyInfo        ,
#endif
    constructDiffOptionsNewPrefix           ,
#if ENABLE_OVERLOADING
    diffOptionsNewPrefix                    ,
#endif
    getDiffOptionsNewPrefix                 ,
    setDiffOptionsNewPrefix                 ,


-- ** oldPrefix #attr:oldPrefix#
{- | /No description available in the introspection data./
-}
#if ENABLE_OVERLOADING
    DiffOptionsOldPrefixPropertyInfo        ,
#endif
    constructDiffOptionsOldPrefix           ,
#if ENABLE_OVERLOADING
    diffOptionsOldPrefix                    ,
#endif
    getDiffOptionsOldPrefix                 ,
    setDiffOptionsOldPrefix                 ,


-- ** pathspec #attr:pathspec#
{- | /No description available in the introspection data./
-}
#if ENABLE_OVERLOADING
    DiffOptionsPathspecPropertyInfo         ,
#endif
    clearDiffOptionsPathspec                ,
    constructDiffOptionsPathspec            ,
#if ENABLE_OVERLOADING
    diffOptionsPathspec                     ,
#endif
    getDiffOptionsPathspec                  ,
    setDiffOptionsPathspec                  ,




    ) where

import Data.GI.Base.ShortPrelude
import qualified Data.GI.Base.ShortPrelude as SP
import qualified Data.GI.Base.Overloading as O
import qualified Prelude as P

import qualified Data.GI.Base.Attributes as GI.Attributes
import qualified Data.GI.Base.ManagedPtr as B.ManagedPtr
import qualified Data.GI.Base.GClosure as B.GClosure
import qualified Data.GI.Base.GError as B.GError
import qualified Data.GI.Base.GVariant as B.GVariant
import qualified Data.GI.Base.GValue as B.GValue
import qualified Data.GI.Base.GParamSpec as B.GParamSpec
import qualified Data.GI.Base.CallStack as B.CallStack
import qualified Data.GI.Base.Properties as B.Properties
import qualified Data.Text as T
import qualified Data.ByteString.Char8 as B
import qualified Data.Map as Map
import qualified Foreign.Ptr as FP
import qualified GHC.OverloadedLabels as OL

import qualified GI.GObject.Objects.Object as GObject.Object
import {-# SOURCE #-} qualified GI.Ggit.Flags as Ggit.Flags

-- | Memory-managed wrapper type.
newtype DiffOptions = DiffOptions (ManagedPtr DiffOptions)
foreign import ccall "ggit_diff_options_get_type"
    c_ggit_diff_options_get_type :: IO GType

instance GObject DiffOptions where
    gobjectType = c_ggit_diff_options_get_type


-- | Type class for types which can be safely cast to `DiffOptions`, for instance with `toDiffOptions`.
class (GObject o, O.IsDescendantOf DiffOptions o) => IsDiffOptions o
instance (GObject o, O.IsDescendantOf DiffOptions o) => IsDiffOptions o

instance O.HasParentTypes DiffOptions
type instance O.ParentTypes DiffOptions = '[GObject.Object.Object]

-- | Cast to `DiffOptions`, for types for which this is known to be safe. For general casts, use `Data.GI.Base.ManagedPtr.castTo`.
toDiffOptions :: (MonadIO m, IsDiffOptions o) => o -> m DiffOptions
toDiffOptions = liftIO . unsafeCastTo DiffOptions

-- | A convenience alias for `Nothing` :: `Maybe` `DiffOptions`.
noDiffOptions :: Maybe DiffOptions
noDiffOptions = Nothing

#if ENABLE_OVERLOADING
type family ResolveDiffOptionsMethod (t :: Symbol) (o :: *) :: * where
    ResolveDiffOptionsMethod "bindProperty" o = GObject.Object.ObjectBindPropertyMethodInfo
    ResolveDiffOptionsMethod "bindPropertyFull" o = GObject.Object.ObjectBindPropertyFullMethodInfo
    ResolveDiffOptionsMethod "forceFloating" o = GObject.Object.ObjectForceFloatingMethodInfo
    ResolveDiffOptionsMethod "freezeNotify" o = GObject.Object.ObjectFreezeNotifyMethodInfo
    ResolveDiffOptionsMethod "getv" o = GObject.Object.ObjectGetvMethodInfo
    ResolveDiffOptionsMethod "isFloating" o = GObject.Object.ObjectIsFloatingMethodInfo
    ResolveDiffOptionsMethod "notify" o = GObject.Object.ObjectNotifyMethodInfo
    ResolveDiffOptionsMethod "notifyByPspec" o = GObject.Object.ObjectNotifyByPspecMethodInfo
    ResolveDiffOptionsMethod "ref" o = GObject.Object.ObjectRefMethodInfo
    ResolveDiffOptionsMethod "refSink" o = GObject.Object.ObjectRefSinkMethodInfo
    ResolveDiffOptionsMethod "runDispose" o = GObject.Object.ObjectRunDisposeMethodInfo
    ResolveDiffOptionsMethod "stealData" o = GObject.Object.ObjectStealDataMethodInfo
    ResolveDiffOptionsMethod "stealQdata" o = GObject.Object.ObjectStealQdataMethodInfo
    ResolveDiffOptionsMethod "thawNotify" o = GObject.Object.ObjectThawNotifyMethodInfo
    ResolveDiffOptionsMethod "unref" o = GObject.Object.ObjectUnrefMethodInfo
    ResolveDiffOptionsMethod "watchClosure" o = GObject.Object.ObjectWatchClosureMethodInfo
    ResolveDiffOptionsMethod "getData" o = GObject.Object.ObjectGetDataMethodInfo
    ResolveDiffOptionsMethod "getFlags" o = DiffOptionsGetFlagsMethodInfo
    ResolveDiffOptionsMethod "getNContextLines" o = DiffOptionsGetNContextLinesMethodInfo
    ResolveDiffOptionsMethod "getNInterhunkLines" o = DiffOptionsGetNInterhunkLinesMethodInfo
    ResolveDiffOptionsMethod "getNewPrefix" o = DiffOptionsGetNewPrefixMethodInfo
    ResolveDiffOptionsMethod "getOldPrefix" o = DiffOptionsGetOldPrefixMethodInfo
    ResolveDiffOptionsMethod "getPathspec" o = DiffOptionsGetPathspecMethodInfo
    ResolveDiffOptionsMethod "getProperty" o = GObject.Object.ObjectGetPropertyMethodInfo
    ResolveDiffOptionsMethod "getQdata" o = GObject.Object.ObjectGetQdataMethodInfo
    ResolveDiffOptionsMethod "setData" o = GObject.Object.ObjectSetDataMethodInfo
    ResolveDiffOptionsMethod "setDataFull" o = GObject.Object.ObjectSetDataFullMethodInfo
    ResolveDiffOptionsMethod "setFlags" o = DiffOptionsSetFlagsMethodInfo
    ResolveDiffOptionsMethod "setNContextLines" o = DiffOptionsSetNContextLinesMethodInfo
    ResolveDiffOptionsMethod "setNInterhunkLines" o = DiffOptionsSetNInterhunkLinesMethodInfo
    ResolveDiffOptionsMethod "setNewPrefix" o = DiffOptionsSetNewPrefixMethodInfo
    ResolveDiffOptionsMethod "setOldPrefix" o = DiffOptionsSetOldPrefixMethodInfo
    ResolveDiffOptionsMethod "setPathspec" o = DiffOptionsSetPathspecMethodInfo
    ResolveDiffOptionsMethod "setProperty" o = GObject.Object.ObjectSetPropertyMethodInfo
    ResolveDiffOptionsMethod l o = O.MethodResolutionFailed l o

instance (info ~ ResolveDiffOptionsMethod t DiffOptions, O.MethodInfo info DiffOptions p) => OL.IsLabel t (DiffOptions -> p) where
#if MIN_VERSION_base(4,10,0)
    fromLabel = O.overloadedMethod (O.MethodProxy :: O.MethodProxy info)
#else
    fromLabel _ = O.overloadedMethod (O.MethodProxy :: O.MethodProxy info)
#endif

#endif

-- VVV Prop "flags"
   -- Type: TInterface (Name {namespace = "Ggit", name = "DiffOption"})
   -- Flags: [PropertyReadable,PropertyWritable,PropertyConstruct]
   -- Nullable: (Just False,Just False)

{- |
Get the value of the “@flags@” property.
When <https://github.com/haskell-gi/haskell-gi/wiki/Overloading overloading> is enabled, this is equivalent to

@
'Data.GI.Base.Attributes.get' diffOptions #flags
@
-}
getDiffOptionsFlags :: (MonadIO m, IsDiffOptions o) => o -> m [Ggit.Flags.DiffOption]
getDiffOptionsFlags obj = liftIO $ B.Properties.getObjectPropertyFlags obj "flags"

{- |
Set the value of the “@flags@” property.
When <https://github.com/haskell-gi/haskell-gi/wiki/Overloading overloading> is enabled, this is equivalent to

@
'Data.GI.Base.Attributes.set' diffOptions [ #flags 'Data.GI.Base.Attributes.:=' value ]
@
-}
setDiffOptionsFlags :: (MonadIO m, IsDiffOptions o) => o -> [Ggit.Flags.DiffOption] -> m ()
setDiffOptionsFlags obj val = liftIO $ B.Properties.setObjectPropertyFlags obj "flags" val

{- |
Construct a `GValueConstruct` with valid value for the “@flags@” property. This is rarely needed directly, but it is used by `Data.GI.Base.Constructible.new`.
-}
constructDiffOptionsFlags :: (IsDiffOptions o) => [Ggit.Flags.DiffOption] -> IO (GValueConstruct o)
constructDiffOptionsFlags val = B.Properties.constructObjectPropertyFlags "flags" val

#if ENABLE_OVERLOADING
data DiffOptionsFlagsPropertyInfo
instance AttrInfo DiffOptionsFlagsPropertyInfo where
    type AttrAllowedOps DiffOptionsFlagsPropertyInfo = '[ 'AttrSet, 'AttrConstruct, 'AttrGet]
    type AttrSetTypeConstraint DiffOptionsFlagsPropertyInfo = (~) [Ggit.Flags.DiffOption]
    type AttrBaseTypeConstraint DiffOptionsFlagsPropertyInfo = IsDiffOptions
    type AttrGetType DiffOptionsFlagsPropertyInfo = [Ggit.Flags.DiffOption]
    type AttrLabel DiffOptionsFlagsPropertyInfo = "flags"
    type AttrOrigin DiffOptionsFlagsPropertyInfo = DiffOptions
    attrGet _ = getDiffOptionsFlags
    attrSet _ = setDiffOptionsFlags
    attrConstruct _ = constructDiffOptionsFlags
    attrClear _ = undefined
#endif

-- VVV Prop "n-context-lines"
   -- Type: TBasicType TInt
   -- Flags: [PropertyReadable,PropertyWritable,PropertyConstruct]
   -- Nullable: (Just False,Just False)

{- |
Get the value of the “@n-context-lines@” property.
When <https://github.com/haskell-gi/haskell-gi/wiki/Overloading overloading> is enabled, this is equivalent to

@
'Data.GI.Base.Attributes.get' diffOptions #nContextLines
@
-}
getDiffOptionsNContextLines :: (MonadIO m, IsDiffOptions o) => o -> m Int32
getDiffOptionsNContextLines obj = liftIO $ B.Properties.getObjectPropertyInt32 obj "n-context-lines"

{- |
Set the value of the “@n-context-lines@” property.
When <https://github.com/haskell-gi/haskell-gi/wiki/Overloading overloading> is enabled, this is equivalent to

@
'Data.GI.Base.Attributes.set' diffOptions [ #nContextLines 'Data.GI.Base.Attributes.:=' value ]
@
-}
setDiffOptionsNContextLines :: (MonadIO m, IsDiffOptions o) => o -> Int32 -> m ()
setDiffOptionsNContextLines obj val = liftIO $ B.Properties.setObjectPropertyInt32 obj "n-context-lines" val

{- |
Construct a `GValueConstruct` with valid value for the “@n-context-lines@” property. This is rarely needed directly, but it is used by `Data.GI.Base.Constructible.new`.
-}
constructDiffOptionsNContextLines :: (IsDiffOptions o) => Int32 -> IO (GValueConstruct o)
constructDiffOptionsNContextLines val = B.Properties.constructObjectPropertyInt32 "n-context-lines" val

#if ENABLE_OVERLOADING
data DiffOptionsNContextLinesPropertyInfo
instance AttrInfo DiffOptionsNContextLinesPropertyInfo where
    type AttrAllowedOps DiffOptionsNContextLinesPropertyInfo = '[ 'AttrSet, 'AttrConstruct, 'AttrGet]
    type AttrSetTypeConstraint DiffOptionsNContextLinesPropertyInfo = (~) Int32
    type AttrBaseTypeConstraint DiffOptionsNContextLinesPropertyInfo = IsDiffOptions
    type AttrGetType DiffOptionsNContextLinesPropertyInfo = Int32
    type AttrLabel DiffOptionsNContextLinesPropertyInfo = "n-context-lines"
    type AttrOrigin DiffOptionsNContextLinesPropertyInfo = DiffOptions
    attrGet _ = getDiffOptionsNContextLines
    attrSet _ = setDiffOptionsNContextLines
    attrConstruct _ = constructDiffOptionsNContextLines
    attrClear _ = undefined
#endif

-- VVV Prop "n-interhunk-lines"
   -- Type: TBasicType TInt
   -- Flags: [PropertyReadable,PropertyWritable,PropertyConstruct]
   -- Nullable: (Just False,Just False)

{- |
Get the value of the “@n-interhunk-lines@” property.
When <https://github.com/haskell-gi/haskell-gi/wiki/Overloading overloading> is enabled, this is equivalent to

@
'Data.GI.Base.Attributes.get' diffOptions #nInterhunkLines
@
-}
getDiffOptionsNInterhunkLines :: (MonadIO m, IsDiffOptions o) => o -> m Int32
getDiffOptionsNInterhunkLines obj = liftIO $ B.Properties.getObjectPropertyInt32 obj "n-interhunk-lines"

{- |
Set the value of the “@n-interhunk-lines@” property.
When <https://github.com/haskell-gi/haskell-gi/wiki/Overloading overloading> is enabled, this is equivalent to

@
'Data.GI.Base.Attributes.set' diffOptions [ #nInterhunkLines 'Data.GI.Base.Attributes.:=' value ]
@
-}
setDiffOptionsNInterhunkLines :: (MonadIO m, IsDiffOptions o) => o -> Int32 -> m ()
setDiffOptionsNInterhunkLines obj val = liftIO $ B.Properties.setObjectPropertyInt32 obj "n-interhunk-lines" val

{- |
Construct a `GValueConstruct` with valid value for the “@n-interhunk-lines@” property. This is rarely needed directly, but it is used by `Data.GI.Base.Constructible.new`.
-}
constructDiffOptionsNInterhunkLines :: (IsDiffOptions o) => Int32 -> IO (GValueConstruct o)
constructDiffOptionsNInterhunkLines val = B.Properties.constructObjectPropertyInt32 "n-interhunk-lines" val

#if ENABLE_OVERLOADING
data DiffOptionsNInterhunkLinesPropertyInfo
instance AttrInfo DiffOptionsNInterhunkLinesPropertyInfo where
    type AttrAllowedOps DiffOptionsNInterhunkLinesPropertyInfo = '[ 'AttrSet, 'AttrConstruct, 'AttrGet]
    type AttrSetTypeConstraint DiffOptionsNInterhunkLinesPropertyInfo = (~) Int32
    type AttrBaseTypeConstraint DiffOptionsNInterhunkLinesPropertyInfo = IsDiffOptions
    type AttrGetType DiffOptionsNInterhunkLinesPropertyInfo = Int32
    type AttrLabel DiffOptionsNInterhunkLinesPropertyInfo = "n-interhunk-lines"
    type AttrOrigin DiffOptionsNInterhunkLinesPropertyInfo = DiffOptions
    attrGet _ = getDiffOptionsNInterhunkLines
    attrSet _ = setDiffOptionsNInterhunkLines
    attrConstruct _ = constructDiffOptionsNInterhunkLines
    attrClear _ = undefined
#endif

-- VVV Prop "new-prefix"
   -- Type: TBasicType TUTF8
   -- Flags: [PropertyReadable,PropertyWritable,PropertyConstruct]
   -- Nullable: (Just True,Just False)

{- |
Get the value of the “@new-prefix@” property.
When <https://github.com/haskell-gi/haskell-gi/wiki/Overloading overloading> is enabled, this is equivalent to

@
'Data.GI.Base.Attributes.get' diffOptions #newPrefix
@
-}
getDiffOptionsNewPrefix :: (MonadIO m, IsDiffOptions o) => o -> m (Maybe T.Text)
getDiffOptionsNewPrefix obj = liftIO $ B.Properties.getObjectPropertyString obj "new-prefix"

{- |
Set the value of the “@new-prefix@” property.
When <https://github.com/haskell-gi/haskell-gi/wiki/Overloading overloading> is enabled, this is equivalent to

@
'Data.GI.Base.Attributes.set' diffOptions [ #newPrefix 'Data.GI.Base.Attributes.:=' value ]
@
-}
setDiffOptionsNewPrefix :: (MonadIO m, IsDiffOptions o) => o -> T.Text -> m ()
setDiffOptionsNewPrefix obj val = liftIO $ B.Properties.setObjectPropertyString obj "new-prefix" (Just val)

{- |
Construct a `GValueConstruct` with valid value for the “@new-prefix@” property. This is rarely needed directly, but it is used by `Data.GI.Base.Constructible.new`.
-}
constructDiffOptionsNewPrefix :: (IsDiffOptions o) => T.Text -> IO (GValueConstruct o)
constructDiffOptionsNewPrefix val = B.Properties.constructObjectPropertyString "new-prefix" (Just val)

#if ENABLE_OVERLOADING
data DiffOptionsNewPrefixPropertyInfo
instance AttrInfo DiffOptionsNewPrefixPropertyInfo where
    type AttrAllowedOps DiffOptionsNewPrefixPropertyInfo = '[ 'AttrSet, 'AttrConstruct, 'AttrGet]
    type AttrSetTypeConstraint DiffOptionsNewPrefixPropertyInfo = (~) T.Text
    type AttrBaseTypeConstraint DiffOptionsNewPrefixPropertyInfo = IsDiffOptions
    type AttrGetType DiffOptionsNewPrefixPropertyInfo = (Maybe T.Text)
    type AttrLabel DiffOptionsNewPrefixPropertyInfo = "new-prefix"
    type AttrOrigin DiffOptionsNewPrefixPropertyInfo = DiffOptions
    attrGet _ = getDiffOptionsNewPrefix
    attrSet _ = setDiffOptionsNewPrefix
    attrConstruct _ = constructDiffOptionsNewPrefix
    attrClear _ = undefined
#endif

-- VVV Prop "old-prefix"
   -- Type: TBasicType TUTF8
   -- Flags: [PropertyReadable,PropertyWritable,PropertyConstruct]
   -- Nullable: (Nothing,Just False)

{- |
Get the value of the “@old-prefix@” property.
When <https://github.com/haskell-gi/haskell-gi/wiki/Overloading overloading> is enabled, this is equivalent to

@
'Data.GI.Base.Attributes.get' diffOptions #oldPrefix
@
-}
getDiffOptionsOldPrefix :: (MonadIO m, IsDiffOptions o) => o -> m (Maybe T.Text)
getDiffOptionsOldPrefix obj = liftIO $ B.Properties.getObjectPropertyString obj "old-prefix"

{- |
Set the value of the “@old-prefix@” property.
When <https://github.com/haskell-gi/haskell-gi/wiki/Overloading overloading> is enabled, this is equivalent to

@
'Data.GI.Base.Attributes.set' diffOptions [ #oldPrefix 'Data.GI.Base.Attributes.:=' value ]
@
-}
setDiffOptionsOldPrefix :: (MonadIO m, IsDiffOptions o) => o -> T.Text -> m ()
setDiffOptionsOldPrefix obj val = liftIO $ B.Properties.setObjectPropertyString obj "old-prefix" (Just val)

{- |
Construct a `GValueConstruct` with valid value for the “@old-prefix@” property. This is rarely needed directly, but it is used by `Data.GI.Base.Constructible.new`.
-}
constructDiffOptionsOldPrefix :: (IsDiffOptions o) => T.Text -> IO (GValueConstruct o)
constructDiffOptionsOldPrefix val = B.Properties.constructObjectPropertyString "old-prefix" (Just val)

#if ENABLE_OVERLOADING
data DiffOptionsOldPrefixPropertyInfo
instance AttrInfo DiffOptionsOldPrefixPropertyInfo where
    type AttrAllowedOps DiffOptionsOldPrefixPropertyInfo = '[ 'AttrSet, 'AttrConstruct, 'AttrGet]
    type AttrSetTypeConstraint DiffOptionsOldPrefixPropertyInfo = (~) T.Text
    type AttrBaseTypeConstraint DiffOptionsOldPrefixPropertyInfo = IsDiffOptions
    type AttrGetType DiffOptionsOldPrefixPropertyInfo = (Maybe T.Text)
    type AttrLabel DiffOptionsOldPrefixPropertyInfo = "old-prefix"
    type AttrOrigin DiffOptionsOldPrefixPropertyInfo = DiffOptions
    attrGet _ = getDiffOptionsOldPrefix
    attrSet _ = setDiffOptionsOldPrefix
    attrConstruct _ = constructDiffOptionsOldPrefix
    attrClear _ = undefined
#endif

-- VVV Prop "pathspec"
   -- Type: TCArray True (-1) (-1) (TBasicType TUTF8)
   -- Flags: [PropertyReadable,PropertyWritable,PropertyConstruct]
   -- Nullable: (Just True,Just True)

{- |
Get the value of the “@pathspec@” property.
When <https://github.com/haskell-gi/haskell-gi/wiki/Overloading overloading> is enabled, this is equivalent to

@
'Data.GI.Base.Attributes.get' diffOptions #pathspec
@
-}
getDiffOptionsPathspec :: (MonadIO m, IsDiffOptions o) => o -> m (Maybe [T.Text])
getDiffOptionsPathspec obj = liftIO $ B.Properties.getObjectPropertyStringArray obj "pathspec"

{- |
Set the value of the “@pathspec@” property.
When <https://github.com/haskell-gi/haskell-gi/wiki/Overloading overloading> is enabled, this is equivalent to

@
'Data.GI.Base.Attributes.set' diffOptions [ #pathspec 'Data.GI.Base.Attributes.:=' value ]
@
-}
setDiffOptionsPathspec :: (MonadIO m, IsDiffOptions o) => o -> [T.Text] -> m ()
setDiffOptionsPathspec obj val = liftIO $ B.Properties.setObjectPropertyStringArray obj "pathspec" (Just val)

{- |
Construct a `GValueConstruct` with valid value for the “@pathspec@” property. This is rarely needed directly, but it is used by `Data.GI.Base.Constructible.new`.
-}
constructDiffOptionsPathspec :: (IsDiffOptions o) => [T.Text] -> IO (GValueConstruct o)
constructDiffOptionsPathspec val = B.Properties.constructObjectPropertyStringArray "pathspec" (Just val)

{- |
Set the value of the “@pathspec@” property to `Nothing`.
When <https://github.com/haskell-gi/haskell-gi/wiki/Overloading overloading> is enabled, this is equivalent to

@
'Data.GI.Base.Attributes.clear' #pathspec
@
-}
clearDiffOptionsPathspec :: (MonadIO m, IsDiffOptions o) => o -> m ()
clearDiffOptionsPathspec obj = liftIO $ B.Properties.setObjectPropertyStringArray obj "pathspec" (Nothing :: Maybe [T.Text])

#if ENABLE_OVERLOADING
data DiffOptionsPathspecPropertyInfo
instance AttrInfo DiffOptionsPathspecPropertyInfo where
    type AttrAllowedOps DiffOptionsPathspecPropertyInfo = '[ 'AttrSet, 'AttrConstruct, 'AttrGet, 'AttrClear]
    type AttrSetTypeConstraint DiffOptionsPathspecPropertyInfo = (~) [T.Text]
    type AttrBaseTypeConstraint DiffOptionsPathspecPropertyInfo = IsDiffOptions
    type AttrGetType DiffOptionsPathspecPropertyInfo = (Maybe [T.Text])
    type AttrLabel DiffOptionsPathspecPropertyInfo = "pathspec"
    type AttrOrigin DiffOptionsPathspecPropertyInfo = DiffOptions
    attrGet _ = getDiffOptionsPathspec
    attrSet _ = setDiffOptionsPathspec
    attrConstruct _ = constructDiffOptionsPathspec
    attrClear _ = clearDiffOptionsPathspec
#endif

#if ENABLE_OVERLOADING
instance O.HasAttributeList DiffOptions
type instance O.AttributeList DiffOptions = DiffOptionsAttributeList
type DiffOptionsAttributeList = ('[ '("flags", DiffOptionsFlagsPropertyInfo), '("nContextLines", DiffOptionsNContextLinesPropertyInfo), '("nInterhunkLines", DiffOptionsNInterhunkLinesPropertyInfo), '("newPrefix", DiffOptionsNewPrefixPropertyInfo), '("oldPrefix", DiffOptionsOldPrefixPropertyInfo), '("pathspec", DiffOptionsPathspecPropertyInfo)] :: [(Symbol, *)])
#endif

#if ENABLE_OVERLOADING
diffOptionsFlags :: AttrLabelProxy "flags"
diffOptionsFlags = AttrLabelProxy

diffOptionsNContextLines :: AttrLabelProxy "nContextLines"
diffOptionsNContextLines = AttrLabelProxy

diffOptionsNInterhunkLines :: AttrLabelProxy "nInterhunkLines"
diffOptionsNInterhunkLines = AttrLabelProxy

diffOptionsNewPrefix :: AttrLabelProxy "newPrefix"
diffOptionsNewPrefix = AttrLabelProxy

diffOptionsOldPrefix :: AttrLabelProxy "oldPrefix"
diffOptionsOldPrefix = AttrLabelProxy

diffOptionsPathspec :: AttrLabelProxy "pathspec"
diffOptionsPathspec = AttrLabelProxy

#endif

#if ENABLE_OVERLOADING
type instance O.SignalList DiffOptions = DiffOptionsSignalList
type DiffOptionsSignalList = ('[ '("notify", GObject.Object.ObjectNotifySignalInfo)] :: [(Symbol, *)])

#endif

-- method DiffOptions::new
-- method type : Constructor
-- Args : []
-- Lengths : []
-- returnType : Just (TInterface (Name {namespace = "Ggit", name = "DiffOptions"}))
-- throws : False
-- Skip return : False

foreign import ccall "ggit_diff_options_new" ggit_diff_options_new ::
    IO (Ptr DiffOptions)

{- |
Create a new diff options object.
-}
diffOptionsNew ::
    (B.CallStack.HasCallStack, MonadIO m) =>
    m (Maybe DiffOptions)
    {- ^ __Returns:__ a 'GI.Ggit.Objects.DiffOptions.DiffOptions' or 'Nothing'. -}
diffOptionsNew  = liftIO $ do
    result <- ggit_diff_options_new
    maybeResult <- convertIfNonNull result $ \result' -> do
        result'' <- (wrapObject DiffOptions) result'
        return result''
    return maybeResult

#if ENABLE_OVERLOADING
#endif

-- method DiffOptions::get_flags
-- method type : OrdinaryMethod
-- Args : [Arg {argCName = "options", argType = TInterface (Name {namespace = "Ggit", name = "DiffOptions"}), direction = DirectionIn, mayBeNull = False, argDoc = Documentation {rawDocText = Just "a #GgitDiffOptions.", sinceVersion = Nothing}, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, argCallerAllocates = False, transfer = TransferNothing}]
-- Lengths : []
-- returnType : Just (TInterface (Name {namespace = "Ggit", name = "DiffOption"}))
-- throws : False
-- Skip return : False

foreign import ccall "ggit_diff_options_get_flags" ggit_diff_options_get_flags ::
    Ptr DiffOptions ->                      -- options : TInterface (Name {namespace = "Ggit", name = "DiffOptions"})
    IO CUInt

{- |
Get the diff flags.
-}
diffOptionsGetFlags ::
    (B.CallStack.HasCallStack, MonadIO m, IsDiffOptions a) =>
    a
    {- ^ /@options@/: a 'GI.Ggit.Objects.DiffOptions.DiffOptions'. -}
    -> m [Ggit.Flags.DiffOption]
    {- ^ __Returns:__ a 'GI.Ggit.Flags.DiffOption'. -}
diffOptionsGetFlags options = liftIO $ do
    options' <- unsafeManagedPtrCastPtr options
    result <- ggit_diff_options_get_flags options'
    let result' = wordToGFlags result
    touchManagedPtr options
    return result'

#if ENABLE_OVERLOADING
data DiffOptionsGetFlagsMethodInfo
instance (signature ~ (m [Ggit.Flags.DiffOption]), MonadIO m, IsDiffOptions a) => O.MethodInfo DiffOptionsGetFlagsMethodInfo a signature where
    overloadedMethod _ = diffOptionsGetFlags

#endif

-- method DiffOptions::get_n_context_lines
-- method type : OrdinaryMethod
-- Args : [Arg {argCName = "options", argType = TInterface (Name {namespace = "Ggit", name = "DiffOptions"}), direction = DirectionIn, mayBeNull = False, argDoc = Documentation {rawDocText = Just "a #GgitDiffOptions.", sinceVersion = Nothing}, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, argCallerAllocates = False, transfer = TransferNothing}]
-- Lengths : []
-- returnType : Just (TBasicType TInt)
-- throws : False
-- Skip return : False

foreign import ccall "ggit_diff_options_get_n_context_lines" ggit_diff_options_get_n_context_lines ::
    Ptr DiffOptions ->                      -- options : TInterface (Name {namespace = "Ggit", name = "DiffOptions"})
    IO Int32

{- |
Get the number of context lines to include in the diff.
-}
diffOptionsGetNContextLines ::
    (B.CallStack.HasCallStack, MonadIO m, IsDiffOptions a) =>
    a
    {- ^ /@options@/: a 'GI.Ggit.Objects.DiffOptions.DiffOptions'. -}
    -> m Int32
    {- ^ __Returns:__ the number of context lines. -}
diffOptionsGetNContextLines options = liftIO $ do
    options' <- unsafeManagedPtrCastPtr options
    result <- ggit_diff_options_get_n_context_lines options'
    touchManagedPtr options
    return result

#if ENABLE_OVERLOADING
data DiffOptionsGetNContextLinesMethodInfo
instance (signature ~ (m Int32), MonadIO m, IsDiffOptions a) => O.MethodInfo DiffOptionsGetNContextLinesMethodInfo a signature where
    overloadedMethod _ = diffOptionsGetNContextLines

#endif

-- method DiffOptions::get_n_interhunk_lines
-- method type : OrdinaryMethod
-- Args : [Arg {argCName = "options", argType = TInterface (Name {namespace = "Ggit", name = "DiffOptions"}), direction = DirectionIn, mayBeNull = False, argDoc = Documentation {rawDocText = Just "a #GgitDiffOptions.", sinceVersion = Nothing}, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, argCallerAllocates = False, transfer = TransferNothing}]
-- Lengths : []
-- returnType : Just (TBasicType TInt)
-- throws : False
-- Skip return : False

foreign import ccall "ggit_diff_options_get_n_interhunk_lines" ggit_diff_options_get_n_interhunk_lines ::
    Ptr DiffOptions ->                      -- options : TInterface (Name {namespace = "Ggit", name = "DiffOptions"})
    IO Int32

{- |
Get the number of interhunk lines to include in the diff.
-}
diffOptionsGetNInterhunkLines ::
    (B.CallStack.HasCallStack, MonadIO m, IsDiffOptions a) =>
    a
    {- ^ /@options@/: a 'GI.Ggit.Objects.DiffOptions.DiffOptions'. -}
    -> m Int32
    {- ^ __Returns:__ the number of lines. -}
diffOptionsGetNInterhunkLines options = liftIO $ do
    options' <- unsafeManagedPtrCastPtr options
    result <- ggit_diff_options_get_n_interhunk_lines options'
    touchManagedPtr options
    return result

#if ENABLE_OVERLOADING
data DiffOptionsGetNInterhunkLinesMethodInfo
instance (signature ~ (m Int32), MonadIO m, IsDiffOptions a) => O.MethodInfo DiffOptionsGetNInterhunkLinesMethodInfo a signature where
    overloadedMethod _ = diffOptionsGetNInterhunkLines

#endif

-- method DiffOptions::get_new_prefix
-- method type : OrdinaryMethod
-- Args : [Arg {argCName = "options", argType = TInterface (Name {namespace = "Ggit", name = "DiffOptions"}), direction = DirectionIn, mayBeNull = False, argDoc = Documentation {rawDocText = Just "a #GgitDiffOptions.", sinceVersion = Nothing}, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, argCallerAllocates = False, transfer = TransferNothing}]
-- Lengths : []
-- returnType : Just (TBasicType TUTF8)
-- throws : False
-- Skip return : False

foreign import ccall "ggit_diff_options_get_new_prefix" ggit_diff_options_get_new_prefix ::
    Ptr DiffOptions ->                      -- options : TInterface (Name {namespace = "Ggit", name = "DiffOptions"})
    IO CString

{- |
Get the diff new-prefix string.
-}
diffOptionsGetNewPrefix ::
    (B.CallStack.HasCallStack, MonadIO m, IsDiffOptions a) =>
    a
    {- ^ /@options@/: a 'GI.Ggit.Objects.DiffOptions.DiffOptions'. -}
    -> m (Maybe T.Text)
    {- ^ __Returns:__ the new-prefix string or 'Nothing'. -}
diffOptionsGetNewPrefix options = liftIO $ do
    options' <- unsafeManagedPtrCastPtr options
    result <- ggit_diff_options_get_new_prefix options'
    maybeResult <- convertIfNonNull result $ \result' -> do
        result'' <- cstringToText result'
        return result''
    touchManagedPtr options
    return maybeResult

#if ENABLE_OVERLOADING
data DiffOptionsGetNewPrefixMethodInfo
instance (signature ~ (m (Maybe T.Text)), MonadIO m, IsDiffOptions a) => O.MethodInfo DiffOptionsGetNewPrefixMethodInfo a signature where
    overloadedMethod _ = diffOptionsGetNewPrefix

#endif

-- method DiffOptions::get_old_prefix
-- method type : OrdinaryMethod
-- Args : [Arg {argCName = "options", argType = TInterface (Name {namespace = "Ggit", name = "DiffOptions"}), direction = DirectionIn, mayBeNull = False, argDoc = Documentation {rawDocText = Just "a #GgitDiffOptions.", sinceVersion = Nothing}, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, argCallerAllocates = False, transfer = TransferNothing}]
-- Lengths : []
-- returnType : Just (TBasicType TUTF8)
-- throws : False
-- Skip return : False

foreign import ccall "ggit_diff_options_get_old_prefix" ggit_diff_options_get_old_prefix ::
    Ptr DiffOptions ->                      -- options : TInterface (Name {namespace = "Ggit", name = "DiffOptions"})
    IO CString

{- |
Get the diff old-prefix string.
-}
diffOptionsGetOldPrefix ::
    (B.CallStack.HasCallStack, MonadIO m, IsDiffOptions a) =>
    a
    {- ^ /@options@/: a 'GI.Ggit.Objects.DiffOptions.DiffOptions'. -}
    -> m (Maybe T.Text)
    {- ^ __Returns:__ the old-prefix string or 'Nothing'. -}
diffOptionsGetOldPrefix options = liftIO $ do
    options' <- unsafeManagedPtrCastPtr options
    result <- ggit_diff_options_get_old_prefix options'
    maybeResult <- convertIfNonNull result $ \result' -> do
        result'' <- cstringToText result'
        freeMem result'
        return result''
    touchManagedPtr options
    return maybeResult

#if ENABLE_OVERLOADING
data DiffOptionsGetOldPrefixMethodInfo
instance (signature ~ (m (Maybe T.Text)), MonadIO m, IsDiffOptions a) => O.MethodInfo DiffOptionsGetOldPrefixMethodInfo a signature where
    overloadedMethod _ = diffOptionsGetOldPrefix

#endif

-- method DiffOptions::get_pathspec
-- method type : OrdinaryMethod
-- Args : [Arg {argCName = "options", argType = TInterface (Name {namespace = "Ggit", name = "DiffOptions"}), direction = DirectionIn, mayBeNull = False, argDoc = Documentation {rawDocText = Just "a #GgitDiffOptions.", sinceVersion = Nothing}, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, argCallerAllocates = False, transfer = TransferNothing}]
-- Lengths : []
-- returnType : Just (TCArray True (-1) (-1) (TBasicType TUTF8))
-- throws : False
-- Skip return : False

foreign import ccall "ggit_diff_options_get_pathspec" ggit_diff_options_get_pathspec ::
    Ptr DiffOptions ->                      -- options : TInterface (Name {namespace = "Ggit", name = "DiffOptions"})
    IO (Ptr CString)

{- |
Get the pathspec.
-}
diffOptionsGetPathspec ::
    (B.CallStack.HasCallStack, MonadIO m, IsDiffOptions a) =>
    a
    {- ^ /@options@/: a 'GI.Ggit.Objects.DiffOptions.DiffOptions'. -}
    -> m (Maybe [T.Text])
    {- ^ __Returns:__ the pathspec or 'Nothing'. -}
diffOptionsGetPathspec options = liftIO $ do
    options' <- unsafeManagedPtrCastPtr options
    result <- ggit_diff_options_get_pathspec options'
    maybeResult <- convertIfNonNull result $ \result' -> do
        result'' <- unpackZeroTerminatedUTF8CArray result'
        return result''
    touchManagedPtr options
    return maybeResult

#if ENABLE_OVERLOADING
data DiffOptionsGetPathspecMethodInfo
instance (signature ~ (m (Maybe [T.Text])), MonadIO m, IsDiffOptions a) => O.MethodInfo DiffOptionsGetPathspecMethodInfo a signature where
    overloadedMethod _ = diffOptionsGetPathspec

#endif

-- method DiffOptions::set_flags
-- method type : OrdinaryMethod
-- Args : [Arg {argCName = "options", argType = TInterface (Name {namespace = "Ggit", name = "DiffOptions"}), direction = DirectionIn, mayBeNull = False, argDoc = Documentation {rawDocText = Just "a #GgitDiffOptions.", sinceVersion = Nothing}, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, argCallerAllocates = False, transfer = TransferNothing},Arg {argCName = "flags", argType = TInterface (Name {namespace = "Ggit", name = "DiffOption"}), direction = DirectionIn, mayBeNull = False, argDoc = Documentation {rawDocText = Just "a #GgitDiffOption.", sinceVersion = Nothing}, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, argCallerAllocates = False, transfer = TransferNothing}]
-- Lengths : []
-- returnType : Nothing
-- throws : False
-- Skip return : False

foreign import ccall "ggit_diff_options_set_flags" ggit_diff_options_set_flags ::
    Ptr DiffOptions ->                      -- options : TInterface (Name {namespace = "Ggit", name = "DiffOptions"})
    CUInt ->                                -- flags : TInterface (Name {namespace = "Ggit", name = "DiffOption"})
    IO ()

{- |
Set the diff flags.
-}
diffOptionsSetFlags ::
    (B.CallStack.HasCallStack, MonadIO m, IsDiffOptions a) =>
    a
    {- ^ /@options@/: a 'GI.Ggit.Objects.DiffOptions.DiffOptions'. -}
    -> [Ggit.Flags.DiffOption]
    {- ^ /@flags@/: a 'GI.Ggit.Flags.DiffOption'. -}
    -> m ()
diffOptionsSetFlags options flags = liftIO $ do
    options' <- unsafeManagedPtrCastPtr options
    let flags' = gflagsToWord flags
    ggit_diff_options_set_flags options' flags'
    touchManagedPtr options
    return ()

#if ENABLE_OVERLOADING
data DiffOptionsSetFlagsMethodInfo
instance (signature ~ ([Ggit.Flags.DiffOption] -> m ()), MonadIO m, IsDiffOptions a) => O.MethodInfo DiffOptionsSetFlagsMethodInfo a signature where
    overloadedMethod _ = diffOptionsSetFlags

#endif

-- method DiffOptions::set_n_context_lines
-- method type : OrdinaryMethod
-- Args : [Arg {argCName = "options", argType = TInterface (Name {namespace = "Ggit", name = "DiffOptions"}), direction = DirectionIn, mayBeNull = False, argDoc = Documentation {rawDocText = Just "a #GgitDiffOptions.", sinceVersion = Nothing}, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, argCallerAllocates = False, transfer = TransferNothing},Arg {argCName = "n", argType = TBasicType TInt, direction = DirectionIn, mayBeNull = False, argDoc = Documentation {rawDocText = Just "the number of lines.", sinceVersion = Nothing}, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, argCallerAllocates = False, transfer = TransferNothing}]
-- Lengths : []
-- returnType : Nothing
-- throws : False
-- Skip return : False

foreign import ccall "ggit_diff_options_set_n_context_lines" ggit_diff_options_set_n_context_lines ::
    Ptr DiffOptions ->                      -- options : TInterface (Name {namespace = "Ggit", name = "DiffOptions"})
    Int32 ->                                -- n : TBasicType TInt
    IO ()

{- |
Set the number of context lines to include in the diff.
-}
diffOptionsSetNContextLines ::
    (B.CallStack.HasCallStack, MonadIO m, IsDiffOptions a) =>
    a
    {- ^ /@options@/: a 'GI.Ggit.Objects.DiffOptions.DiffOptions'. -}
    -> Int32
    {- ^ /@n@/: the number of lines. -}
    -> m ()
diffOptionsSetNContextLines options n = liftIO $ do
    options' <- unsafeManagedPtrCastPtr options
    ggit_diff_options_set_n_context_lines options' n
    touchManagedPtr options
    return ()

#if ENABLE_OVERLOADING
data DiffOptionsSetNContextLinesMethodInfo
instance (signature ~ (Int32 -> m ()), MonadIO m, IsDiffOptions a) => O.MethodInfo DiffOptionsSetNContextLinesMethodInfo a signature where
    overloadedMethod _ = diffOptionsSetNContextLines

#endif

-- method DiffOptions::set_n_interhunk_lines
-- method type : OrdinaryMethod
-- Args : [Arg {argCName = "options", argType = TInterface (Name {namespace = "Ggit", name = "DiffOptions"}), direction = DirectionIn, mayBeNull = False, argDoc = Documentation {rawDocText = Just "a #GgitDiffOptions.", sinceVersion = Nothing}, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, argCallerAllocates = False, transfer = TransferNothing},Arg {argCName = "n", argType = TBasicType TInt, direction = DirectionIn, mayBeNull = False, argDoc = Documentation {rawDocText = Just "the number of lines.", sinceVersion = Nothing}, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, argCallerAllocates = False, transfer = TransferNothing}]
-- Lengths : []
-- returnType : Nothing
-- throws : False
-- Skip return : False

foreign import ccall "ggit_diff_options_set_n_interhunk_lines" ggit_diff_options_set_n_interhunk_lines ::
    Ptr DiffOptions ->                      -- options : TInterface (Name {namespace = "Ggit", name = "DiffOptions"})
    Int32 ->                                -- n : TBasicType TInt
    IO ()

{- |
Set the number of interhunk lines to include in the diff.
-}
diffOptionsSetNInterhunkLines ::
    (B.CallStack.HasCallStack, MonadIO m, IsDiffOptions a) =>
    a
    {- ^ /@options@/: a 'GI.Ggit.Objects.DiffOptions.DiffOptions'. -}
    -> Int32
    {- ^ /@n@/: the number of lines. -}
    -> m ()
diffOptionsSetNInterhunkLines options n = liftIO $ do
    options' <- unsafeManagedPtrCastPtr options
    ggit_diff_options_set_n_interhunk_lines options' n
    touchManagedPtr options
    return ()

#if ENABLE_OVERLOADING
data DiffOptionsSetNInterhunkLinesMethodInfo
instance (signature ~ (Int32 -> m ()), MonadIO m, IsDiffOptions a) => O.MethodInfo DiffOptionsSetNInterhunkLinesMethodInfo a signature where
    overloadedMethod _ = diffOptionsSetNInterhunkLines

#endif

-- method DiffOptions::set_new_prefix
-- method type : OrdinaryMethod
-- Args : [Arg {argCName = "options", argType = TInterface (Name {namespace = "Ggit", name = "DiffOptions"}), direction = DirectionIn, mayBeNull = False, argDoc = Documentation {rawDocText = Just "a #GgitDiffOptions.", sinceVersion = Nothing}, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, argCallerAllocates = False, transfer = TransferNothing},Arg {argCName = "prefix", argType = TBasicType TUTF8, direction = DirectionIn, mayBeNull = False, argDoc = Documentation {rawDocText = Just "the prefix.", sinceVersion = Nothing}, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, argCallerAllocates = False, transfer = TransferNothing}]
-- Lengths : []
-- returnType : Nothing
-- throws : False
-- Skip return : False

foreign import ccall "ggit_diff_options_set_new_prefix" ggit_diff_options_set_new_prefix ::
    Ptr DiffOptions ->                      -- options : TInterface (Name {namespace = "Ggit", name = "DiffOptions"})
    CString ->                              -- prefix : TBasicType TUTF8
    IO ()

{- |
Set the diff new-prefix string.
-}
diffOptionsSetNewPrefix ::
    (B.CallStack.HasCallStack, MonadIO m, IsDiffOptions a) =>
    a
    {- ^ /@options@/: a 'GI.Ggit.Objects.DiffOptions.DiffOptions'. -}
    -> T.Text
    {- ^ /@prefix@/: the prefix. -}
    -> m ()
diffOptionsSetNewPrefix options prefix = liftIO $ do
    options' <- unsafeManagedPtrCastPtr options
    prefix' <- textToCString prefix
    ggit_diff_options_set_new_prefix options' prefix'
    touchManagedPtr options
    freeMem prefix'
    return ()

#if ENABLE_OVERLOADING
data DiffOptionsSetNewPrefixMethodInfo
instance (signature ~ (T.Text -> m ()), MonadIO m, IsDiffOptions a) => O.MethodInfo DiffOptionsSetNewPrefixMethodInfo a signature where
    overloadedMethod _ = diffOptionsSetNewPrefix

#endif

-- method DiffOptions::set_old_prefix
-- method type : OrdinaryMethod
-- Args : [Arg {argCName = "options", argType = TInterface (Name {namespace = "Ggit", name = "DiffOptions"}), direction = DirectionIn, mayBeNull = False, argDoc = Documentation {rawDocText = Just "a #GgitDiffOptions.", sinceVersion = Nothing}, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, argCallerAllocates = False, transfer = TransferNothing},Arg {argCName = "prefix", argType = TBasicType TUTF8, direction = DirectionIn, mayBeNull = False, argDoc = Documentation {rawDocText = Just "the prefix.", sinceVersion = Nothing}, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, argCallerAllocates = False, transfer = TransferNothing}]
-- Lengths : []
-- returnType : Nothing
-- throws : False
-- Skip return : False

foreign import ccall "ggit_diff_options_set_old_prefix" ggit_diff_options_set_old_prefix ::
    Ptr DiffOptions ->                      -- options : TInterface (Name {namespace = "Ggit", name = "DiffOptions"})
    CString ->                              -- prefix : TBasicType TUTF8
    IO ()

{- |
Get the diff old-prefix string.
-}
diffOptionsSetOldPrefix ::
    (B.CallStack.HasCallStack, MonadIO m, IsDiffOptions a) =>
    a
    {- ^ /@options@/: a 'GI.Ggit.Objects.DiffOptions.DiffOptions'. -}
    -> T.Text
    {- ^ /@prefix@/: the prefix. -}
    -> m ()
diffOptionsSetOldPrefix options prefix = liftIO $ do
    options' <- unsafeManagedPtrCastPtr options
    prefix' <- textToCString prefix
    ggit_diff_options_set_old_prefix options' prefix'
    touchManagedPtr options
    freeMem prefix'
    return ()

#if ENABLE_OVERLOADING
data DiffOptionsSetOldPrefixMethodInfo
instance (signature ~ (T.Text -> m ()), MonadIO m, IsDiffOptions a) => O.MethodInfo DiffOptionsSetOldPrefixMethodInfo a signature where
    overloadedMethod _ = diffOptionsSetOldPrefix

#endif

-- method DiffOptions::set_pathspec
-- method type : OrdinaryMethod
-- Args : [Arg {argCName = "options", argType = TInterface (Name {namespace = "Ggit", name = "DiffOptions"}), direction = DirectionIn, mayBeNull = False, argDoc = Documentation {rawDocText = Just "a #GgitDiffOptions.", sinceVersion = Nothing}, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, argCallerAllocates = False, transfer = TransferNothing},Arg {argCName = "pathspec", argType = TCArray True (-1) (-1) (TBasicType TUTF8), direction = DirectionIn, mayBeNull = True, argDoc = Documentation {rawDocText = Just "the pathspec.", sinceVersion = Nothing}, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, argCallerAllocates = False, transfer = TransferNothing}]
-- Lengths : []
-- returnType : Nothing
-- throws : False
-- Skip return : False

foreign import ccall "ggit_diff_options_set_pathspec" ggit_diff_options_set_pathspec ::
    Ptr DiffOptions ->                      -- options : TInterface (Name {namespace = "Ggit", name = "DiffOptions"})
    Ptr CString ->                          -- pathspec : TCArray True (-1) (-1) (TBasicType TUTF8)
    IO ()

{- |
Set the pathspec.
-}
diffOptionsSetPathspec ::
    (B.CallStack.HasCallStack, MonadIO m, IsDiffOptions a) =>
    a
    {- ^ /@options@/: a 'GI.Ggit.Objects.DiffOptions.DiffOptions'. -}
    -> Maybe ([T.Text])
    {- ^ /@pathspec@/: the pathspec. -}
    -> m ()
diffOptionsSetPathspec options pathspec = liftIO $ do
    options' <- unsafeManagedPtrCastPtr options
    maybePathspec <- case pathspec of
        Nothing -> return nullPtr
        Just jPathspec -> do
            jPathspec' <- packZeroTerminatedUTF8CArray jPathspec
            return jPathspec'
    ggit_diff_options_set_pathspec options' maybePathspec
    touchManagedPtr options
    mapZeroTerminatedCArray freeMem maybePathspec
    freeMem maybePathspec
    return ()

#if ENABLE_OVERLOADING
data DiffOptionsSetPathspecMethodInfo
instance (signature ~ (Maybe ([T.Text]) -> m ()), MonadIO m, IsDiffOptions a) => O.MethodInfo DiffOptionsSetPathspecMethodInfo a signature where
    overloadedMethod _ = diffOptionsSetPathspec

#endif