def __init__(opener, ui, root, validate, sparsematchfn):
    """Create a new dirstate object.

        opener is an open()-like callable that can be used to open the
        dirstate file; root is the root of the directory tracked by
        the dirstate.
        """
