{
String filter_name=node.getString("filter-name",false,true);
FilterMapping mapping = new FilterMapping();
mapping.setFilterName(filter_name);
ArrayList paths = new ArrayList();
Iterator iter=node.iterator("url-pattern");
while(iter.hasNext())
{
String p=((XmlParser.Node)iter.next()).toString(false,true);
p=normalizePattern(p);
paths.add(p);
}
mapping.setPathSpecs((String[])paths.toArray(new String[paths.size()]));
ArrayList names = new ArrayList();
iter=node.iterator("servlet-name");
while(iter.hasNext())
{
String n=((XmlParser.Node)iter.next()).toString(false,true);
names.add(n);
}
mapping.setServletNames((String[])names.toArray(new String[names.size()]));
int dispatcher=Handler.DEFAULT;
iter=node.iterator("dispatcher");
while(iter.hasNext())
{
String d=((XmlParser.Node)iter.next()).toString(false,true);
dispatcher|=Dispatcher.type(d);
}
mapping.setDispatches(dispatcher);
_filterMappings=LazyList.add(_filterMappings,mapping);
}