Documentation
¶
Index ¶
- func NewFileFromReader(reader io.Reader, path string, isImport bool) *readerFile
- func NewLocalFileSystem(config LocalFileSystemConfig) (core.ImportAwareFileSystem, error)
- func NewSourceWalker(config SourceWalkerConfig, langs []core.Language) (*sourceWalker, error)
- type LocalFileSystemConfig
- type SourceWalkerConfig
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func NewFileFromReader ¶
NewFileFromReader creates a new readerFile for provided io.Reader with the given path and isImport flag. readerFile is an implementation of core.File which is used to represent a file in the Code analysis framework
This is required when you want to analyze a standalone file eg. an artifact file
func NewLocalFileSystem ¶
func NewLocalFileSystem(config LocalFileSystemConfig) (core.ImportAwareFileSystem, error)
func NewSourceWalker ¶
func NewSourceWalker(config SourceWalkerConfig, langs []core.Language) (*sourceWalker, error)
NewSourceWalker creates a new source walker that can walk the source files in a file system based on language specific rules.
Types ¶
type LocalFileSystemConfig ¶
type LocalFileSystemConfig struct {
// The directories to find 1st party source files
AppDirectories []string
// The directories to find 3rd party source files
// imported by the application
ImportDirectories []string
// Regular expressions to exclude files or directories
// from traversal
ExcludePatterns []*regexp.Regexp
}
type SourceWalkerConfig ¶
type SourceWalkerConfig struct {
IncludeImports bool
}
Click to show internal directories.
Click to hide internal directories.