| OLD | NEW |
| 1 // Copyright (c) 2010 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2010 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 NET_PROXY_PROXY_RESOLVER_SCRIPT_DATA_H_ | 5 #ifndef NET_PROXY_PROXY_RESOLVER_SCRIPT_DATA_H_ |
| 6 #define NET_PROXY_PROXY_RESOLVER_SCRIPT_DATA_H_ | 6 #define NET_PROXY_PROXY_RESOLVER_SCRIPT_DATA_H_ |
| 7 #pragma once | 7 #pragma once |
| 8 | 8 |
| 9 #include "base/ref_counted.h" | 9 #include "base/ref_counted.h" |
| 10 #include "base/string16.h" | 10 #include "base/string16.h" |
| (...skipping 36 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 47 | 47 |
| 48 // Returns the contents of the script as UTF16. | 48 // Returns the contents of the script as UTF16. |
| 49 // (only valid for type() == TYPE_SCRIPT_CONTENTS). | 49 // (only valid for type() == TYPE_SCRIPT_CONTENTS). |
| 50 const string16& utf16() const; | 50 const string16& utf16() const; |
| 51 | 51 |
| 52 // Returns the URL of the script. | 52 // Returns the URL of the script. |
| 53 // (only valid for type() == TYPE_SCRIPT_URL). | 53 // (only valid for type() == TYPE_SCRIPT_URL). |
| 54 const GURL& url() const; | 54 const GURL& url() const; |
| 55 | 55 |
| 56 private: | 56 private: |
| 57 friend class base::RefCountedThreadSafe<ProxyResolverScriptData>; |
| 57 ProxyResolverScriptData(Type type, | 58 ProxyResolverScriptData(Type type, |
| 58 const GURL& url, | 59 const GURL& url, |
| 59 const string16& utf16) | 60 const string16& utf16); |
| 60 : type_(type), | 61 virtual ~ProxyResolverScriptData(); |
| 61 url_(url), | 62 |
| 62 utf16_(utf16) { | |
| 63 } | |
| 64 | 63 |
| 65 const Type type_; | 64 const Type type_; |
| 66 const GURL url_; | 65 const GURL url_; |
| 67 const string16 utf16_; | 66 const string16 utf16_; |
| 68 }; | 67 }; |
| 69 | 68 |
| 70 } // namespace net | 69 } // namespace net |
| 71 | 70 |
| 72 #endif // NET_PROXY_PROXY_RESOLVER_SCRIPT_DATA_H_ | 71 #endif // NET_PROXY_PROXY_RESOLVER_SCRIPT_DATA_H_ |
| OLD | NEW |