/
(ES) checkValidFeatureCollection()

(ES) checkValidFeatureCollection()

Información

Versión de implementación: beta 1.07

Descripción

Comprueba si el objeto con la colección de entidades para puntos, líneas, polígonos y mapas de calor es correcta.

Invocación

checkValidFeatureCollection(
	data
)

Parámetros de entrada

data

Parámetro con el objecto de colección de entidades.

Ejemplos de uso

Comprobar la validez de una variable con JSON llamado "datosEspaciales":

checkValidFeatureCollection(
	datosEspaciales
)

Comprobar la validez de un objecto JSON:

checkValidFeatureCollection(
	{
	type: 'FeatureCollection',
	name: 'points single',
	features: [
		{
			type: 'Feature',
			properties: {
				billboardDefault: 'img/icon_cctv_gray.svg',
				billboardSelected: 'img/icon_cctv_color.svg',
				billboardScale: 0.8,
				buildingName: 'Library',
				deviceTypeId: 'Salto',
				deviceTypeName: 'Door',
				floor: 0,
				id: 'CAET_005',
				name: 'CAET_005',
				weight: 1
			},
			geometry: {
				type: 'Point',
				coordinates: [-15.4351, 28.1195]
			}
		},
		{
			type: 'Feature',
			properties: {
				billboardDefault: 'img/icon_cctv_gray.svg',
				billboardSelected: 'img/icon_cctv_color.svg',
				billboardScale: 0.8,
				buildingName: 'Park',
				deviceTypeId: 'Salto',
				deviceTypeName: 'Door',
				floor: 1,
				id: 'CAET_001',
				name: 'CAET_001',
				weight: 5
			},
			geometry: {
				type: 'Point',
				coordinates: [-15.3767, 28.4755]
			}
		},
		{
			type: 'Feature',
			properties: {
				billboardDefault: 'img/icon_cctv_gray.svg',
				billboardSelected: 'img/icon_cctv_color.svg',
				billboardScale: 0.6,
				weight: 1
			},
			geometry: {
				type: 'Point',
				coordinates: [-15.3767, 28.4747]
			}
		},
		{
			type: 'Feature',
			properties: {
				billboardDefault: 'img/icon_cctv_gray.svg',
				billboardSelected: 'img/icon_cctv_color.svg',
				billboardScale: 0.8,
				buildingName: 'Supermarket',
				deviceTypeId: 'Jump',
				deviceTypeName: 'Camera',
				floor: 2,
				id: 'CAET_011',
				name: 'CAET_011',
				weight: 10
			},
			geometry: {
				type: 'Point',
				coordinates: [-15.3770, 28.4755]
			}
		}
	]
	}
)

Related content

checkValidFeatureCollection()
checkValidFeatureCollection()
More like this
(ES) createLayer()
(ES) createLayer()
More like this
Soporte de valores por defecto
Soporte de valores por defecto
More like this
Soporte Valores Enumerados en Entidades
Soporte Valores Enumerados en Entidades
More like this
(ES) findDataSourceByLayerName()
(ES) findDataSourceByLayerName()
More like this
(ES) updateLayer()
(ES) updateLayer()
More like this