2020-12-25 20:41:34 +08:00
|
|
|
package cn.keking.service.impl;
|
|
|
|
|
|
|
|
|
|
import cn.keking.model.FileAttribute;
|
|
|
|
|
import cn.keking.service.FilePreview;
|
|
|
|
|
import org.springframework.stereotype.Service;
|
|
|
|
|
import org.springframework.ui.Model;
|
|
|
|
|
|
|
|
|
|
/**
|
|
|
|
|
* @author kl (http://kailing.pub)
|
|
|
|
|
* @since 2020/12/25
|
|
|
|
|
*/
|
|
|
|
|
@Service
|
|
|
|
|
public class XmlFilePreviewImpl implements FilePreview {
|
|
|
|
|
|
|
|
|
|
private final SimTextFilePreviewImpl simTextFilePreview;
|
|
|
|
|
|
|
|
|
|
public XmlFilePreviewImpl(SimTextFilePreviewImpl simTextFilePreview) {
|
|
|
|
|
this.simTextFilePreview = simTextFilePreview;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
@Override
|
|
|
|
|
public String filePreviewHandle(String url, Model model, FileAttribute fileAttribute) {
|
2020-12-28 14:50:05 +08:00
|
|
|
simTextFilePreview.filePreviewHandle(url, model, fileAttribute);
|
|
|
|
|
return XML_FILE_PREVIEW_PAGE;
|
2020-12-25 20:41:34 +08:00
|
|
|
}
|
|
|
|
|
}
|