Subversion Repositories AndroidProjects

Rev

Blame | Last modification | View Log | RSS feed

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<!--NewPage-->
<HTML>
<HEAD>
<!-- Generated by javadoc (build 1.6.0_24) on Fri Jul 15 17:00:53 PDT 2011 -->
<TITLE>
AdRequest (Google AdMob Ads SDK)
</TITLE>

<META NAME="date" CONTENT="2011-07-15">

<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../stylesheet.css" TITLE="Style">

<SCRIPT type="text/javascript">
function windowTitle()
{
    if (location.href.indexOf('is-external=true') == -1) {
        parent.document.title="AdRequest (Google AdMob Ads SDK)";
    }
}
</SCRIPT>
<NOSCRIPT>
</NOSCRIPT>

</HEAD>

<BODY BGCOLOR="white" onload="windowTitle();">
<HR>


<!-- ========= START OF TOP NAVBAR ======= -->
<A NAME="navbar_top"><!-- --></A>
<A HREF="#skip-navbar_top" title="Skip navigation links"></A>
<TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
<TR>
<TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
<A NAME="navbar_top_firstrow"><!-- --></A>
<TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
  <TR ALIGN="center" VALIGN="top">
  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="../../../com/google/ads/package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>
  <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Class</B></FONT>&nbsp;</TD>
  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
  </TR>
</TABLE>
</TD>
<TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
</EM>
</TD>
</TR>

<TR>
<TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
&nbsp;<A HREF="../../../com/google/ads/AdListener.html" title="interface in com.google.ads"><B>PREV CLASS</B></A>&nbsp;
&nbsp;<A HREF="../../../com/google/ads/AdRequest.ErrorCode.html" title="enum in com.google.ads"><B>NEXT CLASS</B></A></FONT></TD>
<TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
  <A HREF="../../../index.html?com/google/ads/AdRequest.html" target="_top"><B>FRAMES</B></A>  &nbsp;
&nbsp;<A HREF="AdRequest.html" target="_top"><B>NO FRAMES</B></A>  &nbsp;
&nbsp;<SCRIPT type="text/javascript">
  <!--
 if(window==top) {
   document.writeln('<A HREF="../../../allclasses-noframe.html"><B>All Classes</B></A>');
 }
 //-->
</SCRIPT>
<NOSCRIPT>
  <A HREF="../../../allclasses-noframe.html"><B>All Classes</B></A>
</NOSCRIPT>


</FONT></TD>
</TR>
<TR>
<TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
  SUMMARY:&nbsp;<A HREF="#nested_class_summary">NESTED</A>&nbsp;|&nbsp;<A HREF="#field_summary">FIELD</A>&nbsp;|&nbsp;<A HREF="#constructor_summary">CONSTR</A>&nbsp;|&nbsp;<A HREF="#method_summary">METHOD</A></FONT></TD>
<TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
DETAIL:&nbsp;<A HREF="#field_detail">FIELD</A>&nbsp;|&nbsp;<A HREF="#constructor_detail">CONSTR</A>&nbsp;|&nbsp;<A HREF="#method_detail">METHOD</A></FONT></TD>
</TR>
</TABLE>
<A NAME="skip-navbar_top"></A>
<!-- ========= END OF TOP NAVBAR ========= -->

<HR>
<!-- ======== START OF CLASS DATA ======== -->
<H2>
<FONT SIZE="-1">
com.google.ads</FONT>
<BR>
Class AdRequest</H2>
<PRE>
<A HREF="http://developer.android.com/reference/java/lang/Object.html?is-external=true" title="class or interface in java.lang">java.lang.Object</A>
  <IMG SRC="../../../resources/inherit.gif" ALT="extended by "><B>com.google.ads.AdRequest</B>
</PRE>
<HR>
<DL>
<DT><PRE>public class <B>AdRequest</B><DT>extends <A HREF="http://developer.android.com/reference/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</A></DL>
</PRE>

