Options
All
  • Public
  • Public/Protected
  • All
Menu

Interface UseMapAPI<T, U>

useMap API

  • map Map容器
  • get 获取值
  • set 设置值
  • setAll 重设Map值
  • remove 移除值
  • reset 将值还原为初始值
  • resetInit 重设初始值

Type parameters

  • T

  • U

Hierarchy

  • UseMapAPI

Index

Properties

get

get: (key: T) => undefined | U

Type declaration

    • (key: T): undefined | U
    • Parameters

      • key: T

      Returns undefined | U

map

map: Ref<Map<T, U>>

remove

remove: (key: T) => void

Type declaration

    • (key: T): void
    • Parameters

      • key: T

      Returns void

reset

reset: () => Map<T, U>

Type declaration

    • (): Map<T, U>
    • Returns Map<T, U>

resetInit

resetInit: (newMap: Iterable<readonly T[]>) => any

Type declaration

    • (newMap: Iterable<readonly T[]>): any
    • Parameters

      • newMap: Iterable<readonly T[]>

      Returns any

set

set: (key: T, val: U) => void

Type declaration

    • (key: T, val: U): void
    • Parameters

      • key: T
      • val: U

      Returns void

setAll

setAll: (newMap: Iterable<readonly T[]>) => void

Type declaration

    • (newMap: Iterable<readonly T[]>): void
    • Parameters

      • newMap: Iterable<readonly T[]>

      Returns void

Generated using TypeDoc