code: public void setNavHeaderHtml(String htmlFile) {
          DOMUtil.removeAllChildren(navHeader);
  
          RequestBuilder rb = new RequestBuilder(RequestBuilder.GET, htmlFile);
          rb.setCallback(new RequestCallback() {
  
              public void onResponseReceived(Request request, Response response) {
                  HTMLPanel html = new HTMLPanel(response.getText());
                  navHeader.appendChild((Node) html.getElement());
              }
  
              public void onError(Request request, Throwable exception) {
                  Label label = new Label(AppConstants.INSTANCE.logoBannerError());
                  navHeader.appendChild((Node) label.getElement());
              }
          });
  
          try {
              rb.send();
          } catch ( RequestException re ) {
              Label label = new Label(AppConstants.INSTANCE.logoBannerError());
              navHeader.appendChild((Node) label.getElement());
          }
      }
docs: View logic