(PHP 5 >= 5.2.0, PHP 7, PECL zip >= 1.1.0)
  
  
  
  
  
  
   类摘要
   
   
   
    
    
    
    
     
      ZipArchive
     
     {
    
    
    
    
    
    
   public addEmptyDir
    ( 
string $dirname
   [, 
int $flags = 0
  ] ) : 
bool 
   public addFile
    ( 
string $filename
   [, 
string $entryname = NULL
   [, 
int $start = 0
   [, 
int $length = 0
   [, 
int $flags = ZipArchive::FL_OVERWRITE
  ]]]] ) : 
bool 
   public addFromString
    ( 
string $name
   , 
string $contents
   [, 
int $flags = ZipArchive::FL_OVERWRITE
  ] ) : 
bool 
   public addGlob
    ( 
string $pattern
   [, 
int $flags = 0
   [, 
array $options = array()
  ]] ) : 
array 
   public addPattern
    ( 
string $pattern
   [, 
string $path = "."
   [, 
array $options = array()
  ]] ) : 
array 
   public close
    ( 
void
   ) : 
bool 
   public count
    ( 
void
   ) : 
int 
   public getFromIndex
    ( 
int $index
   [, 
int $length = 0
   [, 
int $flags
  ]] ) : 
string 
   public getFromName
    ( 
string $name
   [, 
int $length = 0
   [, 
int $flags
  ]] ) : 
string 
   public locateName
    ( 
string $name
   [, 
int $flags
  ] ) : 
int 
   public open
    ( 
string $filename
   [, 
int $flags
  ] ) : 
mixed 
   public renameIndex
    ( 
int $index
   , 
string $newname
   ) : 
bool 
   public renameName
    ( 
string $name
   , 
string $newname
   ) : 
bool 
   public replaceFile
    ( 
string $filename
   , 
int $index
   [, 
int $start = 0
   [, 
int $length = 0
   [, 
int $flags = 0
  ]]] ) : 
bool 
   public setCompressionName
    ( 
string $name
   , 
int $comp_method
   [, 
int $comp_flags = 0
  ] ) : 
bool 
   public 
   setMtimeIndex
    ( 
int $index
   , 
int $timestamp
   [, 
int $flags
  ] ) : 
bool 
   public 
   setMtimeName
    ( 
string $name
   , 
int $timestamp
   [, 
int $flags
  ] ) : 
bool 
   public statIndex
    ( 
int $index
   [, 
int $flags
  ] ) : 
array 
   public statName
    ( 
string $name
   [, 
int $flags
  ] ) : 
array 
    
   }
 
   
   
   
  
  
  
   属性
   
    
     - status
 
     - 
      
 Zip Archive 的状态
      
    
    
     - statusSys
 
     - 
      
Zip Archive 的系统状态
      
    
    
     - numFiles
 
     - 
      
压缩包里的文件数
      
    
    
     - filename
 
     - 
      
在文件系统里的文件名
      
    
    
     
     - 
      
压缩包的注释