@RestController public class DocumentController extends Object
| Constructor and Description |
|---|
DocumentController() |
| Modifier and Type | Method and Description |
|---|---|
List<String> |
listDocuments(String user,
String password,
String storageId,
String path)
lists files in user's private space.
|
void |
readDocument(String user,
String password,
String storageId,
String path,
javax.servlet.http.HttpServletResponse response)
Reads user's private file.
|
void |
removeDocument(String user,
String password,
String storageId,
String path)
deletes files from user's private space.
|
void |
writeDocument(String user,
String password,
String storageId,
String path,
org.springframework.web.multipart.MultipartFile file)
Writes file to user's private space.
|
@GetMapping(value="/document/{path:.*}",
produces="application/octet-stream")
public void readDocument(@RequestHeader
String user,
@RequestHeader
String password,
@RequestHeader(defaultValue="DEFAULT")
String storageId,
@PathVariable
String path,
javax.servlet.http.HttpServletResponse response)
@PutMapping(value="/document/{path:.*}",
consumes="multipart/form-data")
public void writeDocument(@RequestHeader
String user,
@RequestHeader
String password,
@RequestHeader(defaultValue="DEFAULT")
String storageId,
@PathVariable
String path,
@RequestParam(value="file")
org.springframework.web.multipart.MultipartFile file)
@GetMapping(value="/documents/{path:.*}")
public List<String> listDocuments(@RequestHeader
String user,
@RequestHeader
String password,
@RequestHeader(defaultValue="DEFAULT")
String storageId,
@PathVariable(required=false)
String path)
Copyright © 2020. All rights reserved.