javacheck

package
v0.6.2 Latest Latest
Warning

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

Go to latest
Published: Mar 11, 2026 License: MIT Imports: 13 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Register

func Register(cfg *config.Config) []checker.CheckRegistration

Register returns all Java check registrations.

Types

type BuildCheck

type BuildCheck struct {
	Config *config.JavaLanguageConfig
}

BuildCheck verifies that the Java project compiles.

func (*BuildCheck) ID

func (c *BuildCheck) ID() string

func (*BuildCheck) Name

func (c *BuildCheck) Name() string

func (*BuildCheck) Run

func (c *BuildCheck) Run(path string) (checker.Result, error)

Run compiles the Java project using Maven or Gradle.

type CoverageCheck

type CoverageCheck struct {
	Threshold float64
}

CoverageCheck verifies Java test coverage using JaCoCo reports.

func (*CoverageCheck) ID

func (c *CoverageCheck) ID() string

func (*CoverageCheck) Name

func (c *CoverageCheck) Name() string

func (*CoverageCheck) Run

func (c *CoverageCheck) Run(path string) (checker.Result, error)

Run checks for JaCoCo coverage reports and validates against threshold.

type DepsCheck

type DepsCheck struct{}

DepsCheck verifies Java dependency security scanning configuration.

func (*DepsCheck) ID

func (c *DepsCheck) ID() string

func (*DepsCheck) Name

func (c *DepsCheck) Name() string

func (*DepsCheck) Run

func (c *DepsCheck) Run(path string) (checker.Result, error)

Run checks for dependency vulnerability scanning tools.

type FormatCheck

type FormatCheck struct{}

FormatCheck detects Java code formatting configuration.

func (*FormatCheck) ID

func (c *FormatCheck) ID() string

func (*FormatCheck) Name

func (c *FormatCheck) Name() string

func (*FormatCheck) Run

func (c *FormatCheck) Run(path string) (checker.Result, error)

Run checks for formatting tools configuration.

type JaCoCoCounter

type JaCoCoCounter struct {
	Type    string `xml:"type,attr"`
	Missed  int    `xml:"missed,attr"`
	Covered int    `xml:"covered,attr"`
}

JaCoCoCounter represents a counter element in JaCoCo report.

type JaCoCoReport

type JaCoCoReport struct {
	XMLName  xml.Name        `xml:"report"`
	Counters []JaCoCoCounter `xml:"counter"`
}

JaCoCoReport represents the JaCoCo XML report structure.

type LintCheck

type LintCheck struct{}

LintCheck detects Java static analysis tools configuration.

func (*LintCheck) ID

func (c *LintCheck) ID() string

func (*LintCheck) Name

func (c *LintCheck) Name() string

func (*LintCheck) Run

func (c *LintCheck) Run(path string) (checker.Result, error)

Run checks for Checkstyle, SpotBugs, and PMD configuration.

type LoggingCheck

type LoggingCheck struct{}

LoggingCheck detects Java structured logging practices.

func (*LoggingCheck) ID

func (c *LoggingCheck) ID() string

func (*LoggingCheck) Name

func (c *LoggingCheck) Name() string

func (*LoggingCheck) Run

func (c *LoggingCheck) Run(path string) (checker.Result, error)

Run checks for structured logging libraries and anti-patterns.

type ProjectCheck

type ProjectCheck struct{}

ProjectCheck verifies that a Java project configuration exists.

func (*ProjectCheck) ID

func (c *ProjectCheck) ID() string

func (*ProjectCheck) Name

func (c *ProjectCheck) Name() string

func (*ProjectCheck) Run

func (c *ProjectCheck) Run(path string) (checker.Result, error)

Run checks for Maven or Gradle project files.

type TestsCheck

type TestsCheck struct {
	Config *config.JavaLanguageConfig
}

TestsCheck runs Java tests.

func (*TestsCheck) ID

func (c *TestsCheck) ID() string

func (*TestsCheck) Name

func (c *TestsCheck) Name() string

func (*TestsCheck) Run

func (c *TestsCheck) Run(path string) (checker.Result, error)

Run executes Java tests using Maven or Gradle.

Jump to

Keyboard shortcuts

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