import type CircuitLocation from "../../../../networks/support/CircuitLocation.js";
import type { JSONSupport, JSONSupportMixinProperties } from "../../../../core/JSONSupport.js";
import type { CircuitLocationProperties } from "../../../../networks/support/CircuitLocation.js";

export interface QueryCircuitsParametersProperties extends JSONSupportMixinProperties, Partial<Pick<QueryCircuitsParameters, "locationType" | "returnConsumerCircuits">> {
  /** The start or stop location of the circuit to query. */
  location?: CircuitLocationProperties | null;
}

export default abstract class QueryCircuitsParameters extends JSONSupport {
  /** The start or stop location of the circuit to query. */
  get location(): CircuitLocation | null | undefined;
  set location(value: CircuitLocationProperties | null | undefined);
  /** The type of location to query circuits by. */
  accessor locationType: "start" | "stop" | "all" | null | undefined;
  /**
   * If false, returns only the immediate circuits passing through
   *   the specified location. Otherwise, returns all the circuits that consume the immediate circuits.
   *
   * @default false
   */
  accessor returnConsumerCircuits: boolean;
}