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

Side by Side Diff: third_party/WebKit/Source/platform/loader/fetch/SubstituteData.h

Issue 2761693002: Wrapped PassRefPtrs in move where passed to RefPtr constructor. (Closed)
Patch Set: Added move wraps for multiple instances in 1 line. Created 3 years, 9 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
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2007 Apple Inc. All rights reserved. 2 * Copyright (C) 2007 Apple Inc. All rights reserved.
3 * 3 *
4 * Redistribution and use in source and binary forms, with or without 4 * Redistribution and use in source and binary forms, with or without
5 * modification, are permitted provided that the following conditions 5 * modification, are permitted provided that the following conditions
6 * are met: 6 * are met:
7 * 1. Redistributions of source code must retain the above copyright 7 * 1. Redistributions of source code must retain the above copyright
8 * notice, this list of conditions and the following disclaimer. 8 * notice, this list of conditions and the following disclaimer.
9 * 2. Redistributions in binary form must reproduce the above copyright 9 * 2. Redistributions in binary form must reproduce the above copyright
10 * notice, this list of conditions and the following disclaimer in the 10 * notice, this list of conditions and the following disclaimer in the
(...skipping 30 matching lines...) Expand all
41 41
42 public: 42 public:
43 SubstituteData() : m_substituteDataLoadPolicy(LoadNormally) {} 43 SubstituteData() : m_substituteDataLoadPolicy(LoadNormally) {}
44 44
45 SubstituteData( 45 SubstituteData(
46 PassRefPtr<SharedBuffer> content, 46 PassRefPtr<SharedBuffer> content,
47 const AtomicString& mimeType, 47 const AtomicString& mimeType,
48 const AtomicString& textEncoding, 48 const AtomicString& textEncoding,
49 const KURL& failingURL, 49 const KURL& failingURL,
50 SubstituteDataLoadPolicy substituteDataLoadPolicy = LoadNormally) 50 SubstituteDataLoadPolicy substituteDataLoadPolicy = LoadNormally)
51 : m_content(content), 51 : m_content(std::move(content)),
52 m_mimeType(mimeType), 52 m_mimeType(mimeType),
53 m_textEncoding(textEncoding), 53 m_textEncoding(textEncoding),
54 m_failingURL(failingURL), 54 m_failingURL(failingURL),
55 m_substituteDataLoadPolicy(substituteDataLoadPolicy) {} 55 m_substituteDataLoadPolicy(substituteDataLoadPolicy) {}
56 56
57 bool isValid() const { return m_content.get(); } 57 bool isValid() const { return m_content.get(); }
58 58
59 SharedBuffer* content() const { return m_content.get(); } 59 SharedBuffer* content() const { return m_content.get(); }
60 const AtomicString& mimeType() const { return m_mimeType; } 60 const AtomicString& mimeType() const { return m_mimeType; }
61 const AtomicString& textEncoding() const { return m_textEncoding; } 61 const AtomicString& textEncoding() const { return m_textEncoding; }
62 const KURL& failingURL() const { return m_failingURL; } 62 const KURL& failingURL() const { return m_failingURL; }
63 bool forceSynchronousLoad() const { 63 bool forceSynchronousLoad() const {
64 return m_substituteDataLoadPolicy == ForceSynchronousLoad; 64 return m_substituteDataLoadPolicy == ForceSynchronousLoad;
65 } 65 }
66 66
67 private: 67 private:
68 RefPtr<SharedBuffer> m_content; 68 RefPtr<SharedBuffer> m_content;
69 AtomicString m_mimeType; 69 AtomicString m_mimeType;
70 AtomicString m_textEncoding; 70 AtomicString m_textEncoding;
71 KURL m_failingURL; 71 KURL m_failingURL;
72 SubstituteDataLoadPolicy m_substituteDataLoadPolicy; 72 SubstituteDataLoadPolicy m_substituteDataLoadPolicy;
73 }; 73 };
74 74
75 } // namespace blink 75 } // namespace blink
76 76
77 #endif // SubstituteData_h 77 #endif // SubstituteData_h
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698