make di easy

move $document argument in DocumentWriter from constructor to write
method
add default filename