1 | import { Environment, EnvironmentOptions, GlimmerTreeChanges, GlimmerTreeConstruction, Transaction, TransactionSymbol, RuntimeContext, RuntimeResolver, Option, RuntimeArtifacts, ComponentInstanceWithCreate, ModifierInstance } from '@glimmer/interfaces';
|
2 | import DebugRenderTree from './debug-render-tree';
|
3 | export declare const TRANSACTION: TransactionSymbol;
|
4 | declare class TransactionImpl implements Transaction {
|
5 | scheduledInstallModifiers: ModifierInstance[];
|
6 | scheduledUpdateModifiers: ModifierInstance[];
|
7 | createdComponents: ComponentInstanceWithCreate[];
|
8 | updatedComponents: ComponentInstanceWithCreate[];
|
9 | didCreate(component: ComponentInstanceWithCreate): void;
|
10 | didUpdate(component: ComponentInstanceWithCreate): void;
|
11 | scheduleInstallModifier(modifier: ModifierInstance): void;
|
12 | scheduleUpdateModifier(modifier: ModifierInstance): void;
|
13 | commit(): void;
|
14 | }
|
15 | export declare class EnvironmentImpl implements Environment {
|
16 | private delegate;
|
17 | [TRANSACTION]: Option<TransactionImpl>;
|
18 | protected appendOperations: GlimmerTreeConstruction;
|
19 | protected updateOperations?: GlimmerTreeChanges;
|
20 | isInteractive: boolean;
|
21 | debugRenderTree: DebugRenderTree<object> | undefined;
|
22 | constructor(options: EnvironmentOptions, delegate: EnvironmentDelegate);
|
23 | getAppendOperations(): GlimmerTreeConstruction;
|
24 | getDOM(): GlimmerTreeChanges;
|
25 | begin(): void;
|
26 | private get transaction();
|
27 | didCreate(component: ComponentInstanceWithCreate): void;
|
28 | didUpdate(component: ComponentInstanceWithCreate): void;
|
29 | scheduleInstallModifier(modifier: ModifierInstance): void;
|
30 | scheduleUpdateModifier(modifier: ModifierInstance): void;
|
31 | commit(): void;
|
32 | }
|
33 | export interface EnvironmentDelegate {
|
34 | |
35 |
|
36 |
|
37 |
|
38 | isInteractive: boolean;
|
39 | |
40 |
|
41 |
|
42 | enableDebugTooling: boolean;
|
43 | |
44 |
|
45 |
|
46 | onTransactionCommit: () => void;
|
47 | }
|
48 | export declare function runtimeContext(options: EnvironmentOptions, delegate: EnvironmentDelegate, artifacts: RuntimeArtifacts, resolver: RuntimeResolver): RuntimeContext;
|
49 | export declare function inTransaction(env: Environment, cb: () => void): void;
|
50 | export default EnvironmentImpl;
|
51 |
|
\ | No newline at end of file |