starcomplexity

package
v0.1.0-dev.20260301204145 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Mar 1, 2026 License: MIT Imports: 3 Imported by: 0

Documentation

Overview

Package starcomplexity computes cyclomatic and cognitive complexity metrics for Starlark source files.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type ComplexityReport

type ComplexityReport struct {
	Files []FileComplexity
}

ComplexityReport holds complexity results for all analyzed files.

type FileComplexity

type FileComplexity struct {
	Path      string
	Functions []FunctionComplexity
}

FileComplexity holds complexity results for a single file.

type FunctionComplexity

type FunctionComplexity struct {
	Name       string
	Line       int
	Cyclomatic int
	Cognitive  int
	MaxNesting int
	LOC        int
	Params     int
}

FunctionComplexity holds complexity metrics for a single function.

type Provider

type Provider struct {
	Root string
}

Provider computes cyclomatic and cognitive complexity metrics for Starlark source files.

+devlore:access=immediate +devlore:bind Root=WorkDir

func (*Provider) ComputeComplexity

func (p *Provider) ComputeComplexity(files []string) (*ComplexityReport, error)

ComputeComplexity analyzes the given files for function complexity.

Directories

Path Synopsis

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL