Built motion from commit 6a09e18b.|2.6.11
[motion2.git] / legacy-libs / @protobufjs / utf8 / index.d.ts
diff --git a/legacy-libs/@protobufjs/utf8/index.d.ts b/legacy-libs/@protobufjs/utf8/index.d.ts
new file mode 100644 (file)
index 0000000..010888c
--- /dev/null
@@ -0,0 +1,24 @@
+/**\r
+ * Calculates the UTF8 byte length of a string.\r
+ * @param {string} string String\r
+ * @returns {number} Byte length\r
+ */\r
+export function length(string: string): number;\r
+\r
+/**\r
+ * Reads UTF8 bytes as a string.\r
+ * @param {Uint8Array} buffer Source buffer\r
+ * @param {number} start Source start\r
+ * @param {number} end Source end\r
+ * @returns {string} String read\r
+ */\r
+export function read(buffer: Uint8Array, start: number, end: number): string;\r
+\r
+/**\r
+ * Writes a string as UTF8 bytes.\r
+ * @param {string} string Source string\r
+ * @param {Uint8Array} buffer Destination buffer\r
+ * @param {number} offset Destination offset\r
+ * @returns {number} Bytes written\r
+ */\r
+export function write(string: string, buffer: Uint8Array, offset: number): number;\r