import type Collection from "../../core/Collection.js";
import type LayerView from "./LayerView.js";
import type { LayerViewProperties } from "./LayerView.js";

export interface GroupLayerViewProperties<TLayerView extends LayerView> extends LayerViewProperties, Partial<Pick<GroupLayerView<TLayerView>, "layerViews">> {}

/**
 * Represents the [LayerView](https://developers.arcgis.com/javascript/latest/api-reference/esri-views-layers-LayerView.html) of a [GroupLayer](https://developers.arcgis.com/javascript/latest/api-reference/esri-layers-GroupLayer.html)
 * after it has been added to a [Map](https://developers.arcgis.com/javascript/latest/api-reference/esri-Map.html) in either a [MapView](https://developers.arcgis.com/javascript/latest/api-reference/esri-views-MapView.html) or [SceneView](https://developers.arcgis.com/javascript/latest/api-reference/esri-views-SceneView.html).
 * The GroupLayerView provides access to a collection of [LayerView](https://developers.arcgis.com/javascript/latest/api-reference/esri-views-layers-LayerView.html)s.
 * Each layer view represents a layer in the [GroupLayer.layers](https://developers.arcgis.com/javascript/latest/api-reference/esri-layers-GroupLayer.html#layers) collection of the [GroupLayer](https://developers.arcgis.com/javascript/latest/api-reference/esri-layers-GroupLayer.html).
 *
 * @since 4.31
 * @see [GroupLayer](https://developers.arcgis.com/javascript/latest/api-reference/esri-layers-GroupLayer.html)
 */
export default abstract class GroupLayerView<TLayerView extends LayerView> extends LayerView {
  /**
   * A collection of layer views within the GroupLayerView.
   * Each layer view represents a layer in the [GroupLayer.layers](https://developers.arcgis.com/javascript/latest/api-reference/esri-layers-GroupLayer.html#layers) collection
   * of the [GroupLayer](https://developers.arcgis.com/javascript/latest/api-reference/esri-layers-GroupLayer.html).
   */
  accessor layerViews: Collection<TLayerView>;
}