Class MyTargetConfig.Builder

java.lang.Object
com.my.target.common.MyTargetConfig.Builder
Enclosing class:
MyTargetConfig

public static final class MyTargetConfig.Builder extends Object
  • Constructor Details

    • Builder

      public Builder()
  • Method Details

    • build

      @NonNull public MyTargetConfig build()
    • from

      @NonNull public MyTargetConfig.Builder from(@NonNull MyTargetConfig myTargetConfig)
      Copies all settings from previous config, it can be used for changing only certain fields of config
      Parameters:
      myTargetConfig - previous config
    • withTrackingEnvironment

      @NonNull public MyTargetConfig.Builder withTrackingEnvironment(boolean enabled)
      Provides the option to disable the collection of environment params. The default is TRUE (information is collected).
      Parameters:
      enabled - enable or disable collection
    • withTrackingLocation

      @NonNull public MyTargetConfig.Builder withTrackingLocation(boolean enabled)
      Provides the option to enable the collection of location and location-based params. The default is FALSE (information is not collected).
      Parameters:
      enabled - enable or disable collection
    • withTestDevices

      @NonNull public MyTargetConfig.Builder withTestDevices(@Nullable String... testDevices)
      Adds test device/s to show test ad. When ad is loading, SDK writes to log
           D/[myTarget]: Device instanceId is {INSTANCE_ID}. Use this value in adInstance.withTestDevices() to enable test mode on this device.
       
      this value should be put here. Multiple, if code needs to run on several test devices. Method must be called before loading Ad
      Parameters:
      testDevices - instanceId from the Logcat