Documentation ¶
Index ¶
- Constants
- func GetFileVersion(filePath, repo, commit string) (string, error)
- func MakeBQCSVReader() *bqCSVReader
- func MergeCSVData(config *Config, reader io.Reader) (map[string]*MergeResult, error)
- type Config
- type DeletedFileLineMerger
- type FileCoverageMerger
- type FileLineCoverMerger
- type FileRecord
- type FileRecords
- type FileVersProvider
- type FuncProxyURI
- type LineToLineMatcher
- type MergeResult
- type RepoCommit
Constants ¶
View Source
const ( KeyKernelRepo = "kernel_repo" KeyKernelBranch = "kernel_branch" KeyKernelCommit = "kernel_commit" KeyFilePath = "file_path" KeyStartLine = "sl" KeyHitCount = "hit_count" )
Variables ¶
This section is empty.
Functions ¶
func GetFileVersion ¶
func MakeBQCSVReader ¶
func MakeBQCSVReader() *bqCSVReader
func MergeCSVData ¶
Types ¶
type Config ¶
type Config struct { Jobs int Workdir string Base RepoCommit FileVersProvider FileVersProvider StoreDetails bool // contains filtered or unexported fields }
type DeletedFileLineMerger ¶
type DeletedFileLineMerger struct { }
func (*DeletedFileLineMerger) Add ¶
func (a *DeletedFileLineMerger) Add(*FileRecord)
func (*DeletedFileLineMerger) Result ¶
func (a *DeletedFileLineMerger) Result() *MergeResult
type FileCoverageMerger ¶
type FileCoverageMerger interface { Add(record *FileRecord) Result() *MergeResult }
type FileLineCoverMerger ¶
type FileLineCoverMerger struct { *MergeResult // contains filtered or unexported fields }
func (*FileLineCoverMerger) Add ¶
func (a *FileLineCoverMerger) Add(record *FileRecord)
func (*FileLineCoverMerger) Result ¶
func (a *FileLineCoverMerger) Result() *MergeResult
type FileRecord ¶
type FileRecord struct { FilePath string RepoCommit StartLine int HitCount int }
type FileRecords ¶
type FileRecords struct {
// contains filtered or unexported fields
}
type FileVersProvider ¶
type FileVersProvider interface { GetFileVersions(targetFilePath string, repoCommits ...RepoCommit, ) (fileVersions, error) }
func MakeMonoRepo ¶
func MakeMonoRepo(workdir string) FileVersProvider
func MakeWebGit ¶
func MakeWebGit(funcProxy FuncProxyURI) FileVersProvider
type FuncProxyURI ¶
type LineToLineMatcher ¶
type LineToLineMatcher struct {
// contains filtered or unexported fields
}
func (*LineToLineMatcher) SameLinePos ¶
func (lm *LineToLineMatcher) SameLinePos(line int) int
type MergeResult ¶
type MergeResult struct { HitCounts map[int]int FileExists bool LineDetails map[int][]*FileRecord }
type RepoCommit ¶
Click to show internal directories.
Click to hide internal directories.