#include "extensions/common/url_pattern_set.h"
#include <iterator>
#include <ostream>
#include "base/containers/contains.h"
#include "base/logging.h"
#include "base/stl_util.h"
#include "extensions/common/error_utils.h"
#include "extensions/common/url_pattern.h"
#include "url/gurl.h"
#include "url/origin.h"
#include "url/url_constants.h"
namespace extensions {
namespace {
const char kInvalidURLPatternError[] = …;
}
URLPatternSet URLPatternSet::CreateDifference(const URLPatternSet& set1,
const URLPatternSet& set2) { … }
URLPatternSet URLPatternSet::CreateIntersection(
const URLPatternSet& set1,
const URLPatternSet& set2,
IntersectionBehavior intersection_behavior) { … }
URLPatternSet URLPatternSet::CreateUnion(const URLPatternSet& set1,
const URLPatternSet& set2) { … }
URLPatternSet::URLPatternSet() = default;
URLPatternSet::URLPatternSet(URLPatternSet&& rhs) = default;
URLPatternSet::URLPatternSet(const std::set<URLPattern>& patterns)
: … { … }
URLPatternSet::~URLPatternSet() = default;
URLPatternSet& URLPatternSet::operator=(URLPatternSet&& rhs) = default;
bool URLPatternSet::operator==(const URLPatternSet& other) const { … }
std::ostream& operator<<(std::ostream& out,
const URLPatternSet& url_pattern_set) { … }
URLPatternSet URLPatternSet::Clone() const { … }
bool URLPatternSet::is_empty() const { … }
size_t URLPatternSet::size() const { … }
bool URLPatternSet::AddPattern(const URLPattern& pattern) { … }
void URLPatternSet::AddPatterns(const URLPatternSet& set) { … }
void URLPatternSet::ClearPatterns() { … }
bool URLPatternSet::AddOrigin(int valid_schemes, const GURL& origin) { … }
bool URLPatternSet::AddOrigin(int valid_schemes, const url::Origin& origin) { … }
bool URLPatternSet::Contains(const URLPatternSet& other) const { … }
bool URLPatternSet::ContainsPattern(const URLPattern& pattern) const { … }
bool URLPatternSet::MatchesURL(const GURL& url) const { … }
bool URLPatternSet::MatchesAllURLs() const { … }
bool URLPatternSet::MatchesHost(const GURL& test,
bool require_match_subdomains) const { … }
bool URLPatternSet::MatchesSecurityOrigin(const GURL& origin) const { … }
bool URLPatternSet::OverlapsWith(const URLPatternSet& other) const { … }
base::Value::List URLPatternSet::ToValue() const { … }
bool URLPatternSet::Populate(const std::vector<std::string>& patterns,
int valid_schemes,
bool allow_file_access,
std::string* error) { … }
std::vector<std::string> URLPatternSet::ToStringVector() const { … }
bool URLPatternSet::Populate(const base::Value::List& value,
int valid_schemes,
bool allow_file_access,
std::string* error) { … }
}