<p>
Select all options that display text matching the argument. That is, when given "Bar" this
would select an option like:
</p>
&lt;option value="foo"&gt;Bar&lt;/option&gt;

@param text The visible text to match against
502152
public FluentSelect selectByVisibleText(final String text) {
        executeAndWrapReThrowIfNeeded(new SelectByVisibleText(text), Context.singular(context, "selectByVisibleText", null, text), true);
        return new FluentSelect(super.delegate, currentElement.getFound(), this.context, monitor, booleanInsteadOfNotFoundException);
    }
216603
public void setText(final String TEXT) {
        if (null == text) {
            _text = TEXT;
            fireSectionEvent(UPDATE_EVENT);
        } else {
            text.set(TEXT);
        }
    }
1006647
public void setToolTipText(String text) {
        this.toolTipText = text;
        if (toolTipDialog != null) {
            toolTipDialog.setText(text);
        }
    }
907787
public final void setDestText(final String text) {
        if (SwingUtilities.isEventDispatchThread()) {
            setDestTextIntern(text);
        } else {
            try {
                SwingUtilities.invokeLater(new Runnable() {
                    public void run() {
                        setDestTextIntern(text);
                    }
                });
            } catch (final Exception ex) {
                ignore();
            }
        }
    }
298393
public void setText(final String text, final Serializable... args) {
		getOrCreateComponentModel().text = I18nUtilities.asMessage(text, args);
	}
346833
public final void setPlaceholder(String text) {
        if (!text.equalsIgnoreCase(mText)) {
            setPlaceholderTextInternal(text, mTextColor, mTextSize, true);
        }
    }
373282
protected boolean validate(String text)
	{
		try
		{
			String[] strings = text.split(",");
			for (int i = 0; i < strings.length; i++)
			{
				Integer.parseInt(strings[i].trim());
			}
			return true;
		}
		catch (NumberFormatException e)
		{
			return false;
		}
	}
76488
public T lookup(String text)
	{
		if (text == null)
			return null;
		
		for (Entry<String,T> entry :lookupMap.entrySet())
		{
			if (Text.matches(text, entry.getKey()))
				return lookupMap.get(entry.getKey());
			
		}

		return null;

	}
754656
public void setText(final String TEXT) {
        if (null == text) {
            _text = TEXT;
        } else {
            text.set(TEXT);
        }
        fireMarkerEvent(TEXT_CHANGED_EVENT);
    }
1022623
def select_by_visible_text(self, text):
        
        xpath = './/option[normalize-space(.) = {0}]'.format(self._escape_string(text))
        opts = self.find_elements_by_xpath(xpath)
        matched = False
        for opt in opts:
            self._set_selected(opt)
            if not self.is_multiple:
                return
            matched = True
        # in case the target option isn't found by xpath
        # attempt to find it by direct comparison among options which contain at least the longest token from the text
        if len(opts) == 0 and ' ' in text:
            sub_string_without_space = self._get_longest_token(text)
            if sub_string_without_space == "":
                candidates = self.get_options()
            else:
                xpath = ".//option[contains(.,{0})]".format(self._escape_string(sub_string_without_space))
                candidates = self.find_elements_by_xpath(xpath)
            for candidate in candidates:
                if text == candidate.text:
                    self._set_selected(candidate)
                    if not self.is_multiple:
                        return
                    matched = True
        if not matched:
            raise NoSuchElementException("Could not locate element with visible text: " + str(text))
772573
public static boolean isRedirect(String text) {
		boolean result = false;
		String pattern;
		for (int i = 0; i < redirectPatterns.size() && !result; i++) {
			pattern = redirectPatterns.get(i);
			result = text.regionMatches(true, 0, pattern, 0, pattern.length());
		}
		return result;

	}
145152
public String lookingAt(CharSequence text)
    {
        try
        {
            if (text.length() == 0)
            {
                if (acceptEmpty)
                {
                    return "";
                }
                else
                {
                    throw new SyntaxErrorException("empty string not accepted");
                }
            }
            InputReader reader = Input.getInstance(text);
            return lookingAt(reader);
        }
        catch (IOException ex)
        {
            throw new IllegalArgumentException("can't happen");
        }
    }
1225823
public void clickOnText(String text) {
		if(config.commandLogging){
			Log.d(config.commandLoggingTag, "clickOnText(\""+text+"\")");
		}
		
		clicker.clickOnText(text, false, 1, true, 0);
	}
175398
public String match(String text){
		if(null == text){
			return null;
		}
		List<String> matchAll = matchAll(text, 1);
		if(CollectionUtil.isNotEmpty(matchAll)){
			return matchAll.get(0);
		}
		return null;
	}
992382
public OptionBuilder withDescription( String text )
    {
        if (option.getDescription() != null) throw new IllegalArgumentException( "Description given twice" );
        option.setDescription( text );
        return this;
    }
618932
public void setTextForNullSelection(String text) {

        // do nothing if there's no null option
        CmsLabelSelectCell cell = m_selectCells.get("");
        if (cell == null) {
            return;
        }
        cell.setText(text);
        // if the null option is selected, we still need to update the opener
        if (CmsStringUtil.isEmptyOrWhitespaceOnly(m_selectedValue)) {
            selectValue("");
        }
    }
1256882
@Override
    public void setAsText(final String text) {
        if (BeanUtils.isNull(text)){
            setValue(null);
            return;
        }
        String[] tokens = super.tokenize(text);
        char[] theValue = new char[tokens.length];

        for (int index = 0; index < tokens.length; index++) {
            if (tokens[index].length() != 1)
                throw new IllegalArgumentException("Too many (" + tokens[index].length() + ") characters: '" + tokens[index]
                        + "'");
            theValue[index] = tokens[index].charAt(0);
        }
        setValue(theValue);
    }