|
Android-cuttlefish cvd tool
|
#include <build_archive.h>
Public Member Functions | |
| const std::set< std::string, std::less< void > > & | Members () const |
| Result< std::string > | MemberFilepath (std::string_view member_name, std::optional< std::string_view > extract_dir) |
| Result< std::string > | MemberContents (std::string_view name) |
Static Public Member Functions | |
| static Result< BuildArchive > | FromFetcherConfig (const FetcherConfig &, FileSource, std::string_view archive_name) |
| static Result< BuildArchive > | FromZip (ReadableZip) |
| static Result< BuildArchive > | FromZipPath (const std::string &) |
Private Member Functions | |
| BuildArchive (std::optional< FileSource >, std::map< std::string, std::string, std::less< void > >, std::set< std::string, std::less< void > >, std::optional< ReadableZip >) | |
Private Attributes | |
| std::optional< FileSource > | source_ |
| std::map< std::string, std::string, std::less< void > > | extracted_ |
| std::set< std::string, std::less< void > > | members_ |
| std::optional< ReadableZip > | zip_file_ |
Friends | |
| PrettyStruct | Pretty (const BuildArchive &, PrettyAdlPlaceholder unused) |
An archive that was downloaded by cvd fetch or created by a build system runnning locally.
The archive may be partially or completely extracted, and the archive may have been deleted as part of the fetch process, leaving only extracted files.
|
private |
|
static |
|
static |
|
static |
| Result< std::string > cuttlefish::BuildArchive::MemberContents | ( | std::string_view | name | ) |
| Result< std::string > cuttlefish::BuildArchive::MemberFilepath | ( | std::string_view | member_name, |
| std::optional< std::string_view > | extract_dir | ||
| ) |
Returns the file path to a member of the archive, extracted on the filesystem. If the member is not already extracted and the archive is present, it will extract the file into extract_dir.
Error conditions:
member_name.extract_dir was not present.| const std::set< std::string, std::less< void > > & cuttlefish::BuildArchive::Members | ( | ) | const |
Returns the filenames of the members held in the archive.
If a subset of the archive members were extracted and the archive was deleted, this may be incomplete.
|
friend |
|
private |
|
private |
|
private |
|
private |