MCPcopy Create free account
hub / github.com/dolthub/doltgresql / HasContainerLeaf

Method HasContainerLeaf

postgres/parser/json/json.go:1881–1895  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

1879}
1880
1881func (j jsonArray) HasContainerLeaf() (bool, error) {
1882 if j.Len() == 0 {
1883 return true, nil
1884 }
1885 for _, c := range j {
1886 child, err := c.HasContainerLeaf()
1887 if err != nil {
1888 return false, err
1889 }
1890 if child {
1891 return true, nil
1892 }
1893 }
1894 return false, nil
1895}
1896
1897func (j jsonNull) HasContainerLeaf() (bool, error) { return false, nil }
1898func (j jsonTrue) HasContainerLeaf() (bool, error) { return false, nil }

Callers

nothing calls this directly

Calls 2

LenMethod · 0.95
HasContainerLeafMethod · 0.65

Tested by

no test coverage detected