1 // Copyright 2014 The Chromium Authors. All rights reserved. 2 // Use of this source code is governed by a BSD-style license that can be 3 // found in the LICENSE file. 4 5 // This file has been auto-generated by code_generator_v8.py. DO NOT MODIFY! 6 7 #ifndef TestDictionary_h 8 #define TestDictionary_h 9 10 #include "bindings/core/v8/Nullable.h" 11 #include "bindings/core/v8/ScriptValue.h" 12 #include "bindings/tests/idls/core/TestInterfaceGarbageCollected.h" 13 #include "bindings/tests/idls/core/TestInterfaceImplementation.h" 14 #include "bindings/tests/idls/core/TestInterfaceWillBeGarbageCollected.h" 15 #include "core/dom/Element.h" 16 #include "platform/heap/Handle.h" 17 #include "wtf/Vector.h" 18 #include "wtf/text/WTFString.h" 19 20 namespace blink { 21 22 class TestDictionary FINAL : public GarbageCollectedFinalized<TestDictionary> { 23 public: 24 static TestDictionary* create() 25 { 26 return new TestDictionary; 27 } 28 29 bool hasBooleanMember() const { return !m_booleanMember.isNull(); } 30 bool booleanMember() const { return m_booleanMember.get(); } 31 void setBooleanMember(bool value) { m_booleanMember = value; } 32 bool hasLongMember() const { return !m_longMember.isNull(); } 33 int longMember() const { return m_longMember.get(); } 34 void setLongMember(int value) { m_longMember = value; } 35 bool hasStringMember() const { return !m_stringMember.isNull(); } 36 String stringMember() const { return m_stringMember; } 37 void setStringMember(String value) { m_stringMember = value; } 38 bool hasTestInterfaceMember() const { return m_testInterfaceMember; } 39 PassRefPtr<TestInterfaceImplementation> testInterfaceMember() const { return m_testInterfaceMember; } 40 void setTestInterfaceMember(PassRefPtr<TestInterfaceImplementation> value) { m_testInterfaceMember = value; } 41 bool hasDoubleOrNullMember() const { return !m_doubleOrNullMember.isNull(); } 42 double doubleOrNullMember() const { return m_doubleOrNullMember.get(); } 43 void setDoubleOrNullMember(double value) { m_doubleOrNullMember = value; } 44 bool hasStringOrNullMember() const { return !m_stringOrNullMember.isNull(); } 45 String stringOrNullMember() const { return m_stringOrNullMember; } 46 void setStringOrNullMember(String value) { m_stringOrNullMember = value; } 47 bool hasTestInterfaceOrNullMember() const { return m_testInterfaceOrNullMember; } 48 PassRefPtr<TestInterfaceImplementation> testInterfaceOrNullMember() const { return m_testInterfaceOrNullMember; } 49 void setTestInterfaceOrNullMember(PassRefPtr<TestInterfaceImplementation> value) { m_testInterfaceOrNullMember = value; } 50 bool hasTestInterfaceGarbageCollectedMember() const { return m_testInterfaceGarbageCollectedMember; } 51 RawPtr<TestInterfaceGarbageCollected> testInterfaceGarbageCollectedMember() const { return m_testInterfaceGarbageCollectedMember; } 52 void setTestInterfaceGarbageCollectedMember(RawPtr<TestInterfaceGarbageCollected> value) { m_testInterfaceGarbageCollectedMember = value; } 53 bool hasTestInterfaceGarbageCollectedOrNullMember() const { return m_testInterfaceGarbageCollectedOrNullMember; } 54 RawPtr<TestInterfaceGarbageCollected> testInterfaceGarbageCollectedOrNullMember() const { return m_testInterfaceGarbageCollectedOrNullMember; } 55 void setTestInterfaceGarbageCollectedOrNullMember(RawPtr<TestInterfaceGarbageCollected> value) { m_testInterfaceGarbageCollectedOrNullMember = value; } 56 bool hasTestInterfaceWillBeGarbageCollectedMember() const { return m_testInterfaceWillBeGarbageCollectedMember; } 57 PassRefPtrWillBeRawPtr<TestInterfaceWillBeGarbageCollected> testInterfaceWillBeGarbageCollectedMember() const { return m_testInterfaceWillBeGarbageCollectedMember; } 58 void setTestInterfaceWillBeGarbageCollectedMember(PassRefPtrWillBeRawPtr<TestInterfaceWillBeGarbageCollected> value) { m_testInterfaceWillBeGarbageCollectedMember = value; } 59 bool hasTestInterfaceWillBeGarbageCollectedOrNullMember() const { return m_testInterfaceWillBeGarbageCollectedOrNullMember; } 60 PassRefPtrWillBeRawPtr<TestInterfaceWillBeGarbageCollected> testInterfaceWillBeGarbageCollectedOrNullMember() const { return m_testInterfaceWillBeGarbageCollectedOrNullMember; } 61 void setTestInterfaceWillBeGarbageCollectedOrNullMember(PassRefPtrWillBeRawPtr<TestInterfaceWillBeGarbageCollected> value) { m_testInterfaceWillBeGarbageCollectedOrNullMember = value; } 62 bool hasStringArrayMember() const { return !m_stringArrayMember.isNull(); } 63 const Vector<String>& stringArrayMember() const { return m_stringArrayMember.get(); } 64 void setStringArrayMember(const Vector<String>& value) { m_stringArrayMember = value; } 65 bool hasStringSequenceMember() const { return !m_stringSequenceMember.isNull(); } 66 const Vector<String>& stringSequenceMember() const { return m_stringSequenceMember.get(); } 67 void setStringSequenceMember(const Vector<String>& value) { m_stringSequenceMember = value; } 68 bool hasEnumMember() const { return !m_enumMember.isNull(); } 69 String enumMember() const { return m_enumMember; } 70 void setEnumMember(String value) { m_enumMember = value; } 71 bool hasElementOrNullMember() const { return m_elementOrNullMember; } 72 PassRefPtrWillBeRawPtr<Element> elementOrNullMember() const { return m_elementOrNullMember; } 73 void setElementOrNullMember(PassRefPtrWillBeRawPtr<Element> value) { m_elementOrNullMember = value; } 74 bool hasObjectMember() const { return !(m_objectMember.isEmpty() || m_objectMember.isNull() || m_objectMember.isUndefined()); } 75 ScriptValue objectMember() const { return m_objectMember; } 76 void setObjectMember(ScriptValue value) { m_objectMember = value; } 77 bool hasObjectOrNullMember() const { return !(m_objectOrNullMember.isEmpty() || m_objectOrNullMember.isNull() || m_objectOrNullMember.isUndefined()); } 78 ScriptValue objectOrNullMember() const { return m_objectOrNullMember; } 79 void setObjectOrNullMember(ScriptValue value) { m_objectOrNullMember = value; } 80 81 void trace(Visitor*); 82 83 private: 84 TestDictionary(); 85 86 Nullable<bool> m_booleanMember; 87 Nullable<int> m_longMember; 88 String m_stringMember; 89 RefPtr<TestInterfaceImplementation> m_testInterfaceMember; 90 Nullable<double> m_doubleOrNullMember; 91 String m_stringOrNullMember; 92 RefPtr<TestInterfaceImplementation> m_testInterfaceOrNullMember; 93 Member<TestInterfaceGarbageCollected> m_testInterfaceGarbageCollectedMember; 94 Member<TestInterfaceGarbageCollected> m_testInterfaceGarbageCollectedOrNullMember; 95 RefPtrWillBeMember<TestInterfaceWillBeGarbageCollected> m_testInterfaceWillBeGarbageCollectedMember; 96 RefPtrWillBeMember<TestInterfaceWillBeGarbageCollected> m_testInterfaceWillBeGarbageCollectedOrNullMember; 97 Nullable<Vector<String> > m_stringArrayMember; 98 Nullable<Vector<String> > m_stringSequenceMember; 99 String m_enumMember; 100 RefPtrWillBeMember<Element> m_elementOrNullMember; 101 ScriptValue m_objectMember; 102 ScriptValue m_objectOrNullMember; 103 104 friend class V8TestDictionary; 105 }; 106 107 } // namespace blink 108 109 #endif // TestDictionary_h 110