MCPcopy Create free account
hub / github.com/Effect-TS/tsgo / asStringAnyMap

Function asStringAnyMap

etscore/options_parser.go:412–424  ·  view source on GitHub ↗
(value any)

Source from the content-addressed store, hash-verified

410}
411
412func asStringAnyMap(value any) (func(string) (any, bool), bool) {
413 switch m := value.(type) {
414 case *collections.OrderedMap[string, any]:
415 return m.Get, true
416 case map[string]any:
417 return func(key string) (any, bool) {
418 val, exists := m[key]
419 return val, exists
420 }, true
421 default:
422 return nil, false
423 }
424}
425
426// parseDiagnosticSeverityMap converts a plugin rule configuration map to map[string]Severity.
427func parseDiagnosticSeverityMap(value any) map[string]Severity {

Callers 2

parseOverridesFunction · 0.85
parseOverrideOptionsFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected