• 设为首页
  • 点击收藏
  • 手机版
    手机扫一扫访问
    迪恩网络手机版
  • 关注官方公众号
    微信扫一扫关注
    公众号

Java Layer类代码示例

原作者: [db:作者] 来自: [db:来源] 收藏 邀请

本文整理汇总了Java中org.gwtopenmaps.openlayers.client.layer.Layer的典型用法代码示例。如果您正苦于以下问题:Java Layer类的具体用法?Java Layer怎么用?Java Layer使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。



Layer类属于org.gwtopenmaps.openlayers.client.layer包,在下文中一共展示了Layer类的20个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于我们的系统推荐出更棒的Java代码示例。

示例1: createClickControl

import org.gwtopenmaps.openlayers.client.layer.Layer; //导入依赖的package包/类
public SelectFeature createClickControl(Layer layer,
		UnselectFeatureListener unSelectListener,
		ClickFeatureListener clickFeatureListener) {

	SelectFeatureOptions clickSelectFeatureOptions = new SelectFeatureOptions();
	clickSelectFeatureOptions.onUnSelect(unSelectListener);
	clickSelectFeatureOptions.clickFeature(clickFeatureListener);
	clickSelectFeatureOptions.setToggle();
	clickSelectFeatureOptions.setMultiple();

	SelectFeature clickSelectFeature = new SelectFeature((Vector) layer,
			clickSelectFeatureOptions);

	clickSelectFeature.setClickOut(true);

	return clickSelectFeature;
}
 
开发者ID:geowe,项目名称:sig-seguimiento-vehiculos,代码行数:18,代码来源:MapControlFactory.java


示例2: onRelease

import org.gwtopenmaps.openlayers.client.layer.Layer; //导入依赖的package包/类
@Override
protected void onRelease() {
	VectorLayer layer = (VectorLayer) layerManager
			.getSelectedLayer(LayerManagerWidget.VECTOR_TAB);
	selectedFeatures = layer.getSelectedFeatures();
	if (selectedFeatures == null || selectedFeatures.length == 0) {
		messageDialogBuilder.createError(UIMessages.INSTANCE.warning(),
				UIMessages.INSTANCE.noSelectedElements()).show();
		return;
	}

	List<Layer> vectorLayers = layerManager.getLayerTree(
			LayerManagerWidget.VECTOR_TAB).getLayers();
	copyElementDialog.setLayers(vectorLayers);
	copyElementDialog.show();
}
 
开发者ID:geowe,项目名称:sig-seguimiento-vehiculos,代码行数:17,代码来源:CopyElementTool.java


示例3: getLayer

import org.gwtopenmaps.openlayers.client.layer.Layer; //导入依赖的package包/类
@Override
public Layer getLayer() {
	
	final WMTSOptions wmtsOptions = new WMTSOptions(getUrl(), getLayerName(),
               "", getTileMatrixSet());
       	wmtsOptions.setName(getLayerName());
       	wmtsOptions.setIsBaseLayer(Boolean.FALSE);
       	wmtsOptions.setFormat(getFormat());
       	wmtsOptions.setDisplayOutsideMaxExtent(true);	
       	wmtsOptions.setNumZoomLevels(GeoMapInitializer.MAX_NUM_ZOOM_LEVEL);
       	wmtsOptions.setProjection(GeoMap.INTERNAL_EPSG);
       	wmtsOptions.setTransitionEffect(TransitionEffect.RESIZE);
        wmtsOptions.setAttribution(getAttribution());

       	return new WMTS(wmtsOptions);		
}
 
开发者ID:geowe,项目名称:sig-seguimiento-vehiculos,代码行数:17,代码来源:WmtsLayerDef.java


示例4: getLayer

import org.gwtopenmaps.openlayers.client.layer.Layer; //导入依赖的package包/类
@Override
public Layer getLayer() {
	Layer layer = null;
	
	try {
		final VectorLayerConfig layerConfig = getVectorLayerConfig();
		layerConfig.setGeoDataString(file.getText());
		layer = VectorLayerFactory.createVectorLayerFromGeoData(layerConfig);
	} catch (Exception e) {
		AlertMessageBox messageBox = new AlertMessageBox(
				UIMessages.INSTANCE.warning(),
				UIMessages.INSTANCE.gditAlertMessage());
		messageBox.show();
	}
	
	return layer;
}
 
开发者ID:geowe,项目名称:sig-seguimiento-vehiculos,代码行数:18,代码来源:SampleFileVectorLayerDef.java


示例5: createLayerFromCatalog

import org.gwtopenmaps.openlayers.client.layer.Layer; //导入依赖的package包/类
private void createLayerFromCatalog(final String layerCatalog) {
	final LayerDef layerDef = appLayerCatalog.getLayer(layerCatalog);
	if (layerDef == null) {
		autoMessageBox.hide();
		messageDialogBuilder.createWarning(UIMessages.INSTANCE.warning(),
				UICatalogMessages.INSTANCE.layerNotInCatalog(layerCatalog))
				.show();
	} else {
		if (layerDef instanceof MultiLayerDef) {
			layerDef.getLayer(); // Internamente realiza la carga de capas
		} else {
			autoMessageBox.show();
			final Layer newLayer = layerDef.getLayer();
			LayerLoader.load(newLayer);
			autoMessageBox.hide();
		}
	}
}
 
开发者ID:geowe,项目名称:sig-seguimiento-vehiculos,代码行数:19,代码来源:URLVectorLayerInitializer.java


示例6: getLayer

import org.gwtopenmaps.openlayers.client.layer.Layer; //导入依赖的package包/类
@Override
public Layer getLayer() {
	WMSParams wmsParams = new WMSParams();
	wmsParams.setFormat(format);
	wmsParams.setLayers(layerName);
	wmsParams.setTransparent(true);		
	
	WMSOptions wmsLayerParams = new WMSOptions();
	wmsLayerParams.setProjection(epsg);
	wmsLayerParams.setTransitionEffect(TransitionEffect.RESIZE);
	wmsLayerParams.setDisplayOutsideMaxExtent(true);			
	wmsLayerParams.setNumZoomLevels(GeoMapInitializer.MAX_NUM_ZOOM_LEVEL);
	wmsLayerParams.setIsBaseLayer(true);
	String attribution = getAttribution();
	if(attribution != null) {
		wmsLayerParams.setAttribution(attribution);
	}
	
	WMS wmsLayer = new WMS(getName(), url, wmsParams, wmsLayerParams);
	wmsLayer.setIsBaseLayer(false);

	return wmsLayer;	
}
 
开发者ID:geowe,项目名称:sig-seguimiento-vehiculos,代码行数:24,代码来源:WmsLayerDef.java


示例7: getLayer

import org.gwtopenmaps.openlayers.client.layer.Layer; //导入依赖的package包/类
@Override
public Layer getLayer() {

	TMSOptions tmsOptions = new TMSOptions();
	tmsOptions.setDisplayOutsideMaxExtent(true);
	tmsOptions.setNumZoomLevels(GeoMapInitializer.MAX_NUM_ZOOM_LEVEL);
	tmsOptions.setProjection(GeoMap.INTERNAL_EPSG);
	tmsOptions.setTransitionEffect(TransitionEffect.RESIZE);
	tmsOptions.setIsBaseLayer(false);
	tmsOptions.setType(getFormat());
	tmsOptions.setGetURL(getMyUrl());

	TMS tms = new TMS(getName(), getUrl(), tmsOptions);

	return tms;

}
 
开发者ID:geowe,项目名称:sig-seguimiento-vehiculos,代码行数:18,代码来源:TmsLayerDef.java


示例8: onRelease

import org.gwtopenmaps.openlayers.client.layer.Layer; //导入依赖的package包/类
@Override
protected void onRelease() {
	final Layer[] mapLayers = geoMap.getMap().getLayers();
	final List<LayerDef> catalogLayers = appLayerCatalog.getAllLayers();
	final List<LayerDef> availableLayers = new ArrayList<LayerDef>();
	addedLayers = new ArrayList<LayerDef>();

	for (final LayerDef layerDef : catalogLayers) {
		if (layerAlreadyExists(layerDef.getName(), mapLayers)) {
			addedLayers.add(layerDef);				
		} else {
			availableLayers.add(layerDef);
		}
	}

	layerCatalogDialog.initialize(availableLayers, addedLayers);
	layerCatalogDialog.show();
}
 
开发者ID:geowe,项目名称:sig-seguimiento-vehiculos,代码行数:19,代码来源:LayerCatalogTool.java


示例9: addSelectedLayers

import org.gwtopenmaps.openlayers.client.layer.Layer; //导入依赖的package包/类
private void addSelectedLayers() {
	final Layer[] mapLayers = geoMap.getMap().getLayers();
	addedLayers = layerCatalogDialog.getAddedLayers();

	for (final LayerDef layerDef : addedLayers) {
		try {
			
			if (!layerAlreadyExists(layerDef.getName(), mapLayers)) {
				if(layerDef instanceof MultiLayerDef) {
					layerDef.getLayer(); //Internamente realiza la carga de capas						
				}
				else {
					final Layer newLayer = layerDef.getLayer();
					addLayer(newLayer, layerDef);
				}					
			}
		} catch (Exception ex) {
			Info.display(
					UIMessages.INSTANCE.layerCatalogToolText(),
					UIMessages.INSTANCE.errorLoadingLayer(layerDef.getName()));
		}
	}
	autoMessageBox.hide();
}
 
