takeHandle function

int takeHandle(
  1. int handle,
  2. Pointer<AimuxCError> err
)

Take a constructor uint64_t handle; throw AimuxException when 0.

Implementation

int takeHandle(int handle, Pointer<AimuxCError> err) {
  if (handle == 0) throw AimuxException.fromC(err.ref);
  return handle;
}