Google OR-Tools v9.11
a fast and portable software suite for combinatorial optimization
Loading...
Searching...
No Matches
zipfile.cc
Go to the documentation of this file.
1// Copyright 2010-2024 Google LLC
2// Licensed under the Apache License, Version 2.0 (the "License");
3// you may not use this file except in compliance with the License.
4// You may obtain a copy of the License at
5//
6// http://www.apache.org/licenses/LICENSE-2.0
7//
8// Unless required by applicable law or agreed to in writing, software
9// distributed under the License is distributed on an "AS IS" BASIS,
10// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
11// See the License for the specific language governing permissions and
12// limitations under the License.
13
14// The zip file is treated a single-level read-only directory.
15// The subfiles that when unzipped would be directories
16// appear to File as zero-length files.
17// This implementation supports only uncompressed and deflate-compressed
18// content (compression method == 8).
19
21
22#include "absl/strings/string_view.h"
23#include "ortools/base/file.h"
25#include "zlib.h"
26
27namespace zipfile {
28
29class ZipFile;
30class ZipArchive;
31
32std::shared_ptr<ZipArchive> OpenZipArchive(absl::string_view path,
33 const ZipFileOptions& options) {
34 // unimplemented
35 LOG(INFO) << "not implemented";
36 return nullptr;
37}
38
39ZipArchive::ZipArchive(absl::string_view path, const ZipFileOptions& options)
40 : filename_(path), options_(options) {}
41
43
44} // namespace zipfile
ZipArchive(absl::string_view path, const ZipFileOptions &options)
Definition zipfile.cc:39
std::shared_ptr< ZipArchive > OpenZipArchive(absl::string_view path, const ZipFileOptions &options)
Definition zipfile.cc:32