package leigh.mecha.olap.xmla;

import leigh.eo.EO;
import leigh.eo.EOLoop;

import javax.xml.stream.XMLStreamException;

public class XmlaUtil {

    public static void drain(EO dst, String key, XmlaResultSet rs) throws XMLStreamException {
        EOLoop loop = new EOLoop();
        while (rs.next()) {
            loop.add(rs.getRow());
        }
        dst.setValue(key, loop);
    }
}
