import type Graphic from "../../Graphic.js";
import type PopupTemplate from "../../PopupTemplate.js";
import type Point from "../../geometry/Point.js";
import type { ClonableMixin } from "../../core/Clonable.js";
import type { JSONSupport } from "../../core/JSONSupport.js";
import type { BarrierType, CurbApproach, FullEdge } from "./types.js";
import type { PointProperties } from "../../geometry/Point.js";
import type { PopupTemplateProperties } from "../../PopupTemplate.js";

export interface PointBarrierProperties extends Partial<Pick<PointBarrier, "barrierType" | "fullEdge" | "name">> {
  /** The point location of the barrier. */
  geometry?: PointProperties | null;
  /**
   * The template for displaying content in a [Popup](https://developers.arcgis.com/javascript/latest/references/core/widgets/Popup/) when the graphic is selected.
   *
   * @since 4.30
   */
  popupTemplate?: PopupTemplateProperties | null;
}

/**
 * A point barrier to restrict travel along a street network when using a [RouteLayer](https://developers.arcgis.com/javascript/latest/references/core/layers/RouteLayer/).
 *
 * @since 4.23
 * @see [RouteParameters](https://developers.arcgis.com/javascript/latest/references/core/rest/support/RouteParameters/)
 * @see [RouteLayer](https://developers.arcgis.com/javascript/latest/references/core/layers/RouteLayer/)
 */
export default class PointBarrier extends PointBarrierSuperclass {
  /**
   * Creates a [PointBarrier](https://developers.arcgis.com/javascript/latest/references/core/rest/support/PointBarrier/) from the parsed [Graphic](https://developers.arcgis.com/javascript/latest/references/core/Graphic/).
   * The method assumes that the graphic's attributes conform to the route layer item schema.
   *
   * @param graphic - A Graphic instance.
   * @returns A PointBarrier instance.
   * @since 4.24
   */
  static fromGraphic(graphic: Graphic): PointBarrier;
  constructor(properties?: PointBarrierProperties);
  /**
   * Specify if the point barrier restricts travel completely or adds time or distance when it is crossed.
   *
   * @see [BarrierType](https://developers.arcgis.com/rest/services-reference/enterprise/route-sync-services.htm#GUID-68ECCC15-6396-49AA-B942-82C4CC37021D)
   */
  accessor barrierType: BarrierType | null | undefined;
  /**
   * The direction of traffic that is affected by the barrier.
   *
   * @see [CurbApproach](https://developers.arcgis.com/rest/services-reference/enterprise/route-sync-services.htm#GUID-4C3C03FD-325D-408A-87C1-759CFF0C0AD0)
   */
  get curbApproach(): CurbApproach | null | undefined;
  /**
   * Point barriers are applied to the edge elements during the analysis.
   * A value of "permit" means that travel is permitted on the edge up to the barrier, but not through it.
   * A value of "restrict" means that travel is restricted anywhere on the associated edge.
   */
  accessor fullEdge: FullEdge | null | undefined;
  /** The point location of the barrier. */
  get geometry(): Point | null | undefined;
  set geometry(value: PointProperties | null | undefined);
  /** The name of the barrier. */
  accessor name: string | null | undefined;
  /**
   * The template for displaying content in a [Popup](https://developers.arcgis.com/javascript/latest/references/core/widgets/Popup/) when the graphic is selected.
   *
   * @since 4.30
   */
  get popupTemplate(): PopupTemplate | null | undefined;
  set popupTemplate(value: PopupTemplateProperties | null | undefined);
  get type(): "point-barrier";
  /**
   * Creates a [Graphic](https://developers.arcgis.com/javascript/latest/references/core/Graphic/) from the [PointBarrier](https://developers.arcgis.com/javascript/latest/references/core/rest/support/PointBarrier/) instance.
   * The resulting graphic will have attributes that conform to the route layer item schema.
   *
   * @returns A Graphic instance.
   * @since 4.24
   */
  toGraphic(): Graphic;
}
declare const PointBarrierSuperclass: typeof JSONSupport & typeof ClonableMixin