gi-ggit-1.0.2: libgit2-glib bindings

CopyrightWill Thompson Iñaki García Etxebarria and Jonas Platte
LicenseLGPL-2.1
MaintainerIñaki García Etxebarria (garetxe@gmail.com)
Safe HaskellNone
LanguageHaskell2010

GI.Ggit.Structs.Reflog

Contents

Description

Represents a reflog.

Synopsis

Exported types

newtype Reflog Source #

Memory-managed wrapper type.

Constructors

Reflog (ManagedPtr Reflog) 
Instances
BoxedObject Reflog Source # 
Instance details

Defined in GI.Ggit.Structs.Reflog

Methods

boxedType :: Reflog -> IO GType #

noReflog :: Maybe Reflog Source #

A convenience alias for Nothing :: Maybe Reflog.

Methods

append

reflogAppend Source #

Arguments

:: (HasCallStack, MonadIO m, IsSignature a) 
=> Reflog

reflog: a Reflog.

-> OId

oid: a OId.

-> a

committer: a Signature.

-> Text

message: the message.

-> m ()

(Can throw GError)

Creates a reflog entry.

getEntryCount

reflogGetEntryCount Source #

Arguments

:: (HasCallStack, MonadIO m) 
=> Reflog

reflog: a Reflog.

-> m Word32

Returns: the number of log entries.

Gets the number of log entries in reflog.

getEntryFromIndex

reflogGetEntryFromIndex Source #

Arguments

:: (HasCallStack, MonadIO m) 
=> Reflog

reflog: a Reflog.

-> Word32

idx: the position to lookup.

-> m (Maybe ReflogEntry)

Returns: the reflog entry at the index, or Nothing if not found.

Gets the ReflogEntry at idx in reflog, or Nothing if not found.

ref

reflogRef Source #

Arguments

:: (HasCallStack, MonadIO m) 
=> Reflog

reflog: a Reflog.

-> m (Maybe Reflog)

Returns: the passed in Reflog or Nothing.

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

rename

reflogRename Source #

Arguments

:: (HasCallStack, MonadIO m) 
=> Reflog

reflog: a Reflog.

-> Text

newName: the new name of the reference.

-> m ()

(Can throw GError)

Renames the reflog for to newName, on error error is set.

unref

reflogUnref Source #

Arguments

:: (HasCallStack, MonadIO m) 
=> Reflog

reflog: a Reflog.

-> m () 

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

write

reflogWrite Source #

Arguments

:: (HasCallStack, MonadIO m) 
=> Reflog

reflog: a Reflog.

-> m ()

(Can throw GError)

Write the reflog to disk.