Skip to main content
Version: v1

SummaryTreeAssembler Class

Summary tree assembler (without stats collection).

Signature

export declare class SummaryTreeAssembler

Constructors

ConstructorDescription
(constructor)(props)Constructs a new instance of the SummaryTreeAssembler class

Properties

PropertyTypeDescription
summaryISummaryTreeGet final summary

Methods

MethodReturn TypeDescription
addAttachment(id)voidAdd attachment to summary
addBlob(key, content)voidAdd blob to summary
addHandle(key, handleType, handle)voidAdd handle to summary
addTree(key, summary)voidAdd tree to summary

Constructor Details

(constructor)

Constructs a new instance of the SummaryTreeAssembler class

Signature

constructor(props?: ISummaryTreeAssemblerProps | undefined);

Parameters

ParameterModifiersTypeDescription
propsoptionalISummaryTreeAssemblerProps | undefined

Property Details

summary

Get final summary

Signature

get summary(): ISummaryTree;

Type: ISummaryTree

Method Details

addAttachment

Add attachment to summary

Signature

addAttachment(id: string): void;

Parameters

ParameterTypeDescription
idstring

addBlob

Add blob to summary

Signature

addBlob(key: string, content: string | Uint8Array): void;

Parameters

ParameterTypeDescription
keystring
contentstring | Uint8Array

addHandle

Add handle to summary

Signature

addHandle(key: string, handleType: SummaryType.Tree | SummaryType.Blob | SummaryType.Attachment, handle: string): void;

Parameters

ParameterTypeDescription
keystring
handleTypeSummaryType.Tree | SummaryType.Blob | SummaryType.Attachment
handlestring

addTree

Add tree to summary

Signature

addTree(key: string, summary: ISummaryTree): void;

Parameters

ParameterTypeDescription
keystring
summaryISummaryTree