GSI - Employe Self Service Mobile
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

24 lines
734 B

2 months ago
  1. /**
  2. * Calculates the UTF8 byte length of a string.
  3. * @param {string} string String
  4. * @returns {number} Byte length
  5. */
  6. export function length(string: string): number;
  7. /**
  8. * Reads UTF8 bytes as a string.
  9. * @param {Uint8Array} buffer Source buffer
  10. * @param {number} start Source start
  11. * @param {number} end Source end
  12. * @returns {string} String read
  13. */
  14. export function read(buffer: Uint8Array, start: number, end: number): string;
  15. /**
  16. * Writes a string as UTF8 bytes.
  17. * @param {string} string Source string
  18. * @param {Uint8Array} buffer Destination buffer
  19. * @param {number} offset Destination offset
  20. * @returns {number} Bytes written
  21. */
  22. export function write(string: string, buffer: Uint8Array, offset: number): number;