开发者ID:geowe,项目名称:sig-seguimiento-vehiculos,代码行数:25,代码来源:LayerCatalogTool.java


示例10: updateStatusInfo

import org.gwtopenmaps.openlayers.client.layer.Layer; //导入依赖的package包/类
private void updateStatusInfo() {
	if (vectorLayers != null) {
		List<VectorLayerInfo> vectors = new ArrayList<VectorLayerInfo>();

		for (Layer layer : vectorLayers) {
			vectors.add(new VectorLayerInfo((Vector) layer));
		}

		layerStore.clear();
		layerStore.addAll(vectors);
		layerCombo.redraw();
	}

	if (selectedLayer != null) {
		layerCombo.setValue(new VectorLayerInfo(selectedLayer));
	}
}
 
开发者ID:geowe,项目名称:sig-seguimiento-vehiculos,代码行数:18,代码来源:PreviewWidget.java


示例11: getFoot

import org.gwtopenmaps.openlayers.client.layer.Layer; //导入依赖的package包/类
private VerticalPanel getFoot() {
	slider.setWidth("290px");
	slider.disable();
	slider.setIncrement(1);

	slider.addValueChangeHandler(new ValueChangeHandler<Integer>() {

		@Override
		public void onValueChange(final ValueChangeEvent<Integer> event) {
			final Layer layer = getSelectedLayer(getSelectedTabName());
			layer.setOpacity((float) (event.getValue().intValue() / 100.0));
		}

	});

	final VerticalPanel panel = new VerticalPanel();
	panel.setWidth("300px");
	panel.addStyleName(ThemeStyles.get().style().borderTop());
	panel.add(new HTML(UIMessages.INSTANCE.lmOpacityHtmlLabel()));
	panel.add(slider);

	panel.add(statusBar);
	return panel;
}
 
开发者ID:geowe,项目名称:sig-seguimiento-vehiculos,代码行数:25,代码来源:LayerManagerWidget.java


示例12: createSelectHover

import org.gwtopenmaps.openlayers.client.layer.Layer; //导入依赖的package包/类
public SelectFeature createSelectHover(Layer layer) {
	createSelectHoverOptions();

	SelectFeature selectHoverFeature = new SelectFeature((Vector) layer,
			selectFeatureHoverOptions);
	selectHoverFeature.setClickOut(false);
	selectHoverFeature
			.addFeatureHighlightedListener(featureToolTipShowListener);
	selectHoverFeature
			.addFeatureUnhighlightedListener(featureToolTipHideListener);
	selectHoverFeature.setToggle(true);

	return selectHoverFeature;
}
 
开发者ID:geowe,项目名称:sig-seguimiento-vehiculos,代码行数:15,代码来源:MapControlFactory.java


示例13: createSelectionControl

import org.gwtopenmaps.openlayers.client.layer.Layer; //导入依赖的package包/类
public SelectFeature createSelectionControl(Layer layer) {

		SelectFeature clickSelectFeature = new SelectFeature((Vector) layer);

		clickSelectFeature.setClickOut(true);
		clickSelectFeature.setToggle(true);
		clickSelectFeature.setMultiple(true);
		clickSelectFeature.setToggleKey("ctrlKey");
		clickSelectFeature.setMultipleKey("shiftKey");

		return clickSelectFeature;
	}
 
开发者ID:geowe,项目名称:sig-seguimiento-vehiculos,代码行数:13,代码来源:MapControlFactory.java


示例14: createCircleControl

import org.gwtopenmaps.openlayers.client.layer.Layer; //导入依赖的package包/类
public DrawFeature createCircleControl(Layer layer,
		DrawFeatureOptions drawFeatureOptions) {
	RegularPolygonHandlerOptions handlerOptions = new RegularPolygonHandlerOptions();
	handlerOptions.setSides(30);
	handlerOptions.setSnapAngle(0);
	handlerOptions.setIrregular(false);

	drawFeatureOptions.setHandlerOptions(handlerOptions);

	DrawFeature drawCircleFeatureControl = new DrawFeature((Vector) layer,
			new RegularPolygonHandler(), drawFeatureOptions);

	return drawCircleFeatureControl;
}
 
开发者ID:geowe,项目名称:sig-seguimiento-vehiculos,代码行数:15,代码来源:MapControlFactory.java


示例15: createRegularPoligonControl

import org.gwtopenmaps.openlayers.client.layer.Layer; //导入依赖的package包/类
public DrawFeature createRegularPoligonControl(Layer layer) {
	RegularPolygonHandlerOptions boxHandlerOptions = new RegularPolygonHandlerOptions();
	boxHandlerOptions.setIrregular(true);

	DrawFeature drawRegularPolygonControl = new DrawFeature((Vector) layer,
			new RegularPolygonHandler());
	((RegularPolygonHandler) drawRegularPolygonControl.getHandler())
			.setOptions(boxHandlerOptions);

	return drawRegularPolygonControl;
}
 
开发者ID:geowe,项目名称:sig-seguimiento-vehiculos,代码行数:12,代码来源:MapControlFactory.java


示例16: createHolePolygonControl

import org.gwtopenmaps.openlayers.client.layer.Layer; //导入依赖的package包/类
public DrawFeature createHolePolygonControl(Layer layer) {
	DrawFeatureOptions drawFeatureOptions = new DrawFeatureOptions();
	PolygonHandlerOptions polygonHandlerOptions = new PolygonHandlerOptions();
	polygonHandlerOptions.setHoleModifier(HoleModifier.ctrlKey);
	drawFeatureOptions.setHandlerOptions(polygonHandlerOptions);

	DrawFeature drawPolygonControl = new DrawFeature((Vector) layer,
			new PolygonHandler(), drawFeatureOptions);
	return drawPolygonControl;
}
 
开发者ID:geowe,项目名称:sig-seguimiento-vehiculos,代码行数:11,代码来源:MapControlFactory.java


示例17: createEditingControl

import org.gwtopenmaps.openlayers.client.layer.Layer; //导入依赖的package包/类
public ModifyFeature createEditingControl(int mode, Layer layer) {
	ModifyFeatureOptions modifyFeatureOptions = new ModifyFeatureOptions();

	ModifyFeature modifyFeature = new ModifyFeature((Vector) layer,
			modifyFeatureOptions);
	modifyFeature.setVirtualStyle(getEditionStyle());
	modifyFeature.setMode(mode);
	return modifyFeature;
}
 
开发者ID:geowe,项目名称:sig-seguimiento-vehiculos,代码行数:10,代码来源:MapControlFactory.java


示例18: getData

import org.gwtopenmaps.openlayers.client.layer.Layer; //导入依赖的package包/类
@Override
protected List<Widget> getData() {
	List<Widget> widgets = new ArrayList<Widget>();
	for (Layer layer : layers) {
		HorizontalPanel hpanel = new HorizontalPanel();
		hpanel.setSpacing(2);
		hpanel.add(getColorPanel(layer));
		hpanel.add(new Label(layer.getName()));

		widgets.add(hpanel);
	}
	return widgets;
}
 
开发者ID:geowe,项目名称:sig-seguimiento-vehiculos,代码行数:14,代码来源:SimpleMapVerticalLegend.java


示例19: getColorPanel

import org.gwtopenmaps.openlayers.client.layer.Layer; //导入依赖的package包/类
private HorizontalPanel getColorPanel(Layer layer) {
	HorizontalPanel colorPanel = new HorizontalPanel();
	colorPanel.setSize("20px", "20px");
	colorPanel.getElement().getStyle()
			.setBackgroundColor(getColor(layer, "fillColor"));
	colorPanel.setBorderWidth(2);
	colorPanel.getElement().getStyle().setBorderStyle(BorderStyle.SOLID);
	colorPanel.getElement().getStyle()
			.setBorderColor(getColor(layer, "strokeColor"));
	return colorPanel;
}
 
开发者ID:geowe,项目名称:sig-seguimiento-vehiculos,代码行数:12,代码来源:SimpleMapVerticalLegend.java


示例20: getColor

import org.gwtopenmaps.openlayers.client.layer.Layer; //导入依赖的package包/类
private String getColor(Layer layer, String property) {
	String color = "#0F58BF";
	if ((((VectorLayer) layer).getStyle()) == null) {

		color = ((VectorLayer) layer).getStyleMap().getJSObject()
				.getProperty("styles").getProperty("default")
				.getProperty("defaultStyle").getPropertyAsString(property);
	} else {
		color = ((VectorLayer) layer).getStyle().getFillColor();
	}
	return color;
}
 
开发者ID:geowe,项目名称:sig-seguimiento-vehiculos,代码行数:13,代码来源:SimpleMapVerticalLegend.java



注:本文中的org.gwtopenmaps.openlayers.client.layer.Layer类示例整理自Github/MSDocs等源码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。


鲜花

握手

雷人

路过

鸡蛋
该文章已有0人参与评论

请发表评论

全部评论

专题导读
上一篇:
Java MiniQJMHACluster类代码示例发布时间:2022-05-22
下一篇:
Java Selector类代码示例发布时间:2022-05-22
热门推荐
阅读排行榜

扫描微信二维码

查看手机版网站

随时了解更新最新资讯

139-2527-9053

在线客服(服务时间 9:00~18:00)

在线QQ客服
地址:深圳市南山区西丽大学城创智工业园
电邮:jeky_zhao#qq.com
移动电话:139-2527-9053

Powered by 互联科技 X3.4© 2001-2213 极客世界.|Sitemap