# Print output for @column tags ?>
Developers

- Design
- Develop
- Distribute

Developer Console

## Most visited

## Recently visited

## Results for

Summary: Ctors | Methods | Inherited Methods

# DownloadRequest.Builder

`public static class DownloadRequest.Builder`
`extends Object` ``

java.lang.Object
↳ | android.telephony.mbms.DownloadRequest.Builder

## Summary

### Public constructors
`Builder(Uri sourceUri, Uri destinationUri)` Builds a new DownloadRequest.

### Public methods
`DownloadRequest` | `build()`
`static DownloadRequest.Builder` | `fromDownloadRequest(DownloadRequest other)` Constructs a `Builder` from a `DownloadRequest`
`static DownloadRequest.Builder` | `fromSerializedRequest(byte[] data)` This method constructs a new instance of `Builder` based on the serialized data passed in.
`DownloadRequest.Builder` | `setAppIntent(Intent intent)` Set the `Intent` that should be sent when the download completes or fails.
`DownloadRequest.Builder` | `setServiceInfo(FileServiceInfo serviceInfo)` Sets the service from which the download request to be built will download from.
`DownloadRequest.Builder` | `setSubscriptionId(int subscriptionId)` Set the subscription ID on which the file(s) should be downloaded.

### Inherited methods
From class `java.lang.Object`
`Object` | `clone()` Creates and returns a copy of this object.
`boolean` | `equals(Object obj)` Indicates whether some other object is "equal to" this one.
`void` | `finalize()` Called by the garbage collector on an object when garbage collection determines that there are no more references to the object.
`final Class<?>` | `getClass()` Returns the runtime class of this `Object`.
`int` | `hashCode()` Returns a hash code value for the object.
`final void` | `notify()` Wakes up a single thread that is waiting on this object's monitor.
`final void` | `notifyAll()` Wakes up all threads that are waiting on this object's monitor.
`String` | `toString()` Returns a string representation of the object.
`final void` | `wait(long timeout, int nanos)` Causes the current thread to wait until another thread invokes the `notify()` method or the `notifyAll()` method for this object, or some other thread interrupts the current thread, or a certain amount of real time has elapsed.
`final void` | `wait(long timeout)` Causes the current thread to wait until either another thread invokes the `notify()` method or the `notifyAll()` method for this object, or a specified amount of time has elapsed.
`final void` | `wait()` Causes the current thread to wait until another thread invokes the `notify()` method or the `notifyAll()` method for this object.

## Public constructors

### Builder

    public Builder (Uri sourceUri,
                    Uri destinationUri)

Builds a new DownloadRequest.

Parameters
`sourceUri` | `Uri`: the source URI for the DownloadRequest to be built. This URI should never be null. This value cannot be `null`.
`destinationUri` | `Uri`: The final location for the file(s) that are to be downloaded. It must be on the same filesystem as the temp file directory set via `MbmsDownloadSession.setTempFileRootDirectory(File)`. The provided path must be a directory that exists. An `IllegalArgumentException` will be thrown otherwise. This value cannot be `null`.

## Public methods

### build

    public DownloadRequest build ()

Returns
`DownloadRequest` |

### fromDownloadRequest

    public static DownloadRequest.Builder fromDownloadRequest (DownloadRequest other)

Constructs a `Builder` from a `DownloadRequest`

Parameters
`other` | `DownloadRequest`: The `DownloadRequest` from which the data for the `Builder` should come.

Returns
`DownloadRequest.Builder` | An instance of `Builder` pre-populated with data from the provided `DownloadRequest`.

### fromSerializedRequest

    public static DownloadRequest.Builder fromSerializedRequest (byte[] data)

This method constructs a new instance of `Builder` based on the serialized data passed in.

Parameters
`data` | `byte`: A byte array, the contents of which should have been originally obtained from `DownloadRequest#toByteArray()`.

Returns
`DownloadRequest.Builder` |

### setAppIntent

    public DownloadRequest.Builder setAppIntent (Intent intent)

Set the `Intent` that should be sent when the download completes or fails. This should be an intent with a explicit `ComponentName` targeted to a `BroadcastReceiver` in the app's package. The middleware should not use this method.

Returns
`DownloadRequest.Builder` |

### setServiceInfo

    public DownloadRequest.Builder setServiceInfo (FileServiceInfo serviceInfo)

Sets the service from which the download request to be built will download from.

Returns
`DownloadRequest.Builder` |

### setSubscriptionId

    public DownloadRequest.Builder setSubscriptionId (int subscriptionId)

Set the subscription ID on which the file(s) should be downloaded.

Returns
`DownloadRequest.Builder` |

Full name *
Email address *
Company / developer name
One of your Play Store app URLs *
Which best describes your business:*
Apps
Games
Apps & Games
*
*