Icons.Icon| Modifier and Type | Field and Description |
|---|---|
protected com.google.common.cache.LoadingCache<java.lang.String,java.lang.String> |
iconsCache |
protected java.util.List<java.lang.Class<? extends Icons.Icon>> |
iconSets |
protected ThemeConstantsManager |
themeConstantsManager |
ICON_NAME_REGEX, NAME| Constructor and Description |
|---|
IconsImpl() |
| Modifier and Type | Method and Description |
|---|---|
java.lang.String |
get(Icons.Icon icon)
For the given
Icons.Icon instance, returns the icon source that can be used to set this icon to components. |
java.lang.String |
get(java.lang.String icon)
For the given
Icons.Icon.iconName(), returns the icon source that can be used to set this icon to components. |
protected java.lang.String |
getThemeIcon(java.lang.String iconName) |
void |
init() |
protected java.lang.String |
resolveIcon(java.lang.String iconName) |
@Inject protected ThemeConstantsManager themeConstantsManager
protected com.google.common.cache.LoadingCache<java.lang.String,java.lang.String> iconsCache
protected java.util.List<java.lang.Class<? extends Icons.Icon>> iconSets
@EventListener(value=AppContextInitializedEvent.class) @Order(value=200) public void init()
public java.lang.String get(@Nullable
Icons.Icon icon)
IconsIcons.Icon instance, returns the icon source that can be used to set this icon to components.
Example:
createButton.setIcon(icons.get(CubaIcon.CREATE));
get in interface Iconsicon - Icons.Icon instanceIcons.Icon.source())public java.lang.String get(@Nullable
java.lang.String icon)
IconsIcons.Icon.iconName(), returns the icon source that can be used to set this icon to components.
Example:
importButton.setIcon(icons.get("IMPORT"));
get in interface Iconsicon - icon name that contains only uppercase letters and underscoresIcons.Icon.source())protected java.lang.String getThemeIcon(java.lang.String iconName)
protected java.lang.String resolveIcon(java.lang.String iconName)