Udostępnij za pośrednictwem


View.GenerateDisplayHash Method

Definition

Called to generate a DisplayHash for this view.

[Android.Runtime.Register("generateDisplayHash", "(Ljava/lang/String;Landroid/graphics/Rect;Ljava/util/concurrent/Executor;Landroid/view/displayhash/DisplayHashResultCallback;)V", "GetGenerateDisplayHash_Ljava_lang_String_Landroid_graphics_Rect_Ljava_util_concurrent_Executor_Landroid_view_displayhash_DisplayHashResultCallback_Handler", ApiSince=31)]
public virtual void GenerateDisplayHash (string hashAlgorithm, Android.Graphics.Rect? bounds, Java.Util.Concurrent.IExecutor executor, Android.Views.DisplayHash.IDisplayHashResultCallback callback);
[<Android.Runtime.Register("generateDisplayHash", "(Ljava/lang/String;Landroid/graphics/Rect;Ljava/util/concurrent/Executor;Landroid/view/displayhash/DisplayHashResultCallback;)V", "GetGenerateDisplayHash_Ljava_lang_String_Landroid_graphics_Rect_Ljava_util_concurrent_Executor_Landroid_view_displayhash_DisplayHashResultCallback_Handler", ApiSince=31)>]
abstract member GenerateDisplayHash : string * Android.Graphics.Rect * Java.Util.Concurrent.IExecutor * Android.Views.DisplayHash.IDisplayHashResultCallback -> unit
override this.GenerateDisplayHash : string * Android.Graphics.Rect * Java.Util.Concurrent.IExecutor * Android.Views.DisplayHash.IDisplayHashResultCallback -> unit

Parameters

hashAlgorithm
String

The hash algorithm to use when hashing the display. Must be one of the values returned from DisplayHashManager#getSupportedHashAlgorithms()

bounds
Rect

The bounds for the content within the View to generate the hash for. If bounds are null, the entire View's bounds will be used. If empty, it will invoke the callback DisplayHashResultCallback#onDisplayHashError with error DisplayHashResultCallback#DISPLAY_HASH_ERROR_INVALID_BOUNDS

executor
IExecutor

The executor that the callback should be invoked on.

callback
IDisplayHashResultCallback

The callback to handle the results of generating the display hash

Attributes

Remarks

Called to generate a DisplayHash for this view.

Java documentation for android.view.View.generateDisplayHash(java.lang.String, android.graphics.Rect, java.util.concurrent.Executor, android.view.displayhash.DisplayHashResultCallback).

Portions of this page are modifications based on work created and shared by the Android Open Source Project and used according to terms described in the Creative Commons 2.5 Attribution License.

Applies to