Show More
@@ -2,26 +2,32 from __future__ import annotations | |||||
2 |
|
2 | |||
3 | import contextlib |
|
3 | import contextlib | |
4 |
|
4 | |||
|
5 | from typing import ( | |||
|
6 | Protocol, | |||
|
7 | ) | |||
|
8 | ||||
5 | from . import util as interfaceutil |
|
9 | from . import util as interfaceutil | |
6 |
|
10 | |||
7 |
|
11 | |||
8 |
class idirstate( |
|
12 | class idirstate(Protocol): | |
9 | def __init__( |
|
13 | # TODO: convert these constructor args to fields? | |
10 | opener, |
|
14 | # def __init__( | |
11 | ui, |
|
15 | # self, | |
12 | root, |
|
16 | # opener, | |
13 | validate, |
|
17 | # ui, | |
14 | sparsematchfn, |
|
18 | # root, | |
15 | nodeconstants, |
|
19 | # validate, | |
16 | use_dirstate_v2, |
|
20 | # sparsematchfn, | |
17 | use_tracked_hint=False, |
|
21 | # nodeconstants, | |
18 | ): |
|
22 | # use_dirstate_v2, | |
19 | """Create a new dirstate object. |
|
23 | # use_tracked_hint=False, | |
20 |
|
24 | # ): | ||
21 | opener is an open()-like callable that can be used to open the |
|
25 | # """Create a new dirstate object. | |
22 | dirstate file; root is the root of the directory tracked by |
|
26 | # | |
23 | the dirstate. |
|
27 | # opener is an open()-like callable that can be used to open the | |
24 | """ |
|
28 | # dirstate file; root is the root of the directory tracked by | |
|
29 | # the dirstate. | |||
|
30 | # """ | |||
25 |
|
31 | |||
26 | # TODO: all these private methods and attributes should be made |
|
32 | # TODO: all these private methods and attributes should be made | |
27 | # public or removed from the interface. |
|
33 | # public or removed from the interface. |
General Comments 0
You need to be logged in to leave comments.
Login now