(str: string)
| 17 | ) { } |
| 18 | |
| 19 | static fromString(str: string): BytesType { |
| 20 | const bound = str === 'byte' ? 1 : Number.parseInt(str.substring(5), 10) || undefined; |
| 21 | return new BytesType(bound); |
| 22 | } |
| 23 | |
| 24 | toString(): string { |
| 25 | return `bytes${this.bound ?? ''}`; |