Created
April 23, 2020 15:29
-
-
Save jdegoes/de4f4d1bfff49d9cf0d9d337ce07dee3 to your computer and use it in GitHub Desktop.
Adding multipart responses into http4k
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// RFC: https://www.w3.org/Protocols/rfc1341/7_2_Multipart.html | |
interface Response { | |
fun multipartBoundary(boundary: String): Response | |
fun multiparts(): List<Response> | |
// | |
// The returned Response will use a content type of multipart response with | |
// a boundary string determined by the implementation. | |
// | |
// If you want to use a custom boundary string, then you should first set | |
// the boundary in the (multipart response) content type of this response. | |
// | |
fun multiparts(responses: List<Response>): Response | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment