去除BaseDocumentService,方法都放到DocumentService
This commit is contained in:
@@ -135,10 +135,6 @@ public class DocumentServiceImpl implements DocumentService {
|
||||
}
|
||||
}
|
||||
|
||||
public byte[] wordToPdf(byte[] source, String sourceFormat, boolean clear) {
|
||||
return wordToPdf(source, clear);
|
||||
}
|
||||
|
||||
public byte[] wordToPdf(byte[] source, boolean clear) {
|
||||
try {
|
||||
long start = System.currentTimeMillis();
|
||||
@@ -185,10 +181,6 @@ public class DocumentServiceImpl implements DocumentService {
|
||||
return null;
|
||||
}
|
||||
|
||||
public byte[] wordToImage(byte[] source, String sourceExtension, String targetExtension) {
|
||||
return wordToImage(source, targetExtension);
|
||||
}
|
||||
|
||||
public byte[] docToDocx(byte[] source) {
|
||||
return convert(source, "doc", "docx", "wdFormatDocumentDefault");
|
||||
}
|
||||
|
||||
@@ -91,7 +91,7 @@ public class DocumentServiceImpl implements DocumentService {
|
||||
* @param targetExtension 目标文件后缀名
|
||||
* @return 转换后的文件流
|
||||
*/
|
||||
public byte[] convert(byte[] source, String sourceExtension, String targetExtension) {
|
||||
private byte[] convert(byte[] source, String sourceExtension, String targetExtension) {
|
||||
try {
|
||||
sourceExtension = sourceExtension.replace(".", "");
|
||||
targetExtension = targetExtension.replace(".", "");
|
||||
@@ -131,10 +131,6 @@ public class DocumentServiceImpl implements DocumentService {
|
||||
}
|
||||
}
|
||||
|
||||
public byte[] wordToPdf(byte[] source, String sourceFormat, boolean clear) {
|
||||
return wordToPdf(source, clear);
|
||||
}
|
||||
|
||||
public byte[] wordToPdf(byte[] source, boolean clear) {
|
||||
try {
|
||||
long start = System.currentTimeMillis();
|
||||
@@ -181,10 +177,6 @@ public class DocumentServiceImpl implements DocumentService {
|
||||
return null;
|
||||
}
|
||||
|
||||
public byte[] wordToImage(byte[] source, String sourceExtension, String targetExtension) {
|
||||
return wordToImage(source, targetExtension);
|
||||
}
|
||||
|
||||
public byte[] docToDocx(byte[] source) {
|
||||
return convert(source, "doc", "docx");
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user