Class BannerExtensions
Inherited Members
Namespace: Chartboost.Mediation.Ad.Banner
Assembly: Chartboost.Mediation.dll
Syntax
public static class BannerExtensions
Methods
IsEqual(LayoutParams, LayoutParams)
Compares two LayoutParams instances to determine if they are approximately equal.
Declaration
public static bool IsEqual(this LayoutParams source, LayoutParams other)
Parameters
| Type | Name | Description |
|---|---|---|
| LayoutParams | source | The first LayoutParams instance to compare. |
| LayoutParams | other | The second LayoutParams instance to compare. |
Returns
| Type | Description |
|---|---|
| bool | True if the x, y, width, and height properties of both instances are within 0.01 units of each other, otherwise false. |
LayoutParams(RectTransform)
Returns LayoutParams(RectTransform) information from a RectTransform.
Declaration
public static LayoutParams LayoutParams(this RectTransform rectTransform)
Parameters
| Type | Name | Description |
|---|---|---|
| RectTransform | rectTransform | Target. |
Returns
| Type | Description |
|---|---|
| LayoutParams | Formatted LayoutParams(RectTransform). |
Size(BannerSizeType)
Converts a BannerSizeType into a respective Vector2 values.
Declaration
public static Vector2 Size(this BannerSizeType bannerSize)
Parameters
| Type | Name | Description |
|---|---|---|
| BannerSizeType | bannerSize | Size to convert. |
Returns
| Type | Description |
|---|---|
| Vector2 | Appropriate Vector2 values. |