UNPKG

@mapgis/webclient-common

Version:

mapgis ES6 format for igserver

6,107 lines 104 kB
<header id="page-title" class="page-title">
    
        <span class="page-title-main">类名</span>
        <span class="page-title-sub">IGSVectorTileLayer</span>
    
</header>





<section>

<article>
    <div class="container-overview">
    
        
            <div class='vertical-section'>
                <div class="members">
                    <div class="member">
                        


    
    <h4 class="name" id="IGSVectorTileLayer">
        <a class="href-link" href="#IGSVectorTileLayer">#</a>
        
        <span class="code-name" id="IGSVectorTileLayer" style="font-size:30px">
            
                new IGSVectorTileLayer<span class="signature">(options)</span>
            
        </span>
    </h4>
    

    
    <div class="description">
        <p>IGS矢量瓦片图层<br/>
支持IGS1.0和2.0两个服务版本<br/>
<br/>
支持通过如下三种方式来初始化矢量瓦片图层对象:<br/>
1、通过服务基地址来初始化矢量瓦片图层对象;<br/>
2、通过加载矢量瓦片样式文件的方式来初始化矢量瓦片图层对象;<br/>
3、通过设置矢量瓦片样式的方式来初始化矢量瓦片图层对象;<br/>
当加载MapGIS制作并由IGS发布的矢量瓦片时,如果矢量瓦片样式中有mapinfo参数,则子图层ID对应的是MapX中的图层索引;
如果没有mapinfo参数,则子图层ID对应的是矢量瓦片样式图层ID;<br/>
当加载第三方发布的矢量瓦片时,子图层ID对应的是矢量瓦片样式图层ID;<br/>
<br><br>[ES5引入方式]:<br/>
zondy.layer.IGSVectorTileLayer() <br/>
[ES6引入方式]:<br/>
import { IGSVectorTileLayer } from &quot;@mapgis/webclient-common&quot; <br/>
<br/>
针对图层的操作请在图层加载完毕事件中进行<br/>
Layer.on('layerview-created', function (result) {<br/>
console.log(&quot;加载完毕:&quot;, result.layer)<br/>
});<br/>
如果不想在该事件中放入业务代码,则请确认图层资源以加载完毕后再进行操作<br/>
if(layer.loadStatus === 'loaded') {<br/>
// 你的业务逻辑<br/>
}
<br/>
<br/>
同时也支持二次开发自定义业务逻辑,示例如下:<br/>
<a href='#custom-es5'>[自定义矢量瓦片业务逻辑-es5]</a>,<a href='#custom-es6'>[自定义矢量瓦片业务逻辑-es6]</a>
<br/>
<br/>
注意:三维上,不支持简单Marker样式设定;二维上,简单Marker的颜色,外边线样式,旋转角度无法在图层初始化和初始化后修改,须在制作数据时进行指定</p>
    </div>
    









    <h4>参数</h4>
    
<div class="table-container">
    <table class="params table">
        <thead>
        <tr>
            
            <th>名称</th>
            

            <th>类型</th>

            
            <th style="min-width: 100px;">默认值</th>
            

            <th class="last">描述</th>
        </tr>
        </thead>

        <tbody>
        

            
<tr class="deep-level-0">
  
      <td class="name"><code>options</code></td>
  

  <td class="type">
  
      
<span class="param-type">
    
             Object
    
</span>



  
  </td>

  
      <td class="default">
      
      </td>
  

  <td class="description last"><p>构造参数</p></td>
</tr>


  
    
<tr class="deep-level-1">
  
      <td class="name"><code>url</code></td>
  

  <td class="type">
  
      
<span class="param-type">
    
             String
    
</span>



  
  </td>

  
      <td class="default">
      
          null
      
      </td>
  

  <td class="description last"><p>服务基地址,和style参数二者选其一:<br>
IGS1.0的服务基地址为:http://{ip}:6163/igs/rest/mrcs/vtiles/{serviceName}<br>
需要注意由于igs1.0版本不再新增功能,无法解析矢量瓦片Lod信息以及坐标系信息,目前需要在矢量瓦片图层接口上显式设置坐标系信息,默认坐标系3857,可选4326或3857,参考示例:<a href='#igs-1'>[IGS1.0的矢量瓦片示例]</a><br/>
IGS2.0的服务基地址为:http://{ip}:{port}/igs/rest/services/{serviceName}/VectorTileServer<br>
参考示例:<a href='#igs-2'>[IGS2.0的矢量瓦片示例]</a><br/>
服务基地址也支持传入矢量瓦片样式文件地址:<br>
IGS1.0的样式文件地址:http://{ip}:6163/igs/rest/mrcs/vtiles/styles/{样式文件名称}.json<br>
IGS2.0的样式文件地址:http://{ip}:8089/igs/rest/mrcs/vtiles/styles/{样式文件名称}.json<br>
请注意当服务基地址内容为矢量瓦片样式文件地址时,请保证图层名和数据源名称一致,否则会导致接口请求异常<br>
删除图层方法:<a href='#remove-layer'>[删除图层]</a></p></td>
</tr>


  
    
<tr class="deep-level-1">
  
      <td class="name"><code>style</code></td>
  

  <td class="type">
  
      
<span class="param-type">
    
             Object
    
</span>



  
  </td>

  
      <td class="default">
      
          null
      
      </td>
  

  <td class="description last"><p>矢量瓦片的mvt样式对象,默认从服务中获取,用户也可主动传入mvt样式对象来构造一个矢量瓦片图层,此时会忽略用户输入的url参数<br/>
和url参数二者选其一<br>
参考示例:<a href='#mvt-style'>[通过mvt样式对象来构造矢量瓦片示例]</a></p></td>
</tr>


  
    
<tr class="deep-level-1">
  
      <td class="name"><code>sublayers</code></td>
  

  <td class="type">
  
      
<span class="param-type">
    
         <a onclick="getTypeHTML(event)" link="Collection.html">Collection</a>.&lt;<a onclick="getTypeHTML(event)" link="IGSVectorTileSubLayer.html">IGSVectorTileSubLayer</a>>
    
</span>



  
  </td>

  
      <td class="default">
      
          new Collection()
      
      </td>
  

  <td class="description last"><p>矢量瓦片子图层数组<br>
目前支持的专题图如下:<br>
<a class="mapgis-link-name" title="UniqueValueRenderer" UniqueValueRenderer.html><code>1、单值专题图</code></a><br/>
<a class="mapgis-link-name" title="ClassBreakRenderer" ClassBreakRenderer.html><code>2、分段专题图</code></a><br/>
<a class="mapgis-link-name" title="SimpleRenderer" SimpleRenderer.html><code>3、统一专题图</code></a><br/>
参考示例:<br/>
<a href='#showAllSubLayers'>[1、显示所有子图层]</a><br/>
<a href='#showSubLayersById'>[2、根据id显示子图层]</a><br/>
<a href='#showSubLayers-property'>[3、通过修改子图参数,设置子图层显隐]</a><br/>
<a href='#setLayerRenderer-unique'>[4、设置子图层专题图-单值专题图]</a><br/>
<a href='#setLayerRenderer-break'>[5、设置子图层专题图-分段专题图]</a><br/>
<a href='#setLayerRenderer-simple'>[6、设置子图层专题图-统一专题图]</a><br/>
<a href='#setLayerRenderer-property'>[7、通过修改子图参数,设置子图层专题图]</a><br/></p></td>
</tr>


  
    
<tr class="deep-level-1">
  
      <td class="name"><code>minScale</code></td>
  

  <td class="type">
  
      
<span class="param-type">
    
             Number
    
</span>



  
  </td>

  
      <td class="default">
      
          0
      
      </td>
  

  <td class="description last"><p>最小显示比例尺,图层在视图中可见的最小比例尺。</p></td>
</tr>


  
    
<tr class="deep-level-1">
  
      <td class="name"><code>maxScale</code></td>
  

  <td class="type">
  
      
<span class="param-type">
    
             Number
    
</span>



  
  </td>

  
      <td class="default">
      
          0
      
      </td>
  

  <td class="description last"><p>最大显示比例尺,图层在视图中可见的最大比例尺。</p></td>
</tr>


  
    
<tr class="deep-level-1">
  
      <td class="name"><code>opacity</code></td>
  

  <td class="type">
  
      
<span class="param-type">
    
             Number
    
</span>



  
  </td>

  
      <td class="default">
      
          1
      
      </td>
  

  <td class="description last"><p>图层透明度,0到1之间的值,0为完全透明,1为不透明,参考示例:<a href='#opacity'>[设置图层透明度]</a></p></td>
</tr>


  
    
<tr class="deep-level-1">
  
      <td class="name"><code>tokenKey</code></td>
  

  <td class="type">
  
      
<span class="param-type">
    
             String
    
</span>



  
  </td>

  
      <td class="default">
      
          'token'
      
      </td>
  

  <td class="description last"><p>token名</p></td>
</tr>


  
    
<tr class="deep-level-1">
  
      <td class="name"><code>tokenValue</code></td>
  

  <td class="type">
  
      
<span class="param-type">
    
             String
    
</span>



  
  </td>

  
      <td class="default">
      
          null
      
      </td>
  

  <td class="description last"><p>token值,只有当tokenValue存在时,才会绑定token</p></td>
</tr>


  
    
<tr class="deep-level-1">
  
      <td class="name"><code>visible</code></td>
  

  <td class="type">
  
      
<span class="param-type">
    
             Boolean
    
</span>



  
  </td>

  
      <td class="default">
      
          true
      
      </td>
  

  <td class="description last"><p>图层显示或隐藏,true则显示,false则隐藏,参考示例:<a href='#visible'>[设置图层显隐]</a></p></td>
</tr>


  
    
<tr class="deep-level-1">
  
      <td class="name"><code>sublayers</code></td>
  

  <td class="type">
  
      
<span class="param-type">
    
         Array.&lt;<a onclick="getTypeHTML(event)" link="IGSVectorTileSubLayer.html">IGSVectorTileSubLayer</a>>
    
</span>



  
  </td>

  
      <td class="default">
      
          []
      
      </td>
  

  <td class="description last"><p>子图层信息。指定的和服务器端获取图层的交集, 默认不设置,加载全部图层。可设置子图层的可见性,以及专题图参数。<br/></p></td>
</tr>


  
    
<tr class="deep-level-1">
  
      <td class="name"><code>labelsRenderMode</code></td>
  

  <td class="type">
  
      
<span class="param-type">
    
             String
    
</span>



  
  </td>

  
      <td class="default">
      
          'off-screen'
      
      </td>
  

  <td class="description last"><p>指定矢量瓦片注记的渲染模式,仅在三维上有效<br/>
on-screen: 使用Cesium接口实时渲染注记<br/>
off-screen: 使用矢量瓦片来绘制注记<br/>
三维注记目前不支持修改透明度和显隐参数<br>
请注意模式切换时,会造成性能损失,在显卡较弱的机器上会出现卡顿现象<br/>
参考示例:<a href='#labels-3d'>[矢量瓦片三维注记]</a><a href='#labels-mode'>[切换三维注记模式]</a><br/></p></td>
</tr>


  
    
<tr class="deep-level-1">
  
      <td class="name"><code>clippingArea</code></td>
  

  <td class="type">
  
      
<span class="param-type">
    
             <a link="Polygon.html" onclick="getTypeHTML(event)" class="mapgis-link-name" title="Polygon" Polygon.html>Polygon</a>
    
</span>
|

<span class="param-type">
    
             <a link="Extent.html" onclick="getTypeHTML(event)" class="mapgis-link-name" title="Extent" Extent.html>Extent</a>
    
</span>
|

<span class="param-type">
    
             <a link="Circle.html" onclick="getTypeHTML(event)" class="mapgis-link-name" title="Circle" Circle.html>Circle</a>
    
</span>
|

