""" Module for ArcGis API utilities. It is implemented in a protocol way. """ from tools.protocols.tms import TMS from tools import const class AGS(TMS): """ Class inherited from TMS protocol, actually the behaviour is identical. Attributes ---------- CONNECTION_REQUIRED: dict Mapping of required connection parameters. Only is important when GMS is used with Itasker. NAME: str Protocol identifier string. Parameters ---------- ip: str Url of service """ CONNECTION_REQUIRED = {'fileType': 'driver_type', 'ip': 'ip', 'source': 'source', 'port': 'port', 'domain': 'domain', 'user': 'user', 'password': 'password', 'subtype': 'type', 'layerName': 'layer_name'} NAME = const.AGS_KEY def __init__(self, ip, port, user, password, *_, **__): super().__init__(ip, port, user, password, *_, **__) self.gdal_wms_conf = "" \ "" \ " {url}" \ " xyXY" \ " 3857" \ "" \ "" \ " -20037508.34" \ " 20037508.34" \ " 20037508.34" \ " -20037508.34" \ " 256" \ " 256" \ "" \ "{credentials}" \ "204,404,500" \ "true" \ ""