Index: third_party/WebKit/Source/bindings/scripts/idl_types.py |
diff --git a/third_party/WebKit/Source/bindings/scripts/idl_types.py b/third_party/WebKit/Source/bindings/scripts/idl_types.py |
index 5d776a7172c563d978594851d86f0b59588d4288..f87d44c2d0afa46d7b4900f6fdd9c82abb17ac45 100644 |
--- a/third_party/WebKit/Source/bindings/scripts/idl_types.py |
+++ b/third_party/WebKit/Source/bindings/scripts/idl_types.py |
@@ -10,6 +10,7 @@ IdlTypeBase |
IdlArrayOrSequenceType |
IdlArrayType |
IdlSequenceType |
+ IdlFrozenArrayType |
IdlNullableType |
IdlTypes are picklable because we store them in interfaces_info. |
@@ -334,11 +335,12 @@ class IdlUnionType(IdlTypeBase): |
################################################################################ |
-# IdlArrayOrSequenceType, IdlArrayType, IdlSequenceType |
+# IdlArrayOrSequenceType, IdlArrayType, IdlSequenceType, IdlFrozenArrayType |
################################################################################ |
+# TODO(bashi): Rename this like "IdlArrayTypeBase" or something. |
class IdlArrayOrSequenceType(IdlTypeBase): |
- """Base class for IdlArrayType and IdlSequenceType.""" |
+ """Base class for array-like types.""" |
def __init__(self, element_type): |
super(IdlArrayOrSequenceType, self).__init__() |
@@ -398,6 +400,19 @@ class IdlSequenceType(IdlArrayOrSequenceType): |
return self.element_type.name + 'Sequence' |
+class IdlFrozenArrayType(IdlArrayOrSequenceType): |
+ def __init__(self, element_type): |
+ super(IdlFrozenArrayType, self).__init__(element_type) |
+ |
+ def __str__(self): |
+ return 'FrozenArray<%s>' % self.element_type |
+ |
+ @property |
+ def name(self): |
+ return self.element_type.name + 'Array' |
+ |
+ |
+ |
################################################################################ |
# IdlNullableType |
################################################################################ |