Copyright | Will Thompson Iñaki García Etxebarria and Jonas Platte |
---|---|
License | LGPL-2.1 |
Maintainer | Iñaki García Etxebarria |
Safe Haskell | None |
Language | Haskell2010 |
No description available in the introspection data.
Synopsis
- newtype GpgVerifyResult = GpgVerifyResult (ManagedPtr GpgVerifyResult)
- class (GObject o, IsDescendantOf GpgVerifyResult o) => IsGpgVerifyResult o
- toGpgVerifyResult :: (MonadIO m, IsGpgVerifyResult o) => o -> m GpgVerifyResult
- gpgVerifyResultCountAll :: (HasCallStack, MonadIO m, IsGpgVerifyResult a) => a -> m Word32
- gpgVerifyResultCountValid :: (HasCallStack, MonadIO m, IsGpgVerifyResult a) => a -> m Word32
- gpgVerifyResultDescribe :: (HasCallStack, MonadIO m, IsGpgVerifyResult a) => a -> Word32 -> String -> Maybe Text -> GpgSignatureFormatFlags -> m ()
- gpgVerifyResultDescribeVariant :: (HasCallStack, MonadIO m) => GVariant -> String -> Maybe Text -> GpgSignatureFormatFlags -> m ()
- gpgVerifyResultGet :: (HasCallStack, MonadIO m, IsGpgVerifyResult a) => a -> Word32 -> [GpgSignatureAttr] -> m GVariant
- gpgVerifyResultGetAll :: (HasCallStack, MonadIO m, IsGpgVerifyResult a) => a -> Word32 -> m GVariant
- gpgVerifyResultLookup :: (HasCallStack, MonadIO m, IsGpgVerifyResult a) => a -> Text -> m (Bool, Word32)
- gpgVerifyResultRequireValidSignature :: (HasCallStack, MonadIO m, IsGpgVerifyResult a) => a -> m ()
Exported types
newtype GpgVerifyResult Source #
Memory-managed wrapper type.
GpgVerifyResult (ManagedPtr GpgVerifyResult) |
Instances
Eq GpgVerifyResult Source # | |
Defined in GI.OSTree.Objects.GpgVerifyResult (==) :: GpgVerifyResult -> GpgVerifyResult -> Bool (/=) :: GpgVerifyResult -> GpgVerifyResult -> Bool | |
GObject GpgVerifyResult Source # | |
Defined in GI.OSTree.Objects.GpgVerifyResult | |
ManagedPtrNewtype GpgVerifyResult Source # | |
Defined in GI.OSTree.Objects.GpgVerifyResult toManagedPtr :: GpgVerifyResult -> ManagedPtr GpgVerifyResult | |
TypedObject GpgVerifyResult Source # | |
Defined in GI.OSTree.Objects.GpgVerifyResult glibType :: IO GType | |
IsGValue GpgVerifyResult Source # | Convert |
Defined in GI.OSTree.Objects.GpgVerifyResult toGValue :: GpgVerifyResult -> IO GValue fromGValue :: GValue -> IO GpgVerifyResult | |
HasParentTypes GpgVerifyResult Source # | |
Defined in GI.OSTree.Objects.GpgVerifyResult | |
type ParentTypes GpgVerifyResult Source # | |
Defined in GI.OSTree.Objects.GpgVerifyResult type ParentTypes GpgVerifyResult = '[Object, Initable] |
class (GObject o, IsDescendantOf GpgVerifyResult o) => IsGpgVerifyResult o Source #
Type class for types which can be safely cast to GpgVerifyResult
, for instance with toGpgVerifyResult
.
Instances
(GObject o, IsDescendantOf GpgVerifyResult o) => IsGpgVerifyResult o Source # | |
Defined in GI.OSTree.Objects.GpgVerifyResult |
toGpgVerifyResult :: (MonadIO m, IsGpgVerifyResult o) => o -> m GpgVerifyResult Source #
Cast to GpgVerifyResult
, for types for which this is known to be safe. For general casts, use castTo
.
Methods
Overloaded methods
countAll
gpgVerifyResultCountAll Source #
:: (HasCallStack, MonadIO m, IsGpgVerifyResult a) | |
=> a |
|
-> m Word32 | Returns: signature count |
Counts all the signatures in result
.
countValid
gpgVerifyResultCountValid Source #
:: (HasCallStack, MonadIO m, IsGpgVerifyResult a) | |
=> a |
|
-> m Word32 | Returns: valid signature count |
Counts only the valid signatures in result
.
describe
gpgVerifyResultDescribe Source #
:: (HasCallStack, MonadIO m, IsGpgVerifyResult a) | |
=> a |
|
-> Word32 |
|
-> String |
|
-> Maybe Text |
|
-> GpgSignatureFormatFlags |
|
-> m () |
Appends a brief, human-readable description of the GPG signature at
signatureIndex
in result
to the outputBuffer
. The description
spans multiple lines. A linePrefix
string, if given, will precede
each line of the description.
The flags
argument is reserved for future variations to the description
format. Currently must be 0.
It is a programmer error to request an invalid signatureIndex
. Use
gpgVerifyResultCountAll
to find the number of signatures in
result
.
describeVariant
gpgVerifyResultDescribeVariant Source #
:: (HasCallStack, MonadIO m) | |
=> GVariant |
|
-> String |
|
-> Maybe Text |
|
-> GpgSignatureFormatFlags |
|
-> m () |
Similar to gpgVerifyResultDescribe
but takes a GVariant
of
all attributes for a GPG signature instead of an GpgVerifyResult
and signature index.
The variant
<emphasis>MUST</emphasis> have been created by
gpgVerifyResultGetAll
.
get
:: (HasCallStack, MonadIO m, IsGpgVerifyResult a) | |
=> a |
|
-> Word32 |
|
-> [GpgSignatureAttr] |
|
-> m GVariant | Returns: a new, floating, |
Builds a GVariant
tuple of requested attributes for the GPG signature at
signatureIndex
in result
. See the GpgSignatureAttr
description
for the VariantType
of each available attribute.
It is a programmer error to request an invalid GpgSignatureAttr
or
an invalid signatureIndex
. Use gpgVerifyResultCountAll
to
find the number of signatures in result
.
getAll
gpgVerifyResultGetAll Source #
:: (HasCallStack, MonadIO m, IsGpgVerifyResult a) | |
=> a |
|
-> Word32 |
|
-> m GVariant | Returns: a new, floating, |
Builds a GVariant
tuple of all available attributes for the GPG signature
at signatureIndex
in result
.
The child values in the returned GVariant
tuple are ordered to match the
GpgSignatureAttr
enumeration, which means the enum values can be
used as index values in functions like g_variant_get_child()
. See the
GpgSignatureAttr
description for the VariantType
of each
available attribute.
<note>
<para>
The GpgSignatureAttr
enumeration may be extended in the future
with new attributes, which would affect the GVariant
tuple returned by
this function. While the position and type of current child values in
the GVariant
tuple will not change, to avoid backward-compatibility
issues <emphasis>please do not depend on the tuple's overall size or
type signature</emphasis>.
</para>
</note>
It is a programmer error to request an invalid signatureIndex
. Use
gpgVerifyResultCountAll
to find the number of signatures in
result
.
lookup
gpgVerifyResultLookup Source #
:: (HasCallStack, MonadIO m, IsGpgVerifyResult a) | |
=> a |
|
-> Text |
|
-> m (Bool, Word32) | Returns: |
Searches result
for a signature signed by keyId
. If a match is found,
the function returns True
and sets outSignatureIndex
so that further
signature details can be obtained through gpgVerifyResultGet
.
If no match is found, the function returns False
and leaves
outSignatureIndex
unchanged.
requireValidSignature
gpgVerifyResultRequireValidSignature Source #
:: (HasCallStack, MonadIO m, IsGpgVerifyResult a) | |
=> a |
|
-> m () | (Can throw |
Checks if the result contains at least one signature from the
trusted keyring. You can call this function immediately after
repoVerifySummary
or repoVerifyCommitExt
-
it will handle the Nothing
result
and filled error
too.
Since: 2016.6