Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(147)

Side by Side Diff: content/public/browser/site_instance.h

Issue 11000027: Rename GetSite in SiteInstance to GetSiteURL. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 8 years, 2 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « content/browser/web_contents/web_contents_impl.cc ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #ifndef CONTENT_PUBLIC_BROWSER_SITE_INSTANCE_H_ 5 #ifndef CONTENT_PUBLIC_BROWSER_SITE_INSTANCE_H_
6 #define CONTENT_PUBLIC_BROWSER_SITE_INSTANCE_H_ 6 #define CONTENT_PUBLIC_BROWSER_SITE_INSTANCE_H_
7 7
8 #include "base/basictypes.h" 8 #include "base/basictypes.h"
9 #include "base/memory/ref_counted.h" 9 #include "base/memory/ref_counted.h"
10 #include "content/common/content_export.h" 10 #include "content/common/content_export.h"
(...skipping 50 matching lines...) Expand 10 before | Expand all | Expand 10 after
61 // SiteInstance. If the process has crashed or otherwise gone away, then 61 // SiteInstance. If the process has crashed or otherwise gone away, then
62 // this method will create a new process and update our host ID accordingly. 62 // this method will create a new process and update our host ID accordingly.
63 virtual content::RenderProcessHost* GetProcess() = 0; 63 virtual content::RenderProcessHost* GetProcess() = 0;
64 64
65 // Browser context to which this SiteInstance (and all related 65 // Browser context to which this SiteInstance (and all related
66 // SiteInstances) belongs. 66 // SiteInstances) belongs.
67 virtual content::BrowserContext* GetBrowserContext() const = 0; 67 virtual content::BrowserContext* GetBrowserContext() const = 0;
68 68
69 // Get the web site that this SiteInstance is rendering pages for. 69 // Get the web site that this SiteInstance is rendering pages for.
70 // This includes the scheme and registered domain, but not the port. 70 // This includes the scheme and registered domain, but not the port.
71 virtual const GURL& GetSite() const = 0; 71 virtual const GURL& GetSiteURL() const = 0;
72 72
73 // Gets a SiteInstance for the given URL that shares the current 73 // Gets a SiteInstance for the given URL that shares the current
74 // BrowsingInstance, creating a new SiteInstance if necessary. This ensures 74 // BrowsingInstance, creating a new SiteInstance if necessary. This ensures
75 // that a BrowsingInstance only has one SiteInstance per site, so that pages 75 // that a BrowsingInstance only has one SiteInstance per site, so that pages
76 // in a BrowsingInstance have the ability to script each other. Callers 76 // in a BrowsingInstance have the ability to script each other. Callers
77 // should ensure that this SiteInstance becomes ref counted, by storing it in 77 // should ensure that this SiteInstance becomes ref counted, by storing it in
78 // a scoped_refptr. (By having this method, we can hide the BrowsingInstance 78 // a scoped_refptr. (By having this method, we can hide the BrowsingInstance
79 // class from the rest of the codebase.) 79 // class from the rest of the codebase.)
80 // TODO(creis): This may be an argument to build a pass_refptr<T> class, as 80 // TODO(creis): This may be an argument to build a pass_refptr<T> class, as
81 // Darin suggests. 81 // Darin suggests.
(...skipping 35 matching lines...) Expand 10 before | Expand all | Expand 10 after
117 protected: 117 protected:
118 friend class base::RefCounted<SiteInstance>; 118 friend class base::RefCounted<SiteInstance>;
119 119
120 SiteInstance() {} 120 SiteInstance() {}
121 virtual ~SiteInstance() {} 121 virtual ~SiteInstance() {}
122 }; 122 };
123 123
124 } // namespace content. 124 } // namespace content.
125 125
126 #endif // CONTENT_PUBLIC_BROWSER_SITE_INSTANCE_H_ 126 #endif // CONTENT_PUBLIC_BROWSER_SITE_INSTANCE_H_
OLDNEW
« no previous file with comments | « content/browser/web_contents/web_contents_impl.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698