Zip archive.  
 More...
#include <zip_archive.h>
◆ ZipArchive() [1/4]
      
        
          | clan::ZipArchive::ZipArchive | ( |  | ) |  | 
      
 
Constructs or loads a ZIP archive. 
- Parameters
- 
  
    | filename | .zip archive to load. |  
 
 
 
◆ ZipArchive() [2/4]
      
        
          | clan::ZipArchive::ZipArchive | ( | IODevice & | input | ) |  | 
      
 
 
◆ ZipArchive() [3/4]
      
        
          | clan::ZipArchive::ZipArchive | ( | const std::string & | filename | ) |  | 
      
 
 
◆ ZipArchive() [4/4]
      
        
          | clan::ZipArchive::ZipArchive | ( | const ZipArchive & | copy | ) |  | 
      
 
 
◆ ~ZipArchive()
      
        
          | clan::ZipArchive::~ZipArchive | ( |  | ) |  | 
      
 
 
◆ add_file()
      
        
          | void clan::ZipArchive::add_file | ( | const std::string & | input_filename, | 
        
          |  |  | const std::string & | filename_in_archive ) | 
      
 
Adds a file to zip archive. 
File is not added to zip file until it save() is called.
- Parameters
- 
  
    | filename | Filename of file. |  
 
 
 
◆ create_file()
      
        
          | IODevice clan::ZipArchive::create_file | ( | const std::string & | filename, | 
        
          |  |  | bool | compress = true ) | 
      
 
Creates a new file entry. 
 
 
◆ get_file_list() [1/2]
      
        
          | std::vector< ZipFileEntry > clan::ZipArchive::get_file_list | ( |  | ) |  | 
      
 
List of file entries in archive. 
 
 
◆ get_file_list() [2/2]
      
        
          | std::vector< ZipFileEntry > clan::ZipArchive::get_file_list | ( | const std::string & | path | ) |  | 
      
 
 
◆ get_pathname()
      
        
          | std::string clan::ZipArchive::get_pathname | ( | const std::string & | filename | ) |  | 
      
 
 
◆ load()
      
        
          | void clan::ZipArchive::load | ( | IODevice & | input | ) |  | 
      
 
Loads the zip archive from a input device (done automatically at construction). 
 
 
◆ open_file()
      
        
          | IODevice clan::ZipArchive::open_file | ( | const std::string & | filename | ) |  | 
      
 
Opens a file in the archive. 
 
 
◆ save() [1/3]
      
        
          | void clan::ZipArchive::save | ( |  | ) |  | 
      
 
Saves zip archive. 
- Parameters
- 
  
    | filename | Filename of zip archive. Must not be used to save to the same as loaded from. |  
 
If no filename parameter was passed, it will modify the zip archive loaded at construction time. It does this by creating a temporary file, saving the new archive, deletes the old one and renames the temp file to the original archive filename.
If the archive was created instead of loaded, a filename must be specify a filename. Likewise, if saving to same archive as loaded from, a filename must not be specified. Doing so will cause the save operation to fail.
 
 
◆ save() [2/3]
      
        
          | void clan::ZipArchive::save | ( | const std::string & | filename | ) |  | 
      
 
Save. 
- Parameters
- 
  
    | filename | = the filename to save to |  
 
 
 
◆ save() [3/3]
      
        
          | void clan::ZipArchive::save | ( | IODevice | iodev | ) |  | 
      
 
Save. 
- Parameters
- 
  
    | iodev | = The file to save to |  
 
 
 
The documentation for this class was generated from the following file: