gi-ggit-1.0.14: 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.DiffLine

Description

Represents the line of a diff.

Synopsis

Exported types

newtype DiffLine Source #

Memory-managed wrapper type.

Constructors

DiffLine (ManagedPtr DiffLine) 

Instances

Instances details
Eq DiffLine Source # 
Instance details

Defined in GI.Ggit.Structs.DiffLine

GBoxed DiffLine Source # 
Instance details

Defined in GI.Ggit.Structs.DiffLine

ManagedPtrNewtype DiffLine Source # 
Instance details

Defined in GI.Ggit.Structs.DiffLine

Methods

toManagedPtr :: DiffLine -> ManagedPtr DiffLine

TypedObject DiffLine Source # 
Instance details

Defined in GI.Ggit.Structs.DiffLine

Methods

glibType :: IO GType

HasParentTypes DiffLine Source # 
Instance details

Defined in GI.Ggit.Structs.DiffLine

IsGValue (Maybe DiffLine) Source #

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

Instance details

Defined in GI.Ggit.Structs.DiffLine

Methods

gvalueGType_ :: IO GType

gvalueSet_ :: Ptr GValue -> Maybe DiffLine -> IO ()

gvalueGet_ :: Ptr GValue -> IO (Maybe DiffLine)

type ParentTypes DiffLine Source # 
Instance details

Defined in GI.Ggit.Structs.DiffLine

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

Methods

Click to display all available methods, including inherited ones

Expand

Methods

ref, unref.

Getters

getContent, getContentOffset, getNewLineno, getOldLineno, getOrigin, getText.

Setters

None.

getContent

diffLineGetContent Source #

Arguments

:: (HasCallStack, MonadIO m) 
=> DiffLine

line: a DiffLine.

-> m ByteString

Returns: the content in bytes.

Gets the content in bytes.

getContentOffset

diffLineGetContentOffset Source #

Arguments

:: (HasCallStack, MonadIO m) 
=> DiffLine

line: a DiffLine.

-> m Int64

Returns: the content offset.

Gets the content offset.

getNewLineno

diffLineGetNewLineno Source #

Arguments

:: (HasCallStack, MonadIO m) 
=> DiffLine

line: a DiffLine.

-> m Int32

Returns: the line's old number of lines.

Gets the Line number in new file or -1 for deleted line.

getOldLineno

diffLineGetOldLineno Source #

Arguments

:: (HasCallStack, MonadIO m) 
=> DiffLine

line: a DiffLine.

-> m Int32

Returns: the line's old line number.

Gets the line number in old file or -1 for added line.

getOrigin

diffLineGetOrigin Source #

Arguments

:: (HasCallStack, MonadIO m) 
=> DiffLine

line: a DiffLine.

-> m DiffLineType

Returns: the DiffLineType value.

Gets the DiffLineType value.

getText

diffLineGetText Source #

Arguments

:: (HasCallStack, MonadIO m) 
=> DiffLine

line: a DiffLine.

-> m (Maybe Text)

Returns: the content in utf-8 encoding or Nothing.

Get the content of the diff line as UTF-8 encoded text.

ref

diffLineRef Source #

Arguments

:: (HasCallStack, MonadIO m) 
=> DiffLine

line: a DiffLine.

-> m (Maybe DiffLine)

Returns: a DiffLine or Nothing.

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

unref

diffLineUnref Source #

Arguments

:: (HasCallStack, MonadIO m) 
=> DiffLine

line: a DiffLine.

-> m () 

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