Package sparked :: Package hardware :: Module inputevent :: Class InputEvent
[hide private]
[frames] | no frames]

Class InputEvent

source code

object --+
         |
        InputEvent

A `struct input_event`. You can instantiate it with a buffer, in which case the method `unpack(buf)` will be called. Or you can create an instance with `InputEvent.new(type, code, value, timestamp=None)`, which can then be packed into the structure with the `pack` method.

Instance Methods [hide private]
 
__init__(self, buf=None)
By default, unpack from a buffer
source code
 
set(self, etype, ecode, evalue, timestamp=None)
Set the parameters of this InputEvent
source code
 
unpack(self, buf) source code
 
pack(self) source code
 
__repr__(self)
repr(x)
source code
 
__str__(self)
str(x)
source code
 
__hash__(self)
hash(x)
source code
 
__eq__(self, other) source code

Inherited from object: __delattr__, __format__, __getattribute__, __new__, __reduce__, __reduce_ex__, __setattr__, __sizeof__, __subclasshook__

Class Methods [hide private]
 
new(cls, etype, ecode, evalue, time=None)
Construct a new InputEvent object
source code
Properties [hide private]
  timestamp
  ecode
  etype
  evalue
  nanotime
  time

Inherited from object: __class__

Method Details [hide private]

__init__(self, buf=None)
(Constructor)

source code 

By default, unpack from a buffer

Overrides: object.__init__

__repr__(self)
(Representation operator)

source code 

repr(x)

Overrides: object.__repr__
(inherited documentation)

__str__(self)
(Informal representation operator)

source code 

str(x)

Overrides: object.__str__
(inherited documentation)

__hash__(self)
(Hashing function)

source code 

hash(x)

Overrides: object.__hash__
(inherited documentation)

Property Details [hide private]

timestamp

Get Method:
unreachable.timestamp(self)