implemented draft of PICA XML writer