MCPcopy Index your code
hub / github.com/PyQt5/PyQt / findPath

Method findPath

QTreeView/Lib/qjsonmodel.py:231–241  ·  view source on GitHub ↗
(
        self,
        path: str,
        flags=Qt.MatchFixedString
        | Qt.MatchCaseSensitive
        | Qt.MatchWrap
        | Qt.MatchRecursive,
    )

Source from the content-addressed store, hash-verified

229 self.setHorizontalHeaderLabels(headers)
230
231 def findPath(
232 self,
233 path: str,
234 flags=Qt.MatchFixedString
235 | Qt.MatchCaseSensitive
236 | Qt.MatchWrap
237 | Qt.MatchRecursive,
238 ) -> Union[QJsonItem, None]:
239 indexes = self.match(self.index(0, 0), QJsonItem.PathRole, path, -1, flags)
240 indexes = [index for index in indexes if index.isValid()]
241 return self.itemFromIndex(indexes[0]) if indexes else None # type: ignore
242
243 def updateValue(
244 self, path: str, value: Any, item: Union[QJsonItem, None] = None

Callers 3

updateValueMethod · 0.95
doQueryMethod · 0.80
_setValueMethod · 0.80

Calls

no outgoing calls

Tested by 1

doQueryMethod · 0.64