Adrià Vilanova Martínez | 43c7520 | 2024-10-19 15:55:15 +0200 | [diff] [blame] | 1 | import { NodeMutation, NodeWatcherHandler } from "../../../../../presentation/nodeWatcher/NodeWatcherHandler"; |
Adrià Vilanova Martínez | 18d03c4 | 2024-04-21 16:43:01 +0200 | [diff] [blame] | 2 | |
| 3 | export abstract class NodeWatcherScriptHandler<Options> |
| 4 | implements NodeWatcherHandler |
| 5 | { |
| 6 | abstract initialDiscoverySelector?: string; |
| 7 | constructor(protected options: Options) {} |
| 8 | abstract nodeFilter(nodeMutation: NodeMutation): boolean; |
| 9 | abstract onMutatedNode(nodeMutation: NodeMutation): void; |
| 10 | } |
| 11 | |
| 12 | export type ConcreteNodeWatcherScriptHandler<Options> = { |
| 13 | new (options: Options): NodeWatcherScriptHandler<Options>; |
| 14 | }; |