code: void showVariationsWindow(String resource) {
  
          final Window window = CmsBasicDialog.prepareWindow(DialogWidth.max);
          CmsVariationsDialog variationsDialog = new CmsVariationsDialog(resource, new Runnable() {
  
              public void run() {
  
                  window.close();
  
              }
  
          }, Mode.FlexCache);
          try {
              CmsResource resourceObject = getRootCms().readResource(CmsFlexCacheKey.getResourceName(resource));
              variationsDialog.displayResourceInfo(Collections.singletonList(resourceObject));
          } catch (CmsException e) {
              //
          }
          window.setCaption(CmsVaadinUtils.getMessageText(Messages.GUI_CACHE_VIEW_FLEX_VARIATIONS_1, resource));
          window.setContent(variationsDialog);
          UI.getCurrent().addWindow(window);
      }
docs: Shows dialog for variations of given resource.<p>
  
  @param resource to show variations for