Gjsify LogoGjsify Logo

Index

Enumerations

Classes

Interfaces

Variables

Functions

Variables

COMMIT_GVARIANT_STRING: string
DIRMETA_GVARIANT_STRING: string
FILEMETA_GVARIANT_STRING: string
MAX_METADATA_SIZE: number

Maximum permitted size in bytes of metadata objects. This is an arbitrary number, but really, no one should be putting humongous data in metadata.

MAX_METADATA_WARN_SIZE: number

Objects committed above this size will be allowed, but a warning will be emitted.

MAX_RECURSION: number

Maximum depth of metadata.

SHA256_DIGEST_LEN: number

Length of a sha256 digest when expressed as raw bytes

SHA256_STRING_LEN: number

Length of a sha256 digest when expressed as a hexadecimal string

SUMMARY_GVARIANT_STRING: string
SUMMARY_SIG_GVARIANT_STRING: string
TIMESTAMP: number

The mtime used for stored files. This was originally 0, changed to 1 for a few releases, then was reverted due to regressions it introduced from users who had been using zero before.

TREE_GVARIANT_STRING: string
WITH_AUTOCLEANUPS: number

Functions

  • checksumB64FromBytes(csum: Uint8Array): string
  • checksumB64ToBytes(checksum: string): Uint8Array
  • checksumBytesPeekValidate(bytes: GLib.Variant): Uint8Array
  • Like ostree_checksum_bytes_peek(), but also throws error.

    Parameters

    Returns Uint8Array

  • Asynchronously compute the OSTree checksum for a given file; complete with ostree_checksum_file_async_finish().

    Parameters

    Returns void

  • Finish computing the OSTree checksum for a given file; see ostree_checksum_file_async().

    Parameters

    Returns [boolean, Uint8Array]

  • checksumFromBytes(csum: Uint8Array): string
  • checksumInplaceToBytes(checksum: string, buf: number): void
  • Convert checksum from a string to binary in-place, without allocating memory. Use this function in hot code paths.

    Parameters

    • checksum: string

      a SHA256 string

    • buf: number

      Output buffer with at least 32 bytes of space

    Returns void

  • checksumToBytes(checksum: string): Uint8Array
  • cmpChecksumBytes(a: number, b: number): number
  • Compare two binary checksums, using memcmp().

    Parameters

    • a: number

      A binary checksum

    • b: number

      A binary checksum

    Returns number

  • commitGetTimestamp(commitVariant: GLib.Variant): number
  • A thin wrapper for ostree_content_stream_parse(); this function converts an object content stream back into components.

    Parameters

    • compressed: boolean

      Whether or not the stream is zlib-compressed

    • contentPath: Gio.File

      Path to file containing content

    • trusted: boolean

      If %TRUE, assume the content has been validated

    • cancellable: Gio.Cancellable

      Cancellable

    Returns [boolean, Gio.InputStream, Gio.FileInfo, GLib.Variant]

  • A thin wrapper for ostree_content_stream_parse(); this function converts an object content stream back into components.

    Parameters

    • compressed: boolean

      Whether or not the stream is zlib-compressed

    • parentDfd: number

      Directory file descriptor

    • path: string

      Subpath

    • trusted: boolean

      If %TRUE, assume the content has been validated

    • cancellable: Gio.Cancellable

      Cancellable

    Returns [boolean, Gio.InputStream, Gio.FileInfo, GLib.Variant]

  • The reverse of ostree_raw_file_to_content_stream(); this function converts an object content stream back into components.

    Parameters

    • compressed: boolean

      Whether or not the stream is zlib-compressed

    • input: Gio.InputStream

      Object content stream

    • inputLength: number

      Length of stream

    • trusted: boolean

      If %TRUE, assume the content has been validated

    • cancellable: Gio.Cancellable

      Cancellable

    Returns [boolean, Gio.InputStream, Gio.FileInfo, GLib.Variant]

  • Compute the difference between directory a and b as 3 separate sets of #OstreeDiffItem in modified, removed, and added.

    Parameters

    Returns boolean

  • hashObjectName(a: object): number
  • Use this function with #GHashTable and ostree_object_name_serialize().

    Parameters

    • a: object

      A #GVariant containing a serialized object

    Returns number

  • Reverse ostree_object_name_serialize(). Note that out_checksum is only valid for the lifetime of variant, and must not be freed.

    Parameters

    Returns [string, OSTree.ObjectType]

  • parseRefspec(refspec: string): [boolean, string, string]
  • Split a refspec like "gnome-ostree:gnome-ostree/buildmaster" into two parts; out_remote will be set to "gnome-ostree", and out_ref will be "gnome-ostree/buildmaster".

    If refspec refers to a local ref, out_remote will be %NULL.

    Parameters

    • refspec: string

      A "refspec" string

    Returns [boolean, string, string]

  • repoCommitTraverseIterCleanup(p: object): void
  • validateChecksumString(sha256: string): boolean
  • Use this function to see if input strings are checksums.

    Parameters

    • sha256: string

      SHA256 hex string

    Returns boolean

  • validateRev(rev: string): boolean
  • validateStructureofChecksumString(checksum: string): boolean
  • validateStructureofCommit(commit: GLib.Variant): boolean
  • Use this to validate the basic structure of commit, independent of any other objects it references.

    Parameters

    • commit: GLib.Variant

      A commit object, %OSTREE_OBJECT_TYPE_COMMIT

    Returns boolean

  • validateStructureofCsumV(checksum: GLib.Variant): boolean
  • validateStructureofDirmeta(dirmeta: GLib.Variant): boolean
  • Use this to validate the basic structure of dirmeta.

    Parameters

    • dirmeta: GLib.Variant

      A dirmeta object, %OSTREE_OBJECT_TYPE_DIR_META

    Returns boolean

  • validateStructureofDirtree(dirtree: GLib.Variant): boolean
  • Use this to validate the basic structure of dirtree, independent of any other objects it references.

    Parameters

    • dirtree: GLib.Variant

      A dirtree object, %OSTREE_OBJECT_TYPE_DIR_TREE

    Returns boolean

  • validateStructureofFileMode(mode: number): boolean
  • validateStructureofObjtype(objtype: number): boolean

Legend

  • Module
  • Object literal
  • Variable
  • Function
  • Function with type parameter
  • Index signature
  • Type alias
  • Type alias with type parameter
  • Enumeration
  • Enumeration member
  • Property
  • Method
  • Interface
  • Interface with type parameter
  • Constructor
  • Property
  • Method
  • Index signature
  • Class
  • Class with type parameter
  • Constructor
  • Property
  • Method
  • Accessor
  • Index signature
  • Inherited constructor
  • Inherited property
  • Inherited method
  • Inherited accessor
  • Protected property
  • Protected method
  • Protected accessor
  • Private property
  • Private method
  • Private accessor
  • Static property
  • Static method