MCPcopy
hub / github.com/larksuite/cli / mapFlagView

Struct mapFlagView

shortcuts/sheets/flag_view.go:54–58  ·  view source on GitHub ↗

mapFlagView adapts a +batch-update sub-op input object (decoded JSON) to the flagView interface so the standalone *Input translators can consume it. Keys are matched leniently against the CLI flag name: a translator asking for "source-range" finds either "source-range" or "source_range" in the map

Source from the content-addressed store, hash-verified

52// translators branch on Changed() (e.g. omit target_index unless --index was
53// set) and others read defaulted values (e.g. row-count defaults to 200).
54type mapFlagView struct {
55 raw map[string]interface{} // user-supplied sub-op input (drives Changed)
56 defaults map[string]interface{} // flag defaults (value fallback only)
57 command string // shortcut command (e.g. "+chart-create"); used by schema validator
58}
59
60func (m mapFlagView) Command() string { return m.command }
61

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected