added emit filter to XML generation