|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectorg.hd.d.pg2k.webSvr.util.Breadcrumbs
public final class Breadcrumbs
Holds the data corresponding to a breadcrumbs navigation aid on a Web page. This consists of a list of text/hyperlink pairs, running from the largest/outermost part of the Website first, to the innermost part (corresponding to that nearest the current page) last.
It is possible to insert items at start or end, though most efficient to insert at the end.
It is possible to insert items with no link, but not with no text.
This can export a read-only view of its content as a List.
This is thread-safe and Serializable so as to be able to be stored in a servlet session; nothing especially long-lived or sensitive.
| Nested Class Summary | |
|---|---|
static class |
Breadcrumbs.Breadcrumb
One item in the breadcrumbs. |
| Field Summary | |
|---|---|
private java.util.List<Breadcrumbs.Breadcrumb> |
crumbs
This is our list of breadcrumbs, in order. |
private static long |
serialVersionUID
Unique Serialisation class ID generated by http://random.hd.org/. |
| Constructor Summary | |
|---|---|
Breadcrumbs()
|
|
| Method Summary | |
|---|---|
void |
append(Breadcrumbs.Breadcrumb crumbForEnd)
Appends crumb (to end of list). |
void |
clear()
Removes all of the crumbs. |
Breadcrumbs.Breadcrumb |
getCrumb(int index)
Get specified crumb by its index. |
boolean |
isEmpty()
Returns true if there are no breadcrumbs. |
void |
prepend(Breadcrumbs.Breadcrumb crumbForStart)
Prepends crumb (to start of list). |
int |
size()
Returns the number of crumbs. |
java.util.List<Breadcrumbs.Breadcrumb> |
viewAsList()
Returns read-only view of the crumbs as a List. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
private final java.util.List<Breadcrumbs.Breadcrumb> crumbs
We expect that usually we will have no more than about four crumbs, and so default to that size.
private static final long serialVersionUID
| Constructor Detail |
|---|
public Breadcrumbs()
| Method Detail |
|---|
public java.util.List<Breadcrumbs.Breadcrumb> viewAsList()
public boolean isEmpty()
public int size()
public void clear()
public void append(Breadcrumbs.Breadcrumb crumbForEnd)
public void prepend(Breadcrumbs.Breadcrumb crumbForStart)
public Breadcrumbs.Breadcrumb getCrumb(int index)
throws java.lang.IndexOutOfBoundsException
java.lang.IndexOutOfBoundsException - if the index is invalid
|
DHD Multimedia Gallery V1.53.0 | ||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||