Logo Search packages:      
Sourcecode: chromium-browser version File versions  Download package


// Copyright (c) 2010 The Chromium Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.


#include <string>
#include <vector>

#include "googleurl/src/gurl.h"

// Represents the set of URLs an extension uses for web content.
class ExtensionExtent {
  const std::vector<std::string>& paths() const { return paths_; }
  void add_path(const std::string& val) { paths_.push_back(val); }
  void clear_paths() { paths_.clear(); }

  const GURL& origin() const { return origin_; }
  void set_origin(const GURL& val) { origin_ = val; }

  bool ContainsURL(const GURL& url) const;

  // The security origin (scheme+host+port) of the extent.
  GURL origin_;

  // A set of path prefixes that further restrict the set of valid URLs below
  // origin_. This may be empty.
  std::vector<std::string> paths_;


Generated by  Doxygen 1.6.0   Back to index