chromium/components/account_id/account_id.cc

// Copyright 2015 The Chromium Authors
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.

#include "components/account_id/account_id.h"

#include <functional>
#include <memory>

#include "base/json/json_reader.h"
#include "base/json/json_writer.h"
#include "base/logging.h"
#include "base/no_destructor.h"
#include "base/notreached.h"
#include "base/strings/string_util.h"
#include "base/values.h"
#include "google_apis/gaia/gaia_auth_util.h"

namespace {

// Serialization keys
const char kGaiaIdKey[] =;
const char kEmailKey[] =;
const char kObjGuid[] =;
const char kAccountTypeKey[] =;

// Serialization values for account type.
const char kGoogle[] =;
const char kAd[] =;
const char kUnknown[] =;

// Prefix for GetAccountIdKey().
const char kKeyGaiaIdPrefix[] =;
const char kKeyAdIdPrefix[] =;

}  // anonymous namespace

AccountId::AccountId() = default;

AccountId::AccountId(const std::string& id,
                     const std::string& user_email,
                     const AccountType& account_type)
    :{}

AccountId::AccountId(const AccountId& other) = default;

AccountId& AccountId::operator=(const AccountId& other) = default;

bool AccountId::operator==(const AccountId& other) const {}

bool AccountId::operator!=(const AccountId& other) const {}

bool AccountId::operator<(const AccountId& right) const {}

bool AccountId::empty() const {}

bool AccountId::is_valid() const {}

void AccountId::clear() {}

AccountType AccountId::GetAccountType() const {}

const std::string& AccountId::GetGaiaId() const {}

const std::string& AccountId::GetObjGuid() const {}

const std::string& AccountId::GetUserEmail() const {}

bool AccountId::HasAccountIdKey() const {}

const std::string AccountId::GetAccountIdKey() const {}

void AccountId::SetUserEmail(const std::string& email) {}

// static
AccountId AccountId::FromNonCanonicalEmail(const std::string& email,
                                           const std::string& gaia_id,
                                           const AccountType& account_type) {}

// static
AccountId AccountId::FromUserEmail(const std::string& email) {}

// static
AccountId AccountId::FromUserEmailGaiaId(const std::string& email,
                                         const std::string& gaia_id) {}

// static
AccountId AccountId::AdFromUserEmailObjGuid(const std::string& email,
                                            const std::string& obj_guid) {}

// static
AccountType AccountId::StringToAccountType(
    const std::string& account_type_string) {}

// static
std::string AccountId::AccountTypeToString(const AccountType& account_type) {}

std::string AccountId::Serialize() const {}

// static
bool AccountId::Deserialize(const std::string& serialized,
                            AccountId* account_id) {}

std::ostream& operator<<(std::ostream& stream, const AccountId& account_id) {}

const AccountId& EmptyAccountId() {}

namespace std {

std::size_t hash<AccountId>::operator()(const AccountId& user_id) const {}

}  // namespace std