Skip to end of metadata
Go to start of metadata

JavaScript is disabled on your browser.
com.appnexus.opensdk

Class TargetingParameters

  • java.lang.Object
    • com.appnexus.opensdk.TargetingParameters


  • public class TargetingParameters
    extends java.lang.Object
    An object of this type is sent to the third-party SDK's MediatedAdView object. The third-party SDK uses this object to retrieve local targeting extras that were sent to the AppNexus SDK.
    • Constructor Summary

      Constructors 
      Constructor and Description
      TargetingParameters(java.lang.String age, AdView.GENDER gender, java.util.ArrayList<android.util.Pair<java.lang.String,java.lang.String>> customKeywords, android.location.Location location, java.lang.String externalUid) 
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method and Description
      java.lang.String getAge()
      The current user's age, passed by to the ad request.
      java.util.ArrayList<android.util.Pair<java.lang.String,java.lang.String>> getCustomKeywords()
      Local custom keywords added to the ad request.
      java.lang.String getExternalUid()
      Retrieve the externalUID that was previously set.
      AdView.GENDER getGender()
      The current user's gender, passed to the ad request.
      android.location.Location getLocation()
      The current user's location, passed to the ad request.
      • Methods inherited from class java.lang.Object

        equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Constructor Detail

      • TargetingParameters

        public TargetingParameters(java.lang.String age,
                                   AdView.GENDER gender,
                                   java.util.ArrayList<android.util.Pair<java.lang.String,java.lang.String>> customKeywords,
                                   android.location.Location location,
                                   java.lang.String externalUid)
    • Method Detail

      • getExternalUid

        public java.lang.String getExternalUid()
        Retrieve the externalUID that was previously set.
        Returns:
        externalUID.
      • getAge

        public java.lang.String getAge()
        The current user's age, passed by to the ad request. Note this string may come in one of several formats: age, birth year, or age range. The default value is null.
        Returns:
        The current user's age.
      • getCustomKeywords

        public java.util.ArrayList<android.util.Pair<java.lang.String,java.lang.String>> getCustomKeywords()
        Local custom keywords added to the ad request.
        Returns:
        The current array list of key-value pairs of custom keywords.
      • getGender

        public AdView.GENDER getGender()
        The current user's gender, passed to the ad request. The default value is UNKNOWN.
        Returns:
        The user's gender.
      • getLocation

        public android.location.Location getLocation()
        The current user's location, passed to the ad request. The default value is null.
        Returns:
        The current user's location.

  • No labels