/// This enum represents the user's geography used to determine the type of consent flow shown to the user.
/// </summary>
publicenumConsentFlowUserGeography
{
/// <summary>
/// User's geography is unknown.
/// </summary>
Unknown,
/// <summary>
/// The user is in GDPR region.
/// </summary>
Gdpr,
/// <summary>
/// The user is in a non-GDPR region.
/// </summary>
Other
}
#ifUNITY_EDITOR||UNITY_IPHONE||UNITY_IOS
/// <summary>
/// App tracking status values. Primarily used in conjunction with iOS14's AppTrackingTransparency.framework.
/// </summary>
publicenumAppTrackingStatus
{
/// <summary>
/// Device is on < iOS14, AppTrackingTransparency.framework is not available.
/// </summary>
Unavailable,
/// <summary>
/// The value returned if a user has not yet received an authorization request to authorize access to app-related data that can be used for tracking the user or the device.
/// </summary>
NotDetermined,
/// <summary>
/// The value returned if authorization to access app-related data that can be used for tracking the user or the device is restricted.
/// </summary>
Restricted,
/// <summary>
/// The value returned if the user denies authorization to access app-related data that can be used for tracking the user or the device.
/// </summary>
Denied,
/// <summary>
/// The value returned if the user authorizes access to app-related data that can be used for tracking the user or the device.
/// </summary>
Authorized,
}
#endif
/// <summary>
/// An enum describing the adapter's initialization status.
/// </summary>
publicenumInitializationStatus
{
/// <summary>
/// The adapter is not initialized. Note: networks need to be enabled for an ad unit id to be initialized.
/// </summary>
NotInitialized=-4,
/// <summary>
/// The 3rd-party SDK does not have an initialization callback with status.
/// </summary>
DoesNotApply=-3,
/// <summary>
/// The 3rd-party SDK is currently initializing.
/// </summary>
Initializing=-2,
/// <summary>
/// The 3rd-party SDK explicitly initialized, but without a status.
/// </summary>
InitializedUnknown=-1,
/// <summary>
/// The 3rd-party SDK initialization failed.
/// </summary>
InitializedFailure=0,
/// <summary>
/// The 3rd-party SDK initialization was successful.
/// </summary>
InitializedSuccess=1
}
publicenumAdViewPosition
{
TopLeft,
TopCenter,
TopRight,
Centered,
CenterLeft,
CenterRight,
BottomLeft,
BottomCenter,
BottomRight
}
publicclassAdViewConfiguration
{
/// <summary>
/// The position of the ad.
/// </summary>
publicAdViewPositionPosition{get;privateset;}
/// <summary>
/// The horizontal (X) position of the banner, relative to the top-left corner of the screen's safe area.
/// </summary>
publicfloatXCoordinate{get;privateset;}
/// <summary>
/// The vertical (Y) position of the banner, relative to the top-left corner of the screen's safe area.
/// </summary>
publicfloatYCoordinate{get;privateset;}
/// <summary>
/// Whether to use adaptive banners. Has no effect on MREC ads.
/// </summary>
publicboolIsAdaptive{get;set;}
internalboolUseCoordinates{get;privateset;}
/// <summary>
/// Creates an AdViewConfiguration with the given AdViewPosition.
/// </summary>
/// <param name="position">The position of the ad. Must not be null.</param>
publicAdViewConfiguration(AdViewPositionposition)
{
Position=position;
IsAdaptive=true;
UseCoordinates=false;
}
/// <summary>
/// Creates an AdViewConfiguration with the given x and y coordinates.
/// </summary>
/// <param name="x">The horizontal (X) position of the banner, relative to the top-left corner of the screen's safe area.</param>
/// <param name="y">The vertical (Y) position of the banner, relative to the top-left corner of the screen's safe area.</param>
publicAdViewConfiguration(floatx,floaty)
{
XCoordinate=x;
YCoordinate=y;
IsAdaptive=true;
UseCoordinates=true;
}
}
publicclassSdkConfiguration
{
/// <summary>
/// Whether or not the SDK has been initialized successfully.
* This enum contains various error codes that the SDK can return when a MAX ad fails to load or display.
*/
publicenumErrorCode
{
/// <summary>
/// This error code represents an error that could not be categorized into one of the other defined errors. See the message field in the error object for more details.
/// </summary>
Unspecified=-1,
/// <summary>
/// This error code indicates that MAX returned no eligible ads from any mediated networks for this app/device.
/// </summary>
NoFill=204,
/// <summary>
/// This error code indicates that MAX returned eligible ads from mediated networks, but all ads failed to load. See the adLoadFailureInfo field in the error object for more details.
/// </summary>
AdLoadFailed=-5001,
/// <summary>
/// This error code represents an error that was encountered when showing an ad.
/// </summary>
AdDisplayFailed=-4205,
/// <summary>
/// This error code indicates that the ad request failed due to a generic network error. See the message field in the error object for more details.
/// </summary>
NetworkError=-1000,
/// <summary>
/// This error code indicates that the ad request timed out due to a slow internet connection.
/// </summary>
NetworkTimeout=-1001,
/// <summary>
/// This error code indicates that the ad request failed because the device is not connected to the internet.
/// </summary>
NoNetwork=-1009,
/// <summary>
/// This error code indicates that you attempted to show a fullscreen ad while another fullscreen ad is still showing.
/// </summary>
FullscreenAdAlreadyShowing=-23,
/// <summary>
/// This error code indicates you are attempting to show a fullscreen ad before the one has been loaded.
/// </summary>
FullscreenAdNotReady=-24,
#ifUNITY_IOS||UNITY_IPHONE
/// <summary>
/// This error code indicates you attempted to present a fullscreen ad from an invalid view controller.
/// </summary>
FullscreenAdInvalidViewController=-25,
#endif
/// <summary>
/// This error code indicates you are attempting to load a fullscreen ad while another fullscreen ad is already loading.
/// </summary>
FullscreenAdAlreadyLoading=-26,
/// <summary>
/// This error code indicates you are attempting to load a fullscreen ad while another fullscreen ad is still showing.
/// </summary>
FullscreenAdLoadWhileShowing=-27,
#ifUNITY_ANDROID
/// <summary>
/// This error code indicates that the SDK failed to display an ad because the user has the "Don't Keep Activities" developer setting enabled.
/// </summary>
DontKeepActivitiesEnabled=-5602,
#endif
/// <summary>
/// This error code indicates that the SDK failed to load an ad because the publisher provided an invalid ad unit identifier.
/// Possible reasons for an invalid ad unit identifier:
/// 1. Ad unit identifier is malformed or does not exist
/// 2. Ad unit is disabled
/// 3. Ad unit is not associated with the current app's package name
/// 4. Ad unit was created within the last 30-60 minutes
/// </summary>
InvalidAdUnitId=-5603
}
/**
* This enum contains possible states of an ad in the waterfall the adapter response info could represent.
*/
publicenumMaxAdLoadState
{
/// <summary>
/// The AppLovin Max SDK did not attempt to load an ad from this network in the waterfall because an ad higher