hasKey static method

bool hasKey(
  1. String key
)

判断是否存在key的数据

Implementation

static bool hasKey(String key) {
  Set keys = getKeys();
  return keys.contains(key);
}