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

Unified Diff: third_party/WebKit/Source/core/testing/SequenceTest.h

Issue 2810843002: bindings: Make the sequence conversion code more complaint with WebIDL. (Closed)
Patch Set: Created 3 years, 8 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 side-by-side diff with in-line comments
Download patch
Index: third_party/WebKit/Source/core/testing/SequenceTest.h
diff --git a/third_party/WebKit/Source/core/testing/SequenceTest.h b/third_party/WebKit/Source/core/testing/SequenceTest.h
new file mode 100644
index 0000000000000000000000000000000000000000..b09cd62ce3098b2dcdbad9d848eba7d3a4b68272
--- /dev/null
+++ b/third_party/WebKit/Source/core/testing/SequenceTest.h
@@ -0,0 +1,49 @@
+// Copyright 2017 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.
+
+#ifndef SequenceTest_h
+#define SequenceTest_h
+
+#include "bindings/core/v8/DoubleOrDoubleSequence.h"
+#include "bindings/core/v8/Nullable.h"
+#include "bindings/core/v8/ScriptWrappable.h"
+#include "core/dom/Element.h"
+#include "platform/heap/Handle.h"
+#include "platform/wtf/Vector.h"
+#include "platform/wtf/text/WTFString.h"
+
+namespace blink {
+
+class SequenceTest final : public GarbageCollectedFinalized<SequenceTest>,
+ public ScriptWrappable {
+ DEFINE_WRAPPERTYPEINFO();
+
+ public:
+ static SequenceTest* create() { return new SequenceTest; }
+ ~SequenceTest();
+
+ Vector<Vector<String>> identityByteStringSequenceSequence(
+ const Vector<Vector<String>>& arg) const;
+ Vector<double> identityDoubleSequence(const Vector<double>& arg) const;
+ Vector<String> identityFoodEnumSequence(const Vector<String>& arg) const;
+ Vector<int32_t> identityLongSequence(const Vector<int32_t>& arg) const;
+ Nullable<Vector<uint8_t>> identityOctetSequenceOrNull(
+ const Nullable<Vector<uint8_t>>& arg) const;
+
+ HeapVector<Member<Element>> getElementSequence() const;
+ void setElementSequence(const HeapVector<Member<Element>>& arg);
+
+ bool unionReceivedSequence(const DoubleOrDoubleSequence& arg);
+
+ DECLARE_TRACE();
+
+ private:
+ SequenceTest();
+
+ HeapVector<Member<Element>> m_elementSequence;
+};
+
+} // namespace blink
+
+#endif // SequenceTest_h

Powered by Google App Engine
This is Rietveld 408576698