MCPcopy
hub / github.com/Tencent/CodeAnalysis / Search

Method Search

tools/owl/scan/scanner.go:178–188  ·  view source on GitHub ↗

Search search signature

(code string)

Source from the content-addressed store, hash-verified

176
177// Search search signature
178func (s *Scanner) Search(code string) ([]*Result, error) {
179 s.Code = code
180 if IsDir(s.Path) {
181 if files, err := Files(s.Path); err != nil {
182 return nil, err
183 } else {
184 return s.Matcher.Search(files, s.Code)
185 }
186 }
187 return nil, ErrNotIsDir
188}
189
190// List returns all files under the specified path to calculate the signature
191func (s *Scanner) List() ([]*Result, error) {

Callers

nothing calls this directly

Calls 3

IsDirFunction · 0.85
FilesFunction · 0.85
SearchMethod · 0.65

Tested by

no test coverage detected