Reference Counting

These functions allow conversion from specific object types that are reference-counted to arbb_refcountable_t instances.

Functions

ARBB_VM_EXPORT arbb_refcountable_t arbb_function_to_refcountable (arbb_function_t convertible)
 Converts the given arbb_function_t to an arbb_refcountable_t instance.
ARBB_VM_EXPORT arbb_refcountable_t arbb_global_variable_to_refcountable (arbb_global_variable_t convertible)
 Converts the given arbb_global_variable_t to an arbb_refcountable_t instance.
ARBB_VM_EXPORT arbb_error_t arbb_acquire_ref (arbb_refcountable_t refcountable, arbb_error_details_t *details)
 Increments the reference count of refcountable.
ARBB_VM_EXPORT arbb_error_t arbb_release_ref (arbb_refcountable_t refcountable, arbb_error_details_t *details)
 Decrements the reference count of refcountable.

Function Documentation

ARBB_VM_EXPORT arbb_refcountable_t arbb_function_to_refcountable ( arbb_function_t  convertible  ) 

Converts the given arbb_function_t to an arbb_refcountable_t instance.

Returns:
An arbb_refcountable_t instance that can be used with arbb_acquire_ref() and arbb_release_ref()
ARBB_VM_EXPORT arbb_refcountable_t arbb_global_variable_to_refcountable ( arbb_global_variable_t  convertible  ) 

Converts the given arbb_global_variable_t to an arbb_refcountable_t instance.

Returns:
An arbb_refcountable_t instance that can be used with arbb_acquire_ref() and arbb_release_ref()
ARBB_VM_EXPORT arbb_error_t arbb_acquire_ref ( arbb_refcountable_t  refcountable,
arbb_error_details_t details 
)

Increments the reference count of refcountable.

Returns:
An error code depending on the result of the operation:
ARBB_VM_EXPORT arbb_error_t arbb_release_ref ( arbb_refcountable_t  refcountable,
arbb_error_details_t details 
)

Decrements the reference count of refcountable.

If the reference count of the object drops to zero, its resources are reclaimed.

Returns:
An error code depending on the result of the operation:

Submit feedback on this help topic

Copyright © 2010, Intel Corporation. All rights reserved.