| 12 | } |
| 13 | |
| 14 | class NullFrame implements IFrame { |
| 15 | public prev: IFrame | null = null |
| 16 | constructor( |
| 17 | public readonly startTime: number = 0, |
| 18 | public readonly endTime: number = 0 |
| 19 | ) { } |
| 20 | duration(): number { return this.endTime - this.startTime } |
| 21 | data(endTime: number, startTime?: number): string { return '' } |
| 22 | snapshot(): string { |
| 23 | if (this.prev) { |
| 24 | return this.prev.snapshot() |
| 25 | } |
| 26 | return '' |
| 27 | } |
| 28 | } |
| 29 | |
| 30 | export type FrameSnapshotFn = (s: string) => string |
| 31 | export const DEFAULT_FRAME_SNAPSHOT_FN = (s: string) => s |
nothing calls this directly
no outgoing calls
no test coverage detected