public class SimpleIconSet extends Object implements MutableIconSet
SimpleIconSet that is made available on an IconSetRegistry| Constructor and Description |
|---|
SimpleIconSet() |
| Modifier and Type | Method and Description |
|---|---|
void |
add(@NonNull String name,
Function<String,com.foreach.across.modules.web.ui.elements.HtmlViewElement> iconResolver)
Adds an icon to the
MutableIconSet. |
Map<String,com.foreach.across.modules.web.ui.elements.HtmlViewElement> |
getAllRegisteredIcons()
Gets a map of all registered icons on the
IconSet. |
com.foreach.across.modules.web.ui.elements.HtmlViewElement |
icon(String name)
Returns an icon with from the current
SimpleIconSet. |
void |
remove(@NonNull String name)
Removes an icon from the
MutableIconSet. |
void |
removeAll()
Remove all icons from the
MutableIconSet. |
void |
setDefaultIconResolver(Function<String,com.foreach.across.modules.web.ui.elements.HtmlViewElement> defaultIconResolver) |
public com.foreach.across.modules.web.ui.elements.HtmlViewElement icon(String name)
IconSetSimpleIconSet. If no iconResolver function was registered for the requested icon, a fallback to the
defaultIconResolver is used.icon in interface IconSetname - of the icon in the SimpleIconSetAbstractNodeViewElementpublic Map<String,com.foreach.across.modules.web.ui.elements.HtmlViewElement> getAllRegisteredIcons()
IconSetIconSet.getAllRegisteredIcons in interface IconSetMap<String, AbstractNodeViewElement> that holds all icons by namepublic void add(@NonNull
@NonNull String name,
Function<String,com.foreach.across.modules.web.ui.elements.HtmlViewElement> iconResolver)
MutableIconSetMutableIconSet.add in interface MutableIconSetname - of the icon to add to the current MutableIconSet.iconResolver - that will be used to resolve a AbstractNodeViewElement iconpublic void remove(@NonNull
@NonNull String name)
MutableIconSetMutableIconSet.remove in interface MutableIconSetname - of the icon to be removedpublic void removeAll()
MutableIconSetMutableIconSet.removeAll in interface MutableIconSetCopyright © 2020. All rights reserved.