Method
find_partial_match_backward
(
self, search_term: str, include_current: bool = False
)
Source from the content-addressed store, hash-verified
| 115 | return 0 |
| 116 | |
| 117 | def find_partial_match_backward( |
| 118 | self, search_term: str, include_current: bool = False |
| 119 | ) -> int: |
| 120 | add = 0 if include_current else 1 |
| 121 | start = self.index + add |
| 122 | for idx, val in enumerate(islice(self.entries_by_index, start, None)): |
| 123 | if search_term in val: |
| 124 | return idx + add |
| 125 | return 0 |
| 126 | |
| 127 | def forward( |
| 128 | self, |
Tested by
no test coverage detected