Skip to main content
Module

x/datastructure/blockChain/helper.d.ts

Implement different Data Structures using TypeScript. Deno Third-party Module.
Latest
File

export type DataType<T> = { key: string value: T}
// BlockChain type of each blockexport type BlockType = { index: number data: DataType<any> time: Date hash: string prevHash: null|string}
// Block chain interfaceexport interface BlockChainApi { length: number createBlock(data: DataType<any>): boolean search(key: null|string, index: null|number): boolean|BlockType latestBlock(): boolean|BlockType log(key: null|string, index: null|number): void; iterator(): Generator checkValidation(): boolean}