Function

AppStream-1.0AppStreamgstring_replace

  • Replaces the string find with the string replace in a GLib.String up to limit times. If the number of instances of find in the GLib.String is less than limit, all instances are replaced. If limit is 0, all instances of find are replaced.

    Parameters

    • string: GLib.String
    • find: string

      the string to find in string

    • replace: string

      the string to insert in place of find

    • limit: number

      the maximum instances of find to replace with replace, or 0 for no limit

    Returns number

    the number of find and replace operations performed.