code: public static <E extends Enum<? extends Style.HasCssName>> void removeEnumStyleNames(final UIObject uiObject,
                                                                                           final Class<E> enumClass) {
  
          for (final Enum<? extends Style.HasCssName> constant : enumClass.getEnumConstants()) {
              final String cssClass = ((Style.HasCssName) constant).getCssName();
  
              if (cssClass != null && !cssClass.isEmpty()) {
                  uiObject.removeStyleName(cssClass);
              }
          }
      }
docs: Removes all CSS style names specified by an enum that implements {@link Style.HasCssName} from an UIObject.
  
  @param uiObject  Object to remove CSS class names from
  @param enumClass Enum representing CSS class names
  @param <E>       Enum type implementing {@link Style.HasCssName}