org.gwtbootstrap3.client.ui.base.helper
Class EnumHelper

java.lang.Object
  extended by org.gwtbootstrap3.client.ui.base.helper.EnumHelper

public final class EnumHelper
extends Object

Author:
Sven Jacobs

Method Summary
static
<E extends Enum<? extends Style.HasCssName>>
E
fromStyleName(String styleName, Class<E> enumClass, E defaultValue)
          Returns first enum constant found in at space-separated list of style names.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Method Detail

fromStyleName

public static <E extends Enum<? extends Style.HasCssName>> E fromStyleName(String styleName,
                                                                           Class<E> enumClass,
                                                                           E defaultValue)
Returns first enum constant found in at space-separated list of style names.

Type Parameters:
E -
Parameters:
styleName - Space-separated list of styles
enumClass - Type of enum
defaultValue - Default value of no match was found
Returns:
First enum constant found or default value


Copyright © 2015. All rights reserved.