FileDeclarationContext

data class FileDeclarationContext(val declaration: FileDeclaration, val modulePath: String, val sourceSet: SourceSetId? = null)

Context wrapper for verifying source file declarations.

Provides both the target declaration and architectural metadata to easily query scope.

Constructors

Link copied to clipboard
constructor(declaration: FileDeclaration, modulePath: String, sourceSet: SourceSetId? = null)

Properties

Link copied to clipboard

Delegates classes property to the underlying FileDeclaration.

Link copied to clipboard

Filter or assertion criteria for declaration.

Link copied to clipboard

Delegates imports property to the underlying FileDeclaration.

Link copied to clipboard

Filter or assertion criteria for module path.

Link copied to clipboard

Delegates name property to the underlying FileDeclaration.

Link copied to clipboard

Delegates packageName property to the underlying FileDeclaration.

Link copied to clipboard
val sourceSet: SourceSetId? = null

Filter or assertion criteria for source set.

Link copied to clipboard

Delegates topLevelFunctions property to the underlying FileDeclaration.

Link copied to clipboard

Delegates topLevelProperties property to the underlying FileDeclaration.

Functions

Link copied to clipboard

Helper extension to check if a file contains a class matching the predicate.

Link copied to clipboard

Helper extension to check if a file imports the specified match.

Link copied to clipboard

Helper extension to check if a file imports any match containing target segments.