Example usage for org.apache.wicket.util.value IValueMap makeImmutable

List of usage examples for org.apache.wicket.util.value IValueMap makeImmutable

Introduction

In this page you can find the example usage for org.apache.wicket.util.value IValueMap makeImmutable.

Prototype

IValueMap makeImmutable();

Source Link

Document

Makes this IValueMap immutable by changing the underlying map representation to a Collections.unmodifiableMap.

Usage

From source file:sf.wicklet.wicketext.markup.impl.WicketWriter.java

License:Apache License

protected void addAttributes(final IValueMap a, final String wicketid, final String... attrs) {
    if (wicketid != null) {
        a.put("wicket:id", wicketid);
    }/*from www . ja va 2  s .  c  om*/
    for (int i = 0, len = attrs.length; i < len; i += 2) {
        a.put(attrs[i], attrs[i + 1]);
    }
    a.makeImmutable();
}

From source file:sf.wicklet.wicketext.markup.impl.WicketWriter.java

License:Apache License

protected void addAttributes(final IValueMap a, final String wicketid, final Iterable<IAttribute> attrs) {
    if (wicketid != null) {
        a.put("wicket:id", wicketid);
    }/*from  ww  w.j  a v  a 2s. com*/
    for (final IAttribute attr : attrs) {
        a.put(attr.name(), attr.value());
    }
    a.makeImmutable();
}