MCPcopy Create free account
hub / github.com/clips/pattern / _dataFilePathname

Function _dataFilePathname

pattern/text/en/wordnet/pywordnet/wordnet.py:1129–1137  ·  view source on GitHub ↗
(filenameroot)

Source from the content-addressed store, hash-verified

1127# File utilities
1128#
1129def _dataFilePathname(filenameroot):
1130 if os.name in ('dos', 'nt'):
1131 path = os.path.join(WNSEARCHDIR, filenameroot + ".dat")
1132 if os.path.exists(path):
1133 return [path]
1134 # Tom De Smedt, 2011
1135 # Return a list of consecutive data files.
1136 import glob
1137 return sorted(glob.glob(os.path.join(WNSEARCHDIR, "data." + filenameroot + "*")))
1138
1139def _indexFilePathname(filenameroot):
1140 if os.name in ('dos', 'nt'):

Callers 1

__init__Method · 0.85

Calls 1

existsMethod · 0.80

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…