Skip to main content

OH_Drawing_RectGetArrayElement

Function OH_Drawing_RectGetArrayElement 

Source
pub unsafe extern "C" fn OH_Drawing_RectGetArrayElement(
    rectArray: *mut OH_Drawing_Array,
    index: usize,
    rect: *mut *mut OH_Drawing_Rect,
) -> DrawingResult
Available on crate features api-11 and api-18 only.
Expand description

Gets the specified OH_Drawing_Rect object from OH_Drawing_Array object.

Required System Capabilities: SystemCapability.Graphic.Graphic2D.NativeDrawing

§Arguments

  • rectArray - Indicates the array object.

  • index - Indicates the index of array, caller must make sure the index is valid.

  • rect - Pointers to Pointer of OH_Drawing_Rect object, returned to the caller.

§Returns

  • Returns the error code. Returns [OH_DRAWING_SUCCESS] if the operation is successful. Returns [OH_DRAWING_ERROR_INVALID_PARAMETER] if rectArray or rect is nullptr, or index is valid.

Available since API-level: 18

Version: 1.0