Skip to content


Subversion checkout URL

You can clone with
Download ZIP
Browse files

Improve doc formatting

  • Loading branch information...
1 parent 7013b2b commit 78d383bf93bc0b39a978731144c49bfd5ed75cd0 @daggerrz daggerrz committed
Showing with 14 additions and 14 deletions.
  1. +14 −14 ad-serving/
28 ad-serving/
@@ -18,8 +18,8 @@ Once the API is initialized, there are two major ways to work with it:
Note that the SDK requires Internet access, so make sure you have the following permission in your `AndroidManifest.xml`:
- <uses-permission android:name="android.permission.INTERNET"/>
+<uses-permission android:name="android.permission.INTERNET"/>
@@ -27,19 +27,19 @@ Note that the SDK requires Internet access, so make sure you have the following
The simplest integration approach is to add an SDK managed WebView to your layout. This class is called `AdView` and supports automatic ad refresh intervals etc.
### Add the AdView to your layout
- <com.tapad.adserving.ui.AdView
- android:id="@+id/ad_view"
- android:layout_height="50dip"
- android:layout_width="fill_parent"
- android:visibility="gone"
- />
+ android:id="@+id/ad_view"
+ android:layout_height="50dip"
+ android:layout_width="fill_parent"
+ android:visibility="gone"
### Add onResume and onPause event hooks to your Activity
To make sure that the view start refreshing ads when the activity becomes active and stops when the activity is passivated, add the following code to the activity containing the `AdView`:
protected void onResume() {
@@ -64,13 +64,13 @@ Note that we're hiding the `AdView` by default. The view will automatically show
# Using your own WebViews
After the API has been initialized, you can get a reference to the `AdServiceService` by invoking:
- AdServingService service = com.tapad.adserving.AdServing.get();
+AdServingService service = com.tapad.adserving.AdServing.get();
The `AdServingService` allows you to asynchronously request ads. When the ad markup is available (or an error occurred), the `onResponse` method of your request will be invoked. For example:
AdServing.get().requestAd(new AdRequest(placementId, size) {
protected void onResponse(final AdResponse response) {
Runnable action = null;
@@ -100,7 +100,7 @@ The source code of our SDK is freely available here on Github, so you are free t
For the latter:

0 comments on commit 78d383b

Please sign in to comment.
Something went wrong with that request. Please try again.