<P>
An <A HREF="../../../com/google/ads/AdRequest.html" title="class in com.google.ads"><CODE>AdRequest</CODE></A> object contains information about the ad to fetch. The
 information is primarily for targeting, though parameters can also be set to
 control ad formats and such.
<P>

<P>
<HR>

<P>
<!-- ======== NESTED CLASS SUMMARY ======== -->

<A NAME="nested_class_summary"><!-- --></A>
<TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
<TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
<TH ALIGN="left" COLSPAN="2"><FONT SIZE="+2">
<B>Nested Class Summary</B></FONT></TH>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>static&nbsp;class</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../com/google/ads/AdRequest.ErrorCode.html" title="enum in com.google.ads">AdRequest.ErrorCode</A></B></CODE>

<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;An enumeration of the various types of errors that might occur while
 fetching an ad.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>static&nbsp;class</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../com/google/ads/AdRequest.Gender.html" title="enum in com.google.ads">AdRequest.Gender</A></B></CODE>

<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;The gender of the user for targeting purposes.</TD>
</TR>
</TABLE>
&nbsp;<!-- =========== FIELD SUMMARY =========== -->

<A NAME="field_summary"><!-- --></A>
<TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
<TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
<TH ALIGN="left" COLSPAN="2"><FONT SIZE="+2">
<B>Field Summary</B></FONT></TH>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>static&nbsp;<A HREF="http://developer.android.com/reference/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A></CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../com/google/ads/AdRequest.html#LOGTAG">LOGTAG</A></B></CODE>

<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;The tag the SDK uses for all logging messages.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>static&nbsp;<A HREF="http://developer.android.com/reference/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A></CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../com/google/ads/AdRequest.html#TEST_EMULATOR">TEST_EMULATOR</A></B></CODE>

<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;The constant for the emulator's device ID.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>static&nbsp;<A HREF="http://developer.android.com/reference/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A></CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../com/google/ads/AdRequest.html#VERSION">VERSION</A></B></CODE>

<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;The current version of the SDK.</TD>
</TR>
</TABLE>
&nbsp;
<!-- ======== CONSTRUCTOR SUMMARY ======== -->

<A NAME="constructor_summary"><!-- --></A>
<TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
<TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
<TH ALIGN="left" COLSPAN="2"><FONT SIZE="+2">
<B>Constructor Summary</B></FONT></TH>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD><CODE><B><A HREF="../../../com/google/ads/AdRequest.html#AdRequest()">AdRequest</A></B>()</CODE>

<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</TD>
</TR>
</TABLE>
&nbsp;
<!-- ========== METHOD SUMMARY =========== -->

<A NAME="method_summary"><!-- --></A>
<TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
<TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
<TH ALIGN="left" COLSPAN="2"><FONT SIZE="+2">
<B>Method Summary</B></FONT></TH>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>&nbsp;void</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../com/google/ads/AdRequest.html#addExtra(java.lang.String, java.lang.Object)">addExtra</A></B>(<A HREF="http://developer.android.com/reference/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A>&nbsp;key,
         <A HREF="http://developer.android.com/reference/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</A>&nbsp;value)</CODE>

<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Adds an extra ad request parameter.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>&nbsp;void</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../com/google/ads/AdRequest.html#addKeyword(java.lang.String)">addKeyword</A></B>(<A HREF="http://developer.android.com/reference/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A>&nbsp;keyword)</CODE>

<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Adds a keyword.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>&nbsp;void</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../com/google/ads/AdRequest.html#addTestDevice(java.lang.String)">addTestDevice</A></B>(<A HREF="http://developer.android.com/reference/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A>&nbsp;testDevice)</CODE>

<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Causes test ads to be returned to a device.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>&nbsp;<A HREF="http://developer.android.com/reference/java/util/Map.html?is-external=true" title="class or interface in java.util">Map</A>&lt;<A HREF="http://developer.android.com/reference/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A>,<A HREF="http://developer.android.com/reference/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</A>&gt;</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../com/google/ads/AdRequest.html#getRequestMap(android.content.Context)">getRequestMap</A></B>(<A HREF="http://developer.android.com/reference/android/content/Context.html?is-external=true" title="class or interface in android.content">Context</A>&nbsp;context)</CODE>

<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Creates a map from all of the information contained within this
 <A HREF="../../../com/google/ads/AdRequest.html" title="class in com.google.ads"><CODE>AdRequest</CODE></A>.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>&nbsp;boolean</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../com/google/ads/AdRequest.html#isTestDevice(android.content.Context)">isTestDevice</A></B>(<A HREF="http://developer.android.com/reference/android/content/Context.html?is-external=true" title="class or interface in android.content">Context</A>&nbsp;context)</CODE>

<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Returns <code>true</code> if this device will have test ads returned or
 <code>false</code> if real ads are returned.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>&nbsp;void</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../com/google/ads/AdRequest.html#setBirthday(java.lang.String)">setBirthday</A></B>(<A HREF="http://developer.android.com/reference/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A>&nbsp;birthday)</CODE>

<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Sets the user's birthday for targeting purposes.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>&nbsp;void</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../com/google/ads/AdRequest.html#setExtras(java.util.Map)">setExtras</A></B>(<A HREF="http://developer.android.com/reference/java/util/Map.html?is-external=true" title="class or interface in java.util">Map</A>&lt;<A HREF="http://developer.android.com/reference/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A>,<A HREF="http://developer.android.com/reference/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</A>&gt;&nbsp;extras)</CODE>

<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Sets the extra ad request parameters.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>&nbsp;void</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../com/google/ads/AdRequest.html#setGender(com.google.ads.AdRequest.Gender)">setGender</A></B>(<A HREF="../../../com/google/ads/AdRequest.Gender.html" title="enum in com.google.ads">AdRequest.Gender</A>&nbsp;gender)</CODE>

<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Sets the user's gender for targeting purposes.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>&nbsp;void</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../com/google/ads/AdRequest.html#setKeywords(java.util.Set)">setKeywords</A></B>(<A HREF="http://developer.android.com/reference/java/util/Set.html?is-external=true" title="class or interface in java.util">Set</A>&lt;<A HREF="http://developer.android.com/reference/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A>&gt;&nbsp;keywords)</CODE>

<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Sets the keywords.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>&nbsp;void</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../com/google/ads/AdRequest.html#setLocation(android.location.Location)">setLocation</A></B>(<A HREF="http://developer.android.com/reference/android/location/Location.html?is-external=true" title="class or interface in android.location">Location</A>&nbsp;location)</CODE>

<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Sets the user's location for targeting purposes.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>&nbsp;void</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../com/google/ads/AdRequest.html#setTestDevices(java.util.Set)">setTestDevices</A></B>(<A HREF="http://developer.android.com/reference/java/util/Set.html?is-external=true" title="class or interface in java.util">Set</A>&lt;<A HREF="http://developer.android.com/reference/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A>&gt;&nbsp;testDevices)</CODE>

<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Sets the test devices.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>&nbsp;void</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../com/google/ads/AdRequest.html#setTesting(boolean)">setTesting</A></B>(boolean&nbsp;testing)</CODE>

<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<B>Deprecated.</B>&nbsp;</TD>
</TR>
</TABLE>
&nbsp;<A NAME="methods_inherited_from_class_java.lang.Object"><!-- --></A>
<TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
<TR BGCOLOR="#EEEEFF" CLASS="TableSubHeadingColor">
<TH ALIGN="left"><B>Methods inherited from class java.lang.<A HREF="http://developer.android.com/reference/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</A></B></TH>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD><CODE><A HREF="http://developer.android.com/reference/java/lang/Object.html?is-external=true#equals(java.lang.Object)" title="class or interface in java.lang">equals</A>, <A HREF="http://developer.android.com/reference/java/lang/Object.html?is-external=true#getClass()" title="class or interface in java.lang">getClass</A>, <A HREF="http://developer.android.com/reference/java/lang/Object.html?is-external=true#hashCode()" title="class or interface in java.lang">hashCode</A>, <A HREF="http://developer.android.com/reference/java/lang/Object.html?is-external=true#notify()" title="class or interface in java.lang">notify</A>, <A HREF="http://developer.android.com/reference/java/lang/Object.html?is-external=true#notifyAll()" title="class or interface in java.lang">notifyAll</A>, <A HREF="http://developer.android.com/reference/java/lang/Object.html?is-external=true#toString()" title="class or interface in java.lang">toString</A>, <A HREF="http://developer.android.com/reference/java/lang/Object.html?is-external=true#wait()" title="class or interface in java.lang">wait</A>, <A HREF="http://developer.android.com/reference/java/lang/Object.html?is-external=true#wait(long)" title="class or interface in java.lang">wait</A>, <A HREF="http://developer.android.com/reference/java/lang/Object.html?is-external=true#wait(long, int)" title="class or interface in java.lang">wait</A></CODE></TD>
</TR>
</TABLE>
&nbsp;
<P>

