MCPcopy Index your code
hub / github.com/AirtestProject/Poco / parent

Method parent

poco/proxy.py:192–209  ·  view source on GitHub ↗

Select the direct parent from the UI element(s) given by the query expression, see ``QueryCondition`` for more details about the selectors. Warnings: Experimental method, may not be available for all drivers. Returns: :py:class:`UIObjectProx

(self)

Source from the content-addressed store, hash-verified

190 return obj
191
192 def parent(self):
193 """
194 Select the direct parent from the UI element(s) given by the query expression, see ``QueryCondition`` for
195 more details about the selectors.
196
197 Warnings:
198 Experimental method, may not be available for all drivers.
199
200 Returns:
201 :py:class:`UIObjectProxy <poco.proxy.UIObjectProxy>`: a new UI proxy object representing the direct parent
202 of the first UI element.
203 """
204
205 sub_query = build_query(None) # as placeholder
206 query = ('^', (self.query, sub_query))
207 obj = UIObjectProxy(self.poco)
208 obj.query = query
209 return obj
210
211 def __getitem__(self, item):
212 """

Callers

nothing calls this directly

Calls 2

build_queryFunction · 0.90
UIObjectProxyClass · 0.85

Tested by

no test coverage detected