Codota Logo
HasHTML
Code IndexAdd Codota to your IDE (free)

How to use
HasHTML
in
com.google.gwt.user.client.ui

Best Java code snippets using com.google.gwt.user.client.ui.HasHTML (Showing top 20 results out of 315)

  • Add the Codota plugin to your IDE and get smart completions
private void myMethod () {
Charset c =
  • Codota IconString charsetName;Charset.forName(charsetName)
  • Codota IconCharset.defaultCharset()
  • Codota IconContentType contentType;contentType.getCharset()
  • Smart code suggestions by Codota
}
origin: org.apache.james.hupa/hupa-widgets

public String getHTML() {
  return ((HasHTML)link).getHTML();
}
 
origin: com.google.gwt/gwt-servlet

/**
 * Sets a stack header's HTML contents.
 *
 * Use care when setting an object's HTML; it is an easy way to expose
 * script-based security problems. Consider using
 * {@link #setHeaderHTML(int, SafeHtml)} or
 * {@link #setHeaderText(int, String)} whenever possible.
 *
 * @param index the index of the header whose HTML is to be set
 * @param html the header's new HTML contents
 */
public void setHeaderHTML(int index, @IsSafeHtml String html) {
 checkIndex(index);
 LayoutData data = layoutData.get(index);
 Widget headerWidget = data.header.getWidget();
 assert headerWidget instanceof HasHTML : "Header widget does not implement HasHTML";
 ((HasHTML) headerWidget).setHTML(html);
}
origin: gwt-test-utils/gwt-test-utils

protected String getString(Object o) {
  String actualValue;
  if (o == null) {
    return null;
  } else if (HasHTML.class.isInstance(o)) {
    HasHTML hasHTML = (HasHTML) o;
    String html = hasHTML.getHTML();
    actualValue = html != null && html.length() > 0 ? html : hasHTML.getText();
  } else if (HasText.class.isInstance(o)) {
    actualValue = ((HasText) o).getText();
  } else {
    actualValue = "" + o;
  }
  return actualValue;
}
origin: org.apache.james.hupa/hupa-widgets

public String getText() {
  return ((HasHTML)link).getText();
}
 
origin: com.googlecode.mgwt/mgwt

@Override
public void setTitleText(String text) {
 dialogPanel.getDialogTitle().setText(text);
}
origin: com.googlecode.mgwt/mgwt

@Override
public String getTitleText() {
 return dialogPanel.getDialogTitle().getText();
}
origin: org.apache.james.hupa/hupa-widgets

public void setText(String text) {
  ((HasHTML)link).setText(text);
  html.setText(text);
}
 
origin: stephenh/tessell

@Override
public String getValue() {
 return target.getHTML();
}
origin: stephenh/tessell

 @Override
 public void setValue(String value) {
  target.setHTML(value);
 }
};
origin: dankurka/mgwt

@Override
public String getTitleText() {
 return dialogPanel.getDialogTitle().getText();
}
origin: dankurka/mgwt

@Override
public void setTitleText(String text) {
 dialogPanel.getDialogTitle().setText(text);
}
origin: gwt-test-utils/gwt-test-utils

public void visitHasHTML(HasHTML hasHTML, WidgetRepository repository) {
  if (hasHTML.getHTML() != null && hasHTML.getHTML().length() > 0) {
    repository.addAlias(hasHTML.getHTML(), hasHTML);
  }
}
origin: dankurka/mgwt

@Override
public void setTitleText(String title) {
 dialogPanel1.getDialogTitle().setHTML(title);
}
origin: org.jboss.errai/errai-data-binding

private Optional<Supplier<Object>> maybeCreateElementValueGetter(final Element element) {
 final Optional<Supplier<Object>> uiGetter;
 final Supplier<ElementWrapperWidget> toWidget = () -> ElementWrapperWidget.getWidget(element);
 final ElementWrapperWidget wrapper = toWidget.get();
 if (wrapper instanceof HasValue) {
  uiGetter = Optional.ofNullable(() -> ((HasValue) toWidget.get()).getValue());
 }
 else if (wrapper instanceof HasHTML) {
  uiGetter = Optional.ofNullable(() -> ((HasHTML) toWidget.get()).getText());
 }
 else {
  uiGetter = Optional.empty();
 }
 return uiGetter;
}
origin: com.googlecode.mgwt/mgwt

@Override
public String getTitleText() {
 return dialogPanel1.getDialogTitle().getHTML();
}
origin: com.googlecode.mgwt/mgwt

