gi-ggit-1.0.11: libgit2-glib bindings
CopyrightWill Thompson and Iñaki García Etxebarria
LicenseLGPL-2.1
MaintainerIñaki García Etxebarria
Safe HaskellSafe-Inferred
LanguageHaskell2010

GI.Ggit.Structs.DiffHunk

Description

Represents the hunk of a diff.

Synopsis

Exported types

newtype DiffHunk Source #

Memory-managed wrapper type.

Constructors

DiffHunk (ManagedPtr DiffHunk) 

Instances

Instances details
Eq DiffHunk Source # 
Instance details

Defined in GI.Ggit.Structs.DiffHunk

GBoxed DiffHunk Source # 
Instance details

Defined in GI.Ggit.Structs.DiffHunk

ManagedPtrNewtype DiffHunk Source # 
Instance details

Defined in GI.Ggit.Structs.DiffHunk

TypedObject DiffHunk Source # 
Instance details

Defined in GI.Ggit.Structs.DiffHunk

Methods

glibType :: IO GType #

HasParentTypes DiffHunk Source # 
Instance details

Defined in GI.Ggit.Structs.DiffHunk

IsGValue (Maybe DiffHunk) Source #

Convert DiffHunk to and from GValue. See toGValue and fromGValue.

Instance details

Defined in GI.Ggit.Structs.DiffHunk

type ParentTypes DiffHunk Source # 
Instance details

Defined in GI.Ggit.Structs.DiffHunk

type ParentTypes DiffHunk = '[] :: [Type]

Methods

Click to display all available methods, including inherited ones

Expand

Methods

ref, unref.

Getters

getHeader, getNewLines, getNewStart, getOldLines, getOldStart.

Setters

None.

getHeader

diffHunkGetHeader :: (HasCallStack, MonadIO m) => DiffHunk -> m Text Source #

No description available in the introspection data.

getNewLines

diffHunkGetNewLines Source #

Arguments

:: (HasCallStack, MonadIO m) 
=> DiffHunk

hunk: a DiffHunk.

-> m Int32

Returns: the number of lines in the new file.

Gets the number of lines in the new file.

getNewStart

diffHunkGetNewStart Source #

Arguments

:: (HasCallStack, MonadIO m) 
=> DiffHunk

hunk: a DiffHunk.

-> m Int32

Returns: the starting line number in the new file.

Gets the starting line number in the new file.

getOldLines

diffHunkGetOldLines Source #

Arguments

:: (HasCallStack, MonadIO m) 
=> DiffHunk

hunk: a DiffHunk.

-> m Int32

Returns: the number of lines in the old file.

Gets the number of lines in the old file.

getOldStart

diffHunkGetOldStart Source #

Arguments

:: (HasCallStack, MonadIO m) 
=> DiffHunk

hunk: a DiffHunk.

-> m Int32

Returns: the starting line number in the old file.

Gets the starting line number in the old file.

ref

diffHunkRef Source #

Arguments

:: (HasCallStack, MonadIO m) 
=> DiffHunk

hunk: a DiffHunk.

-> m (Maybe DiffHunk)

Returns: a DiffHunk or Nothing.

Atomically increments the reference count of hunk by one. This function is MT-safe and may be called from any thread.

unref

diffHunkUnref Source #

Arguments

:: (HasCallStack, MonadIO m) 
=> DiffHunk

hunk: a DiffHunk.

-> m () 

Atomically decrements the reference count of hunk by one. If the reference count drops to 0, hunk is freed.