UploadRequest class final
HTTP multipart upload request.
- Inheritance
-
- Object
- TransferRequest
- UploadRequest
Constructors
-
UploadRequest({required String sourcePath, required Uri destination, String method = 'POST', String fieldName = 'file', UploadSourcePolicy sourcePolicy = UploadSourcePolicy.reference, Map<
String, String> headers = const {}, String? authScope, String? groupId, TransferPriority priority = TransferPriority.normal, RetryPolicy? retryPolicy, NetworkPolicy? networkPolicy, TransferNotification? notification, Checksum? checksum, String? expectedChecksum}) -
Creates a multipart upload request.
const
Properties
- authScope → String?
-
Opaque key passed to the configured authentication provider.
finalinherited
- checksum → Checksum?
-
Hash algorithm used to verify the local artifact.
finalinherited
- destination → Uri
-
Remote upload endpoint.
final
- expectedChecksum → String?
-
Expected lowercase or uppercase hexadecimal checksum.
finalinherited
- fieldName → String
-
Multipart form field containing the file.
final
- groupId → String?
-
Optional application-defined grouping identifier.
finalinherited
- hashCode → int
-
The hash code for this object.
no setterinherited
-
headers
→ Map<
String, String> -
Additional HTTP headers sent with the request.
finalinherited
- method → String
-
HTTP method used for the multipart request.
final
- networkPolicy → NetworkPolicy?
-
Request-specific network policy, or
nullto use manager defaults.finalinherited - notification → TransferNotification?
-
Native notification preferences.
finalinherited
- priority → TransferPriority
-
Queue scheduling priority.
finalinherited
- protocol → String
-
Protocol identifier used to select an execution engine.
no setteroverride
- remoteUri → Uri
-
Remote endpoint used for scheduling and per-host concurrency.
no setteroverride
- retryPolicy → RetryPolicy?
-
Request-specific retry policy, or
nullto use manager defaults.finalinherited - runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
- sourcePath → String
-
Path of the local file to upload.
final
- sourcePolicy → UploadSourcePolicy
-
Persistence strategy for the local source file.
final
- type → TransferType
-
Whether this request uploads or downloads data.
no setteroverride
Methods
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
toString(
) → String -
A string representation of this object.
inherited
-
withSourcePath(
String path) → UploadRequest -
Returns an equivalent request that reads from
path.
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited