aboutsummaryrefslogtreecommitdiffstats
path: root/tools/asn2wrs.py
diff options
context:
space:
mode:
authorkukosa <kukosa@f5534014-38df-0310-8fa8-9805f1628bb7>2007-10-31 12:57:01 +0000
committerkukosa <kukosa@f5534014-38df-0310-8fa8-9805f1628bb7>2007-10-31 12:57:01 +0000
commit1b4970a5b63fa0a3dbe1594c04d52ffb752060c7 (patch)
tree2056cd6d2a5693d82ccd52ba8aaa881b7987547f /tools/asn2wrs.py
parenta1b3fa5ac8128579356b84c1793c1fe193803c46 (diff)
small improvement in class fields handling
git-svn-id: http://anonsvn.wireshark.org/wireshark/trunk@23321 f5534014-38df-0310-8fa8-9805f1628bb7
Diffstat (limited to 'tools/asn2wrs.py')
-rwxr-xr-xtools/asn2wrs.py16
1 files changed, 14 insertions, 2 deletions
diff --git a/tools/asn2wrs.py b/tools/asn2wrs.py
index d75592c240..5d86811e7d 100755
--- a/tools/asn2wrs.py
+++ b/tools/asn2wrs.py
@@ -5311,10 +5311,12 @@ class FixedTypeValueFieldSpec (FieldSpec):
return repr
class VariableTypeValueFieldSpec (FieldSpec):
- pass
+ def get_repr(self):
+ return ['_' + self.type]
class FixedTypeValueSetFieldSpec (FieldSpec):
- pass
+ def get_repr(self):
+ return ['_' + self.type]
class ObjectFieldSpec (FieldSpec):
def get_repr(self):
@@ -6943,11 +6945,21 @@ object_class_typerefs = { }
object_class_classrefs = { }
+# dummy types
+class _VariableTypeValueFieldSpec (AnyType):
+ pass
+
+class _FixedTypeValueSetFieldSpec (AnyType):
+ pass
+
class_types_creator = {
'BooleanType' : lambda : BooleanType(),
'IntegerType' : lambda : IntegerType(),
'ObjectIdentifierType' : lambda : ObjectIdentifierType(),
'OpenType' : lambda : OpenType(),
+ # dummy types
+ '_VariableTypeValueFieldSpec' : lambda : _VariableTypeValueFieldSpec(),
+ '_FixedTypeValueSetFieldSpec' : lambda : _FixedTypeValueSetFieldSpec(),
}
class_names = { }