Documentation
¶
Overview ¶
Package internal provides internal utilities for the checkapi package.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func ExprToString ¶
ExprToString converts an AST expression to a string representation.
func ReadComponentType ¶
ReadComponentType reads the component type from the metadata.yaml file in the given folder.
Types ¶
type API ¶
type API struct { Values []string `json:"values,omitempty"` Structs []APIstruct `json:"structs,omitempty"` Functions []Function `json:"functions,omitempty"` }
API represents the API of the codebase, including functions and structs.
type Config ¶
type Config struct { IgnoredPaths []string `yaml:"ignored_paths"` ExcludedFiles []string `yaml:"excluded_files"` AllowedFunctions []FunctionDescription `yaml:"allowed_functions"` IgnoredFunctions []string `yaml:"ignored_functions"` UnkeyedLiteral UnkeyedLiteral `yaml:"unkeyed_literal_initialization"` }
Config represents the configuration for the codebase analysis.
type Function ¶
type Function struct { Name string `json:"name"` Receiver string `json:"receiver"` ReturnTypes []string `json:"return_types,omitempty"` Params []string `json:"params,omitempty"` TypeParams []string `json:"type_params,omitempty"` }
Function represents a function in the codebase.
type FunctionDescription ¶
type FunctionDescription struct { Classes []string `yaml:"classes"` Name string `yaml:"name"` Parameters []string `yaml:"parameters"` ReturnTypes []string `yaml:"return_types"` }
FunctionDescription represents a function description.
type UnkeyedLiteral ¶
UnkeyedLiteral represents the configuration for unkeyed literal initialization.
Click to show internal directories.
Click to hide internal directories.