<span class="param-type">
    
             <a link="MultiPolygon.html" onclick="getTypeHTML(event)" class="mapgis-link-name" title="MultiPolygon" MultiPolygon.html>MultiPolygon</a>
    
</span>
|

<span class="param-type">
    
             null
    
</span>



  
  </td>

  
      <td class="default">
      
          null
      
      </td>
  

  <td class="description last"><p>图层空间裁剪范围,仅支持多多边形裁剪、多边形裁剪、矩形裁剪、圆形裁剪</p></td>
</tr>


  



        
        </tbody>
    </table>
</div>






<dl class="details">

    

    

    

    

    

    

    

    

    

    

    

    
    

    

    

    
</dl>





    <div class="method-parameter columns">
        <div class="column is-2"><label>绑定事件</label></div>
        <div class="column is-10">
            <ul>
                <li><a href="#图层加载完毕事件">图层加载完毕事件</a></li>
            
                <li><a href="#图层销毁完毕事件">图层销毁完毕事件</a></li>
            
                <li><a href="#图层更新完毕事件">图层更新完毕事件</a></li>
            
                <li><a href="#图层显隐更新完毕事件">图层显隐更新完毕事件</a></li>
            
                <li><a href="#图层透明度更新完毕事件">图层透明度更新完毕事件</a></li>
            </ul>
        </div>
    </div>

















<p class="summary"><h5>支持如下方法:</h5>
<a href='#findSublayerById'>[1、根据子图层id查询图层]</a><br/>
<a href='#fromJSON'>[2、通过传入的json构造并返回一个新的IGSVectorTileLayer对象]</a><br/>
<a href='#toJSON'>[3、导出为json对象]</a><br/>
<a class="mapgis-link-name" title="VectorTileLayer#getStyleLayer" VectorTileLayer.html#getStyleLayer><code>4、通过矢量瓦片样式图层的id,找到对应的矢量瓦片样式图层对象</code></a><br/>
<a class="mapgis-link-name" title="VectorTileLayer#getStyleLayerIndex" VectorTileLayer.html#getStyleLayerIndex><code>5、通过矢量瓦片样式图层的id,找到对应的矢量瓦片样式图层的序号</code></a><br/>
<a class="mapgis-link-name" title="VectorTileLayer#getStyleLayerId" VectorTileLayer.html#getStyleLayerId><code>6、通过矢量瓦片样式图层的序号,找到对应的矢量瓦片样式图层的id</code></a><br/>
<a class="mapgis-link-name" title="VectorTileLayer#setStyleLayer" VectorTileLayer.html#setStyleLayer><code>7、设置样式图层属性对象</code></a><br/>
<a class="mapgis-link-name" title="VectorTileLayer#deleteStyleLayer" VectorTileLayer.html#deleteStyleLayer><code>8、删除样式图层</code></a><br/>
<a class="mapgis-link-name" title="VectorTileLayer#setStyleLayerVisibility" VectorTileLayer.html#setStyleLayerVisibility><code>9、设置样式图层可见性</code></a><br/>
<a class="mapgis-link-name" title="VectorTileLayer#getStyleLayerVisibility" VectorTileLayer.html#getStyleLayerVisibility><code>10、获取样式图层可见性</code></a><br/>
<a class="mapgis-link-name" title="VectorTileLayer#getPaintProperties" VectorTileLayer.html#getPaintProperties><code>11、获取样式图层绘制属性</code></a><br/>
<a class="mapgis-link-name" title="VectorTileLayer#setPaintProperties" VectorTileLayer.html#setPaintProperties><code>12、设置样式图层绘制属性</code></a><br/>
<a class="mapgis-link-name" title="VectorTileLayer#getLayoutProperties" VectorTileLayer.html#getLayoutProperties><code>13、获取样式图层布局属性</code></a><br/>
<a class="mapgis-link-name" title="VectorTileLayer#setLayoutProperties" VectorTileLayer.html#setLayoutProperties><code>14、设置样式图层布局属性</code></a><br/>
<a class="mapgis-link-name" title="VectorTileLayer#setExtendProperties" VectorTileLayer.html#setExtendProperties><code>15、设置样式图层的额外属性</code></a><br/>
<a class="mapgis-link-name" title="VectorTileLayer#getExtendProperties" VectorTileLayer.html#getExtendProperties><code>16、获取样式图层的额外属性</code></a><br/>
<a class="mapgis-link-name" title="VectorTileLayer#clone" VectorTileLayer.html#clone><code>17、克隆图层</code></a><br/></p>



    <h5>示例</h5>
    
        <p class="code-caption"><h7 id='igs-1'>IGS1.0的矢量瓦片示例</h7></p>
    
    
        <pre class="prettyprint"><code>//初始化地图管理容器
// ES5引入方式
const { IGSVectorTileLayer } = zondy.layer
const { SpatialReference } = zondy
// ES6引入方式
import { IGSVectorTileLayer, SpatialReference } from "@mapgis/webclient-common"
//初始化矢量瓦片图层
const igsVectorTileLayer = new IGSVectorTileLayer({
  // 矢量瓦片基地址
  url: '',
  // 图层参考系
  spatialReference:new SpatialReference('EPSG:4326')
});</code></pre>
    

        <p class="code-caption"><h7 id='igs-2'>IGS2.0的矢量瓦片示例</h7></p>
    
    
        <pre class="prettyprint"><code> // ES5引入方式
const { IGSVectorTileLayer } = zondy.layer
// ES6引入方式
import { IGSVectorTileLayer } from "@mapgis/webclient-common"
// 初始化矢量瓦片图层
const igsVectorTileLayer = new IGSVectorTileLayer({
  // 矢量瓦片基地址
  url: ''
});</code></pre>
    

        <p class="code-caption"><h7 id='mvt-style'>通过mvt样式对象来构造矢量瓦片示例</h7></p>
    
    
        <pre class="prettyprint"><code>// ES5引入方式
const { IGSVectorTileLayer } = zondy.layer
// ES6引入方式
import { IGSVectorTileLayer } from "@mapgis/webclient-common"
// 初始化矢量瓦片图层
const igsVectorTileLayer = new IGSVectorTileLayer({
  // 矢量瓦片的mvt样式对象
  style: {}
});</code></pre>
    

        <p class="code-caption"><h7 id='custom-es5'>自定义矢量瓦片业务逻辑-es5</h7></p>
    
    
        <pre class="prettyprint"><code>// ES5引入方式
const { IGSVectorTileLayer } = zondy.layer
// ES6引入方式
import { IGSVectorTileLayer } from "@mapgis/webclient-common"
// 初始化矢量瓦片图层
const igsVectorTileLayer = new IGSVectorTileLayer({
  // 矢量瓦片基地址
  url: ''
});
// 例如通过重写igsVectorTileLayer对象的covertCustomStyleToMVTStyle方法,来自定义矢量瓦片业务逻辑
igsVectorTileLayer.covertCustomStyleToMVTStyle = function(customStyle) {
  // 自定义你的业务逻辑
  // 此方法必须要返回一个符合MapBox标准的矢量瓦片
  return mvtStyle
}
// 在ES5模式下,如果更改了图层的业务逻辑,则必须通过图层的load方法来加载元信息,之后再添加图层
igsVectorTileLayer.load().then(() => {
  // 添加图层
  map.add(igsVectorTileLayer)
})</code></pre>
    

        <p class="code-caption"><h7 id='custom-es6'>自定义矢量瓦片业务逻辑-es6</h7></p>
    
    
        <pre class="prettyprint"><code>// ES6引入方式
import { IGSVectorTileLayer } from "@mapgis/webclient-common"
// 在ES6模式下继承IGSVectorTileLayer,并重写其业务逻辑
class IGSVectorTileLayerCustom extends IGSVectorTileLayer {
  constructor(options) {
    super(options)
  }
}
// 重写方法
IGSVectorTileLayerCustom.prototype.covertCustomStyleToMVTStyle = function (customStyle) {
  // 自定义你的业务逻辑
  // 此方法必须要返回一个符合MapBox标准的矢量瓦片
  return mvtStyle
}
const customLayer = new IGSVectorTileLayerCustom({
  // 矢量瓦片基地址
  url: ''
})</code></pre>
    

        <p class="code-caption"><h7 id='labels-3d'>矢量瓦片三维注记</h7></p>
    
    
        <pre class="prettyprint"><code>// ES5引入方式
const { LabelClass } = zondy
const { IGSVectorTileLayer } = zondy.layer
// ES6引入方式
import { IGSVectorTileLayer, LabelClass } from "@mapgis/webclient-common"
// 初始化一个额外的图标DOM对象
const iconImage = new Image()
iconImage.src = '图片地址或者base64字符串'
// 初始化矢量瓦片图层
const igsVectorTileLayer = new IGSVectorTileLayer({
  // 矢量瓦片基地址
  url: '',
  // 开启三维注记
  labelsRenderMode: 'on-screen',
  // 设置要应用三维主句的子图层
  sublayers: [{
    // 矢量瓦片子图层id
    id: '矢量瓦片子图层id',
    // 注记参数,目前仅用填写一个
    labelingInfo: [
      new LabelClass({
        symbol: {
          // 填充颜色 rgba or 16进制颜色
          color: 'rgba(255,255,255,1)',
          // 描边颜色
          haloColor: 'rgba(0,0,0,0.5)',
          // 描边宽度
          haloSize: 2,
          // 行高
          lineHeight: 1.1,
          // 文本间距
          letterSpacing: 2,
          // 字体样式 参考css
          font: {
            size: 14,
            family: '微软雅黑',
            weight: 'normal',
            style: 'normal'
          },
          // 额外的图标
          textExtraIcon: iconImage,
          // 图标的大小
          textExtraIconSize:20,
          // 图标方位
          textExtraIconAnchor:'left'
        },
        // 渲染方式 1.canvas 2.label 3.ground
        renderMode: 'canvas',
        // 最大可见范围
        minScale: 60000000,
        // 最小可见范围
        maxScale: 1,
        // 布局位置 可选 1.above-left 2.above-center 3.above-right 4.center-left 5.center-center 6.center-right 7.below-left 8.below-center 9.below-right
        labelPlacement: 'above-center',
        // 高程采样参数
        elevationInfo: {
          mode: 'OnTheGround',
          offset: 0
        }
      })
    ]
  }]
});</code></pre>
    

        <p class="code-caption"><h7 id='labels-mode'>切换三维注记模式</h7></p>
    
    
        <pre class="prettyprint"><code>// 矢量瓦片渲染模式
igsVectorTileLayer.labelsRenderMode = 'off-screen'
// Cesium三维渲染模式
igsVectorTileLayer.labelsRenderMode = 'on-screen'</code></pre>
    

        <p class="code-caption"><h7 id='opacity'>设置图层透明度</h7></p>
    
    
        <pre class="prettyprint"><code>igsVectorTileLayer.opacity = 0.5</code></pre>
    

        <p class="code-caption"><h7 id='visible'>显示或隐藏图层</h7></p>
    
    
        <pre class="prettyprint"><code>igsVectorTileLayer.visible = !igsVectorTileLayer.visible</code></pre>
    

        <p class="code-caption"><h7 id='remove-layer'>删除图层</h7></p>
    
    
        <pre class="prettyprint"><code>map.remove(igsVectorTileLayer)</code></pre>
    

        <p class="code-caption"><h7 id='showAllSubLayers'>显示所有子图层</h7></p>
    
    
        <pre class="prettyprint"><code> // ES5引入方式
const { IGSVectorTileLayer } = zondy.layer
// ES6引入方式
import { IGSVectorTileLayer } from "@mapgis/webclient-common"
// 添加图层
const igsVectorTileLayer = new IGSVectorTileLayer({
  // 服务基地址
  url: 'http://{ip}:{port}/igs/rest/services/{serviceName}/VectorTileServer',
  //默认不设置sublayers,加载全部图层
});</code></pre>
    

        <p class="code-caption"><h7 id='showSubLayersById'>根据id显示子图层</h7></p>
    
    
        <pre class="prettyprint"><code>// ES5引入方式
