From: Philippe Proulx Date: Wed, 10 Dec 2014 00:34:41 +0000 (-0500) Subject: Python: document writer.EnumerationMapping X-Git-Tag: v2.0.0-pre1~1375 X-Git-Url: http://git.efficios.com/?a=commitdiff_plain;h=1759e1322b07b2d42942d292dd9be8665115819c;p=babeltrace.git Python: document writer.EnumerationMapping Signed-off-by: Philippe Proulx Signed-off-by: Jérémie Galarneau --- diff --git a/bindings/python/writer.py b/bindings/python/writer.py index fbcd6875..8e9c79f9 100644 --- a/bindings/python/writer.py +++ b/bindings/python/writer.py @@ -35,10 +35,18 @@ _MAX_UINT64 = 0xFFFFFFFFFFFFFFFF class EnumerationMapping: """ - Enumeration mapping class. start and end values are inclusive. + Mapping from an enumeration label to a range of integers. """ def __init__(self, name, start, end): + """ + Creates an enumeration mapping, where label *name* is mapped to + the [*start*, *end*] range of integers (*end* is included). + + Set *start* and *end* to the same value to create an enumeration + mapping to a single value. + """ + self.name = name self.start = start self.end = end