Class NativeMRC50TrackedView
-
- All Implemented Interfaces:
-
com.inmobi.media.ads.common.visibility.checker.VisibilityTrackedView
public final class NativeMRC50TrackedView implements VisibilityTrackedView
A VisibilityTrackedView implementation for tracking native ad viewability with a focus on MRC 50% criteria (specifically the view's spatial requirements).
This class determines the visibility status of a native ad view based on global visibility, percentage of viewable area, minimum dimensions, obstruction by other views, and the attachment and visibility of required child views (like icon or media). The logic for
isRequiredViewsAttachedis tailored: if media is required, only media's validity is checked; otherwise, if the icon is required, only the icon's validity is checked. If neither is explicitly required, it defaults to true.
-
-
Constructor Summary
Constructors Constructor Description NativeMRC50TrackedView(ViewableTypeVisibilityConfig viewableConfig, NativeViewabilityViewHolder nativeViewabilityViewHolder)
-
Method Summary
Modifier and Type Method Description VisibilityStatusisVisible()Determines the current visibility status of the tracked view. -
-
Constructor Detail
-
NativeMRC50TrackedView
NativeMRC50TrackedView(ViewableTypeVisibilityConfig viewableConfig, NativeViewabilityViewHolder nativeViewabilityViewHolder)
-
-
Method Detail
-
isVisible
VisibilityStatus isVisible()
Determines the current visibility status of the tracked view.
This method evaluates the tracked view against the implemented visibility criteria and returns the appropriate VisibilityStatus. The implementation should consider all relevant factors including friendly views, viewport intersection, occlusion, and any minimum visibility thresholds.
- Returns:
VisibilityStatus.VISIBLE if the view meets visibility criteria, VisibilityStatus.HIDDEN otherwise
-
-
-
-