| OLD | NEW |
| 1 // Copyright 2015 The Chromium Authors. All rights reserved. | 1 // Copyright 2015 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 URLSearchParams_h | 5 #ifndef URLSearchParams_h |
| 6 #define URLSearchParams_h | 6 #define URLSearchParams_h |
| 7 | 7 |
| 8 #include "bindings/core/v8/Iterable.h" | 8 #include "bindings/core/v8/Iterable.h" |
| 9 #include "bindings/core/v8/ScriptWrappable.h" | 9 #include "bindings/core/v8/ScriptWrappable.h" |
| 10 #include "bindings/core/v8/UnionTypesCore.h" | 10 #include "bindings/core/v8/UnionTypesCore.h" |
| (...skipping 28 matching lines...) Expand all Loading... |
| 39 void append(const String& name, const String& value); | 39 void append(const String& name, const String& value); |
| 40 void deleteAllWithName(const String&); | 40 void deleteAllWithName(const String&); |
| 41 String get(const String&) const; | 41 String get(const String&) const; |
| 42 Vector<String> getAll(const String&) const; | 42 Vector<String> getAll(const String&) const; |
| 43 bool has(const String&) const; | 43 bool has(const String&) const; |
| 44 void set(const String& name, const String& value); | 44 void set(const String& name, const String& value); |
| 45 void setInput(const String&); | 45 void setInput(const String&); |
| 46 | 46 |
| 47 // Internal helpers | 47 // Internal helpers |
| 48 PassRefPtr<EncodedFormData> encodeFormData() const; | 48 PassRefPtr<EncodedFormData> encodeFormData() const; |
| 49 const Vector<std::pair<String, String>>& params() const { return m_params; } |
| 49 | 50 |
| 50 DECLARE_TRACE(); | 51 DECLARE_TRACE(); |
| 51 | 52 |
| 52 private: | 53 private: |
| 53 friend class URLSearchParamsTest_EncodedFormData_Test; | 54 friend class URLSearchParamsTest_EncodedFormData_Test; |
| 54 | 55 |
| 55 explicit URLSearchParams(const String&); | 56 explicit URLSearchParams(const String&); |
| 56 explicit URLSearchParams(URLSearchParams*); | 57 explicit URLSearchParams(URLSearchParams*); |
| 57 Vector<std::pair<String, String>> m_params; | 58 Vector<std::pair<String, String>> m_params; |
| 58 | 59 |
| 59 IterationSource* startIteration(ScriptState*, ExceptionState&) override; | 60 IterationSource* startIteration(ScriptState*, ExceptionState&) override; |
| 60 }; | 61 }; |
| 61 | 62 |
| 62 } // namespace blink | 63 } // namespace blink |
| 63 | 64 |
| 64 #endif // URLSearchParams_h | 65 #endif // URLSearchParams_h |
| OLD | NEW |