<?php
namespace lib\excel;
/**
* 消息队列
* @version 1.0.0
*/
interface excelInterface
{
    //固定内存模式
    public function setConstMemory(bool $constMemory):excelInterface;
    public function setDirFile(string $fullfilename):excelInterface;
    public function setDir(string $dirname):excelInterface;
    public function setFile(string $filename):excelInterface;
    public function setStream($fp, string $filename):excelInterface;
    public function formatSheetName(string $sheetName):string;
    public function formatFileName(string $filename):string;
    public function header(string $outFilename=''):excelInterface;
    public function bookBegin():excelInterface;
    public function bookEnd();
    public function sheetBegin(string $sheetName, array $headerRow=[], array $columnStyle=[]):excelInterface;
    public function sheetEnd():excelInterface;
    public function append(array $row=[]):excelInterface;
    /** 回调读取 
    * @param function $callback 回调函数原型 function ($row, $col, $data)
    * @remark
    */
    public function each($callback,$sheetName=null);
    public function toArray($types=[]):array;
    public function toCsv($dist):bool;
    public function zipFile(array $filelist,string $zipfile, bool $isDelete=true):excelInterface;
}