MCPcopy Create free account
hub / github.com/SeleniumHQ/selenium / LocateElement

Method LocateElement

cpp/iedriver/IECommandExecutor.cpp:1662–1682  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1660}
1661
1662int IECommandExecutor::LocateElement(const ElementHandle parent_wrapper,
1663 const std::string& mechanism,
1664 const std::string& criteria,
1665 Json::Value* found_element) const {
1666 LOG(TRACE) << "Entering IECommandExecutor::LocateElement";
1667
1668 std::wstring mechanism_translation = L"";
1669 int status_code = this->GetElementFindMethod(mechanism,
1670 &mechanism_translation);
1671 if (status_code != WD_SUCCESS) {
1672 LOG(WARN) << "Unable to determine mechanism translation for " << mechanism;
1673 return status_code;
1674 }
1675
1676 std::wstring wide_criteria = StringUtilities::ToWString(criteria);
1677 return this->element_finder()->FindElement(*this,
1678 parent_wrapper,
1679 mechanism_translation,
1680 wide_criteria,
1681 found_element);
1682}
1683
1684int IECommandExecutor::LocateElements(const ElementHandle parent_wrapper,
1685 const std::string& mechanism,

Callers 2

ExecuteInternalMethod · 0.80
ExecuteInternalMethod · 0.80

Calls 4

GetElementFindMethodMethod · 0.95
element_finderMethod · 0.95
LOGClass · 0.50
FindElementMethod · 0.45

Tested by

no test coverage detected