Browse Source
Merge in DESIGN/design from ~DESTINY.LIN/design:fbp/master to fbp/master * commit '480148d56c5284c8b831d8ec5703010b50630bd0': REPORT-137540 - 远程设计下地图加载卡慢fbp/master
Destiny.Lin-林锦龙
1 month ago
2 changed files with 40 additions and 0 deletions
@ -0,0 +1,36 @@ |
|||||||
|
package com.fanruan.map; |
||||||
|
|
||||||
|
import com.fr.decision.webservice.v10.map.geojson.MapDataType; |
||||||
|
import com.fr.decision.webservice.v10.map.geojson.helper.GEOJSONHelper; |
||||||
|
import com.fr.decision.webservice.v10.map.geojson.helper.GEOJSONUtils; |
||||||
|
import com.fr.log.FineLoggerFactory; |
||||||
|
import com.fr.third.org.apache.commons.lang3.time.StopWatch; |
||||||
|
import com.fr.workspace.server.repository.map.MapRepository; |
||||||
|
|
||||||
|
/** |
||||||
|
* 设计器地图资源Helper |
||||||
|
* |
||||||
|
* @author Destiny.Lin |
||||||
|
* @since 11.0 |
||||||
|
* Created on 2024/9/27 |
||||||
|
*/ |
||||||
|
public class DesignGEOJSONHelper extends GEOJSONHelper { |
||||||
|
|
||||||
|
@Override |
||||||
|
protected void init() { |
||||||
|
try { |
||||||
|
|
||||||
|
StopWatch watch = new StopWatch(); |
||||||
|
watch.start(); |
||||||
|
URL_JSON_MAP.putAll(MapRepository.getInstance().getMapResource(GEOJSONUtils.getMapDataTypePath(MapDataType.GEOGRAPHIC))); |
||||||
|
URL_JSON_MAP.putAll(MapRepository.getInstance().getMapResource(GEOJSONUtils.getMapDataTypePath(MapDataType.IMAGE))); |
||||||
|
|
||||||
|
FineLoggerFactory.getLogger().info("Load chart map resources spend time {} ms", watch.getTime()); |
||||||
|
watch.stop(); |
||||||
|
|
||||||
|
} catch (Exception e) { |
||||||
|
FineLoggerFactory.getLogger().error(e.getMessage(), e); |
||||||
|
} |
||||||
|
} |
||||||
|
|
||||||
|
} |
Loading…
Reference in new issue