const { IGSVectorTileLayer } = zondy.layer
// ES6引入方式
import { IGSVectorTileLayer } from "@mapgis/webclient-common"
// 添加图层
const igsVectorTileLayer = new IGSVectorTileLayer({
  // 服务基地址
  url: 'http://{ip}:{port}/igs/rest/services/{serviceName}/VectorTileServer',
  // 根据id显示子图层
  sublayers: [
     {
       // 子图层id
       id: '子图层id',
       // 显示子图层
       visible: true
     }
   ]
});</code></pre>
    

        <p class="code-caption"><h7 id='showSubLayers-property'>通过修改子图参数,设置子图层显隐</h7></p>
    
    
        <pre class="prettyprint"><code>// ES5引入方式
const { IGSVectorTileLayer } = zondy.layer
// ES6引入方式
import { IGSVectorTileLayer } from "@mapgis/webclient-common"
// 添加图层
const igsVectorTileLayer = new IGSVectorTileLayer({
  // 服务基地址
  url: 'http://{ip}:{port}/igs/rest/services/{serviceName}/VectorTileServer'
});
igsVectorTileLayer.on('layerview-created', function (result) {
  console.log("加载完毕:", result.layer)
  // 根据id获取子图层
  const subLayer = igsVectorTileLayer.findSublayerById('图层id')
  // 设置子图层显隐
  subLayer.visible = false
})</code></pre>
    

        <p class="code-caption"><h7 id='setLayerRenderer-unique'>设置子图层专题图-单值专题图</h7></p>
    
    
        <pre class="prettyprint"><code>// ES5引入方式
const { IGSVectorTileLayer } = zondy.layer
const { UniqueValueRenderer } = zondy.renderer
const { SimpleFillSymbol,SimpleLineSymbol } = zondy.symbol
const { Color } = zondy
// ES6引入方式
import { IGSVectorTileLayer,UniqueValueRenderer ,SimpleFillSymbol,SimpleLineSymbol,Color} from "@mapgis/webclient-common"
const igsVectorTileLayer = new IGSVectorTileLayer({
  // 服务基地址,当不指定图层名称时,默认查询第一个子图层
  url: 'http://{ip}:{port}/igs/rest/services/{serviceName}/VectorTileServer',
  // 设置子图层专题图
  sublayers: [
     {
       // 子图层id
       id: '子图层id',
       // 设置渲染样式-单值专题图
       renderer: new UniqueValueRenderer({
         //专题图过滤字段名
         field: '你的字段名',
         // 默认样式,当没有匹配到指定值时,会使用默认样式
         //因为该数据的几何类型为区,因此设置区样式
         defaultSymbol: new SimpleFillSymbol({
           // 填充颜色
           color: 'rgba(1,1,252,0)',
           // 外边线样式
           outline: new SimpleLineSymbol({
             //线颜色
             color: new Color(255, 1, 0, 1),
             //线宽
             width: 1
           })
         }),
         //单值专题图过滤调条件数组
         uniqueValueInfos: [{
           //指定字段值
           value: "指定的值",
           //匹配到该值后的样式
           //因为该数据的几何类型为区,因此设置区样式
           symbol: new SimpleFillSymbol({
             // 填充颜色
             color: 'rgba(1,1,252,1)',
             // 外边线样式
             outline: new SimpleLineSymbol({
               //线符号颜色
               color: new Color(255, 1, 0, 11),
               //线宽
               width: 1
               })
             })
           },{
             //指定字段值
             value: "指定的值",
             //匹配到该值后的样式
             //因为该数据的几何类型为区,因此设置区样式
             symbol: new SimpleFillSymbol({
               // 填充颜色
               color: new Color(211, 111, 11, 1)
             })
           }]
       })
     }
  ]
});</code></pre>
    

        <p class="code-caption"><h7 id='setLayerRenderer-break'>设置子图层专题图-分段专题图</h7></p>
    
    
        <pre class="prettyprint"><code>// ES5引入方式
const { IGSVectorTileLayer } = zondy.layer
const { ClassBreakRenderer } = zondy.renderer
const { SimpleFillSymbol,SimpleLineSymbol } = zondy.symbol
const { Color } = zondy
// ES6引入方式
import { IGSVectorTileLayer,ClassBreakRenderer ,SimpleFillSymbol,SimpleLineSymbol,Color} from "@mapgis/webclient-commo
const igsVectorTileLayer = new IGSVectorTileLayer({
  // 服务基地址,当不指定图层名称时,默认查询第一个子图层
  url: 'http://{ip}:{port}/igs/rest/services/{serviceName}/VectorTileServer',
  // 设置子图层专题图
  sublayers: [
    {
     // 子图层id
     id: '子图层id',
     // 设置渲染样式-分段专题图
     renderer: new ClassBreakRenderer({
       //专题图过滤字段名
       field: '你的字段名',
       // 默认样式,当没有匹配到指定值时,会使用默认样式
       // 因为该数据的几何类型为区,因此设置区样式
       defaultSymbol:  new SimpleFillSymbol({
         // 填充颜色
         color: 'rgba(222,1,252,1)',
         // 线符号样式
         outline: new SimpleLineSymbol({
           //线符号颜色
           color: new Color(255, 1, 0, 1),
           //线宽
           width: 1
         })
       }),
       //分段专题图过滤条件数组
       classBreakInfos: [{
         // 最大过滤范围,field对应的值小于maxValue
         maxValue: "最大范围",
         // 最小过滤范围,field对应的值大于等于minValue
         minValue: "最小范围",
         // 匹配到该值后的样式
         // 因为该数据的几何类型为区,因此设置区样式
         symbol:  new SimpleFillSymbol({
           // 填充颜色
           color: 'rgba(1,1,252,1)',
           // 线符号样式
           outline: new SimpleLineSymbol({
             //线符号颜色
             color: new Color(255, 1, 0, 1),
             //线宽
             width: 1
           })
         })
       }]
     })
   }
 ]
});</code></pre>
    

        <p class="code-caption"><h7 id='setLayerRenderer-property'>通过修改子图参数,设置子图层专题图</h7></p>
    
    
        <pre class="prettyprint"><code>// ES5引入方式
const { IGSVectorTileLayer } = zondy.layer
const { ClassBreakRenderer } = zondy.renderer
const { SimpleFillSymbol,SimpleLineSymbol } = zondy.symbol
const { Color } = zondy
// ES6引入方式
import { IGSVectorTileLayer,ClassBreakRenderer ,SimpleFillSymbol,SimpleLineSymbol,Color} from "@mapgis/webclient-commo
const igsVectorTileLayer = new IGSVectorTileLayer({
  // 服务基地址
  url: 'http://{ip}:{port}/igs/rest/services/{serviceName}/VectorTileServer'
});
// 根据id获取子图层
const subLayer = igsVectorTileLayer.findSublayerById('子图层id')
// 设置渲染样式-分段专题图
subLayer.renderer = new ClassBreakRenderer({
    // 专题图过滤字段名
    field: '你的字段名',
    // 默认样式,当没有匹配到指定值时,会使用默认样式
    // 因为该数据的几何类型为区,因此设置区样式
    defaultSymbol:  new SimpleFillSymbol({
      // 填充颜色
      color: 'rgba(222,1,252,1)',
      // 线符号样式
      outline: new SimpleLineSymbol({
        //线符号颜色
        color: new Color(255, 1, 0, 1),
        //线宽
        width: 1
      })
    }),
    //分段专题图过滤条件数组
    classBreakInfos: [{
      // 最大过滤范围,field对应的值小于maxValue
      maxValue: "最大范围",
      // 最小过滤范围,field对应的值大于等于minValue
      minValue: "最小范围",
      // 匹配到该值后的样式
      // 因为该数据的几何类型为区,因此设置区样式
      symbol:  new SimpleFillSymbol({
        // 填充颜色
        color: 'rgba(1,1,252,1)',
        // 线符号样式
        outline: new SimpleLineSymbol({
          //线符号颜色
          color: new Color(255, 1, 0, 1),
          //线宽
          width: 1
        })
      })
    }]
  })</code></pre>
    

        <p class="code-caption"><h7 id='setLayerRenderer-simple'>统一专题图</h7></p>
    
    
        <pre class="prettyprint"><code>// ES5引入方式
const { IGSVectorTileLayer } = zondy.layer
const { SimpleRenderer } = zondy.renderer
const { SimpleFillSymbol,SimpleLineSymbol } = zondy.symbol
const { Color } = zondy
// ES6引入方式
import { IGSVectorTileLayer,SimpleRenderer ,SimpleFillSymbol,SimpleLineSymbol,Color} from "@mapgis/webclient-commo
const igsVectorTileLayer = new IGSVectorTileLayer({
  // 服务基地址
  url: 'http://{ip}:{port}/igs/rest/services/{serviceName}/VectorTileServer',
  // 设置子图层专题图
  sublayers: [{
    // 子图层id
    id: '子图层id',
    // 设置渲染样式-统一专题图
    renderer: new SimpleRenderer({
    // 因为该数据的几何类型为区,因此设置区样式
    symbol: new SimpleFillSymbol({
      // 填充颜色
      color: new zondy.Color(255, 0, 0),
      // 外边线样式
      outline: new SimpleLineSymbol({
        // 线颜色
        color: new Color(0, 0, 0),
        // 线宽度
        width: 1
      })
    })
  })
  }]
})</code></pre>
    



                    </div>
                </div>
            </div>
        
    
    </div>
    
    
        <h3 class="subsection-title">继承关系</h3>

        


    <ul>
        <li><a link="VectorTileLayer.html" onclick="getTypeHTML(event)" class="mapgis-link-name" title="VectorTileLayer" VectorTileLayer.html>VectorTileLayer</a></li>
    </ul>


    

    

    

    

    

    

    
        <div class='vertical-section'>
            <h3 id='member'>成员变量</h3>
            <h4 style="margin-top: 20px;margin-bottom: 20px;">成员变量概述</h4>
            <div class="table-container">
                <table class="params table">
                    <thead>
                    <tr>
                        <th>名称</th>
                        <th>类型</th>
                        <th>描述</th>
                    </tr>
                    </thead>
                    <tbody>
                        
                            <tr class="deep-level-0">
                                <td class="name"><code><a href="#capabilities">capabilities</a></code></td>
                                <td class="name">
                                    <code>
                                        
<span class="param-type">
    
         Array.&lt;String>
    
</span>



                                    </code>
                                </td>
                                <td class="name"><code><p>服务支持的能力</p></code></td>
                            </tr>
                        
                            <tr class="deep-level-0">
                                <td class="name"><code><a href="#clippingArea">clippingArea</a></code></td>
                                <td class="name">
                                    <code>
                                        
<span class="param-type">
    
             <a link="Polygon.html" onclick="getTypeHTML(event)" class="mapgis-link-name" title="Polygon" Polygon.html>Polygon</a>
    
</span>
|

<span class="param-type">
    
             <a link="Extent.html" onclick="getTypeHTML(event)" class="mapgis-link-name" title="Extent" Extent.html>Extent</a>
    
</span>
|

<span class="param-type">
    
             <a link="Circle.html" onclick="getTypeHTML(event)" class="mapgis-link-name" title="Circle" Circle.html>Circle</a>
    
</span>
|

<span class="param-type">
    
             <a link="MultiPolygon.html" onclick="getTypeHTML(event)" class="mapgis-link-name" title="MultiPolygon" MultiPolygon.html>MultiPolygon</a>
    
</span>
|

<span class="param-type">
    
             null
    
