本文整理汇总了Java中com.amap.api.maps.model.Marker.remove方法的典型用法代码示例。如果您正苦于以下问题:Java Marker.remove方法的具体用法?Java Marker.remove怎么用?Java Marker.remove使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类com.amap.api.maps.model.Marker
的用法示例。
在下文中一共展示了Marker.remove方法的13个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。
示例1: onDestroy
import com.amap.api.maps.model.Marker; //导入方法依赖的package包/类
/**
* 在不适用此Overlay功能时,以及onDestroy的生命周期里,调用此方法,回收相关资源,避免内存泄漏
*/
public void onDestroy() {
for (RankEntity rankEntity : mRankEntities) {
Marker marker = rankEntity.getMarker();
if (marker != null) {
marker.remove();
marker.destroy();
}
}
mRankEntities.clear();
mBitmapCache.evictAll();
}
示例2: onDestroy
import com.amap.api.maps.model.Marker; //导入方法依赖的package包/类
public void onDestroy() {
mIsCanceled = true;
mSignClusterHandler.removeCallbacksAndMessages(null);
mMarkerhandler.removeCallbacksAndMessages(null);
mSignClusterThread.quit();
mMarkerHandlerThread.quit();
for (Marker marker : mAddMarkers) {
marker.remove();
}
mAddMarkers.clear();
mLruCache.evictAll();
}
示例3: onAnimationEnd
import com.amap.api.maps.model.Marker; //导入方法依赖的package包/类
@Override
public void onAnimationEnd() {
for(Marker marker:mRemoveMarkers){
marker.remove();
}
mRemoveMarkers.clear();
}
示例4: resetRankEntities
import com.amap.api.maps.model.Marker; //导入方法依赖的package包/类
public void resetRankEntities(List<RankEntity>rankEntities){
for (RankEntity rankEntity : mRankEntities) {
Marker marker = rankEntity.getMarker();
if (marker != null) {
marker.remove();
marker.destroy();
}
}
mRankEntities.clear();
mRankEntities=rankEntities;
generateAll();
}
示例5: removeMarkers
import com.amap.api.maps.model.Marker; //导入方法依赖的package包/类
/**
* 移除marker
*/
public static void removeMarkers() {
for(Marker marker:markers){
marker.remove();
marker.destroy();
}
markers.clear();
}
示例6: onDestroy
import com.amap.api.maps.model.Marker; //导入方法依赖的package包/类
public void onDestroy() {
mIsCanceled = true;
mSignClusterHandler.removeCallbacksAndMessages(null);
mMarkerhandler.removeCallbacksAndMessages(null);
mSignClusterThread.quit();
mMarkerHandlerThread.quit();
for (Marker marker : mAddMarkers) {
marker.remove();
}
mAddMarkers.clear();
mLruCache.evictAll();
}
示例7: onAnimationEnd
import com.amap.api.maps.model.Marker; //导入方法依赖的package包/类
@Override
public void onAnimationEnd() {
for (Marker marker : mRemoveMarkers) {
marker.remove();
}
mRemoveMarkers.clear();
}
示例8: removeMarkers
import com.amap.api.maps.model.Marker; //导入方法依赖的package包/类
private void removeMarkers() {
if(null != centerMarker){
centerMarker.remove();
centerMarker = null;
}
if (null != markerList && markerList.size() > 0) {
for (Marker marker : markerList) {
marker.remove();
}
markerList.clear();
}
}
示例9: removeMarkers
import com.amap.api.maps.model.Marker; //导入方法依赖的package包/类
private void removeMarkers() {
if (null != markerList && markerList.size() > 0) {
for (Marker marker : markerList) {
marker.remove();
}
markerList.clear();
}
}
示例10: remove
import com.amap.api.maps.model.Marker; //导入方法依赖的package包/类
public boolean remove(Marker marker) {
try {
if (mMarkers.remove(marker)) {
mAllMarkers.remove(marker);
marker.remove();
return true;
}
} catch (Exception e) {
}
return false;
}
示例11: clear
import com.amap.api.maps.model.Marker; //导入方法依赖的package包/类
public void clear() {
for (Marker marker : mMarkers) {
marker.remove();
mAllMarkers.remove(marker);
}
mMarkers.clear();
}
示例12: clear
import com.amap.api.maps.model.Marker; //导入方法依赖的package包/类
/**
* Remove all Clusterkraf-managed markers from the map
*/
public void clear() {
/**
* cancel the background thread clustering task
*/
if (clusteringTaskHost != null) {
clusteringTaskHost.cancel();
clusteringTaskHost = null;
}
/**
* cancel the background thread transition building task
*/
if (clusterTransitionsBuildingTaskHost != null) {
clusterTransitionsBuildingTaskHost.cancel();
clusterTransitionsBuildingTaskHost = null;
}
/**
* we avoid AMap.clear() so users can manage their own
* non-clustered markers on the map.
*
* @see http://code.google.com/p/gmaps-api-issues/issues/detail?id=4703
*/
if (currentMarkers != null) {
for (Marker marker : currentMarkers) {
marker.remove();
}
}
currentClusters = null;
currentClusterPointsByMarker = null;
currentMarkers = null;
previousClusters = null;
previousMarkers = null;
points.clear();
}
示例13: removePreviousMarkers
import com.amap.api.maps.model.Marker; //导入方法依赖的package包/类
private void removePreviousMarkers() {
AMap map = mapRef.get();
if (map != null && previousClusters != null && previousMarkers != null) {
for (Marker marker : previousMarkers) {
marker.remove();
}
previousMarkers = null;
previousClusters = null;
}
}