修改sdk
This commit is contained in:
@ -78,6 +78,26 @@ public class ModelConvertor {
|
||||
});
|
||||
}
|
||||
|
||||
/**
|
||||
* @param json
|
||||
* @return
|
||||
*/
|
||||
public Optional<byte[]> toByteArray(String json) {
|
||||
return Optional.ofNullable(json).map(content -> {
|
||||
try {
|
||||
Optional<SysStorageVO> op = tpDownPO(content);
|
||||
|
||||
if (op.isPresent()) {
|
||||
return op.get().getFileStream();
|
||||
}
|
||||
} catch (JsonProcessingException e) {
|
||||
log.error(json);
|
||||
log.error(e.getMessage());
|
||||
}
|
||||
return null;
|
||||
});
|
||||
}
|
||||
|
||||
/**
|
||||
* @param json
|
||||
* @return
|
||||
|
@ -14,6 +14,9 @@ public class SysStorageVO {
|
||||
/* 业务id */
|
||||
private String objectId;
|
||||
|
||||
/* 文件流 */
|
||||
private byte[] fileStream;
|
||||
|
||||
/* 文件唯一标识 */
|
||||
private String fileName;
|
||||
|
||||
|
Reference in New Issue
Block a user