@Override
public void setTitleText(String title) {
 dialogPanel1.getDialogTitle().setHTML(title);
}
origin: errai/errai

private Optional<Supplier<Object>> maybeCreateElementValueGetter(final Element element) {
 final Optional<Supplier<Object>> uiGetter;
 final Supplier<ElementWrapperWidget> toWidget = () -> ElementWrapperWidget.getWidget(element);
 final ElementWrapperWidget wrapper = toWidget.get();
 if (wrapper instanceof HasValue) {
  uiGetter = Optional.ofNullable(() -> ((HasValue) toWidget.get()).getValue());
 }
 else if (wrapper instanceof HasHTML) {
  uiGetter = Optional.ofNullable(() -> ((HasHTML) toWidget.get()).getText());
 }
 else {
  uiGetter = Optional.empty();
 }
 return uiGetter;
}
origin: dankurka/mgwt

@Override
public String getTitleText() {
 return dialogPanel1.getDialogTitle().getHTML();
}
origin: com.vaadin.external.gwt/gwt-user

/**
 * Sets a stack header's HTML contents.
 *
 * Use care when setting an object's HTML; it is an easy way to expose
 * script-based security problems. Consider using
 * {@link #setHeaderHTML(int, SafeHtml)} or 
 * {@link #setHeaderText(int, String)} whenever possible.
 *
 * @param index the index of the header whose HTML is to be set
 * @param html the header's new HTML contents
 */
public void setHeaderHTML(int index, String html) {
 checkIndex(index);
 LayoutData data = layoutData.get(index);
 Widget headerWidget = data.header.getWidget();
 assert headerWidget instanceof HasHTML : "Header widget does not implement HasHTML";
 ((HasHTML) headerWidget).setHTML(html);
}
origin: com.googlecode.gwt-test-utils/gwt-test-utils

/**
 * Verifies that the actual {@link UIObject} HTML contains the given sequence.
 *
 * @param sequence the sequence to search for.
 * @return this assertion object.
 * @throws AssertionError if the actual HTML value does not contain the given sequence.
 */
public S htmlContains(String sequence) {
  String html = HasHTML.class.isInstance(actual) ? ((HasHTML) actual).getHTML()
      : actual.getInnerHTML();
  if (!html.contains(sequence))
    failWithMessage("actual HTML [%s] does not contains [%s]", html, sequence);
  return myself;
}
com.google.gwt.user.client.uiHasHTML

Javadoc

An object that implements this interface contains text, which can be set and retrieved using these methods. The object's text can be set either as HTML or as text.

Use in UiBinder Templates

The body of an XML element representing a widget that implements HasHTML will be parsed as HTML and be used in a call to its #setHTML(String) method.

For example:

 
<g:PushButton><b>Click me!</b></g:PushButton> 

Most used methods

  • getHTML
    Gets this object's contents as HTML.
  • setHTML
    Sets this object's contents via HTML. Use care when setting an object's HTML; it is an easy way to e
  • getText
  • setText

Popular in Java

  • Reactive rest calls using spring rest template
  • addToBackStack (FragmentTransaction)
  • runOnUiThread (Activity)
  • onRequestPermissionsResult (Fragment)
  • Font (java.awt)
    The Font class represents fonts, which are used to render text in a visible way. A font provides the
  • GridLayout (java.awt)
    The GridLayout class is a layout manager that lays out a container's components in a rectangular gri
  • IOException (java.io)
    Signals that an I/O exception of some sort has occurred. This class is the general class of exceptio
  • PriorityQueue (java.util)
    An unbounded priority Queue based on a priority heap. The elements of the priority queue are ordered
  • Callable (java.util.concurrent)
    A task that returns a result and may throw an exception. Implementors define a single method with no
  • ThreadPoolExecutor (java.util.concurrent)
    An ExecutorService that executes each submitted task using one of possibly several pooled threads, n
Codota Logo
  • Products

    Search for Java codeSearch for JavaScript codeEnterprise
  • IDE Plugins

    IntelliJ IDEAWebStormAndroid StudioEclipseVisual Studio CodePyCharmSublime TextPhpStormVimAtomGoLandRubyMineEmacsJupyter
  • Company

    About UsContact UsCareers
  • Resources

    FAQBlogCodota Academy Plugin user guide Terms of usePrivacy policyJava Code IndexJavascript Code Index
Get Codota for your IDE now