MCPcopy Create free account
hub / github.com/cel-expr/cel-go / NewVariableDoc

Function NewVariableDoc

common/doc.go:121–128  ·  view source on GitHub ↗

NewVariableDoc creates a new Doc struct specifically for documenting a variable.

(name, celType, description string)

Source from the content-addressed store, hash-verified

119
120// NewVariableDoc creates a new Doc struct specifically for documenting a variable.
121func NewVariableDoc(name, celType, description string) *Doc {
122 return &Doc{
123 Kind: DocVariable,
124 Name: name,
125 Type: celType,
126 Description: ParseDescription(description),
127 }
128}
129
130// NewFunctionDoc creates a new Doc struct for documenting a function.
131func NewFunctionDoc(name, description string, overloads ...*Doc) *Doc {

Callers 2

DocumentationMethod · 0.92
TestNewDocFunction · 0.85

Calls 1

ParseDescriptionFunction · 0.85

Tested by 1

TestNewDocFunction · 0.68