Back to Alamofire

MultipartEncodingFailureReason

docs/Enums/AFError/MultipartEncodingFailureReason.html

5.12.03.3 KB
Original Source

MultipartEncodingFailureReason

public enum MultipartEncodingFailureReason : Sendable

The underlying reason the .multipartEncodingFailed error occurred.

`

                bodyPartURLInvalid(url:)
                `

The fileURL provided for reading an encodable body part isn’t a file URL.

Declaration

Swift

case bodyPartURLInvalid(url: URL)

`

                bodyPartFilenameInvalid(in:)
                `

The filename of the fileURL provided has either an empty lastPathComponent or pathExtension.

Declaration

Swift

case bodyPartFilenameInvalid(in: URL)

`

                bodyPartFileNotReachable(at:)
                `

The file at the fileURL provided was not reachable.

Declaration

Swift

case bodyPartFileNotReachable(at: URL)

`

                bodyPartFileNotReachableWithError(atURL:error:)
                `

Attempting to check the reachability of the fileURL provided threw an error.

Declaration

Swift

case bodyPartFileNotReachableWithError(atURL: URL, error: any Error)

`

                bodyPartFileIsDirectory(at:)
                `

The file at the fileURL provided is actually a directory.

Declaration

Swift

case bodyPartFileIsDirectory(at: URL)

`

                bodyPartFileSizeNotAvailable(at:)
                `

The size of the file at the fileURL provided was not returned by the system.

Declaration

Swift

case bodyPartFileSizeNotAvailable(at: URL)

`

                bodyPartFileSizeQueryFailedWithError(forURL:error:)
                `

The attempt to find the size of the file at the fileURL provided threw an error.

Declaration

Swift

case bodyPartFileSizeQueryFailedWithError(forURL: URL, error: any Error)

`

                bodyPartInputStreamCreationFailed(for:)
                `

An InputStream could not be created for the provided fileURL.

Declaration

Swift

case bodyPartInputStreamCreationFailed(for: URL)

`

                outputStreamCreationFailed(for:)
                `

An OutputStream could not be created when attempting to write the encoded data to disk.

Declaration

Swift

case outputStreamCreationFailed(for: URL)

`

                outputStreamFileAlreadyExists(at:)
                `

The encoded body data could not be written to disk because a file already exists at the provided fileURL.

Declaration

Swift

case outputStreamFileAlreadyExists(at: URL)

`

                outputStreamURLInvalid(url:)
                `

The fileURL provided for writing the encoded body data to disk is not a file URL.

Declaration

Swift

case outputStreamURLInvalid(url: URL)

`

                outputStreamWriteFailed(error:)
                `

The attempt to write the encoded body data to disk failed with an underlying error.

Declaration

Swift

case outputStreamWriteFailed(error: any Error)

`

                inputStreamReadFailed(error:)
                `

The attempt to read an encoded body part InputStream failed with underlying system error.

Declaration

Swift

case inputStreamReadFailed(error: any Error)