<!-- ============ FIELD DETAIL =========== -->

<A NAME="field_detail"><!-- --></A>
<TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
<TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
<TH ALIGN="left" COLSPAN="1"><FONT SIZE="+2">
<B>Field Detail</B></FONT></TH>
</TR>
</TABLE>

<A NAME="VERSION"><!-- --></A><H3>
VERSION</H3>
<PRE>
public static final <A HREF="http://developer.android.com/reference/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A> <B>VERSION</B></PRE>
<DL>
<DD>The current version of the SDK.
<P>
<DL>
<DT><B>See Also:</B><DD><A HREF="../../../constant-values.html#com.google.ads.AdRequest.VERSION">Constant Field Values</A></DL>
</DL>
<HR>

<A NAME="LOGTAG"><!-- --></A><H3>
LOGTAG</H3>
<PRE>
public static final <A HREF="http://developer.android.com/reference/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A> <B>LOGTAG</B></PRE>
<DL>
<DD>The tag the SDK uses for all logging messages.
<P>
<DL>
<DT><B>See Also:</B><DD><A HREF="../../../constant-values.html#com.google.ads.AdRequest.LOGTAG">Constant Field Values</A></DL>
</DL>
<HR>

<A NAME="TEST_EMULATOR"><!-- --></A><H3>
TEST_EMULATOR</H3>
<PRE>
public static final <A HREF="http://developer.android.com/reference/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A> <B>TEST_EMULATOR</B></PRE>
<DL>
<DD>The constant for the emulator's device ID.
<P>
<DL>
</DL>
</DL>

<!-- ========= CONSTRUCTOR DETAIL ======== -->

<A NAME="constructor_detail"><!-- --></A>
<TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
<TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
<TH ALIGN="left" COLSPAN="1"><FONT SIZE="+2">
<B>Constructor Detail</B></FONT></TH>
</TR>
</TABLE>

<A NAME="AdRequest()"><!-- --></A><H3>
AdRequest</H3>
<PRE>
public <B>AdRequest</B>()</PRE>
<DL>
</DL>

<!-- ============ METHOD DETAIL ========== -->

<A NAME="method_detail"><!-- --></A>
<TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
<TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
<TH ALIGN="left" COLSPAN="1"><FONT SIZE="+2">
<B>Method Detail</B></FONT></TH>
</TR>
</TABLE>

<A NAME="setGender(com.google.ads.AdRequest.Gender)"><!-- --></A><H3>
setGender</H3>
<PRE>
public void <B>setGender</B>(<A HREF="../../../com/google/ads/AdRequest.Gender.html" title="enum in com.google.ads">AdRequest.Gender</A>&nbsp;gender)</PRE>
<DL>
<DD>Sets the user's gender for targeting purposes.
<P>
<DD><DL>
<DT><B>Parameters:</B><DD><CODE>gender</CODE> - the gender.</DL>
</DD>
</DL>
<HR>

