Add UpdateFileOriginMetadata.

PiperOrigin-RevId: 657632869
This commit is contained in:
Francis Tsui
2024-07-30 10:06:40 -07:00
committed by Copybara-Service
parent b77797857b
commit 68d432c5a8
8 changed files with 38 additions and 9 deletions
+8
View File
@@ -15,8 +15,10 @@
#ifndef THIRD_PARTY_NEARBY_SHARING_INTERNAL_API_SHARING_PLATFORM_H_
#define THIRD_PARTY_NEARBY_SHARING_INTERNAL_API_SHARING_PLATFORM_H_
#include <filesystem> // NOLINT
#include <functional>
#include <memory>
#include <vector>
#include "absl/status/status.h"
#include "absl/strings/string_view.h"
@@ -96,6 +98,12 @@ class SharingPlatform {
virtual std::unique_ptr<SharingRpcClientFactory>
CreateSharingRpcClientFactory(
nearby::sharing::analytics::AnalyticsRecorder* analytics_recorder) = 0;
// On platforms where it is supported, tag the transferred files as
// originating from an untrusted source.
// Returns true on success.
virtual bool UpdateFileOriginMetadata(
std::vector<std::filesystem::path>& file_paths) = 0;
};
} // namespace nearby::sharing::api