Skip to content

BlockSuite API Documentation / @blocksuite/store / ASTWalker

Class: ASTWalker<ONode, TNode>

Type Parameters

ONode extends object

TNode extends object | never

Constructors

new ASTWalker()

new ASTWalker<ONode, TNode>(): ASTWalker<ONode, TNode>

Returns

ASTWalker<ONode, TNode>

Defined in

packages/framework/store/src/adapter/base.ts:291

Methods

setEnter()

setEnter(fn): void

Parameters

fn: WalkerFn<ONode, TNode>

Returns

void

Defined in

packages/framework/store/src/adapter/base.ts:268


setLeave()

setLeave(fn): void

Parameters

fn: WalkerFn<ONode, TNode>

Returns

void

Defined in

packages/framework/store/src/adapter/base.ts:272


setONodeTypeGuard()

setONodeTypeGuard(fn): void

Parameters

fn

Returns

void

Defined in

packages/framework/store/src/adapter/base.ts:276


walk()

walk(oNode, tNode): Promise<TNode>

Parameters

oNode: ONode

tNode: TNode

Returns

Promise<TNode>

Defined in

packages/framework/store/src/adapter/base.ts:280


walkONode()

walkONode(oNode): Promise<void>

Parameters

oNode: ONode

Returns

Promise<void>

Defined in

packages/framework/store/src/adapter/base.ts:287