index.js
function determineWMSAbstract(json, version) {
	var ret = '';

	if (version == '1.3.0') {
		if (json.WMS_Capabilities.Service) {
			if (json.WMS_Capabilities.Service[0]) {
				if (json.WMS_Capabilities.Service[0].Abstract) {
					if (json.WMS_Capabilities.Service[0].Abstract[0]) {
						ret = json.WMS_Capabilities.Service[0].Abstract[0];
					}
				}
			}
		}
	} else {
		if (version == '1.1.1' || version == '1.1.0' || version == '1.0.0') {
			if (json.WMT_MS_Capabilities.Service) {
				if (json.WMT_MS_Capabilities.Service[0]) {
					if (json.WMT_MS_Capabilities.Service[0].Abstract) {
						if (json.WMT_MS_Capabilities.Service[0].Abstract[0]) {
							ret = json.WMT_MS_Capabilities.Service[0].Abstract[0];
						}
					}
				}
			}
		}
	}

	return ret;
}
function determineWMSAbstract(json, version) {
	var ret = '';

	if (version == '1.3.0') {
		if (json.WMS_Capabilities.Service) {
			if (json.WMS_Capabilities.Service[0]) {
				if (json.WMS_Capabilities.Service[0].Abstract) {
					if (json.WMS_Capabilities.Service[0].Abstract[0]) {
						ret = json.WMS_Capabilities.Service[0].Abstract[0];
					}
				}
			}
		}
	} else {
		if (version == '1.1.1' || version == '1.1.0' || version == '1.0.0') {
			if (json.WMT_MS_Capabilities.Service) {
				if (json.WMT_MS_Capabilities.Service[0]) {
					if (json.WMT_MS_Capabilities.Service[0].Abstract) {
						if (json.WMT_MS_Capabilities.Service[0].Abstract[0]) {
							ret = json.WMT_MS_Capabilities.Service[0].Abstract[0];
						}
					}
				}
			}
		}
	}

	return ret;
}
function determineWMSAbstract ( json , version ) { var ret = '' ; if ( version == '1.3.0' ) { if ( json . WMS_Capabilities . Service ) { if ( json . WMS_Capabilities . Service [ 0 ] ) { if ( json . WMS_Capabilities . Service [ 0 ] . Abstract ) { if ( json . WMS_Capabilities . Service [ 0 ] . Abstract [ 0 ] ) { ret = json . WMS_Capabilities . Service [ 0 ] . Abstract [ 0 ] ; } } } } } else { if ( version == '1.1.1' || version == '1.1.0' || version == '1.0.0' ) { if ( json . WMT_MS_Capabilities . Service ) { if ( json . WMT_MS_Capabilities . Service [ 0 ] ) { if ( json . WMT_MS_Capabilities . Service [ 0 ] . Abstract ) { if ( json . WMT_MS_Capabilities . Service [ 0 ] . Abstract [ 0 ] ) { ret = json . WMT_MS_Capabilities . Service [ 0 ] . Abstract [ 0 ] ; } } } } } } return ret ; }
It determines the WMS abstract.

@param {object}
json GetCapabilities document as JSON.
@param {string}
version Version of GetCapabilities document.
@returns {string} WMS abstract.
It determines the WMS abstract .