class CounterDispatcher

Defined at line 17 of file ../../zircon/kernel/object/include/object/counter_dispatcher.h

Public Methods

void ~CounterDispatcher ()

Defined at line 41 of file ../../zircon/kernel/object/counter_dispatcher.cc

zx_status_t Create (KernelHandle<CounterDispatcher> * handle, zx_rights_t * rights)

Creates a CounterDispatcher.

Defined at line 23 of file ../../zircon/kernel/object/counter_dispatcher.cc

zx_obj_type_t get_type ()

Defined at line 25 of file ../../zircon/kernel/object/include/object/counter_dispatcher.h

int64_t Value ()

Returns the counter's value.

Synchronizes-with |SetValue| or |Add|.

Defined at line 30 of file ../../zircon/kernel/object/include/object/counter_dispatcher.h

void SetValue (int64_t new_value)

Sets the counter's value, asserting/deasserting signals as appropriate.

Synchronizes-with |Value| or |Add|.

Defined at line 38 of file ../../zircon/kernel/object/include/object/counter_dispatcher.h

zx_status_t Add (int64_t amount)

Adds |amount| to this counter.

Synchronizes-with |SetValue| or |Value|.

Returns an error if the value would underflow/overflow.

Defined at line 48 of file ../../zircon/kernel/object/include/object/counter_dispatcher.h