</span>



                                    </code>
                                </td>
                                <td class="name"><code><p>空间裁剪范围</p></code></td>
                            </tr>
                        
                            <tr class="deep-level-0">
                                <td class="name"><code><a href="#currentStyleInfo">currentStyleInfo</a></code></td>
                                <td class="name">
                                    <code>
                                        
<span class="param-type">
    
             Object
    
</span>



                                    </code>
                                </td>
                                <td class="name"><code><p>当前的矢量瓦片样式信息,包含serviceUrl 、styleUrl 、spriteUrl 、glyphsUrl 以及style</p></code></td>
                            </tr>
                        
                            <tr class="deep-level-0">
                                <td class="name"><code><a href="#description">description</a></code></td>
                                <td class="name">
                                    <code>
                                        
<span class="param-type">
    
             String
    
</span>



                                    </code>
                                </td>
                                <td class="name"><code><p>图层描述</p></code></td>
                            </tr>
                        
                            <tr class="deep-level-0">
                                <td class="name"><code><a href="#labelsRenderMode">labelsRenderMode</a></code></td>
                                <td class="name">
                                    <code>
                                        
<span class="param-type">
    
             String
    
</span>



                                    </code>
                                </td>
                                <td class="name"><code><p>指定矢量瓦片注记的渲染模式,仅在三维上有效;
on-screen: 使用Cesium接口实时渲染注记;
off-screen: 使用矢量瓦片来绘制注记;
请注意模式切换时,会造成性能损失,在显卡较弱的机器上会出现卡顿现象;</p></code></td>
                            </tr>
                        
                            <tr class="deep-level-0">
                                <td class="name"><code><a href="#mvtExtent">mvtExtent</a></code></td>
                                <td class="name">
                                    <code>
                                        
<span class="param-type">
    
             Number
    
</span>



                                    </code>
                                </td>
                                <td class="name"><code><p>mvt矢量瓦片相对坐标范围,默认为4096,表示矢量瓦片相对坐标的范围为0到4096</p></code></td>
                            </tr>
                        
                            <tr class="deep-level-0">
                                <td class="name"><code><a href="#style">style</a></code></td>
                                <td class="name">
                                    <code>
                                        
<span class="param-type">
    
             Object
    
</span>



                                    </code>
                                </td>
                                <td class="name"><code><p>矢量瓦片的mvt样式对象</p></code></td>
                            </tr>
                        
                            <tr class="deep-level-0">
                                <td class="name"><code><a href="#sublayers">sublayers</a></code></td>
                                <td class="name">
                                    <code>
                                        
<span class="param-type">
    
         <a onclick="getTypeHTML(event)" link="Collection.html">Collection</a>.&lt;<a onclick="getTypeHTML(event)" link="IGSVectorTileSubLayer.html">IGSVectorTileSubLayer</a>>
    
</span>



                                    </code>
                                </td>
                                <td class="name"><code><p>矢量瓦片子图层</p></code></td>
                            </tr>
                        
                            <tr class="deep-level-0">
                                <td class="name"><code><a href="#tileInfo">tileInfo</a></code></td>
                                <td class="name">
                                    <code>
                                        
<span class="param-type">
    
             <a link="TileInfo.html" onclick="getTypeHTML(event)" class="mapgis-link-name" title="TileInfo" TileInfo.html>TileInfo</a>
    
</span>
|

<span class="param-type">
    
             undefined
    
</span>



                                    </code>
                                </td>
                                <td class="name"><code><p>瓦片切图信息</p></code></td>
                            </tr>
                        
                            <tr class="deep-level-0">
                                <td class="name"><code><a href="#type">type</a></code></td>
                                <td class="name">
                                    <code>
                                        
<span class="param-type">
    
             String
    
</span>



                                    </code>
                                </td>
                                <td class="name"><code><p>图层类型</p></code></td>
                            </tr>
                        
                            <tr class="deep-level-0">
                                <td class="name"><code><a href="#url">url</a></code></td>
                                <td class="name">
                                    <code>
                                        
<span class="param-type">
    
             String
    
</span>



                                    </code>
                                </td>
                                <td class="name"><code><p>矢量瓦片服务地址</p></code></td>
                            </tr>
                        
                    </tbody>
                </table>
            </div>
            <h4 style="margin-top: 20px;margin-bottom: 20px;">成员变量详情</h4>
            <div class="members">
            
                <div class="member">

    <span class="method-parameter is-pulled-right">
        <label>类型:</label>
        
<span class="param-type">
    
         Array.&lt;String>
    
</span>



    </span>

<h4 class="name" id="capabilities">
    <a class="href-link" href="#capabilities">#</a>
    
    <span class="code-name">
        capabilities
    </span>
    
</h4>




<div class="description">
    <p>服务支持的能力</p>
</div>





<dl class="details">

    

    

    

    
    <dt class="tag-overrides">Overrides:</dt>
    <dd class="tag-overrides"><ul class="dummy"><li>
        <a class="mapgis-link-name" title="VectorTileLayer#capabilities" VectorTileLayer.html#capabilities>VectorTileLayer#capabilities</a>
    </li></ul></dd>
    

    

    

    

    

    

    

    

    
    

    

    

    
</dl>





</div>
            
                <div class="member">

    <span class="method-parameter is-pulled-right">
        <label>类型:</label>
        
<span class="param-type">
    
             <a link="Polygon.html" onclick="getTypeHTML(event)" class="mapgis-link-name" title="Polygon" Polygon.html>Polygon</a>
    
</span>
|

<span class="param-type">
    
             <a link="Extent.html" onclick="getTypeHTML(event)" class="mapgis-link-name" title="Extent" Extent.html>Extent</a>
    
</span>
|

<span class="param-type">
    
             <a link="Circle.html" onclick="getTypeHTML(event)" class="mapgis-link-name" title="Circle" Circle.html>Circle</a>
    
</span>
|

<span class="param-type">
    
             <a link="MultiPolygon.html" onclick="getTypeHTML(event)" class="mapgis-link-name" title="MultiPolygon" MultiPolygon.html>MultiPolygon</a>
    
</span>
|

<span class="param-type">
    
             null
    
</span>



    </span>

<h4 class="name" id="clippingArea">
    <a class="href-link" href="#clippingArea">#</a>
    
    <span class="code-name">
        clippingArea
    </span>
    
</h4>




<div class="description">
    <p>空间裁剪范围</p>
</div>





<dl class="details">

    

    

    
    <dt class="inherited-from">Inherited From:</dt>
    <dd class="inherited-from"><ul class="dummy"><li>
        <a goto="clippingArea" link="VectorTileLayer.html" onclick="getTypeHTML(event)" class="mapgis-link-name" title="VectorTileLayer#clippingArea" VectorTileLayer.html#clippingArea>VectorTileLayer#clippingArea</a>
    </li></ul></dd>
    

    

    

    

    

    

    

    

    

    
    

    

    

    
</dl>





</div>
            
                <div class="member">

    <span class="method-parameter is-pulled-right">
        <label>类型:</label>
        
<span class="param-type">
    
             Object
    
</span>



    </span>

<h4 class="name" id="currentStyleInfo">
    <a class="href-link" href="#currentStyleInfo">#</a>
    
        
            <span class='tag'>readonly</span>
        
    
    <span class="code-name">
        currentStyleInfo
    </span>
    
</h4>




<div class="description">
    <p>当前的矢量瓦片样式信息,包含serviceUrl 、styleUrl 、spriteUrl 、glyphsUrl 以及style</p>
</div>





<dl class="details">

    

    

    
    <dt class="inherited-from">Inherited From:</dt>
    <dd class="inherited-from"><ul class="dummy"><li>
        <a goto="currentStyleInfo" link="VectorTileLayer.html" onclick="getTypeHTML(event)" class="mapgis-link-name" title="VectorTileLayer#currentStyleInfo" VectorTileLayer.html#currentStyleInfo>VectorTileLayer#currentStyleInfo</a>
    </li></ul></dd>
    

    

    

    

    

    

    

    

    

    
    

    

    

    
</dl>





</div>
            
                <div class="member">

    <span class="method-parameter is-pulled-right">
        <label>类型:</label>
        
<span class="param-type">
    
             String
    
</span>



    </span>

<h4 class="name" id="description">
    <a class="href-link" href="#description">#</a>
    
        
            <span class='tag'>readonly</span>
        
    
    <span class="code-name">
        description
    </span>
    
</h4>




<div class="description">
    <p>图层描述</p>
</div>





<dl class="details">

    

    

    

    

    

    

    

    

    

    

    

    
    <dt class="tag-default">Default Value:</dt>
    <dd class="tag-default"><ul class="dummy">
            <li>IGS矢量瓦片图层</li>
        </ul></dd>
    
    

    

    

    
</dl>





</div>
            
                <div class="member">

    <span class="method-parameter is-pulled-right">
        <label>类型:</label>
        
<span class="param-type">
    
             String
    
</span>



    </span>

<h4 class="name" id="labelsRenderMode">
    <a class="href-link" href="#labelsRenderMode">#</a>
    
    <span class="code-name">
        labelsRenderMode
    </span>
    
</h4>




<div class="description">
    <p>指定矢量瓦片注记的渲染模式,仅在三维上有效;
on-screen: 使用Cesium接口实时渲染注记;
off-screen: 使用矢量瓦片来绘制注记;
请注意模式切换时,会造成性能损失,在显卡较弱的机器上会出现卡顿现象;</p>
</div>





<dl class="details">

    

    

    
    <dt class="inherited-from">Inherited From:</dt>
    <dd class="inherited-from"><ul class="dummy"><li>
        <a goto="labelsRenderMode" link="VectorTileLayer.html" onclick="getTypeHTML(event)" class="mapgis-link-name" title="VectorTileLayer#labelsRenderMode" VectorTileLayer.html#labelsRenderMode>VectorTileLayer#labelsRenderMode</a>
    </li></ul></dd>
    

    

    

    

    

    

    

    

    

    
    

    

    

    
</dl>





</div>
            
                <div class="member">

    <span class="method-parameter is-pulled-right">
        <label>类型:</label>
        
<span class="param-type">
    
             Number
    
</span>



    </span>

<h4 class="name" id="mvtExtent">
    <a class="href-link" href="#mvtExtent">#</a>
    
    <span class="code-name">
        mvtExtent
    </span>
    
</h4>




<div class="description">
    <p>mvt矢量瓦片相对坐标范围,默认为4096,表示矢量瓦片相对坐标的范围为0到4096</p>
</div>





<dl class="details">

    

    

    
    <dt class="inherited-from">Inherited From:</dt>
    <dd class="inherited-from"><ul class="dummy"><li>
        <a goto="mvtExtent" link="VectorTileLayer.html" onclick="getTypeHTML(event)" class="mapgis-link-name" title="VectorTileLayer#mvtExtent" VectorTileLayer.html#mvtExtent>VectorTileLayer#mvtExtent</a>
    </li></ul></dd>
    

    

    

    

    

    

    

    

    

    
    <dt class="tag-default">Default Value:</dt>
    <dd class="tag-default"><ul class="dummy">
            <li>4096</li>
        </ul></dd>
    
    

    

    

    
</dl>





</div>
            
                <div class="member">

    <span class="method-parameter is-pulled-right">
        <label>类型:</label>
        
<span class="param-type">
    
             Object
    
</span>



    </span>

<h4 class="name" id="style">
    <a class="href-link" href="#style">#</a>
    
    <span class="code-name">
        style
    </span>
    
</h4>




<div class="description">
    <p>矢量瓦片的mvt样式对象</p>
</div>





<dl class="details">

    

    

    
    <dt class="inherited-from">Inherited From:</dt>
    <dd class="inherited-from"><ul class="dummy"><li>
        <a goto="style" link="VectorTileLayer.html" onclick="getTypeHTML(event)" class="mapgis-link-name" title="VectorTileLayer#style" VectorTileLayer.html#style>VectorTileLayer#style</a>
    </li></ul></dd>
    

    

    

    

    

    

    

    

    

    
    

    

    

    
