|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object org.apache.wicket.markup.Markup
public class Markup
The content of a markup file, consisting of a list of markup elements.
MarkupResourceStream
,
MarkupElement
,
ComponentTag
,
RawMarkup
Field Summary | |
---|---|
static Markup |
NO_MARKUP
Placeholder that indicates no markup |
Constructor Summary | |
---|---|
Markup(MarkupResourceStream markupResourceStream)
Constructor |
Method Summary | |
---|---|
void |
addMarkupElement(int pos,
MarkupElement markupElement)
Add a MarkupElement |
void |
addMarkupElement(MarkupElement markupElement)
Add a MarkupElement |
IMarkupFragment |
find(String id)
Find the markup fragment of the component with 'path' |
MarkupElement |
get(int index)
Get the MarkupElement at the index provided. |
MarkupResourceStream |
getMarkupResourceStream()
Get the underlying markup resource stream, which might contain more than just the markup portion represented by the IMarkupFragment. |
Iterator<MarkupElement> |
iterator()
|
Iterator<MarkupElement> |
iterator(int startIndex,
int size)
|
String |
locationAsString()
|
void |
makeImmutable()
Make all tags immutable and the list of elements unmodifiable. |
static Markup |
of(String markup)
Take the markup string, parse it and return the Markup (list of MarkupElements). |
void |
replace(int index,
MarkupElement elem)
|
int |
size()
The number of markup elements. |
String |
toString()
|
String |
toString(boolean markupOnly)
|
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Field Detail |
---|
public static final Markup NO_MARKUP
Constructor Detail |
---|
public Markup(MarkupResourceStream markupResourceStream)
markupResourceStream
- The associated MarkupMethod Detail |
---|
public static Markup of(String markup)
Limitation: Please note that MarkupFactory is NOT used and thus no caching is used (which doesn't matter for Strings anyway), but what might matter is that your own MarkupFilters are not applied, which you might have registered with MarkupFactory.
markup
-
public final MarkupElement get(int index)
IMarkupFragment
get
in interface IMarkupFragment
index
- Index into markup list
public final MarkupResourceStream getMarkupResourceStream()
IMarkupFragment
getMarkupResourceStream
in interface IMarkupFragment
public final void replace(int index, MarkupElement elem)
index
- elem
- public String locationAsString()
public final int size()
IMarkupFragment
size
in interface IMarkupFragment
public final void addMarkupElement(MarkupElement markupElement)
markupElement
- public final void addMarkupElement(int pos, MarkupElement markupElement)
pos
- markupElement
- public final void makeImmutable()
public final IMarkupFragment find(String id)
IMarkupFragment
find
in interface IMarkupFragment
id
- The component's id to search for
public final String toString()
toString
in class Object
public final String toString(boolean markupOnly)
toString
in interface IMarkupFragment
markupOnly
- True, if only the markup shall be returned
public final Iterator<MarkupElement> iterator()
iterator
in interface Iterable<MarkupElement>
Iterable.iterator()
public final Iterator<MarkupElement> iterator(int startIndex, int size)
startIndex
- size
-
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |