code: public static String formatVersion(CmsHistoryResourceBean bean) {
  
          CmsHistoryVersion hVersion = bean.getVersion();
          Integer v = hVersion.getVersionNumber();
          String result = "" + (v != null ? v.toString() : "-");
          String suffix = "";
          if (hVersion.isOnline()) {
              suffix = " (Online)";
          } else if (hVersion.isOffline()) {
              suffix = " (Offline)";
          }
          result += suffix;
          return result;
  
      }
docs: Formats the file version for display.<p>
  
  @param bean the history resource bean
  
  @return the formatted version