</dl>





</div>
            
                <div class="member">

    <span class="method-parameter is-pulled-right">
        <label>类型:</label>
        
<span class="param-type">
    
         <a onclick="getTypeHTML(event)" link="Collection.html">Collection</a>.&lt;<a onclick="getTypeHTML(event)" link="IGSVectorTileSubLayer.html">IGSVectorTileSubLayer</a>>
    
</span>



    </span>

<h4 class="name" id="sublayers">
    <a class="href-link" href="#sublayers">#</a>
    
    <span class="code-name">
        sublayers
    </span>
    
</h4>




<div class="description">
    <p>矢量瓦片子图层</p>
</div>





<dl class="details">

    

    

    

    

    

    

    

    

    

    

    

    
    

    

    

    
</dl>





</div>
            
                <div class="member">

    <span class="method-parameter is-pulled-right">
        <label>类型:</label>
        
<span class="param-type">
    
             <a link="TileInfo.html" onclick="getTypeHTML(event)" class="mapgis-link-name" title="TileInfo" TileInfo.html>TileInfo</a>
    
</span>
|

<span class="param-type">
    
             undefined
    
</span>



    </span>

<h4 class="name" id="tileInfo">
    <a class="href-link" href="#tileInfo">#</a>
    
        
            <span class='tag'>readonly</span>
        
    
    <span class="code-name">
        tileInfo
    </span>
    
</h4>




<div class="description">
    <p>瓦片切图信息</p>
</div>





<dl class="details">

    

    

    

    
    <dt class="tag-overrides">Overrides:</dt>
    <dd class="tag-overrides"><ul class="dummy"><li>
        <a class="mapgis-link-name" title="VectorTileLayer#tileInfo" VectorTileLayer.html#tileInfo>VectorTileLayer#tileInfo</a>
    </li></ul></dd>
    

    

    

    

    

    

    

    

    
    

    

    

    
</dl>





</div>
            
                <div class="member">

    <span class="method-parameter is-pulled-right">
        <label>类型:</label>
        
<span class="param-type">
    
             String
    
</span>



    </span>

<h4 class="name" id="type">
    <a class="href-link" href="#type">#</a>
    
        
            <span class='tag'>readonly</span>
        
    
    <span class="code-name">
        type
    </span>
    
</h4>




<div class="description">
    <p>图层类型</p>
</div>





<dl class="details">

    

    

    

    

    

    

    

    

    

    

    

    
    <dt class="tag-default">Default Value:</dt>
    <dd class="tag-default"><ul class="dummy">
            <li>LayerType.igsVectorTile</li>
        </ul></dd>
    
    

    

    

    
</dl>





</div>
            
                <div class="member">

    <span class="method-parameter is-pulled-right">
        <label>类型:</label>
        
<span class="param-type">
    
             String
    
</span>



    </span>

<h4 class="name" id="url">
    <a class="href-link" href="#url">#</a>
    
    <span class="code-name">
        url
    </span>
    
</h4>




<div class="description">
    <p>矢量瓦片服务地址</p>
</div>





<dl class="details">

    

    

    

    
    <dt class="tag-overrides">Overrides:</dt>
    <dd class="tag-overrides"><ul class="dummy"><li>
        <a class="mapgis-link-name" title="VectorTileLayer#url" VectorTileLayer.html#url>VectorTileLayer#url</a>
    </li></ul></dd>
    

    

    

    

    

    

    

    

    
    

    

    

    
</dl>





</div>
            
            </div>
        </div>
    

    
        <div class='vertical-section'>
            <h3 id='function'>方法</h3>
            <h4 style="margin-top: 20px;margin-bottom: 20px;">方法概述</h4>
            <div class="members">
            <div class="table-container">
                <table class="params table">
                    <thead>
                    <tr>
                        <th>名称</th>
                        <th>返回值类型</th>
                        <th>描述</th>
                    </tr>
                    </thead>
                    <tbody>
                        
                            <tr class="deep-level-0">
                                <td class="name"><code><a href="#fromJSON">fromJSON</a></code></td>
                                <td class="name">
                                    <code>
                                        
                                                
<span class="param-type">
    
             <a link="IGSVectorTileLayer.html" onclick="getTypeHTML(event)" class="mapgis-link-name" title="IGSVectorTileLayer" IGSVectorTileLayer.html>IGSVectorTileLayer</a>
    
</span>



                                            
                                    </code>
                                </td>
                                <td class="name"><code><p>通过传入的json构造并返回一个新的VectorTileLayer对象</code></td>
                            </tr>
                        
                            <tr class="deep-level-0">
                                <td class="name"><code><a href="#_initSubLayerOptions">_initSubLayerOptions</a></code></td>
                                <td class="name">
                                    <code>
                                        
                                    </code>
                                </td>
                                <td class="name"><code><p>通过元信息中获取的子图层参数和用户设置的参数,构造MapGIS矢量瓦片子图层的初始化参数数组</p></code></td>
                            </tr>
                        
                            <tr class="deep-level-0">
                                <td class="name"><code><a href="#clone">clone</a></code></td>
                                <td class="name">
                                    <code>
                                        
                                                
<span class="param-type">
    
             <a link="Layer.html" onclick="getTypeHTML(event)" class="mapgis-link-name" title="Layer" Layer.html>Layer</a>
    
</span>



                                            
                                    </code>
                                </td>
                                <td class="name"><code><p>克隆方法</p></code></td>
                            </tr>
                        
                            <tr class="deep-level-0">
                                <td class="name"><code><a href="#covertCustomStyleToMVTStyle">covertCustomStyleToMVTStyle</a></code></td>
                                <td class="name">
                                    <code>
                                        
                                                
<span class="param-type">
    
             Object
    
</span>



                                            
                                    </code>
                                </td>
                                <td class="name"><code><p>将自定义的style转成矢量瓦片的mvtStyle,可有子类或初始化时自定义</p></code></td>
                            </tr>
                        
                            <tr class="deep-level-0">
                                <td class="name"><code><a href="#deleteStyleLayer">deleteStyleLayer</a></code></td>
                                <td class="name">
                                    <code>
                                        
                                    </code>
                                </td>
                                <td class="name"><code></code></td>
                            </tr>
                        
                            <tr class="deep-level-0">
                                <td class="name"><code><a href="#findSublayerById">findSublayerById</a></code></td>
                                <td class="name">
                                    <code>
                                        
                                                
<span class="param-type">
    
             <a link="IGSVectorTileSubLayer.html" onclick="getTypeHTML(event)" class="mapgis-link-name" title="IGSVectorTileSubLayer" IGSVectorTileSubLayer.html>IGSVectorTileSubLayer</a>
    
</span>



                                            
                                    </code>
                                </td>
                                <td class="name"><code><p>根据子图层id查询图层</p></code></td>
                            </tr>
                        
                            <tr class="deep-level-0">
                                <td class="name"><code><a href="#getExtendProperties">getExtendProperties</a></code></td>
                                <td class="name">
                                    <code>
                                        
                                                
<span class="param-type">
    
             Any
    
</span>



                                            
                                    </code>
                                </td>
                                <td class="name"><code></code></td>
                            </tr>
                        
                            <tr class="deep-level-0">
                                <td class="name"><code><a href="#getLayoutProperties">getLayoutProperties</a></code></td>
                                <td class="name">
                                    <code>
                                        
                                                
<span class="param-type">
    
             Object
    
</span>
|

<span class="param-type">
    
             null
    
</span>



                                            
                                    </code>
                                </td>
                                <td class="name"><code></code></td>
                            </tr>
                        
                            <tr class="deep-level-0">
                                <td class="name"><code><a href="#getPaintProperties">getPaintProperties</a></code></td>
                                <td class="name">
                                    <code>
                                        
                                                
<span class="param-type">
    
             Object
    
</span>
|

<span class="param-type">
    
             null
    
</span>



                                            
                                    </code>
                                </td>
                                <td class="name"><code></code></td>
                            </tr>
                        
                            <tr class="deep-level-0">
                                <td class="name"><code><a href="#getStyleLayer">getStyleLayer</a></code></td>
                                <td class="name">
                                    <code>
                                        
                                                
<span class="param-type">
    
             Object
    
</span>



                                            
                                    </code>
                                </td>
                                <td class="name"><code></code></td>
                            </tr>
                        
                            <tr class="deep-level-0">
                                <td class="name"><code><a href="#getStyleLayerId">getStyleLayerId</a></code></td>
                                <td class="name">
                                    <code>
                                        
                                                
<span class="param-type">
    
             String
    
</span>



                                            
                                    </code>
                                </td>
                                <td class="name"><code></code></td>
                            </tr>
                        
                            <tr class="deep-level-0">
                                <td class="name"><code><a href="#getStyleLayerIndex">getStyleLayerIndex</a></code></td>
                                <td class="name">
                                    <code>
                                        
                                                
<span class="param-type">
    
             Number
    
</span>



                                            
                                    </code>
                                </td>
                                <td class="name"><code></code></td>
                            </tr>
                        
                            <tr class="deep-level-0">
                                <td class="name"><code><a href="#getStyleLayerVisibility">getStyleLayerVisibility</a></code></td>
                                <td class="name">
                                    <code>
                                        
                                                
<span class="param-type">
    
             Boolean
    
</span>



                                            
                                    </code>
                                </td>
                                <td class="name"><code><p>获取样式图层可见性
</code></td>
                            </tr>
                        
                            <tr class="deep-level-0">
                                <td class="name"><code><a href="#setExtendProperties">setExtendProperties</a></code></td>
                                <td class="name">
                                    <code>
                                        
                                    </code>
                                </td>
                                <td class="name"><code></code></td>
                            </tr>
                        
                            <tr class="deep-level-0">
                                <td class="name"><code><a href="#setLayoutProperties">setLayoutProperties</a></code></td>
                                <td class="name">
                                    <code>
                                        
                                    </code>
                                </td>
                                <td class="name"><code></code></td>
                            </tr>
                        
                            <tr class="deep-level-0">
                                <td class="name"><code><a href="#setPaintProperties">setPaintProperties</a></code></td>
                                <td class="name">
                                    <code>
                                        
                                    </code>
                                </td>
                                <td class="name"><code></code></td>
                            </tr>
                        
                            <tr class="deep-level-0">
                                <td class="name"><code><a href="#setStyleLayer">setStyleLayer</a></code></td>
                                <td class="name">
                                    <code>
                                        
                                    </code>
                                </td>
                                <td class="name"><code></code></td>
                            </tr>
                        
                            <tr class="deep-level-0">
                                <td class="name"><code><a href="#setStyleLayerVisibility">setStyleLayerVisibility</a></code></td>
                                <td class="name">
                                    <code>
                                        
                                    </code>
                                </td>
                                <td class="name"><code></code></td>
                            </tr>
                        
                            <tr class="deep-level-0">
                                <td class="name"><code><a href="#toJSON">toJSON</a></code></td>
                                <td class="name">
                                    <code>
                                        
                                                
<span class="param-type">
    
             Object
    
</span>



                                            
                                    </code>
                                </td>
                                <td class="name"><code><p>转换为json对象</p></code></td>
                            </tr>
                        
                    </tbody>
                </table>
            </div>
            <h4 style="margin-top: 20px;margin-bottom: 20px;">方法详情</h4>
            
                <div class="member">


    
    <h4 class="name" id=".fromJSON">
        <a class="href-link" href="#.fromJSON">#</a>
        
            
                <span class='tag'>static</span>
            
        
        <span class="code-name" id="fromJSON" style="font-size:30px">
            
                fromJSON<span class="signature">(json)</span>
            
        </span>
    </h4>
    

    
    <div class="description">
        <p>通过传入的json构造并返回一个新的VectorTileLayer对象<a id='fromJSON'></a></p>
    </div>
    









    <h4>参数</h4>
    
<div class="table-container">
    <table class="params table">
        <thead>
        <tr>
            
            <th>名称</th>
            

            <th>类型</th>

            

            <th class="last">描述</th>
        </tr>
        </thead>

        <tbody>
        

            
<tr class="deep-level-0">
  
      <td class="name"><code>json</code></td>
  

  <td class="type">
  
      
<span class="param-type">
    
             Object
    
</span>



  
  </td>

  

  <td class="description last"><p>JSON对象</p></td>
</tr>



        
        </tbody>
    </table>
</div>






<dl class="details">

    

    

    

    

    

    

    

    

    

    

    

    
    

    

    

    
</dl>


















    <div class='columns method-parameter'>
        <div class="column is-2"><label>返回值</label></div>
        <div class="column is-10">
            
                    

<div class="columns">
    
    <div class='param-desc column is-7'><p>新的VectorTileLayer对象</p></div>
    
    
    <div class='column is-5 has-text-left'>
        <label>类型: </label>
        
<span class="param-type">
    
             <a link="IGSVectorTileLayer.html" onclick="getTypeHTML(event)" class="mapgis-link-name" title="IGSVectorTileLayer" IGSVectorTileLayer.html>IGSVectorTileLayer</a>
    
</span>



    </div>
    
</div>

                
        </div>
    </div>






</div>
            
                <div class="member">


    
    <h4 class="name" id="_initSubLayerOptions">
        <a class="href-link" href="#_initSubLayerOptions">#</a>
        
        <span class="code-name" id="_initSubLayerOptions" style="font-size:30px">
            
                _initSubLayerOptions<span class="signature">(serverSubLayers, clientSubLayers)</span>
            
        </span>
    </h4>
    

    
    <div class="description">
        <p>通过元信息中获取的子图层参数和用户设置的参数,构造MapGIS矢量瓦片子图层的初始化参数数组</p>
    </div>
    









    <h4>参数</h4>
    
<div class="table-container">
    <table class="params table">
        <thead>
        <tr>
            
            <th>名称</th>
            

            <th>类型</th>

            

            <th class="last">描述</th>
        </tr>
        </thead>

        <tbody>
        

            
<tr class="deep-level-0">
  
      <td class="name"><code>serverSubLayers</code></td>
  

  <td class="type">
  
      
<span class="param-type">
    
         Array.&lt;Object>
    
</span>



  
  </td>

  

  <td class="description last"><p>服务器端获取的子图层参数,同时也是最终的构造参数</p></td>
</tr>



        

            
<tr class="deep-level-0">
  
      <td class="name"><code>clientSubLayers</code></td>
  

  <td class="type">
  
      
<span class="param-type">
    
         Array.&lt;Object>
    
</span>



  
  </td>

  

  <td class="description last"><p>客户端获取的子图层参数</p></td>
</tr>



        
        </tbody>
    </table>
</div>






<dl class="details">

    

    

    

    

    

    

    

    

    

    

    

    
    

    

    

    
</dl>























</div>
            
                <div class="member">


    
    <h4 class="name" id="clone">
        <a class="href-link" href="#clone">#</a>
        
        <span class="code-name" id="clone" style="font-size:30px">
            
                clone<span class="signature">()</span>
            
        </span>
    </h4>
    

    
    <div class="description">
        <p>克隆方法</p>
    </div>
    













<dl class="details">

    

    

    
    <dt class="inherited-from">Inherited From:</dt>
    <dd class="inherited-from"><ul class="dummy"><li>
        <a goto="clone" link="VectorTileLayer.html" onclick="getTypeHTML(event)" class="mapgis-link-name" title="VectorTileLayer#clone" VectorTileLayer.html#clone>VectorTileLayer#clone</a>
    </li></ul></dd>
    

    

    

    

    

    

    

    

    

    
    

    

    

    
</dl>


















    <div class='columns method-parameter'>
        <div class="column is-2"><label>返回值</label></div>
        <div class="column is-10">
            
                    

<div class="columns">
    
    <div class='param-desc column is-7'><p>图层</p></div>
    
    
    <div class='column is-5 has-text-left'>
        <label>类型: </label>
        
<span class="param-type">
    
             <a link="Layer.html" onclick="getTypeHTML(event)" class="mapgis-link-name" title="Layer" Layer.html>Layer</a>
    
</span>



    </div>
    
</div>

                
        </div>
    </div>






</div>
            
                <div class="member">


    
    <h4 class="name" id="covertCustomStyleToMVTStyle">
        <a class="href-link" href="#covertCustomStyleToMVTStyle">#</a>
        
        <span class="code-name" id="covertCustomStyleToMVTStyle" style="font-size:30px">
            
                covertCustomStyleToMVTStyle<span class="signature">(customStyle)</span>
            
        </span>
    </h4>
    

    
    <div class="description">
        <p>将自定义的style转成矢量瓦片的mvtStyle,可有子类或初始化时自定义</p>
    </div>
    









    <h4>参数</h4>
    
<div class="table-container">
    <table class="params table">
        <thead>
        <tr>
            
            <th>名称</th>
            

            <th>类型</th>

            

            <th class="last">描述</th>
        </tr>
        </thead>

        <tbody>
        

            
<tr class="deep-level-0">
  
      <td class="name"><code>customStyle</code></td>
  

  <td class="type">
  
      
<span class="param-type">
    
             Object
    
</span>



  
  </td>

  

  <td class="description last"><p>自定义的style</p></td>
</tr>



        
        </tbody>
    </table>
</div>






<dl class="details">

    

    

    

    

    

    

    

    

    

    

    

    
    

    

    

    
</dl>


















    <div class='columns method-parameter'>
        <div class="column is-2"><label>返回值</label></div>
        <div class="column is-10">
            
                    

<div class="columns">
    
    <div class='param-desc column is-7'><p>修改好的符合矢量瓦片规范的样式对象</p></div>
    
    
    <div class='column is-5 has-text-left'>
        <label>类型: </label>
        
<span class="param-type">
    
             Object
    
</span>



    </div>
    
</div>

                
        </div>
    </div>






</div>
            
                <div class="member">


    
    <h4 class="name" id="deleteStyleLayer">
        <a class="href-link" href="#deleteStyleLayer">#</a>
        
        <span class="code-name" id="deleteStyleLayer" style="font-size:30px">
            
                deleteStyleLayer<span class="signature">(styleLayerId)</span>
            
        </span>
    </h4>
    

    
    <div class="description">
        <a id='deleteStyleLayer'/>
删除样式图层
    </div>
    









    <h4>参数</h4>
    
<div class="table-container">
    <table class="params table">
        <thead>
        <tr>
            
            <th>名称</th>
            

            <th>类型</th>

            

            <th class="last">描述</th>
        </tr>
        </thead>

        <tbody>
        

            
<tr class="deep-level-0">
  
      <td class="name"><code>styleLayerId</code></td>
  

  <td class="type">
  
      
<span class="param-type">
    
             String
    
</span>



  
  </td>

  

  <td class="description last"><p>样式图层id</p></td>
</tr>



        
        </tbody>
    </table>
</div>






<dl class="details">

    

    

    
    <dt class="inherited-from">Inherited From:</dt>
    <dd class="inherited-from"><ul class="dummy"><li>
        <a goto="deleteStyleLayer" link="VectorTileLayer.html" onclick="getTypeHTML(event)" class="mapgis-link-name" title="VectorTileLayer#deleteStyleLayer" VectorTileLayer.html#deleteStyleLayer>VectorTileLayer#deleteStyleLayer</a>
    </li></ul></dd>
    

    

    

    

    

    

    

    

    

    
    

    

    

    
</dl>























</div>
            
                <div class="member">


    
    <h4 class="name" id="findSublayerById">
        <a class="href-link" href="#findSublayerById">#</a>
        
        <span class="code-name" id="findSublayerById" style="font-size:30px">
            
                findSublayerById<span class="signature">(sublayerID)</span>
            
        </span>
    </h4>
    

    
    <div class="description">
        <p>根据子图层id查询图层</p>
    </div>
    









    <h4>参数</h4>
    
<div class="table-container">
    <table class="params table">
        <thead>
        <tr>
            
            <th>名称</th>
            

            <th>类型</th>

            

            <th class="last">描述</th>
        </tr>
        </thead>

        <tbody>
        

            
<tr class="deep-level-0">
  
      <td class="name"><code>sublayerID</code></td>
  

  <td class="type">
  
      
<span class="param-type">
    
             String
    
</span>



  
  </td>

  

  <td class="description last"><p>图层ID</p></td>
</tr>



        
        </tbody>
    </table>
</div>






<dl class="details">

    

    

    

    

    

    

    

    

    

    

    

    
    

    

    

    
</dl>


















    <div class='columns method-parameter'>
        <div class="column is-2"><label>返回值</label></div>
        <div class="column is-10">
            
                    

<div class="columns">
    
    <div class='param-desc column is-7'><p>子图层</p></div>
    
    
    <div class='column is-5 has-text-left'>
        <label>类型: </label>
        
<span class="param-type">
    
             <a link="IGSVectorTileSubLayer.html" onclick="getTypeHTML(event)" class="mapgis-link-name" title="IGSVectorTileSubLayer" IGSVectorTileSubLayer.html>IGSVectorTileSubLayer</a>
    
</span>



    </div>
    
</div>

                
        </div>
    </div>






    <h5>示例</h5>
    
        <p class="code-caption"><h7 id='findSublayerById'>根据子图层id查询图层</h7></p>
    
    
        <pre class="prettyprint"><code>// ES5引入方式
const { IGSVectorTileLayer } = zondy.layer
// ES6引入方式
import { IGSVectorTileLayer} from "@mapgis/webclient-common"
const igsVectorTileLayer = new IGSVectorTileLayer({
  // 服务基地址
  url: 'http://{ip}:{port}/igs/rest/services/{serviceName}/VectorTileServer'
});
map.add(igsVectorTileLayer);
// 根据id获取子图层
const subLayer = igsVectorTileLayer.findSublayerById('子图层id')</code></pre>
    


</div>
            
                <div class="member">


    
    <h4 class="name" id="getExtendProperties">
        <a class="href-link" href="#getExtendProperties">#</a>
        
        <span class="code-name" id="getExtendProperties" style="font-size:30px">
            
                getExtendProperties<span class="signature">(styleLayerId, key)</span>
            
        </span>
    </h4>
    

    
    <div class="description">
        <a id='getExtendProperties'/>
获取样式图层的额外属性
    </div>
    









    <h4>参数</h4>
    
<div class="table-container">
    <table class="params table">
        <thead>
        <tr>
            
            <th>名称</th>
            

            <th>类型</th>

            

            <th class="last">描述</th>
        </tr>
        </thead>

        <tbody>
        

            
<tr class="deep-level-0">
  
      <td class="name"><code>styleLayerId</code></td>
  

  <td class="type">
  
      
<span class="param-type">
    
             String
    
</span>



  
  </td>

  

  <td class="description last"><p>样式图层id</p></td>
</tr>



        

            
<tr class="deep-level-0">
  
      <td class="name"><code>key</code></td>
  

  <td class="type">
  
      
<span class="param-type">
    
             String
    
</span>



  
  </td>

  

  <td class="description last"><p>额外属性的属性名</p></td>
</tr>



        
        </tbody>
    </table>
</div>






<dl class="details">

    

    

    
    <dt class="inherited-from">Inherited From:</dt>
    <dd class="inherited-from"><ul class="dummy"><li>
        <a goto="getExtendProperties" link="VectorTileLayer.html" onclick="getTypeHTML(event)" class="mapgis-link-name" title="VectorTileLayer#getExtendProperties" VectorTileLayer.html#getExtendProperties>VectorTileLayer#getExtendProperties</a>
    </li></ul></dd>
    

    

    

    

    

    

    

    

    

    
    

    

    

    
</dl>


















    <div class='columns method-parameter'>
        <div class="column is-2"><label>返回值</label></div>
        <div class="column is-10">
            
                    

<div class="columns">
    
    <div class='param-desc column is-7'><p>额外属性的属性值</p></div>
    
    
    <div class='column is-5 has-text-left'>
        <label>类型: </label>
        
<span class="param-type">
    
             Any
    
</span>



    </div>
    
</div>

                
        </div>
    </div>






</div>
            
                <div class="member">


    
    <h4 class="name" id="getLayoutProperties">
        <a class="href-link" href="#getLayoutProperties">#</a>
        
        <span class="code-name" id="getLayoutProperties" style="font-size:30px">
            
                getLayoutProperties<span class="signature">(styleLayerId)</span>
            
        </span>
    </h4>
    

    
    <div class="description">
        <a id='getLayoutProperties'/>
获取样式图层布局属性
    </div>
    









    <h4>参数</h4>
    
<div class="table-container">
    <table class="params table">
        <thead>
        <tr>
            
            <th>名称</th>
            

            <th>类型</th>

            

            <th class="last">描述</th>
        </tr>
        </thead>

        <tbody>
        

            
<tr class="deep-level-0">
  
      <td class="name"><code>styleLayerId</code></td>
  

  <td class="type">
  
      
<span class="param-type">
    
             String
    
</span>



  
  </td>

  

  <td class="description last"><p>样式图层id</p></td>
</tr>



        
        </tbody>
    </table>
</div>






<dl class="details">

    

    

    
    <dt class="inherited-from">Inherited From:</dt>
    <dd class="inherited-from"><ul class="dummy"><li>
        <a goto="getLayoutProperties" link="VectorTileLayer.html" onclick="getTypeHTML(event)" class="mapgis-link-name" title="VectorTileLayer#getLayoutProperties" VectorTileLayer.html#getLayoutProperties>VectorTileLayer#getLayoutProperties</a>
    </li></ul></dd>
    

    

    

    

    

    

    

    

    

    
    

    

    

    
</dl>


















    <div class='columns method-parameter'>
        <div class="column is-2"><label>返回值</label></div>
        <div class="column is-10">
            
                    

<div class="columns">
    
    <div class='param-desc column is-7'><p>样式图层布局属性</p></div>
    
    
    <div class='column is-5 has-text-left'>
        <label>类型: </label>
        
<span class="param-type">
    
             Object
    
</span>
|

<span class="param-type">
    
             null
    
</span>



    </div>
    
</div>

                
        </div>
    </div>






</div>
            
                <div class="member">


    
    <h4 class="name" id="getPaintProperties">
        <a class="href-link" href="#getPaintProperties">#</a>
        
        <span class="code-name" id="getPaintProperties" style="font-size:30px">
            
                getPaintProperties<span class="signature">(styleLayerId)</span>
            
        </span>
    </h4>
    

    
    <div class="description">
        <a id='getPaintProperties'/>
获取样式图层绘制属性
    </div>
    









    <h4>参数</h4>
    
<div class="table-container">
    <table class="params table">
        <thead>
        <tr>
            
            <th>名称</th>
            

            <th>类型</th>

            

            <th class="last">描述</th>
        </tr>
        </thead>

        <tbody>
        

            
<tr class="deep-level-0">
  
      <td class="name"><code>styleLayerId</code></td>
  

  <td class="type">
  
      
<span class="param-type">
    
             String
    
</span>



  
  </td>

  

  <td class="description last"><p>样式图层id</p></td>
</tr>



        
        </tbody>
    </table>
</div>






<dl class="details">

    

    

    
    <dt class="inherited-from">Inherited From:</dt>
    <dd class="inherited-from"><ul class="dummy"><li>
        <a goto="getPaintProperties" link="VectorTileLayer.html" onclick="getTypeHTML(event)" class="mapgis-link-name" title="VectorTileLayer#getPaintProperties" VectorTileLayer.html#getPaintProperties>VectorTileLayer#getPaintProperties</a>
    </li></ul></dd>
    

    

    

    

    

    

    

    

    

    
    

    

    

    
</dl>


















    <div class='columns method-parameter'>
        <div class="column is-2"><label>返回值</label></div>
        <div class="column is-10">
            
                    

<div class="columns">
    
    <div class='param-desc column is-7'><p>返回样式图层绘制属性</p></div>
    
    
    <div class='column is-5 has-text-left'>
        <label>类型: </label>
        
<span class="param-type">
    
             Object
    
</span>
|

<span class="param-type">
    
             null
    
</span>



    </div>
    
</div>

                
        </div>
    </div>






</div>
            
                <div class="member">


    
    <h4 class="name" id="getStyleLayer">
        <a class="href-link" href="#getStyleLayer">#</a>
        
        <span class="code-name" id="getStyleLayer" style="font-size:30px">
            
                getStyleLayer<span class="signature">(styleLayerId)</span>
            
        </span>
    </h4>
    

    
    <div class="description">
        <a id='getStyleLayer'/>
通过矢量瓦片样式图层的id,找到对应的矢量瓦片样式图层对象
    </div>
    









    <h4>参数</h4>
    
<div class="table-container">
    <table class="params table">
        <thead>
        <tr>
            
            <th>名称</th>
            

            <th>类型</th>

            

            <th class="last">描述</th>
        </tr>
        </thead>

        <tbody>
        

            
<tr class="deep-level-0">
  
      <td class="name"><code>styleLayerId</code></td>
  

  <td class="type">
  
      
<span class="param-type">
    
             String
    
</span>



  
  </td>

  

  <td class="description last"><p>样式图层的id</p></td>
</tr>



        
        </tbody>
    </table>
</div>






<dl class="details">

    

    

    
    <dt class="inherited-from">Inherited From:</dt>
    <dd class="inherited-from"><ul class="dummy"><li>
        <a goto="getStyleLayer" link="VectorTileLayer.html" onclick="getTypeHTML(event)" class="mapgis-link-name" title="VectorTileLayer#getStyleLayer" VectorTileLayer.html#getStyleLayer>VectorTileLayer#getStyleLayer</a>
    </li></ul></dd>
    

    

    

    

    

    

    

    

    

    
    

    

    

    
</dl>


















    <div class='columns method-parameter'>
        <div class="column is-2"><label>返回值</label></div>
        <div class="column is-10">
            
                    

<div class="columns">
    
    <div class='param-desc column is-7'><p>样式图层对象</p></div>
    
    
    <div class='column is-5 has-text-left'>
        <label>类型: </label>
        
<span class="param-type">
    
             Object
    
</span>



    </div>
    
</div>

                
        </div>
    </div>






</div>
            
                <div class="member">


    
    <h4 class="name" id="getStyleLayerId">
        <a class="href-link" href="#getStyleLayerId">#</a>
        
        <span class="code-name" id="getStyleLayerId" style="font-size:30px">
            
                getStyleLayerId<span class="signature">(index)</span>
            
        </span>
    </h4>
    

    
    <div class="description">
        <a id='getStyleLayerIndex'/>
通过矢量瓦片样式图层的序号,找到对应的矢量瓦片样式图层的id
    </div>
    









    <h4>参数</h4>
    
<div class="table-container">
    <table class="params table">
        <thead>
        <tr>
            
            <th>名称</th>
            

            <th>类型</th>

            

            <th class="last">描述</th>
        </tr>
        </thead>

        <tbody>
        

            
<tr class="deep-level-0">
  
      <td class="name"><code>index</code></td>
  

  <td class="type">
  
      
<span class="param-type">
    
             Number
    
</span>



  
  </td>

  

  <td class="description last"><p>样式图层的序号</p></td>
</tr>



        
        </tbody>
    </table>
</div>






<dl class="details">

    

    

    
    <dt class="inherited-from">Inherited From:</dt>
    <dd class="inherited-from"><ul class="dummy"><li>
        <a goto="getStyleLayerId" link="VectorTileLayer.html" onclick="getTypeHTML(event)" class="mapgis-link-name" title="VectorTileLayer#getStyleLayerId" VectorTileLayer.html#getStyleLayerId>VectorTileLayer#getStyleLayerId</a>
    </li></ul></dd>
    

    

    

    

    

    

    

    

    

    
    

    

    

    
</dl>


















    <div class='columns method-parameter'>
        <div class="column is-2"><label>返回值</label></div>
        <div class="column is-10">
            
                    

<div class="columns">
    
    <div class='param-desc column is-7'><p>样式图层的id</p></div>
    
    
    <div class='column is-5 has-text-left'>
        <label>类型: </label>
        
<span class="param-type">
    
             String
    
</span>



    </div>
    
</div>

                
        </div>
    </div>






</div>
            
                <div class="member">


    
    <h4 class="name" id="getStyleLayerIndex">
        <a class="href-link" href="#getStyleLayerIndex">#</a>
        
        <span class="code-name" id="getStyleLayerIndex" style="font-size:30px">
            
                getStyleLayerIndex<span class="signature">(styleLayerId)</span>
            
        </span>
    </h4>
    

    
    <div class="description">
        <a id='getStyleLayerIndex'/>
通过矢量瓦片样式图层的id,找到对应的矢量瓦片样式图层的序号
    </div>
    









    <h4>参数</h4>
    
<div class="table-container">
    <table class="params table">
        <thead>
        <tr>
            
            <th>名称</th>
            

            <th>类型</th>

            

            <th class="last">描述</th>
        </tr>
        </thead>

        <tbody>
        

            
<tr class="deep-level-0">
  
      <td class="name"><code>styleLayerId</code></td>
  

  <td class="type">
  
      
<span class="param-type">
    
             String
    
</span>



  
  </td>

  

  <td class="description last"><p>样式图层的id</p></td>
</tr>



        
        </tbody>
    </table>
</div>






<dl class="details">

    

    

    
    <dt class="inherited-from">Inherited From:</dt>
    <dd class="inherited-from"><ul class="dummy"><li>
        <a goto="getStyleLayerIndex" link="VectorTileLayer.html" onclick="getTypeHTML(event)" class="mapgis-link-name" title="VectorTileLayer#getStyleLayerIndex" VectorTileLayer.html#getStyleLayerIndex>VectorTileLayer#getStyleLayerIndex</a>
    </li></ul></dd>
    

    

    

    

    

    

    

    

    

    
    

    

    

    
</dl>


















    <div class='columns method-parameter'>
        <div class="column is-2"><label>返回值</label></div>
        <div class="column is-10">
            
                    

<div class="columns">
    
    <div class='param-desc column is-7'><p>样式图层的序号</p></div>
    
    
    <div class='column is-5 has-text-left'>
        <label>类型: </label>
        
<span class="param-type">
    
             Number
    
</span>



    </div>
    
</div>

                
        </div>
    </div>






</div>
            
                <div class="member">


    
    <h4 class="name" id="getStyleLayerVisibility">
        <a class="href-link" href="#getStyleLayerVisibility">#</a>
        
        <span class="code-name" id="getStyleLayerVisibility" style="font-size:30px">
            
                getStyleLayerVisibility<span class="signature">(styleLayerId)</span>
            
        </span>
    </h4>
    

    
    <div class="description">
        <p>获取样式图层可见性
<a id='getStyleLayerVisibility'/></p>
    </div>
    









    <h4>参数</h4>
    
<div class="table-container">
    <table class="params table">
        <thead>
        <tr>
            
            <th>名称</th>
            

            <th>类型</th>

            

            <th class="last">描述</th>
        </tr>
        </thead>

        <tbody>
        

            
<tr class="deep-level-0">
  
      <td class="name"><code>styleLayerId</code></td>
  

  <td class="type">
  
      
<span class="param-type">
    
             String
    
</span>



  
  </td>

  

  <td class="description last"><p>样式图层id</p></td>
