1<?php
2
3namespace FINDOLOGIC\Export\Helpers;
4
5/**
6 * Data that is serializable as CSV or XML.
7 */
8interface Serializable
9{
10    /**
11     * @param \DOMDocument The document to work with. It should be passed along if getDomDocument of other objects is
12     *      called. It should not be modified, unless at the root!
13     * @return \DOMElement The root element of whatever was generated.
14     */
15    public function getDomSubtree(\DOMDocument $document);
16
17    /**
18     * @return string A CSV fragment that, combined with other fragments, will finally become an export file.
19     */
20    public function getCsvFragment();
21}
22