The rest of the code in this module is inside the PathInfo
class. We state here in the class's documentation string
the class invariants: conditions
that must always be true once the constructor has
completed. For more on invariants, see the author's
notes on cleanroom verification of objects.
#================================================================
# Functions and classes
#----------------------------------------------------------------
# - - - - - c l a s s P a t h I n f o - - - - -
class PathInfo:
"""Represents a snapshot of one file's status.
Class invariants:
.path:
[ the pathname passed to the class constructor ]
.size:
[ self.path's size in bytes as an integer ]
.createEpoch:
[ the epoch time when self.path was created ]
.modEpoch:
[ the epoch time when self.path was last modified ]
.mode:
[ the mode bits for self.path ]
"""