</tr>



        
        </tbody>
    </table>
</div>






<dl class="details">

    

    

    
    <dt class="inherited-from">Inherited From:</dt>
    <dd class="inherited-from"><ul class="dummy"><li>
        <a goto="getStyleLayerVisibility" link="VectorTileLayer.html" onclick="getTypeHTML(event)" class="mapgis-link-name" title="VectorTileLayer#getStyleLayerVisibility" VectorTileLayer.html#getStyleLayerVisibility>VectorTileLayer#getStyleLayerVisibility</a>
    </li></ul></dd>
    

    

    

    

    

    

    

    

    

    
    

    

    

    
</dl>


















    <div class='columns method-parameter'>
        <div class="column is-2"><label>返回值</label></div>
        <div class="column is-10">
            
                    

<div class="columns">
    
    <div class='param-desc column is-7'><p>样式图层可见性状态</p></div>
    
    
    <div class='column is-5 has-text-left'>
        <label>类型: </label>
        
<span class="param-type">
    
             Boolean
    
</span>



    </div>
    
</div>

                
        </div>
    </div>






</div>
            
                <div class="member">


    
    <h4 class="name" id="setExtendProperties">
        <a class="href-link" href="#setExtendProperties">#</a>
        
        <span class="code-name" id="setExtendProperties" style="font-size:30px">
            
                setExtendProperties<span class="signature">(styleLayerId, key, value)</span>
            
        </span>
    </h4>
    

    
    <div class="description">
        <a id='setExtendProperties'/>
设置样式图层的额外属性
    </div>
    









    <h4>参数</h4>
    
<div class="table-container">
    <table class="params table">
        <thead>
        <tr>
            
            <th>名称</th>
            

            <th>类型</th>

            

            <th class="last">描述</th>
        </tr>
        </thead>

        <tbody>
        

            
<tr class="deep-level-0">
  
      <td class="name"><code>styleLayerId</code></td>
  

  <td class="type">
  
      
<span class="param-type">
    
             String
    
</span>



  
  </td>

  

  <td class="description last"><p>样式图层id</p></td>
</tr>



        

            
<tr class="deep-level-0">
  
      <td class="name"><code>key</code></td>
  

  <td class="type">
  
      
<span class="param-type">
    
             String
    
</span>



  
  </td>

  

  <td class="description last"><p>额外属性的属性名</p></td>
</tr>



        

            
<tr class="deep-level-0">
  
      <td class="name"><code>value</code></td>
  

  <td class="type">
  
      
<span class="param-type">
    
             Any
    
</span>



  
  </td>

  

  <td class="description last"><p>额外属性的属性值</p></td>
</tr>



        
        </tbody>
    </table>
</div>






<dl class="details">

    

    

    
    <dt class="inherited-from">Inherited From:</dt>
    <dd class="inherited-from"><ul class="dummy"><li>
        <a goto="setExtendProperties" link="VectorTileLayer.html" onclick="getTypeHTML(event)" class="mapgis-link-name" title="VectorTileLayer#setExtendProperties" VectorTileLayer.html#setExtendProperties>VectorTileLayer#setExtendProperties</a>
    </li></ul></dd>
    

    

    

    

    

    

    

    

    

    
    

    

    

    
</dl>























</div>
            
                <div class="member">


    
    <h4 class="name" id="setLayoutProperties">
        <a class="href-link" href="#setLayoutProperties">#</a>
        
        <span class="code-name" id="setLayoutProperties" style="font-size:30px">
            
                setLayoutProperties<span class="signature">(styleLayerId, layout)</span>
            
        </span>
    </h4>
    

    
    <div class="description">
        <a id='setLayoutProperties'/>
设置样式图层布局属性
    </div>
    









    <h4>参数</h4>
    
<div class="table-container">
    <table class="params table">
        <thead>
        <tr>
            
            <th>名称</th>
            

            <th>类型</th>

            

            <th class="last">描述</th>
        </tr>
        </thead>

        <tbody>
        

            
<tr class="deep-level-0">
  
      <td class="name"><code>styleLayerId</code></td>
  

  <td class="type">
  
      
<span class="param-type">
    
             String
    
</span>



  
  </td>

  

  <td class="description last"><p>样式图层id</p></td>
</tr>



        

            
<tr class="deep-level-0">
  
      <td class="name"><code>layout</code></td>
  

  <td class="type">
  
      
<span class="param-type">
    
             Object
    
</span>



  
  </td>

  

  <td class="description last"><p>布局属性</p></td>
</tr>



        
        </tbody>
    </table>
</div>






<dl class="details">

    

    

    

    
    <dt class="tag-overrides">Overrides:</dt>
    <dd class="tag-overrides"><ul class="dummy"><li>
        <a class="mapgis-link-name" title="VectorTileLayer#setLayoutProperties" VectorTileLayer.html#setLayoutProperties>VectorTileLayer#setLayoutProperties</a>
    </li></ul></dd>
    

    

    

    

    

    

    

    

    
    

    

    

    
</dl>























</div>
            
                <div class="member">


    
    <h4 class="name" id="setPaintProperties">
        <a class="href-link" href="#setPaintProperties">#</a>
        
        <span class="code-name" id="setPaintProperties" style="font-size:30px">
            
                setPaintProperties<span class="signature">(styleLayerId, paint)</span>
            
        </span>
    </h4>
    

    
    <div class="description">
        <a id='setPaintProperties'/>
设置样式图层绘制属性
    </div>
    









    <h4>参数</h4>
    
<div class="table-container">
    <table class="params table">
        <thead>
        <tr>
            
            <th>名称</th>
            

            <th>类型</th>

            

            <th class="last">描述</th>
        </tr>
        </thead>

        <tbody>
        

            
<tr class="deep-level-0">
  
      <td class="name"><code>styleLayerId</code></td>
  

  <td class="type">
  
      
<span class="param-type">
    
             String
    
</span>



  
  </td>

  

  <td class="description last"><p>样式图层id</p></td>
</tr>



        

            
<tr class="deep-level-0">
  
      <td class="name"><code>paint</code></td>
  

  <td class="type">
  
      
<span class="param-type">
    
             Object
    
</span>



  
  </td>

  

  <td class="description last"><p>绘制属性</p></td>
</tr>



        
        </tbody>
    </table>
</div>






<dl class="details">

    

    

    

    
    <dt class="tag-overrides">Overrides:</dt>
    <dd class="tag-overrides"><ul class="dummy"><li>
        <a class="mapgis-link-name" title="VectorTileLayer#setPaintProperties" VectorTileLayer.html#setPaintProperties>VectorTileLayer#setPaintProperties</a>
    </li></ul></dd>
    

    

    

    

    

    

    

    

    
    

    

    

    
</dl>























</div>
            
                <div class="member">


    
    <h4 class="name" id="setStyleLayer">
        <a class="href-link" href="#setStyleLayer">#</a>
        
        <span class="code-name" id="setStyleLayer" style="font-size:30px">
            
                setStyleLayer<span class="signature">(styleLayer, index)</span>
            
        </span>
    </h4>
    

    
    <div class="description">
        <a id='setStyleLayer'/>
设置样式图层属性对象,可以对图层进行修改、重新排序等。布局属性和绘制属性推荐用setLayoutProperties和setPaintProperties实现。
    </div>
    









    <h4>参数</h4>
    
<div class="table-container">
    <table class="params table">
        <thead>
        <tr>
            
            <th>名称</th>
            

            <th>类型</th>

            

            <th class="last">描述</th>
        </tr>
        </thead>

        <tbody>
        

            
<tr class="deep-level-0">
  
      <td class="name"><code>styleLayer</code></td>
  

  <td class="type">
  
      
<span class="param-type">
    
             Object
    
</span>



  
  </td>

  

  <td class="description last"><p>样式图层对象</p></td>
</tr>



        

            
<tr class="deep-level-0">
  
      <td class="name"><code>index</code></td>
  

  <td class="type">
  
      
<span class="param-type">
    
             String
    
</span>



  
  </td>

  

  <td class="description last"><p>样式图层顺序</p></td>
</tr>



        
        </tbody>
    </table>
</div>






<dl class="details">

    

    

    
    <dt class="inherited-from">Inherited From:</dt>
    <dd class="inherited-from"><ul class="dummy"><li>
        <a goto="setStyleLayer" link="VectorTileLayer.html" onclick="getTypeHTML(event)" class="mapgis-link-name" title="VectorTileLayer#setStyleLayer" VectorTileLayer.html#setStyleLayer>VectorTileLayer#setStyleLayer</a>
    </li></ul></dd>
    

    

    

    

    

    

    

    

    

    
    

    

    

    
</dl>























</div>
            
                <div class="member">


    
    <h4 class="name" id="setStyleLayerVisibility">
        <a class="href-link" href="#setStyleLayerVisibility">#</a>
        
        <span class="code-name" id="setStyleLayerVisibility" style="font-size:30px">
            
                setStyleLayerVisibility<span class="signature">(styleLayerId, visible)</span>
            
        </span>
    </h4>
    

    
    <div class="description">
        <a id='setStyleLayerVisibility'/>
设置样式图层可见性,visible为true,显示图层,为false,隐藏图层
    </div>
    









    <h4>参数</h4>
    
<div class="table-container">
    <table class="params table">
        <thead>
        <tr>
            
            <th>名称</th>
            

            <th>类型</th>

            

            <th class="last">描述</th>
        </tr>
        </thead>

        <tbody>
        

            
<tr class="deep-level-0">
  
      <td class="name"><code>styleLayerId</code></td>
  

  <td class="type">
  
      
<span class="param-type">
    
             String
    
</span>



  
  </td>

  

  <td class="description last"><p>样式图层id</p></td>
</tr>



        

            
<tr class="deep-level-0">
  
      <td class="name"><code>visible</code></td>
  

  <td class="type">
  
      
<span class="param-type">
    
             Boolean
    
</span>



  
  </td>

  

  <td class="description last"><p>可见性</p></td>
</tr>



        
        </tbody>
    </table>
</div>






<dl class="details">

    

    

    
    <dt class="inherited-from">Inherited From:</dt>
    <dd class="inherited-from"><ul class="dummy"><li>
        <a goto="setStyleLayerVisibility" link="VectorTileLayer.html" onclick="getTypeHTML(event)" class="mapgis-link-name" title="VectorTileLayer#setStyleLayerVisibility" VectorTileLayer.html#setStyleLayerVisibility>VectorTileLayer#setStyleLayerVisibility</a>
    </li></ul></dd>
    

    

    

    

    

    

    

    

    

    
    

    

    

    
</dl>























</div>
            
                <div class="member">


    
    <h4 class="name" id="toJSON">
        <a class="href-link" href="#toJSON">#</a>
        
        <span class="code-name" id="toJSON" style="font-size:30px">
            
                toJSON<span class="signature">()</span>
            
        </span>
    </h4>
    

    
    <div class="description">
        <p>转换为json对象</p>
    </div>
    













<dl class="details">

    

    

    

    
    <dt class="tag-overrides">Overrides:</dt>
    <dd class="tag-overrides"><ul class="dummy"><li>
        <a class="mapgis-link-name" title="VectorTileLayer#toJSON" VectorTileLayer.html#toJSON>VectorTileLayer#toJSON</a>
    </li></ul></dd>
    

    

    

    

    

    

    

    

    
    

    

    

    
</dl>


















    <div class='columns method-parameter'>
        <div class="column is-2"><label>返回值</label></div>
        <div class="column is-10">
            
                    

<div class="columns">
    
    <div class='param-desc column is-7'><p>json对象</p></div>
    
    
    <div class='column is-5 has-text-left'>
        <label>类型: </label>
        
<span class="param-type">
    
             Object
    
</span>



    </div>
    
</div>

                
        </div>
    </div>






</div>
            
            </div>
        </div>
    

    

    
</article>

</section>