MCPcopy
hub / github.com/grafana/k6 / Get

Function Get

ext/ext.go:87–101  ·  view source on GitHub ↗

Get returns all extensions of the specified type.

(typ ExtensionType)

Source from the content-addressed store, hash-verified

85
86// Get returns all extensions of the specified type.
87func Get(typ ExtensionType) map[string]*Extension {
88 mx.RLock()
89 defer mx.RUnlock()
90
91 exts, ok := extensions[typ]
92 if !ok {
93 panic(fmt.Sprintf("unsupported extension type: %T", typ))
94 }
95
96 result := make(map[string]*Extension, len(exts))
97
98 maps.Copy(result, exts)
99
100 return result
101}
102
103// GetAll returns all extensions, sorted by their import path and name.
104func GetAll() []*Extension {

Callers 5

getCloudConstructorFunction · 0.92
getJSModulesFunction · 0.92
extensionSubcommandsFunction · 0.92
createSecretSourcesFunction · 0.92
getAllOutputConstructorsFunction · 0.92

Calls

no outgoing calls

Tested by 1

getCloudConstructorFunction · 0.74