Next: 4.10.21 nxo_instance Up: 4.10 Classes Previous: 4.10.19 nxo_fino Contents Index
Subsections

- 4.10.20.1 API

##
4.10.20 nxo_handle

The nxo_handle class is a subclass of the nxo class.

### 4.10.20.1 API

void cw_nxo_handle_eval_t(void *a_opaque, cw_nxo_t *a_thread):

  Input(s):
    a_opaque:
      Opaque data pointer.
    a_thread:
      Pointer to a thread nxo.
  Output(s):
    None.
  Exception(s):
    Handle-dependent.
  Description:
    Evaluation function typedef.

cw_nxoe_t * cw_nxo_handle_ref_iter_t(void *a_opaque, bool a_reset):

  Input(s):
    a_opaque:
      Opaque data pointer.
    a_reset:
      false:
        At least one iteration has already occurred.
      true:
        First iteration.
  Output(s):
    retval:
      non-NULL:
        Pointer to an nxoe.
      NULL:
        No more references.
  Exception(s):
    None.
  Description:
    Reference iterator function typedef.

bool cw_nxo_handle_delete_t(void *a_opaque, uint32_t a_iter):

  Input(s):
    a_opaque:
      Opaque data pointer.
    a_iter:
      Garbage collector sweep iteration count (starts at 0). This value can be used to impose ordering of dependent object deletions.
  Output(s):
    retval:
      false:
        Success.
      true:
        Defer deletion until a later garbage collector sweep iteration.
  Exception(s):
    None.
  Description:
    Destructor function typedef.

void nxo_handle_new(cw_nxo_t *a_nxo, void *a_opaque, cw_nxo_handle_eval_t *a_eval_f, cw_nxo_handle_ref_iter_t *a_ref_iter_f, cw_nxo_handle_delete_t *a_delete_f):

  Input(s):
    a_nxo:
      Pointer to a handle nxo.
    a_opaque:
      Opaque data pointer to be passed to a_eval_f, a_ref_iter_f, and a_delete_f.
    a_eval_f:
      Pointer to an evaluation function.
    a_ref_iter_f:
      Pointer to a reference iterator function.
    a_delete_f:
      Pointer to a destructor function.
  Output(s):
    None.
  Exception(s):
    CW_ONYXX_OOM.
  Description:
    Constructor.

cw_nxo_t * nxo_handle_tag_get(const cw_nxo_t *a_nxo):

  Input(s):
    a_nxo:
      Pointer to a handle nxo.
  Output(s):
    retval:
      Pointer to the tag object associated with a_nxo.
  Exception(s):
    None.
  Description:
    Return a pointer to the tag object associated with a_nxo. This object pointer can safely be used for modifying the tag object.

void * nxo_handle_opaque_get(const cw_nxo_t *a_nxo):

  Input(s):
    a_nxo:
      Pointer to a handle nxo.
  Output(s):
    retval:
      Opaque data pointer.
  Exception(s):
    None.
  Description:
    Return the opaque data pointer associated with a_nxo.

void nxo_handle_opaque_set(cw_nxo_t *a_nxo, void *a_opaque):

  Input(s):
    a_nxo:
      Pointer to a handle nxo.
    a_opaque:
      Opaque data pointer.
  Output(s):
    None.
  Exception(s):
    None.
  Description:
    Set the opaque data pointer associated with a_nxo.

void nxo_handle_eval(cw_nxo_t *a_nxo, cw_nxo_t *a_thread):

  Input(s):
    a_nxo:
      Pointer to a handle nxo.
    a_thread:
      Pointer to a thread nxo.
  Output(s):
    None.
  Exception(s):
    Handle-specific.
  Description:
    Evaluate the a_nxo. If there is no evaluation function associated with a_nxo, it is pushed onto ostack.

Next: 4.10.21 nxo_instance Up: 4.10 Classes Previous: 4.10.19 nxo_fino Contents Index