List of usage examples for org.openqa.selenium WebElement clear
void clear();
From source file:org.alfresco.po.share.search.AdvanceSearchCRMPage.java
License:Open Source License
/** * Enter the text value in the CrmCaseNumber field. * /*from w ww . java2 s. co m*/ * @param caseNumber String */ public void inputCrmCaseNumber(final String caseNumber) { if (caseNumber == null || caseNumber.isEmpty()) { throw new UnsupportedOperationException("Search term is required to perform a search"); } WebElement nameElement = findElementDisplayed(CRM_CASE_NUMBER); nameElement.clear(); nameElement.sendKeys(caseNumber); }
From source file:org.alfresco.po.share.search.AdvanceSearchCRMPage.java
License:Open Source License
/** * Enter the text value in the CrmCaseName field. * /*from w w w. j a v a 2s . co m*/ * @param caseName String */ public void inputCrmCaseName(final String caseName) { if (caseName == null || caseName.isEmpty()) { throw new UnsupportedOperationException("Search term is required to perform a search"); } WebElement nameElement = findElementDisplayed(CRM_CASE_NAME); nameElement.clear(); nameElement.sendKeys(caseName); }
From source file:org.alfresco.po.share.search.AdvanceSearchPage.java
License:Open Source License
/** * Content keyword is Displayed and enter search text in the keyword. * * @param keyWordSearchText String//from w w w. j ava 2 s .c om */ public void inputKeyword(final String keyWordSearchText) { if (keyWordSearchText == null) { throw new UnsupportedOperationException("Search term is required to perform a search"); } WebElement keyWordElement = findElementDisplayed(KEYWORD_SEARCH); keyWordElement.clear(); keyWordElement.sendKeys(keyWordSearchText); }
From source file:org.alfresco.po.share.search.AdvanceSearchPage.java
License:Open Source License
/** * Enter the text value in the Name field. * * @param nameSearchText String/*from w w w .j av a2 s . co m*/ */ public void inputName(final String nameSearchText) { if (nameSearchText == null) { throw new UnsupportedOperationException("Search term is required to perform a search"); } WebElement nameElement = findElementDisplayed(NAME_SEARCH); nameElement.clear(); nameElement.sendKeys(nameSearchText); // name.clear(); // name.sendKeys(nameSearchText); }
From source file:org.alfresco.po.share.search.AdvanceSearchPage.java
License:Open Source License
/** * Enter the text value in the title field. * * @param titleSearchText String//from w w w .j a v a2 s . c o m */ public void inputTitle(final String titleSearchText) { if (titleSearchText == null) { throw new UnsupportedOperationException("Search term is required to perform a search"); } WebElement titleElement = findElementDisplayed(TITLE_SEARCH); titleElement.clear(); titleElement.sendKeys(titleSearchText); }
From source file:org.alfresco.po.share.search.AdvanceSearchPage.java
License:Open Source License
/** * Enter the text value in the description field. * * @param descriptionSearchText String//w w w .ja v a 2s. co m */ public void inputDescription(final String descriptionSearchText) { if (descriptionSearchText == null) { throw new UnsupportedOperationException("Search term is required to perform a search"); } WebElement descriptionElement = findElementDisplayed(DESCRIPTION_SEARCH); descriptionElement.clear(); descriptionElement.sendKeys(descriptionSearchText); }
From source file:org.alfresco.po.share.search.AdvanceSearchPage.java
License:Open Source License
/** * Enter the text value in the modifier field. * * @param modifierSearchText String// w w w.j a v a 2 s. co m */ public void inputModifier(final String modifierSearchText) { if (modifierSearchText == null) { throw new UnsupportedOperationException("Search term is required to perform a search"); } WebElement modifierElement = findElementDisplayed(MODIFIER_SEARCH); modifierElement.clear(); modifierElement.sendKeys(modifierSearchText); }
From source file:org.alfresco.po.share.search.AdvanceSearchPage.java
License:Open Source License
/** * Enter the date in the from date field. * * @param fromDateText String//from w w w . ja v a2s . c om */ public void inputFromDate(final String fromDateText) { if (fromDateText == null) { throw new UnsupportedOperationException("Search term is required to perform a search"); } WebElement modifierFromElement = findElementDisplayed(MODIFIER_FROM_SEARCH); modifierFromElement.clear(); modifierFromElement.sendKeys(fromDateText); }
From source file:org.alfresco.po.share.search.AdvanceSearchPage.java
License:Open Source License
/** * Enter the date in the To date field./* ww w .ja v a 2 s. c o m*/ * * @param toDateText String */ public void inputToDate(final String toDateText) { if (toDateText == null) { throw new UnsupportedOperationException("Search term is required to perform a search"); } WebElement modifierToElement = findElementDisplayed(MODIFIER_TO_SEARCH); modifierToElement.clear(); modifierToElement.sendKeys(toDateText); }
From source file:org.alfresco.po.share.search.SearchBox.java
License:Open Source License
/** * Performs the search by entering the term into search field * and submitting the search./* w w w. j av a2 s .c om*/ * * @param term String term to search * @return true when actioned */ public HtmlPage search(final String term) { if (term == null || term.isEmpty()) { throw new UnsupportedOperationException("Search term is required to perform a search"); } try { WebElement input = driver.findElement(selector); input.clear(); input.sendKeys(term + "\n"); if (logger.isTraceEnabled()) { logger.trace("Apply search on the keyword: " + term); } } catch (NoSuchElementException nse) { } return getCurrentPage(); }