<A NAME="setBirthday(java.lang.String)"><!-- --></A><H3>
setBirthday</H3>
<PRE>
public void <B>setBirthday</B>(<A HREF="http://developer.android.com/reference/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A>&nbsp;birthday)</PRE>
<DL>
<DD>Sets the user's birthday for targeting purposes.
<P>
<DD><DL>
<DT><B>Parameters:</B><DD><CODE>birthday</CODE> - the birthday <A HREF="http://developer.android.com/reference/java/lang/String.html?is-external=true" title="class or interface in java.lang"><CODE>String</CODE></A> in the format of
 <code>YYYYMMDD</code>.</DL>
</DD>
</DL>
<HR>

<A NAME="setKeywords(java.util.Set)"><!-- --></A><H3>
setKeywords</H3>
<PRE>
public void <B>setKeywords</B>(<A HREF="http://developer.android.com/reference/java/util/Set.html?is-external=true" title="class or interface in java.util">Set</A>&lt;<A HREF="http://developer.android.com/reference/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A>&gt;&nbsp;keywords)</PRE>
<DL>
<DD>Sets the keywords.
<P>
<DD><DL>
<DT><B>Parameters:</B><DD><CODE>keywords</CODE> - the keywords.<DT><B>See Also:</B><DD><A HREF="../../../com/google/ads/AdRequest.html#addKeyword(java.lang.String)"><CODE>addKeyword(String)</CODE></A></DL>
</DD>
</DL>
<HR>

<A NAME="addKeyword(java.lang.String)"><!-- --></A><H3>
addKeyword</H3>
<PRE>
public void <B>addKeyword</B>(<A HREF="http://developer.android.com/reference/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A>&nbsp;keyword)</PRE>
<DL>
<DD>Adds a keyword.
<P>
<DD><DL>
<DT><B>Parameters:</B><DD><CODE>keyword</CODE> - the keyword to add.<DT><B>See Also:</B><DD><A HREF="../../../com/google/ads/AdRequest.html#setKeywords(java.util.Set)"><CODE>setKeywords(Set)</CODE></A></DL>
</DD>
</DL>
<HR>

<A NAME="setExtras(java.util.Map)"><!-- --></A><H3>
setExtras</H3>
<PRE>
public void <B>setExtras</B>(<A HREF="http://developer.android.com/reference/java/util/Map.html?is-external=true" title="class or interface in java.util">Map</A>&lt;<A HREF="http://developer.android.com/reference/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A>,<A HREF="http://developer.android.com/reference/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</A>&gt;&nbsp;extras)</PRE>
<DL>
<DD>Sets the extra ad request parameters.
<P>
<DD><DL>
<DT><B>Parameters:</B><DD><CODE>extras</CODE> - the new map of values to send with the ad request.<DT><B>See Also:</B><DD><A HREF="../../../com/google/ads/AdRequest.html#addExtra(java.lang.String, java.lang.Object)"><CODE>addExtra(String, Object)</CODE></A></DL>
</DD>
</DL>
<HR>

<A NAME="addExtra(java.lang.String, java.lang.Object)"><!-- --></A><H3>
addExtra</H3>
<PRE>
public void <B>addExtra</B>(<A HREF="http://developer.android.com/reference/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A>&nbsp;key,
                     <A HREF="http://developer.android.com/reference/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</A>&nbsp;value)</PRE>
<DL>
<DD>Adds an extra ad request parameter.
<P>
<DD><DL>
<DT><B>Parameters:</B><DD><CODE>key</CODE> - the key of the extra to add.<DD><CODE>value</CODE> - the value of the extra to add.<DT><B>See Also:</B><DD><A HREF="../../../com/google/ads/AdRequest.html#setExtras(java.util.Map)"><CODE>setExtras(Map)</CODE></A></DL>
</DD>
</DL>
<HR>

<A NAME="setLocation(android.location.Location)"><!-- --></A><H3>
setLocation</H3>
<PRE>
public void <B>setLocation</B>(<A HREF="http://developer.android.com/reference/android/location/Location.html?is-external=true" title="class or interface in android.location">Location</A>&nbsp;location)</PRE>
<DL>
<DD>Sets the user's location for targeting purposes.
<P>
<DD><DL>
<DT><B>Parameters:</B><DD><CODE>location</CODE> - the <A HREF="http://developer.android.com/reference/android/location/Location.html?is-external=true" title="class or interface in android.location"><CODE>Location</CODE></A>.</DL>
</DD>
</DL>
<HR>

<A NAME="setTesting(boolean)"><!-- --></A><H3>
setTesting</H3>
<PRE>
<FONT SIZE="-1"><A HREF="http://developer.android.com/reference/java/lang/Deprecated.html?is-external=true" title="class or interface in java.lang">@Deprecated</A>
</FONT>public void <B>setTesting</B>(boolean&nbsp;testing)</PRE>
<DL>
<DD><B>Deprecated.</B>&nbsp;
<P>
<DD>This method is deprecated. Use <A HREF="../../../com/google/ads/AdRequest.html#addTestDevice(java.lang.String)"><CODE>addTestDevice(String)</CODE></A> or
 <A HREF="../../../com/google/ads/AdRequest.html#setTestDevices(java.util.Set)"><CODE>setTestDevices(Set)</CODE></A> instead.
<P>
<DD><DL>
<DT><B>Parameters:</B><DD><CODE>testing</CODE> - <code>true</code> if the test ads should be shown on emulators.<DT><B>See Also:</B><DD><A HREF="../../../com/google/ads/AdRequest.html#addTestDevice(java.lang.String)"><CODE>addTestDevice(String)</CODE></A>,
<A HREF="../../../com/google/ads/AdRequest.html#setTestDevices(java.util.Set)"><CODE>setTestDevices(Set)</CODE></A></DL>
</DD>
</DL>
<HR>

<A NAME="getRequestMap(android.content.Context)"><!-- --></A><H3>
getRequestMap</H3>
<PRE>
public <A HREF="http://developer.android.com/reference/java/util/Map.html?is-external=true" title="class or interface in java.util">Map</A>&lt;<A HREF="http://developer.android.com/reference/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A>,<A HREF="http://developer.android.com/reference/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</A>&gt; <B>getRequestMap</B>(<A HREF="http://developer.android.com/reference/android/content/Context.html?is-external=true" title="class or interface in android.content">Context</A>&nbsp;context)</PRE>
<DL>
<DD>Creates a map from all of the information contained within this
 <A HREF="../../../com/google/ads/AdRequest.html" title="class in com.google.ads"><CODE>AdRequest</CODE></A>.
<P>
<DD><DL>

<DT><B>Returns:</B><DD>the <A HREF="http://developer.android.com/reference/java/util/Map.html?is-external=true" title="class or interface in java.util"><CODE>Map</CODE></A> with all the parameters and their associated keys.</DL>
</DD>
</DL>
<HR>

<A NAME="addTestDevice(java.lang.String)"><!-- --></A><H3>
addTestDevice</H3>
<PRE>
public void <B>addTestDevice</B>(<A HREF="http://developer.android.com/reference/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A>&nbsp;testDevice)</PRE>
<DL>
<DD>Causes test ads to be returned to a device. Look at <code>logcat</code> while
 requesting an ad to see how to return test ads to a device. There will
 be a log message with the code needed to add the current device to the
 list of test devices. For example:
 <pre class="code">
   adRequest.addTestDevice(AdRequest.TEST_EMULATOR);
   adRequest.addTestDevice("E83D20734F72FB3108F104ABC0FFC738"); // My T-Mobile G1 test phone
 </pre>
<P>
<DD><DL>
<DT><B>Parameters:</B><DD><CODE>testDevice</CODE> - the device ID. Use <A HREF="../../../com/google/ads/AdRequest.html#TEST_EMULATOR"><CODE>TEST_EMULATOR</CODE></A> to get test
 ads in the emulator.<DT><B>See Also:</B><DD><A HREF="../../../com/google/ads/AdRequest.html#setTestDevices(java.util.Set)"><CODE>setTestDevices(Set)</CODE></A></DL>
</DD>
</DL>
<HR>

<A NAME="setTestDevices(java.util.Set)"><!-- --></A><H3>
setTestDevices</H3>
<PRE>
public void <B>setTestDevices</B>(<A HREF="http://developer.android.com/reference/java/util/Set.html?is-external=true" title="class or interface in java.util">Set</A>&lt;<A HREF="http://developer.android.com/reference/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A>&gt;&nbsp;testDevices)</PRE>
<DL>
<DD>Sets the test devices.
<P>
<DD><DL>
<DT><B>Parameters:</B><DD><CODE>testDevices</CODE> - the test devices.<DT><B>See Also:</B><DD><A HREF="../../../com/google/ads/AdRequest.html#addTestDevice(java.lang.String)"><CODE>addTestDevice(String)</CODE></A></DL>
</DD>
</DL>
<HR>

<A NAME="isTestDevice(android.content.Context)"><!-- --></A><H3>
isTestDevice</H3>
<PRE>
public boolean <B>isTestDevice</B>(<A HREF="http://developer.android.com/reference/android/content/Context.html?is-external=true" title="class or interface in android.content">Context</A>&nbsp;context)</PRE>
<DL>
<DD>Returns <code>true</code> if this device will have test ads returned or
 <code>false</code> if real ads are returned.
<P>
<DD><DL>
<DT><B>Parameters:</B><DD><CODE>context</CODE> - the <A HREF="http://developer.android.com/reference/android/content/Context.html?is-external=true" title="class or interface in android.content"><CODE>Context</CODE></A> used to determine the current device's
 ID.
<DT><B>Returns:</B><DD><code>true</code> if the current device has been enabled for testing.</DL>
</DD>
</DL>
<!-- ========= END OF CLASS DATA ========= -->
<HR>


<!-- ======= START OF BOTTOM NAVBAR ====== -->
<A NAME="navbar_bottom"><!-- --></A>
<A HREF="#skip-navbar_bottom" title="Skip navigation links"></A>
<TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
<TR>
<TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
<A NAME="navbar_bottom_firstrow"><!-- --></A>
<TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
  <TR ALIGN="center" VALIGN="top">
  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="../../../com/google/ads/package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>
  <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Class</B></FONT>&nbsp;</TD>
  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
  </TR>
</TABLE>
</TD>
<TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
</EM>
</TD>
</TR>

<TR>
<TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
&nbsp;<A HREF="../../../com/google/ads/AdListener.html" title="interface in com.google.ads"><B>PREV CLASS</B></A>&nbsp;
&nbsp;<A HREF="../../../com/google/ads/AdRequest.ErrorCode.html" title="enum in com.google.ads"><B>NEXT CLASS</B></A></FONT></TD>
<TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
  <A HREF="../../../index.html?com/google/ads/AdRequest.html" target="_top"><B>FRAMES</B></A>  &nbsp;
&nbsp;<A HREF="AdRequest.html" target="_top"><B>NO FRAMES</B></A>  &nbsp;
&nbsp;<SCRIPT type="text/javascript">
  <!--
 if(window==top) {
   document.writeln('<A HREF="../../../allclasses-noframe.html"><B>All Classes</B></A>');
 }
 //-->
</SCRIPT>
<NOSCRIPT>
  <A HREF="../../../allclasses-noframe.html"><B>All Classes</B></A>
</NOSCRIPT>


</FONT></TD>
</TR>
<TR>
<TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
  SUMMARY:&nbsp;<A HREF="#nested_class_summary">NESTED</A>&nbsp;|&nbsp;<A HREF="#field_summary">FIELD</A>&nbsp;|&nbsp;<A HREF="#constructor_summary">CONSTR</A>&nbsp;|&nbsp;<A HREF="#method_summary">METHOD</A></FONT></TD>
<TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
DETAIL:&nbsp;<A HREF="#field_detail">FIELD</A>&nbsp;|&nbsp;<A HREF="#constructor_detail">CONSTR</A>&nbsp;|&nbsp;<A HREF="#method_detail">METHOD</A></FONT></TD>
</TR>
</TABLE>
<A NAME="skip-navbar_bottom"></A>
<!-- ======== END OF BOTTOM NAVBAR ======= -->

<HR>

</BODY>
</HTML>