LSSTApplications
10.0+286,10.0+36,10.0+46,10.0-2-g4f67435,10.1+152,10.1+37,11.0,11.0+1,11.0-1-g47edd16,11.0-1-g60db491,11.0-1-g7418c06,11.0-2-g04d2804,11.0-2-g68503cd,11.0-2-g818369d,11.0-2-gb8b8ce7
LSSTDataManagementBasePackage
|
Public Member Functions | |
def | __init__ |
def | getFields |
def | isNumeric |
def | isInt |
def | isFloat |
def | processPath |
Public Attributes | |
globString | |
fields | |
reString | |
Class to scan a filesystem location for paths matching a template. Decomposes the resulting paths into fields and passes them to a callback function.
Definition at line 33 of file fsScanner.py.
def lsst.daf.butlerUtils.fsScanner.FsScanner.__init__ | ( | self, | |
pathTemplate | |||
) |
Constructor. Takes the path template, which should be in the form of a Python string with named format substitution specifications. Such a template would be suitable for generating a path given a set of fields in a dictionary. Does not handle hex (%x or %X). Example: %(field)s/%(visit)d/%(exposure)d/raw-%(visit)d-e%(exposure)03d-c%(ccd)03d-a%(amp)03d.fits Note that fields may appear multiple times; the second and subsequent appearances of such fields will have "_{number}" appended to them to disambiguate, although it is typically assumed that they will all be identical.
Definition at line 40 of file fsScanner.py.
def lsst.daf.butlerUtils.fsScanner.FsScanner.getFields | ( | self | ) |
Return the list of fields that will be returned from matched paths, in order.
Definition at line 90 of file fsScanner.py.
def lsst.daf.butlerUtils.fsScanner.FsScanner.isFloat | ( | self, | |
name | |||
) |
def lsst.daf.butlerUtils.fsScanner.FsScanner.isInt | ( | self, | |
name | |||
) |
def lsst.daf.butlerUtils.fsScanner.FsScanner.isNumeric | ( | self, | |
name | |||
) |
def lsst.daf.butlerUtils.fsScanner.FsScanner.processPath | ( | self, | |
location, | |||
callback | |||
) |
Scan a given path location with the given callback function.
Definition at line 114 of file fsScanner.py.
lsst.daf.butlerUtils.fsScanner.FsScanner.fields |
Definition at line 61 of file fsScanner.py.
lsst.daf.butlerUtils.fsScanner.FsScanner.globString |
Definition at line 57 of file fsScanner.py.
lsst.daf.butlerUtils.fsScanner.FsScanner.reString |
Definition at line 62 of file fsScanner.py.