gi-ggit-1.0.4: GI/Ggit/Objects/CherryPickOptions.hs
{- |
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 doign a cherry-pick.
-}
#define ENABLE_OVERLOADING (MIN_VERSION_haskell_gi_overloading(1,0,0) \
&& !defined(__HADDOCK_VERSION__))
module GI.Ggit.Objects.CherryPickOptions
(
-- * Exported types
CherryPickOptions(..) ,
IsCherryPickOptions ,
toCherryPickOptions ,
noCherryPickOptions ,
-- * Methods
-- ** getCheckoutOptions #method:getCheckoutOptions#
#if ENABLE_OVERLOADING
CherryPickOptionsGetCheckoutOptionsMethodInfo,
#endif
cherryPickOptionsGetCheckoutOptions ,
-- ** getMainline #method:getMainline#
#if ENABLE_OVERLOADING
CherryPickOptionsGetMainlineMethodInfo ,
#endif
cherryPickOptionsGetMainline ,
-- ** getMergeOptions #method:getMergeOptions#
#if ENABLE_OVERLOADING
CherryPickOptionsGetMergeOptionsMethodInfo,
#endif
cherryPickOptionsGetMergeOptions ,
-- ** new #method:new#
cherryPickOptionsNew ,
-- ** setCheckoutOptions #method:setCheckoutOptions#
#if ENABLE_OVERLOADING
CherryPickOptionsSetCheckoutOptionsMethodInfo,
#endif
cherryPickOptionsSetCheckoutOptions ,
-- ** setMainline #method:setMainline#
#if ENABLE_OVERLOADING
CherryPickOptionsSetMainlineMethodInfo ,
#endif
cherryPickOptionsSetMainline ,
-- ** setMergeOptions #method:setMergeOptions#
#if ENABLE_OVERLOADING
CherryPickOptionsSetMergeOptionsMethodInfo,
#endif
cherryPickOptionsSetMergeOptions ,
-- * Properties
-- ** checkoutOptions #attr:checkoutOptions#
{- | /No description available in the introspection data./
-}
#if ENABLE_OVERLOADING
CherryPickOptionsCheckoutOptionsPropertyInfo,
#endif
#if ENABLE_OVERLOADING
cherryPickOptionsCheckoutOptions ,
#endif
clearCherryPickOptionsCheckoutOptions ,
constructCherryPickOptionsCheckoutOptions,
getCherryPickOptionsCheckoutOptions ,
setCherryPickOptionsCheckoutOptions ,
-- ** mainline #attr:mainline#
{- | /No description available in the introspection data./
-}
#if ENABLE_OVERLOADING
CherryPickOptionsMainlinePropertyInfo ,
#endif
#if ENABLE_OVERLOADING
cherryPickOptionsMainline ,
#endif
constructCherryPickOptionsMainline ,
getCherryPickOptionsMainline ,
setCherryPickOptionsMainline ,
-- ** mergeOptions #attr:mergeOptions#
{- | /No description available in the introspection data./
-}
#if ENABLE_OVERLOADING
CherryPickOptionsMergeOptionsPropertyInfo,
#endif
#if ENABLE_OVERLOADING
cherryPickOptionsMergeOptions ,
#endif
clearCherryPickOptionsMergeOptions ,
constructCherryPickOptionsMergeOptions ,
getCherryPickOptionsMergeOptions ,
setCherryPickOptionsMergeOptions ,
) 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.Objects.CheckoutOptions as Ggit.CheckoutOptions
import {-# SOURCE #-} qualified GI.Ggit.Structs.MergeOptions as Ggit.MergeOptions
-- | Memory-managed wrapper type.
newtype CherryPickOptions = CherryPickOptions (ManagedPtr CherryPickOptions)
foreign import ccall "ggit_cherry_pick_options_get_type"
c_ggit_cherry_pick_options_get_type :: IO GType
instance GObject CherryPickOptions where
gobjectType = c_ggit_cherry_pick_options_get_type
-- | Type class for types which can be safely cast to `CherryPickOptions`, for instance with `toCherryPickOptions`.
class (GObject o, O.IsDescendantOf CherryPickOptions o) => IsCherryPickOptions o
instance (GObject o, O.IsDescendantOf CherryPickOptions o) => IsCherryPickOptions o
instance O.HasParentTypes CherryPickOptions
type instance O.ParentTypes CherryPickOptions = '[GObject.Object.Object]
-- | Cast to `CherryPickOptions`, for types for which this is known to be safe. For general casts, use `Data.GI.Base.ManagedPtr.castTo`.
toCherryPickOptions :: (MonadIO m, IsCherryPickOptions o) => o -> m CherryPickOptions
toCherryPickOptions = liftIO . unsafeCastTo CherryPickOptions
-- | A convenience alias for `Nothing` :: `Maybe` `CherryPickOptions`.
noCherryPickOptions :: Maybe CherryPickOptions
noCherryPickOptions = Nothing
#if ENABLE_OVERLOADING
type family ResolveCherryPickOptionsMethod (t :: Symbol) (o :: *) :: * where
ResolveCherryPickOptionsMethod "bindProperty" o = GObject.Object.ObjectBindPropertyMethodInfo
ResolveCherryPickOptionsMethod "bindPropertyFull" o = GObject.Object.ObjectBindPropertyFullMethodInfo
ResolveCherryPickOptionsMethod "forceFloating" o = GObject.Object.ObjectForceFloatingMethodInfo
ResolveCherryPickOptionsMethod "freezeNotify" o = GObject.Object.ObjectFreezeNotifyMethodInfo
ResolveCherryPickOptionsMethod "getv" o = GObject.Object.ObjectGetvMethodInfo
ResolveCherryPickOptionsMethod "isFloating" o = GObject.Object.ObjectIsFloatingMethodInfo
ResolveCherryPickOptionsMethod "notify" o = GObject.Object.ObjectNotifyMethodInfo
ResolveCherryPickOptionsMethod "notifyByPspec" o = GObject.Object.ObjectNotifyByPspecMethodInfo
ResolveCherryPickOptionsMethod "ref" o = GObject.Object.ObjectRefMethodInfo
ResolveCherryPickOptionsMethod "refSink" o = GObject.Object.ObjectRefSinkMethodInfo
ResolveCherryPickOptionsMethod "runDispose" o = GObject.Object.ObjectRunDisposeMethodInfo
ResolveCherryPickOptionsMethod "stealData" o = GObject.Object.ObjectStealDataMethodInfo
ResolveCherryPickOptionsMethod "stealQdata" o = GObject.Object.ObjectStealQdataMethodInfo
ResolveCherryPickOptionsMethod "thawNotify" o = GObject.Object.ObjectThawNotifyMethodInfo
ResolveCherryPickOptionsMethod "unref" o = GObject.Object.ObjectUnrefMethodInfo
ResolveCherryPickOptionsMethod "watchClosure" o = GObject.Object.ObjectWatchClosureMethodInfo
ResolveCherryPickOptionsMethod "getCheckoutOptions" o = CherryPickOptionsGetCheckoutOptionsMethodInfo
ResolveCherryPickOptionsMethod "getData" o = GObject.Object.ObjectGetDataMethodInfo
ResolveCherryPickOptionsMethod "getMainline" o = CherryPickOptionsGetMainlineMethodInfo
ResolveCherryPickOptionsMethod "getMergeOptions" o = CherryPickOptionsGetMergeOptionsMethodInfo
ResolveCherryPickOptionsMethod "getProperty" o = GObject.Object.ObjectGetPropertyMethodInfo
ResolveCherryPickOptionsMethod "getQdata" o = GObject.Object.ObjectGetQdataMethodInfo
ResolveCherryPickOptionsMethod "setCheckoutOptions" o = CherryPickOptionsSetCheckoutOptionsMethodInfo
ResolveCherryPickOptionsMethod "setData" o = GObject.Object.ObjectSetDataMethodInfo
ResolveCherryPickOptionsMethod "setMainline" o = CherryPickOptionsSetMainlineMethodInfo
ResolveCherryPickOptionsMethod "setMergeOptions" o = CherryPickOptionsSetMergeOptionsMethodInfo
ResolveCherryPickOptionsMethod "setProperty" o = GObject.Object.ObjectSetPropertyMethodInfo
ResolveCherryPickOptionsMethod l o = O.MethodResolutionFailed l o
instance (info ~ ResolveCherryPickOptionsMethod t CherryPickOptions, O.MethodInfo info CherryPickOptions p) => OL.IsLabel t (CherryPickOptions -> 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 "checkout-options"
-- Type: TInterface (Name {namespace = "Ggit", name = "CheckoutOptions"})
-- Flags: [PropertyReadable,PropertyWritable]
-- Nullable: (Just False,Just True)
{- |
Get the value of the “@checkout-options@” property.
When <https://github.com/haskell-gi/haskell-gi/wiki/Overloading overloading> is enabled, this is equivalent to
@
'Data.GI.Base.Attributes.get' cherryPickOptions #checkoutOptions
@
-}
getCherryPickOptionsCheckoutOptions :: (MonadIO m, IsCherryPickOptions o) => o -> m Ggit.CheckoutOptions.CheckoutOptions
getCherryPickOptionsCheckoutOptions obj = liftIO $ checkUnexpectedNothing "getCherryPickOptionsCheckoutOptions" $ B.Properties.getObjectPropertyObject obj "checkout-options" Ggit.CheckoutOptions.CheckoutOptions
{- |
Set the value of the “@checkout-options@” property.
When <https://github.com/haskell-gi/haskell-gi/wiki/Overloading overloading> is enabled, this is equivalent to
@
'Data.GI.Base.Attributes.set' cherryPickOptions [ #checkoutOptions 'Data.GI.Base.Attributes.:=' value ]
@
-}
setCherryPickOptionsCheckoutOptions :: (MonadIO m, IsCherryPickOptions o, Ggit.CheckoutOptions.IsCheckoutOptions a) => o -> a -> m ()
setCherryPickOptionsCheckoutOptions obj val = liftIO $ B.Properties.setObjectPropertyObject obj "checkout-options" (Just val)
{- |
Construct a `GValueConstruct` with valid value for the “@checkout-options@” property. This is rarely needed directly, but it is used by `Data.GI.Base.Constructible.new`.
-}
constructCherryPickOptionsCheckoutOptions :: (IsCherryPickOptions o, Ggit.CheckoutOptions.IsCheckoutOptions a) => a -> IO (GValueConstruct o)
constructCherryPickOptionsCheckoutOptions val = B.Properties.constructObjectPropertyObject "checkout-options" (Just val)
{- |
Set the value of the “@checkout-options@” 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' #checkoutOptions
@
-}
clearCherryPickOptionsCheckoutOptions :: (MonadIO m, IsCherryPickOptions o) => o -> m ()
clearCherryPickOptionsCheckoutOptions obj = liftIO $ B.Properties.setObjectPropertyObject obj "checkout-options" (Nothing :: Maybe Ggit.CheckoutOptions.CheckoutOptions)
#if ENABLE_OVERLOADING
data CherryPickOptionsCheckoutOptionsPropertyInfo
instance AttrInfo CherryPickOptionsCheckoutOptionsPropertyInfo where
type AttrAllowedOps CherryPickOptionsCheckoutOptionsPropertyInfo = '[ 'AttrSet, 'AttrConstruct, 'AttrGet, 'AttrClear]
type AttrSetTypeConstraint CherryPickOptionsCheckoutOptionsPropertyInfo = Ggit.CheckoutOptions.IsCheckoutOptions
type AttrBaseTypeConstraint CherryPickOptionsCheckoutOptionsPropertyInfo = IsCherryPickOptions
type AttrGetType CherryPickOptionsCheckoutOptionsPropertyInfo = Ggit.CheckoutOptions.CheckoutOptions
type AttrLabel CherryPickOptionsCheckoutOptionsPropertyInfo = "checkout-options"
type AttrOrigin CherryPickOptionsCheckoutOptionsPropertyInfo = CherryPickOptions
attrGet _ = getCherryPickOptionsCheckoutOptions
attrSet _ = setCherryPickOptionsCheckoutOptions
attrConstruct _ = constructCherryPickOptionsCheckoutOptions
attrClear _ = clearCherryPickOptionsCheckoutOptions
#endif
-- VVV Prop "mainline"
-- Type: TBasicType TUInt
-- Flags: [PropertyReadable,PropertyWritable]
-- Nullable: (Just False,Just False)
{- |
Get the value of the “@mainline@” property.
When <https://github.com/haskell-gi/haskell-gi/wiki/Overloading overloading> is enabled, this is equivalent to
@
'Data.GI.Base.Attributes.get' cherryPickOptions #mainline
@
-}
getCherryPickOptionsMainline :: (MonadIO m, IsCherryPickOptions o) => o -> m Word32
getCherryPickOptionsMainline obj = liftIO $ B.Properties.getObjectPropertyUInt32 obj "mainline"
{- |
Set the value of the “@mainline@” property.
When <https://github.com/haskell-gi/haskell-gi/wiki/Overloading overloading> is enabled, this is equivalent to
@
'Data.GI.Base.Attributes.set' cherryPickOptions [ #mainline 'Data.GI.Base.Attributes.:=' value ]
@
-}
setCherryPickOptionsMainline :: (MonadIO m, IsCherryPickOptions o) => o -> Word32 -> m ()
setCherryPickOptionsMainline obj val = liftIO $ B.Properties.setObjectPropertyUInt32 obj "mainline" val
{- |
Construct a `GValueConstruct` with valid value for the “@mainline@” property. This is rarely needed directly, but it is used by `Data.GI.Base.Constructible.new`.
-}
constructCherryPickOptionsMainline :: (IsCherryPickOptions o) => Word32 -> IO (GValueConstruct o)
constructCherryPickOptionsMainline val = B.Properties.constructObjectPropertyUInt32 "mainline" val
#if ENABLE_OVERLOADING
data CherryPickOptionsMainlinePropertyInfo
instance AttrInfo CherryPickOptionsMainlinePropertyInfo where
type AttrAllowedOps CherryPickOptionsMainlinePropertyInfo = '[ 'AttrSet, 'AttrConstruct, 'AttrGet]
type AttrSetTypeConstraint CherryPickOptionsMainlinePropertyInfo = (~) Word32
type AttrBaseTypeConstraint CherryPickOptionsMainlinePropertyInfo = IsCherryPickOptions
type AttrGetType CherryPickOptionsMainlinePropertyInfo = Word32
type AttrLabel CherryPickOptionsMainlinePropertyInfo = "mainline"
type AttrOrigin CherryPickOptionsMainlinePropertyInfo = CherryPickOptions
attrGet _ = getCherryPickOptionsMainline
attrSet _ = setCherryPickOptionsMainline
attrConstruct _ = constructCherryPickOptionsMainline
attrClear _ = undefined
#endif
-- VVV Prop "merge-options"
-- Type: TInterface (Name {namespace = "Ggit", name = "MergeOptions"})
-- Flags: [PropertyReadable,PropertyWritable]
-- Nullable: (Nothing,Just True)
{- |
Get the value of the “@merge-options@” property.
When <https://github.com/haskell-gi/haskell-gi/wiki/Overloading overloading> is enabled, this is equivalent to
@
'Data.GI.Base.Attributes.get' cherryPickOptions #mergeOptions
@
-}
getCherryPickOptionsMergeOptions :: (MonadIO m, IsCherryPickOptions o) => o -> m (Maybe Ggit.MergeOptions.MergeOptions)
getCherryPickOptionsMergeOptions obj = liftIO $ B.Properties.getObjectPropertyBoxed obj "merge-options" Ggit.MergeOptions.MergeOptions
{- |
Set the value of the “@merge-options@” property.
When <https://github.com/haskell-gi/haskell-gi/wiki/Overloading overloading> is enabled, this is equivalent to
@
'Data.GI.Base.Attributes.set' cherryPickOptions [ #mergeOptions 'Data.GI.Base.Attributes.:=' value ]
@
-}
setCherryPickOptionsMergeOptions :: (MonadIO m, IsCherryPickOptions o) => o -> Ggit.MergeOptions.MergeOptions -> m ()
setCherryPickOptionsMergeOptions obj val = liftIO $ B.Properties.setObjectPropertyBoxed obj "merge-options" (Just val)
{- |
Construct a `GValueConstruct` with valid value for the “@merge-options@” property. This is rarely needed directly, but it is used by `Data.GI.Base.Constructible.new`.
-}
constructCherryPickOptionsMergeOptions :: (IsCherryPickOptions o) => Ggit.MergeOptions.MergeOptions -> IO (GValueConstruct o)
constructCherryPickOptionsMergeOptions val = B.Properties.constructObjectPropertyBoxed "merge-options" (Just val)
{- |
Set the value of the “@merge-options@” 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' #mergeOptions
@
-}
clearCherryPickOptionsMergeOptions :: (MonadIO m, IsCherryPickOptions o) => o -> m ()
clearCherryPickOptionsMergeOptions obj = liftIO $ B.Properties.setObjectPropertyBoxed obj "merge-options" (Nothing :: Maybe Ggit.MergeOptions.MergeOptions)
#if ENABLE_OVERLOADING
data CherryPickOptionsMergeOptionsPropertyInfo
instance AttrInfo CherryPickOptionsMergeOptionsPropertyInfo where
type AttrAllowedOps CherryPickOptionsMergeOptionsPropertyInfo = '[ 'AttrSet, 'AttrConstruct, 'AttrGet, 'AttrClear]
type AttrSetTypeConstraint CherryPickOptionsMergeOptionsPropertyInfo = (~) Ggit.MergeOptions.MergeOptions
type AttrBaseTypeConstraint CherryPickOptionsMergeOptionsPropertyInfo = IsCherryPickOptions
type AttrGetType CherryPickOptionsMergeOptionsPropertyInfo = (Maybe Ggit.MergeOptions.MergeOptions)
type AttrLabel CherryPickOptionsMergeOptionsPropertyInfo = "merge-options"
type AttrOrigin CherryPickOptionsMergeOptionsPropertyInfo = CherryPickOptions
attrGet _ = getCherryPickOptionsMergeOptions
attrSet _ = setCherryPickOptionsMergeOptions
attrConstruct _ = constructCherryPickOptionsMergeOptions
attrClear _ = clearCherryPickOptionsMergeOptions
#endif
#if ENABLE_OVERLOADING
instance O.HasAttributeList CherryPickOptions
type instance O.AttributeList CherryPickOptions = CherryPickOptionsAttributeList
type CherryPickOptionsAttributeList = ('[ '("checkoutOptions", CherryPickOptionsCheckoutOptionsPropertyInfo), '("mainline", CherryPickOptionsMainlinePropertyInfo), '("mergeOptions", CherryPickOptionsMergeOptionsPropertyInfo)] :: [(Symbol, *)])
#endif
#if ENABLE_OVERLOADING
cherryPickOptionsCheckoutOptions :: AttrLabelProxy "checkoutOptions"
cherryPickOptionsCheckoutOptions = AttrLabelProxy
cherryPickOptionsMainline :: AttrLabelProxy "mainline"
cherryPickOptionsMainline = AttrLabelProxy
cherryPickOptionsMergeOptions :: AttrLabelProxy "mergeOptions"
cherryPickOptionsMergeOptions = AttrLabelProxy
#endif
#if ENABLE_OVERLOADING
type instance O.SignalList CherryPickOptions = CherryPickOptionsSignalList
type CherryPickOptionsSignalList = ('[ '("notify", GObject.Object.ObjectNotifySignalInfo)] :: [(Symbol, *)])
#endif
-- method CherryPickOptions::new
-- method type : Constructor
-- Args : []
-- Lengths : []
-- returnType : Just (TInterface (Name {namespace = "Ggit", name = "CherryPickOptions"}))
-- throws : False
-- Skip return : False
foreign import ccall "ggit_cherry_pick_options_new" ggit_cherry_pick_options_new ::
IO (Ptr CherryPickOptions)
{- |
Create a new cherry-pick options object.
-}
cherryPickOptionsNew ::
(B.CallStack.HasCallStack, MonadIO m) =>
m CherryPickOptions
{- ^ __Returns:__ a 'GI.Ggit.Objects.CherryPickOptions.CherryPickOptions'. -}
cherryPickOptionsNew = liftIO $ do
result <- ggit_cherry_pick_options_new
checkUnexpectedReturnNULL "cherryPickOptionsNew" result
result' <- (wrapObject CherryPickOptions) result
return result'
#if ENABLE_OVERLOADING
#endif
-- method CherryPickOptions::get_checkout_options
-- method type : OrdinaryMethod
-- Args : [Arg {argCName = "options", argType = TInterface (Name {namespace = "Ggit", name = "CherryPickOptions"}), direction = DirectionIn, mayBeNull = False, argDoc = Documentation {rawDocText = Just "a #GgitCherryPickOptions.", sinceVersion = Nothing}, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, argCallerAllocates = False, transfer = TransferNothing}]
-- Lengths : []
-- returnType : Just (TInterface (Name {namespace = "Ggit", name = "CheckoutOptions"}))
-- throws : False
-- Skip return : False
foreign import ccall "ggit_cherry_pick_options_get_checkout_options" ggit_cherry_pick_options_get_checkout_options ::
Ptr CherryPickOptions -> -- options : TInterface (Name {namespace = "Ggit", name = "CherryPickOptions"})
IO (Ptr Ggit.CheckoutOptions.CheckoutOptions)
{- |
Get the checkout options.
-}
cherryPickOptionsGetCheckoutOptions ::
(B.CallStack.HasCallStack, MonadIO m, IsCherryPickOptions a) =>
a
{- ^ /@options@/: a 'GI.Ggit.Objects.CherryPickOptions.CherryPickOptions'. -}
-> m Ggit.CheckoutOptions.CheckoutOptions
{- ^ __Returns:__ a 'GI.Ggit.Objects.CheckoutOptions.CheckoutOptions'. -}
cherryPickOptionsGetCheckoutOptions options = liftIO $ do
options' <- unsafeManagedPtrCastPtr options
result <- ggit_cherry_pick_options_get_checkout_options options'
checkUnexpectedReturnNULL "cherryPickOptionsGetCheckoutOptions" result
result' <- (newObject Ggit.CheckoutOptions.CheckoutOptions) result
touchManagedPtr options
return result'
#if ENABLE_OVERLOADING
data CherryPickOptionsGetCheckoutOptionsMethodInfo
instance (signature ~ (m Ggit.CheckoutOptions.CheckoutOptions), MonadIO m, IsCherryPickOptions a) => O.MethodInfo CherryPickOptionsGetCheckoutOptionsMethodInfo a signature where
overloadedMethod _ = cherryPickOptionsGetCheckoutOptions
#endif
-- method CherryPickOptions::get_mainline
-- method type : OrdinaryMethod
-- Args : [Arg {argCName = "options", argType = TInterface (Name {namespace = "Ggit", name = "CherryPickOptions"}), direction = DirectionIn, mayBeNull = False, argDoc = Documentation {rawDocText = Just "a #GgitCherryPickOptions.", sinceVersion = Nothing}, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, argCallerAllocates = False, transfer = TransferNothing}]
-- Lengths : []
-- returnType : Just (TBasicType TUInt)
-- throws : False
-- Skip return : False
foreign import ccall "ggit_cherry_pick_options_get_mainline" ggit_cherry_pick_options_get_mainline ::
Ptr CherryPickOptions -> -- options : TInterface (Name {namespace = "Ggit", name = "CherryPickOptions"})
IO Word32
{- |
Get the mainline parent to use when cherry-picking a merge commit.
-}
cherryPickOptionsGetMainline ::
(B.CallStack.HasCallStack, MonadIO m, IsCherryPickOptions a) =>
a
{- ^ /@options@/: a 'GI.Ggit.Objects.CherryPickOptions.CherryPickOptions'. -}
-> m Word32
{- ^ __Returns:__ the mainline parent. -}
cherryPickOptionsGetMainline options = liftIO $ do
options' <- unsafeManagedPtrCastPtr options
result <- ggit_cherry_pick_options_get_mainline options'
touchManagedPtr options
return result
#if ENABLE_OVERLOADING
data CherryPickOptionsGetMainlineMethodInfo
instance (signature ~ (m Word32), MonadIO m, IsCherryPickOptions a) => O.MethodInfo CherryPickOptionsGetMainlineMethodInfo a signature where
overloadedMethod _ = cherryPickOptionsGetMainline
#endif
-- method CherryPickOptions::get_merge_options
-- method type : OrdinaryMethod
-- Args : [Arg {argCName = "options", argType = TInterface (Name {namespace = "Ggit", name = "CherryPickOptions"}), direction = DirectionIn, mayBeNull = False, argDoc = Documentation {rawDocText = Just "a #GgitCherryPickOptions.", sinceVersion = Nothing}, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, argCallerAllocates = False, transfer = TransferNothing}]
-- Lengths : []
-- returnType : Just (TInterface (Name {namespace = "Ggit", name = "MergeOptions"}))
-- throws : False
-- Skip return : False
foreign import ccall "ggit_cherry_pick_options_get_merge_options" ggit_cherry_pick_options_get_merge_options ::
Ptr CherryPickOptions -> -- options : TInterface (Name {namespace = "Ggit", name = "CherryPickOptions"})
IO (Ptr Ggit.MergeOptions.MergeOptions)
{- |
Get the merge options.
-}
cherryPickOptionsGetMergeOptions ::
(B.CallStack.HasCallStack, MonadIO m, IsCherryPickOptions a) =>
a
{- ^ /@options@/: a 'GI.Ggit.Objects.CherryPickOptions.CherryPickOptions'. -}
-> m Ggit.MergeOptions.MergeOptions
{- ^ __Returns:__ a 'GI.Ggit.Structs.MergeOptions.MergeOptions'. -}
cherryPickOptionsGetMergeOptions options = liftIO $ do
options' <- unsafeManagedPtrCastPtr options
result <- ggit_cherry_pick_options_get_merge_options options'
checkUnexpectedReturnNULL "cherryPickOptionsGetMergeOptions" result
result' <- (wrapBoxed Ggit.MergeOptions.MergeOptions) result
touchManagedPtr options
return result'
#if ENABLE_OVERLOADING
data CherryPickOptionsGetMergeOptionsMethodInfo
instance (signature ~ (m Ggit.MergeOptions.MergeOptions), MonadIO m, IsCherryPickOptions a) => O.MethodInfo CherryPickOptionsGetMergeOptionsMethodInfo a signature where
overloadedMethod _ = cherryPickOptionsGetMergeOptions
#endif
-- method CherryPickOptions::set_checkout_options
-- method type : OrdinaryMethod
-- Args : [Arg {argCName = "options", argType = TInterface (Name {namespace = "Ggit", name = "CherryPickOptions"}), direction = DirectionIn, mayBeNull = False, argDoc = Documentation {rawDocText = Just "a #GgitCherryPickOptions.", sinceVersion = Nothing}, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, argCallerAllocates = False, transfer = TransferNothing},Arg {argCName = "checkout_options", argType = TInterface (Name {namespace = "Ggit", name = "CheckoutOptions"}), direction = DirectionIn, mayBeNull = True, argDoc = Documentation {rawDocText = Just "a #GgitCheckoutOptions.", sinceVersion = Nothing}, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, argCallerAllocates = False, transfer = TransferNothing}]
-- Lengths : []
-- returnType : Nothing
-- throws : False
-- Skip return : False
foreign import ccall "ggit_cherry_pick_options_set_checkout_options" ggit_cherry_pick_options_set_checkout_options ::
Ptr CherryPickOptions -> -- options : TInterface (Name {namespace = "Ggit", name = "CherryPickOptions"})
Ptr Ggit.CheckoutOptions.CheckoutOptions -> -- checkout_options : TInterface (Name {namespace = "Ggit", name = "CheckoutOptions"})
IO ()
{- |
Set the checkout options.
-}
cherryPickOptionsSetCheckoutOptions ::
(B.CallStack.HasCallStack, MonadIO m, IsCherryPickOptions a, Ggit.CheckoutOptions.IsCheckoutOptions b) =>
a
{- ^ /@options@/: a 'GI.Ggit.Objects.CherryPickOptions.CherryPickOptions'. -}
-> Maybe (b)
{- ^ /@checkoutOptions@/: a 'GI.Ggit.Objects.CheckoutOptions.CheckoutOptions'. -}
-> m ()
cherryPickOptionsSetCheckoutOptions options checkoutOptions = liftIO $ do
options' <- unsafeManagedPtrCastPtr options
maybeCheckoutOptions <- case checkoutOptions of
Nothing -> return nullPtr
Just jCheckoutOptions -> do
jCheckoutOptions' <- unsafeManagedPtrCastPtr jCheckoutOptions
return jCheckoutOptions'
ggit_cherry_pick_options_set_checkout_options options' maybeCheckoutOptions
touchManagedPtr options
whenJust checkoutOptions touchManagedPtr
return ()
#if ENABLE_OVERLOADING
data CherryPickOptionsSetCheckoutOptionsMethodInfo
instance (signature ~ (Maybe (b) -> m ()), MonadIO m, IsCherryPickOptions a, Ggit.CheckoutOptions.IsCheckoutOptions b) => O.MethodInfo CherryPickOptionsSetCheckoutOptionsMethodInfo a signature where
overloadedMethod _ = cherryPickOptionsSetCheckoutOptions
#endif
-- method CherryPickOptions::set_mainline
-- method type : OrdinaryMethod
-- Args : [Arg {argCName = "options", argType = TInterface (Name {namespace = "Ggit", name = "CherryPickOptions"}), direction = DirectionIn, mayBeNull = False, argDoc = Documentation {rawDocText = Just "a #GgitCherryPickOptions.", sinceVersion = Nothing}, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, argCallerAllocates = False, transfer = TransferNothing},Arg {argCName = "mainline", argType = TBasicType TUInt, direction = DirectionIn, mayBeNull = False, argDoc = Documentation {rawDocText = Just "the mainline parent.", sinceVersion = Nothing}, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, argCallerAllocates = False, transfer = TransferNothing}]
-- Lengths : []
-- returnType : Nothing
-- throws : False
-- Skip return : False
foreign import ccall "ggit_cherry_pick_options_set_mainline" ggit_cherry_pick_options_set_mainline ::
Ptr CherryPickOptions -> -- options : TInterface (Name {namespace = "Ggit", name = "CherryPickOptions"})
Word32 -> -- mainline : TBasicType TUInt
IO ()
{- |
Set the mainline parent to use when cherry-picking a merge commit.
-}
cherryPickOptionsSetMainline ::
(B.CallStack.HasCallStack, MonadIO m, IsCherryPickOptions a) =>
a
{- ^ /@options@/: a 'GI.Ggit.Objects.CherryPickOptions.CherryPickOptions'. -}
-> Word32
{- ^ /@mainline@/: the mainline parent. -}
-> m ()
cherryPickOptionsSetMainline options mainline = liftIO $ do
options' <- unsafeManagedPtrCastPtr options
ggit_cherry_pick_options_set_mainline options' mainline
touchManagedPtr options
return ()
#if ENABLE_OVERLOADING
data CherryPickOptionsSetMainlineMethodInfo
instance (signature ~ (Word32 -> m ()), MonadIO m, IsCherryPickOptions a) => O.MethodInfo CherryPickOptionsSetMainlineMethodInfo a signature where
overloadedMethod _ = cherryPickOptionsSetMainline
#endif
-- method CherryPickOptions::set_merge_options
-- method type : OrdinaryMethod
-- Args : [Arg {argCName = "options", argType = TInterface (Name {namespace = "Ggit", name = "CherryPickOptions"}), direction = DirectionIn, mayBeNull = False, argDoc = Documentation {rawDocText = Just "a #GgitCherryPickOptions.", sinceVersion = Nothing}, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, argCallerAllocates = False, transfer = TransferNothing},Arg {argCName = "merge_options", argType = TInterface (Name {namespace = "Ggit", name = "MergeOptions"}), direction = DirectionIn, mayBeNull = True, argDoc = Documentation {rawDocText = Just "a #GgitMergeOptions.", sinceVersion = Nothing}, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, argCallerAllocates = False, transfer = TransferNothing}]
-- Lengths : []
-- returnType : Nothing
-- throws : False
-- Skip return : False
foreign import ccall "ggit_cherry_pick_options_set_merge_options" ggit_cherry_pick_options_set_merge_options ::
Ptr CherryPickOptions -> -- options : TInterface (Name {namespace = "Ggit", name = "CherryPickOptions"})
Ptr Ggit.MergeOptions.MergeOptions -> -- merge_options : TInterface (Name {namespace = "Ggit", name = "MergeOptions"})
IO ()
{- |
Set the merge options.
-}
cherryPickOptionsSetMergeOptions ::
(B.CallStack.HasCallStack, MonadIO m, IsCherryPickOptions a) =>
a
{- ^ /@options@/: a 'GI.Ggit.Objects.CherryPickOptions.CherryPickOptions'. -}
-> Maybe (Ggit.MergeOptions.MergeOptions)
{- ^ /@mergeOptions@/: a 'GI.Ggit.Structs.MergeOptions.MergeOptions'. -}
-> m ()
cherryPickOptionsSetMergeOptions options mergeOptions = liftIO $ do
options' <- unsafeManagedPtrCastPtr options
maybeMergeOptions <- case mergeOptions of
Nothing -> return nullPtr
Just jMergeOptions -> do
jMergeOptions' <- unsafeManagedPtrGetPtr jMergeOptions
return jMergeOptions'
ggit_cherry_pick_options_set_merge_options options' maybeMergeOptions
touchManagedPtr options
whenJust mergeOptions touchManagedPtr
return ()
#if ENABLE_OVERLOADING
data CherryPickOptionsSetMergeOptionsMethodInfo
instance (signature ~ (Maybe (Ggit.MergeOptions.MergeOptions) -> m ()), MonadIO m, IsCherryPickOptions a) => O.MethodInfo CherryPickOptionsSetMergeOptionsMethodInfo a signature where
overloadedMethod _ = cherryPickOptionsSetMergeOptions
#endif