#include "third_party/blink/renderer/core/frame/navigator_ua_data.h"
#include "base/compiler_specific.h"
#include "base/task/single_thread_task_runner.h"
#include "third_party/blink/public/common/features.h"
#include "third_party/blink/public/common/privacy_budget/identifiability_metric_builder.h"
#include "third_party/blink/public/common/privacy_budget/identifiability_study_settings.h"
#include "third_party/blink/public/common/privacy_budget/identifiable_surface.h"
#include "third_party/blink/public/common/privacy_budget/identifiable_token.h"
#include "third_party/blink/public/common/privacy_budget/identifiable_token_builder.h"
#include "third_party/blink/public/mojom/use_counter/metrics/web_feature.mojom-blink.h"
#include "third_party/blink/renderer/bindings/core/v8/script_promise_resolver.h"
#include "third_party/blink/renderer/bindings/core/v8/v8_ua_data_values.h"
#include "third_party/blink/renderer/core/execution_context/execution_context.h"
#include "third_party/blink/renderer/core/frame/dactyloscoper.h"
#include "third_party/blink/renderer/core/frame/web_feature_forward.h"
#include "third_party/blink/renderer/core/page/page.h"
namespace blink {
namespace {
void MaybeRecordMetric(bool record_identifiability,
const String& hint,
const IdentifiableToken token,
ExecutionContext* execution_context) { … }
void MaybeRecordMetric(bool record_identifiability,
const String& hint,
const String& value,
ExecutionContext* execution_context) { … }
void MaybeRecordMetric(bool record_identifiability,
const String& hint,
const Vector<String>& strings,
ExecutionContext* execution_context) { … }
}
NavigatorUAData::NavigatorUAData(ExecutionContext* context)
: … { … }
void NavigatorUAData::AddBrandVersion(const String& brand,
const String& version) { … }
void NavigatorUAData::AddBrandFullVersion(const String& brand,
const String& version) { … }
void NavigatorUAData::SetBrandVersionList(
const UserAgentBrandList& brand_version_list) { … }
void NavigatorUAData::SetFullVersionList(
const UserAgentBrandList& full_version_list) { … }
void NavigatorUAData::SetMobile(bool mobile) { … }
void NavigatorUAData::SetPlatform(const String& brand, const String& version) { … }
void NavigatorUAData::SetArchitecture(const String& architecture) { … }
void NavigatorUAData::SetModel(const String& model) { … }
void NavigatorUAData::SetUAFullVersion(const String& ua_full_version) { … }
void NavigatorUAData::SetBitness(const String& bitness) { … }
void NavigatorUAData::SetWoW64(bool wow64) { … }
void NavigatorUAData::SetFormFactors(Vector<String> form_factors) { … }
bool NavigatorUAData::mobile() const { … }
const HeapVector<Member<NavigatorUABrandVersion>>& NavigatorUAData::brands()
const { … }
const String& NavigatorUAData::platform() const { … }
ScriptPromise<UADataValues> NavigatorUAData::getHighEntropyValues(
ScriptState* script_state,
Vector<String>& hints) const { … }
ScriptValue NavigatorUAData::toJSON(ScriptState* script_state) const { … }
void NavigatorUAData::Trace(Visitor* visitor) const { … }
}