public class SharedFunctionality
extends java.lang.Object
This class contains all methods which are shared between all plug-ins in general.
Please note that both Advantage and MRAID Functionalities are implemented as plugins as well.
AdvantagePlugin,
MraidPlugin| Modifier and Type | Method and Description |
|---|---|
void |
expand()
Opens a
modal view with the given size. |
void |
expand(java.lang.String url)
Opens a
modal view with the given size and load a given URL to the
second AdWebView. |
android.graphics.Point |
getCurrentAdWebViewPoint(Enum.SizeMeasures measures)
Computes the 'Left' and 'Top' position of the active
AdWebView relative to its parent based on
the the logical density of the display. |
int |
getCurrentOrientation() |
android.graphics.Point |
getDefaultAdWebViewPoint(Enum.SizeMeasures measures)
Computes the coordinates of the default (first part)
AdWebView in its window based on
the the logical density of the display. |
Enum.States |
getState()
This method always returns the current state of banner.
|
java.lang.String |
getVersion() |
void |
hideCloseArea()
Hide the banner's close button.
|
boolean |
isAdWebViewVisible()
Returns the visibility status for the default (first part)
AdWebView. |
void |
notify(java.lang.Object object)
Occurs when a message sends from Advantage object to the SDK implementer.
|
void |
onError(java.lang.String msg,
Enum.ErrorCategory errorCategory)
Occurs when an SDK major error occurs.
|
void |
resize()
Opens a
modal view with the given size. |
void |
setState(Enum.States state)
Sets the current banner's
state. |
void |
showCloseArea()
Display the banner's close button.
|
public int getCurrentOrientation()
public java.lang.String getVersion()
public Enum.States getState()
This method always returns the current state of banner.
state of banner.public void setState(Enum.States state)
Sets the current banner's state.
state - Current statepublic void showCloseArea()
Display the banner's close button. this method operates on UI thread.
public void hideCloseArea()
Hide the banner's close button. this method runs on UI thread.
public void expand()
Opens a modal view with the given size. At this point, expand
properties need to be set.
public void expand(java.lang.String url)
Opens a modal view with the given size and load a given URL to the
second AdWebView. if size is not already specified, the modal will be
shown in full screen size. At this point, expand properties need to be set.
url - the URL of the resource to load.public void resize()
Opens a modal view with the given size. If ResizeProperties is not
already specified, the modal will be shown with the default resize properties.
public android.graphics.Point getCurrentAdWebViewPoint(Enum.SizeMeasures measures)
AdWebView relative to its parent based on
the the logical density of the display.measures - The measurement type.public android.graphics.Point getDefaultAdWebViewPoint(Enum.SizeMeasures measures)
AdWebView in its window based on
the the logical density of the display.measures - The measurement type.public boolean isAdWebViewVisible()
AdWebView.true If this view is visible.
false otherwise.public void notify(java.lang.Object object)
Occurs when a message sends from Advantage object to the SDK implementer. The event contains the value of the message.
object - Message from Advantage instance.public void onError(java.lang.String msg,
Enum.ErrorCategory errorCategory)
Occurs when an SDK major error occurs. The event contains a description of the error that occurred.
msg - Error message.errorCategory - Category of reported error.