import { ContainingTypes, } from '../relations/ContainingTypes'; import { ContainmentTypes, } from '../relations/ContainmentTypes'; import { FindOnticArgs, IFindBaseArgs, } from '../querying/FindModelArgs'; import { IAdjacencyRelation, } from '../relations/IAdjacencyRelation'; import { IContainmentRelation, } from '../relations/IContainmentRelation'; import { IModel, } from '../models/IModel'; import { ISerializedOntology, } from './ISerializedOntology'; import { ITag, } from '../../tags/ITag'; import { IWorld, } from '../world/IWorld'; import { ModelType, } from '../models/ModelType'; import { NoLocation, } from './NoLocation'; import { OnticTypes, } from './OnticTypes'; import { Tag, } from '../../tags/Tag'; export interface IOntology< Type extends OnticTypes, Being extends OnticTypes, > { readonly adjacency: IAdjacencyRelation; readonly containment: Type extends ContainmentTypes ? IContainmentRelation> : null; readonly modelType: Type; readonly tags: readonly ITag[]; readonly world: IWorld; readonly addTag: (tag: Tag) => void; readonly clone: (self: IOntology) => IOntology; readonly destroy: (self: IOntology) => void; readonly find: ( args: string | (IFindBaseArgs & FindOnticArgs), ) => IModel | null; readonly findAll: ( args: '*' | (IFindBaseArgs & FindOnticArgs), ) => readonly IModel[]; readonly findAllGenerator: ( args: '*' | (IFindBaseArgs & FindOnticArgs), ) => IterableIterator>; readonly getTag: (toSearch: Tag) => ITag | null; readonly removeTag: (tag: Tag) => void; readonly serialize: ( self: IOntology, spaces?: number, ) => string; readonly serializeToObject: ( self: IOntology, ) => ISerializedOntology; readonly finalize?: (self: IOntology) => void; readonly initialize?: (self: IOntology) => void; }