MCPcopy Create free account
hub / github.com/MG-RAST/Shock / HasIndex

Method HasIndex

shock-server/node/helper.go:39–50  ·  view source on GitHub ↗
(index string)

Source from the content-addressed store, hash-verified

37}
38
39func (node *Node) HasIndex(index string) bool {
40 if virtIdx[index] {
41 return true
42 } else {
43 if node.HasFile() {
44 if _, err := os.Stat(node.IndexPath() + "/" + index); err == nil {
45 return true
46 }
47 }
48 }
49 return false
50}
51
52func (node *Node) HasParent() bool {
53 for _, linkage := range node.Linkages {

Callers

nothing calls this directly

Calls 3

HasFileMethod · 0.95
IndexPathMethod · 0.95
StatMethod · 0.65

Tested by

no test coverage detected