import { Collection, OmitVertexProperties, PickVertexProperties, Vertex } from "./vertex.js"; import { EdgeMultiplicity, EdgeWrapper } from "./edges.js"; import { Tail } from "./util.js"; //#region src/core/interfaces/vertices/util/common.d.ts type IsAny = 0 extends (1 & T) ? true : false; /** * Picks all properties of a vertex that are edges to other vertices. (we ignore explicit any types) */ type PickEdges> = { [K in keyof V as NonNullable extends EdgeWrapper ? IsAny extends true ? never : K : never]: V[K] }; /** * Omits all properties of a vertex that are edges to other vertices. */ type OmitEdges> = PickVertexProperties & OmitVertexProperties<{ [K in keyof V as NonNullable extends EdgeWrapper ? never : K]: V[K] }>; declare const SELECT_KEY = "select"; type SelectKey = typeof SELECT_KEY; declare const EXPAND_KEY = "expand"; type ExpandKey = typeof EXPAND_KEY; type InvalidEdgeMessage = 'INVALID VERTEX EDGE'; type RemoveNeverValues = { [K in keyof T as T[K] extends never ? never : K]: T[K] }; type DepthDecrementMap = [never, 0, 1, 2, 3]; type SupportedDepths = DepthDecrementMap[number]; type MaxDepth = Tail; type MinDepth = Extract; type Decrement = DepthDecrementMap[T]; //#endregion export { Decrement, EXPAND_KEY, ExpandKey, InvalidEdgeMessage, MaxDepth, MinDepth, OmitEdges, PickEdges, RemoveNeverValues, SELECT_KEY, SelectKey, SupportedDepths }; //# sourceMappingURL=common.d.ts.map