|
@@ -28,6 +28,7 @@ import org.opengis.feature.simple.SimpleFeature;
|
|
|
import org.opengis.filter.Filter;
|
|
|
import org.opengis.filter.FilterFactory2;
|
|
|
import org.opengis.geometry.DirectPosition;
|
|
|
+import org.springframework.stereotype.Service;
|
|
|
|
|
|
import javax.annotation.Resource;
|
|
|
import javax.imageio.ImageIO;
|
|
@@ -41,6 +42,7 @@ import java.util.UUID;
|
|
|
/**
|
|
|
* 生成图片服务
|
|
|
*/
|
|
|
+@Service
|
|
|
public class ImageServiceImpl implements IImageService {
|
|
|
@Resource
|
|
|
private ImageMapper imageMapper;
|
|
@@ -75,7 +77,7 @@ public class ImageServiceImpl implements IImageService {
|
|
|
g.dispose();
|
|
|
|
|
|
// Save image to local file system
|
|
|
- String fileName = "overlay_" + UUID.randomUUID().toString() + ".png";
|
|
|
+ String fileName = "overlay_" + UUID.randomUUID() + ".png";
|
|
|
String filePath = Paths.get(System.getProperty("user.dir"), "images", fileName).toString();
|
|
|
File outputFile = new File(filePath);
|
|
|
|