reven2.types._integer.FixedWidthInteger(Integer)
class documentationreven2.types._integer
(View In Hierarchy)
An integer type of a fixed size.
Method | __init__ | Build a new integer type of a fixed size. |
Method | size_bytes | The minimal number of bytes necessary to hold an instance of this integer type. |
Method | endianness | Property: The endianness of this integer type. |
Method | signedness | Property: The signedness of this integer type. |
Inherited from Type (via Integer):
Method | parse | Parses the value of an instance of this type from a raw buffer, possibly depending on the context. |
Method | is_context_sensitive | Whether the context argument needed by some methods actually has an effect. |
Inherited from Type (via Integer):
Method | parse | Parses the value of an instance of this type from a raw buffer, possibly depending on the context. |
Method | is_context_sensitive | Whether the context argument needed by some methods actually has an effect. |
Build a new integer type of a fixed size.
Parameters | size | the size, in bytes, of instance of this integer type |
signedness | an element of the Signedness
enum indicating whether instances of this type are signed | |
endianness | an element of the Endianness
enum indicating the endianness of instances of this type | |
Raises | ValueError | if the passed size is negative or null |
The minimal number of bytes necessary to hold an instance of this integer type.
Parameters | context | The context object. See package documentation. |
Returns | An integer . |