public class LinkHighlight extends AbstractHighlight
LinkHighlight.Flavor is a closed set of NO-, PRIMARY-, or SECONDARY- highlighting.
Mod is an open ended set of additional modifications (CSS classes)
that may also be applied.
Note that MOD_OPTICAL and MOD_ANIMATED are pre-defined mods.
Label text may be set, which will also be displayed on the link.| Modifier and Type | Class and Description |
|---|---|
static class |
LinkHighlight.Flavor
Link highlighting flavor.
|
| Modifier and Type | Field and Description |
|---|---|
static Mod |
MOD_ANIMATED
Denotes a link to be tagged with animated traffic ("marching ants").
|
static Mod |
MOD_OPTICAL
Denotes a link to be tagged as an optical link.
|
| Constructor and Description |
|---|
LinkHighlight(String linkId,
LinkHighlight.Flavor flavor)
Constructs a link highlight entity.
|
| Modifier and Type | Method and Description |
|---|---|
LinkHighlight |
addMod(Mod mod)
Adds a highlighting modification to this link highlight.
|
String |
cssClasses()
|
LinkHighlight.Flavor |
flavor()
Returns the highlight flavor.
|
String |
label()
Returns the label text.
|
Set<Mod> |
mods()
Returns the highlight modifications.
|
LinkHighlight |
setLabel(String label)
Adds a label to be displayed on the link.
|
elementId, keepSubdued, subdued, typepublic static final Mod MOD_OPTICAL
public static final Mod MOD_ANIMATED
public LinkHighlight(String linkId, LinkHighlight.Flavor flavor)
linkId - the link identifierflavor - the highlight flavorpublic LinkHighlight addMod(Mod mod)
mod - mod to be addedpublic LinkHighlight setLabel(String label)
label - the label textpublic LinkHighlight.Flavor flavor()
public String cssClasses()
public String label()