Package robaho.net.httpserver.extras
Class MultipartFormParser
java.lang.Object
robaho.net.httpserver.extras.MultipartFormParser
parse multipart form data
-
Nested Class Summary
Nested Classes -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic Map<String, List<MultipartFormParser.Part>> parse(String encoding, String content_type, InputStream is, Path storage) parse a multipart input stream, write files to storage.
-
Constructor Details
-
MultipartFormParser
public MultipartFormParser()
-
-
Method Details
-
parse
public static Map<String,List<MultipartFormParser.Part>> parse(String encoding, String content_type, InputStream is, Path storage) throws IOException parse a multipart input stream, write files to storage. The caller is responsible to delete files when they are no longer needed.- Returns:
- a map of key to either a String (non-file) or a File
- Throws:
IOException
-