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.
11 lines
383 B
11 lines
383 B
10 months ago
|
import { Stream } from "./Stream";
|
||
|
/** @interface */
|
||
|
export interface Encoder {
|
||
|
/**
|
||
|
* @param {Stream} stream The stream of code points being encoded.
|
||
|
* @param {number} code_point Next code point read from the stream.
|
||
|
* @return {(number|!Array.<number>)} Byte(s) to emit, or |finished|.
|
||
|
*/
|
||
|
handler(stream: Stream, code_point: number): number | number[];
|
||
|
}
|