Options
All
  • Public
  • Public/Protected
  • All
Menu

Index

Functions

decode_safe

  • decode_safe(buffer: string | Uint8Array, options?: undefined | { mode: text }): string
  • decode_safe(buffer: string | Uint8Array, options?: undefined | { mode: bytes }): Uint8Array
  • Returns a decoded [ASCII85](https://en.wikipedia.org/wiki/Ascii85 buffer into a string or Uint8Array

    NOTE: Some Adapters and Overlays can automatically handle encoding for safe storage, so make sure to not double encode

    Parameters

    • buffer: string | Uint8Array
    • Optional options: undefined | { mode: text }

    Returns string

  • Parameters

    • buffer: string | Uint8Array
    • Optional options: undefined | { mode: bytes }

    Returns Uint8Array

decode_utf8

  • decode_utf8(buffer: Uint8Array): string
  • Returns the given buffer decoded from a UTF-8 encoded Uint8Array into a string

    Parameters

    • buffer: Uint8Array

    Returns string

encode_safe

  • encode_safe(buffer: string | Uint8Array, options?: undefined | { mode: text }): string
  • encode_safe(buffer: string | Uint8Array, options?: undefined | { mode: bytes }): Uint8Array
  • Returns a [ASCII85](https://en.wikipedia.org/wiki/Ascii85 encoded string or Uint8Array from the given buffer

    NOTE: Some Adapters and Overlays can automatically handle encoding for safe storage, so make sure to not double encode

    Parameters

    • buffer: string | Uint8Array
    • Optional options: undefined | { mode: text }

    Returns string

  • Parameters

    • buffer: string | Uint8Array
    • Optional options: undefined | { mode: bytes }

    Returns Uint8Array

encode_utf8

  • encode_utf8(text: string): Uint8Array
  • Returns the given text into a UTF-8 encoded Uint8Array

    Parameters

    • text: string

    Returns Uint8Array

Legend

  • Variable
  • Function
  • Type alias
  • Type alias with type parameter
  • Interface
  • Interface with type parameter
  • Class
  • Class with type parameter
  • Enumeration

Generated using TypeDoc