|
19 | 19 | from .tables import ProFeatureTable |
20 | 20 |
|
21 | 21 | # .NET Imports |
22 | | -from ArcGIS.Core.CIM import CIMFeatureLayer, CIMGroupLayer, CIMRasterLayer |
| 22 | +from ArcGIS.Core.CIM import CIMFeatureLayer, CIMGroupLayer, CIMRasterLayer, \ |
| 23 | + CIMMosaicLayer, CIMImageMosaicSubLayer,CIMFeatureMosaicSubLayer |
23 | 24 |
|
24 | 25 |
|
25 | 26 | class ProLayerBase(with_metaclass(ABCMeta, object)): |
@@ -110,3 +111,33 @@ def __init__(self, proj_zip, layer_string): |
110 | 111 |
|
111 | 112 | def _get_child_paths(self): |
112 | 113 | return [cp[8:] for cp in self._cim_obj.Layers] |
| 114 | + |
| 115 | + |
| 116 | +class ProMosaicLayer(ProLayerBase): |
| 117 | + def __init__(self, proj_zip, layer_string): |
| 118 | + try: |
| 119 | + super().__init__(proj_zip, CIMMosaicLayer.FromXml(layer_string)) |
| 120 | + except AttributeError: |
| 121 | + # probably JSON, attempt that |
| 122 | + super().__init__(proj_zip, CIMMosaicLayer.FromJson(layer_string)) |
| 123 | + |
| 124 | + def _get_child_paths(self): |
| 125 | + return [self._cim_obj.BoundaryLayer[8:], self._cim_obj.FootprintLayer[8:], self._cim_obj.ImageLayer[8:]] |
| 126 | + |
| 127 | + |
| 128 | +class ProFeatureMosaicSubLayer(ProLayerBase): |
| 129 | + def __init__(self, proj_zip, layer_string): |
| 130 | + try: |
| 131 | + super().__init__(proj_zip, CIMFeatureMosaicSubLayer.FromXml(layer_string)) |
| 132 | + except AttributeError: |
| 133 | + # probably JSON, attempt that |
| 134 | + super().__init__(proj_zip, CIMFeatureMosaicSubLayer.FromJson(layer_string)) |
| 135 | + |
| 136 | + |
| 137 | +class ProImageMosaicSubLayer(ProLayerBase): |
| 138 | + def __init__(self, proj_zip, layer_string): |
| 139 | + try: |
| 140 | + super().__init__(proj_zip, CIMImageMosaicSubLayer.FromXml(layer_string)) |
| 141 | + except AttributeError: |
| 142 | + # probably JSON, attempt that |
| 143 | + super().__init__(proj_zip, CIMImageMosaicSubLayer.FromJson(layer_string)) |
0 commit comments