declare type _Digit = 0 | 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9; declare type UppercaseLetter = "A" | "B" | "C" | "D" | "E" | "F" | "G" | "H" | "I" | "J" | "K" | "L" | "M" | "N" | "O" | "P" | "Q" | "R" | "S" | "T" | "U" | "V" | "W" | "X" | "Y" | "Z"; declare type LowercaseLetter = Lowercase; /** Alphabet letter. */ export declare type Alpha = UppercaseLetter | LowercaseLetter; /** Digit letter. */ export declare type Digit = `${_Digit}`; /** [tchar](https://www.rfc-editor.org/rfc/rfc9110.html#section-5.6.2-2) letter. */ export declare type Tchar = "!" | "#" | "$" | "%" | "&" | "'" | "*" | "+" | "-" | "." | "^" | "_" | "`" | "|" | "~" | Digit | Alpha; /** Representation of [token](https://www.rfc-editor.org/rfc/rfc9110.html#section-5.6.2-2). */ export declare type Token = `${Tchar}${string}`; /** Whether the input is [token](https://www.rfc-editor.org/rfc/rfc9110.html#section-5.6.2-2) or not. * * @example * ```ts * import { isToken } from "https://deno.land/x/http_utils@$VERSION/token.ts"; * import { * assert, * assertFalse, * } from "https://deno.land/std@$VERSION/testing/asserts.ts"; * * assert(isToken("token")); * assert(isToken("*!~")); * assertFalse(isToken("")); * ``` */ export declare function isToken(input: string): input is Token; /** Whether the input is [tchar](https://www.rfc-editor.org/rfc/rfc9110.html#section-5.6.2-2) or not. * * @example * ```ts * import { isTchar } from "https://deno.land/x/http_utils@$VERSION/token.ts"; * import { * assert, * assertFalse, * } from "https://deno.land/std@$VERSION/testing/asserts.ts"; * * assert(isTchar("!")); * assert(isTchar("a")); * assert(isTchar("Z")); * assertFalse(isTchar("")); * ``` */ export declare function isTchar(input: string): input is Tchar; export {};