| Dependency | Represents a dependency discovered during scanning, including its name, version, type, and location information. |
| DependencyScanner | Provides the base class for scanning source code files to discover dependencies across multiple package ecosystems and formats.
var dependencies = await DependencyScanner.ScanDirectoryAsync(
"C:\\MyProject",
options: null,
cancellationToken);
foreach (var dependency in dependencies)
{
Console.WriteLine($"{dependency.Type}: {dependency.Name}@{dependency.Version}");
}
|
| DependencyScannerException | Represents errors that occur during dependency scanning operations. |
| Location | Represents the location of a dependency value in a source file, providing the ability to update the value in place. |
| LocationExtensions | Provides extension methods for ordering dependencies by their location in source files. |
| ScannerOptions | Provides configuration options for dependency scanning operations.var options = new ScannerOptions
{
DegreeOfParallelism = 8,
RecurseSubdirectories = true,
IncludedDependencyTypes = [DependencyType.NuGet, DependencyType.Npm],
};
var dependencies = await DependencyScanner.ScanDirectoryAsync("C:\\MyProject", options, cancellationToken);
|