FileDocCategorySizeDatePackage
CollectionAdapter.javaAPI DocExample2085Mon Jul 23 13:26:44 BST 2007org.apache.struts2.views.xslt

CollectionAdapter

public class CollectionAdapter extends AbstractAdapterElement

Fields Summary
private Log
log
Constructors Summary
public CollectionAdapter()


       
public CollectionAdapter(AdapterFactory rootAdapterFactory, AdapterNode parent, String propertyName, Object value)

        setContext(rootAdapterFactory, parent, propertyName, value);
    
Methods Summary
protected java.util.ListbuildChildAdapters()

        Collection values = (Collection) getPropertyValue();
        List<Node> children = new ArrayList<Node>(values.size());

        for (Object value : values) {
            Node childAdapter = getAdapterFactory().adaptNode(this, "item", value);
            if (childAdapter != null)
                children.add(childAdapter);

            if (log.isDebugEnabled()) {
                log.debug(this + " adding adapter: " + childAdapter);
            }
        }

        return children;