import type { DataTypeRootType, EntityRootType, EntityTypeRootType, PropertyTypeRootType, Subgraph, SubgraphRootType } from "../../types/subgraph.js"; /** * Returns all root elements. * * For a narrower return type, first narrow the type of `subgraph` by using one of the helper type-guards: * - {@link isDataTypeRootedSubgraph} * - {@link isPropertyTypeRootedSubgraph} * - {@link isEntityTypeRootedSubgraph} * - {@link isEntityRootedSubgraph} * * @param subgraph */ export declare const getRoots: (subgraph: Subgraph) => RootType["element"][]; /** * A type-guard that can be used to constrain the generic parameter of `Subgraph` to `DataTypeWithMetadata`. * * Doing so will help TS infer that `getRoots` returns `DataTypeWithMetadata`s, removing the need for additional * type checks or casts. * * @param subgraph */ export declare const isDataTypeRootedSubgraph: (subgraph: Subgraph) => subgraph is Subgraph; /** * A type-guard that can be used to constrain the generic parameter of `Subgraph` to `PropertyTypeWithMetadata`. * * Doing so will help TS infer that `getRoots` returns `PropertyTypeWithMetadata`s, removing the need for additional * type checks or casts. * * @param subgraph */ export declare const isPropertyTypeRootedSubgraph: (subgraph: Subgraph) => subgraph is Subgraph; /** * A type-guard that can be used to constrain the generic parameter of `Subgraph` to `EntityTypeWithMetadata`. * * Doing so will help TS infer that `getRoots` returns `EntityTypeWithMetadata`s, removing the need for additional * type checks or casts. * * @param subgraph */ export declare const isEntityTypeRootedSubgraph: (subgraph: Subgraph) => subgraph is Subgraph; /** * A type-guard that can be used to constrain the generic parameter of `Subgraph` to `Entity`. * * Doing so will help TS infer that `getRoots` returns `Entity`s, removing the need for additional * type checks or casts. * * @param subgraph */ export declare const isEntityRootedSubgraph: (subgraph: Subgraph) => subgraph is Subgraph;