Documentation
¶
Index ¶
- func BuildCSharpIndices(suppliedFiles map[string]bool, contentReader vcs.ContentReader) (map[string][]string, map[string]map[string][]string, map[string]string, ...)
- func ExtractCSharpTypeIdentifiers(source string) []string
- func IsTestFile(filePath string) bool
- func ParseCSharpNamespace(source string) string
- func ParseCSharpPartialTypeNames(source string) map[string]bool
- func ParseTopLevelCSharpTypeNames(source string) []string
- func ResolveCSharpProjectImports(absPath string, _ string, namespaceToFiles map[string][]string, ...) ([]string, error)
- type CSharpImport
- type Provider
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func BuildCSharpIndices ¶
func ExtractCSharpTypeIdentifiers ¶
ExtractCSharpTypeIdentifiers extracts likely type identifiers from code references.
func IsTestFile ¶
IsTestFile reports whether the given C# path is a test file.
func ParseCSharpNamespace ¶
ParseCSharpNamespace extracts the file namespace declaration.
func ParseCSharpPartialTypeNames ¶ added in v0.27.0
ParseCSharpPartialTypeNames returns the set of type names declared with the `partial` modifier. In valid C# the same type name may appear in multiple files of one namespace only as a partial type, so this lets the resolver link every file of a partial class (the common Foo.cs / Foo.Async.cs split) while still treating non-partial duplicate names as ambiguous.
func ParseTopLevelCSharpTypeNames ¶
ParseTopLevelCSharpTypeNames extracts top-level type names declared in a file.
Types ¶
type CSharpImport ¶
type CSharpImport struct {
Path string
}
CSharpImport represents a using directive.
func CSharpImports ¶
func CSharpImports(filePath string) ([]CSharpImport, error)
CSharpImports parses a C# file and returns its imports.
func ParseCSharpImports ¶
func ParseCSharpImports(source string) []CSharpImport
ParseCSharpImports parses C# source code and extracts using directives.
type Provider ¶ added in v0.27.0
type Provider struct{}
func (Provider) Extensions ¶ added in v0.27.0
func (Provider) IsTestFile ¶ added in v0.27.0
func (Provider) IsTestFile(filePath string, _ vcs.ContentReader) bool
func (Provider) Maturity ¶ added in v0.27.0
func (Provider) Maturity() moduleapi.MaturityLevel