@itwin/core-backend
Version:
iTwin.js backend components
50 lines • 2.02 kB
TypeScript
/** @packageDocumentation
* @module Elements
*/
import { Id64String } from "@itwin/core-bentley";
import { ChannelControl, ChannelKey, ChannelUpgradeOptions } from "../ChannelControl";
import { IModelDb } from "../IModelDb";
import { EditTxn } from "../EditTxn";
import { _implementationProhibited, _verifyChannel } from "./Symbols";
declare class ChannelAdmin implements ChannelControl {
private _iModel;
static readonly channelClassName = "bis:ChannelRootAspect";
readonly [_implementationProhibited]: undefined;
private _allowedChannels;
private _allowedModels;
private _deniedModels;
constructor(_iModel: IModelDb);
addAllowedChannel(channelKey: ChannelKey): void;
removeAllowedChannel(channelKey: ChannelKey): void;
getChannelKey(elementId: Id64String): ChannelKey;
[_verifyChannel](modelId: Id64String): void;
makeChannelRoot(args: {
elementId: Id64String;
channelKey: ChannelKey;
txn: EditTxn;
}): void;
/** @deprecated in 5.9.0 - will not be removed until after 2027-05-04. Use makeChannelRoot and supply `txn`. */
makeChannelRoot(args: {
elementId: Id64String;
channelKey: ChannelKey;
}): void;
insertChannelSubject(args: {
subjectName: string;
channelKey: ChannelKey;
parentSubjectId?: Id64String;
description?: string;
txn: EditTxn;
}): Id64String;
/** @deprecated in 5.9.0 - will not be removed until after 2027-05-04. Use insertChannelSubject and supply `txn`. */
insertChannelSubject(args: {
subjectName: string;
channelKey: ChannelKey;
parentSubjectId?: Id64String;
description?: string;
}): Id64String;
queryChannelRoot(channelKey: ChannelKey): Id64String | undefined;
upgradeChannel(options: ChannelUpgradeOptions, iModel: IModelDb, data?: any): Promise<void>;
}
export declare function createChannelControl(iModel: IModelDb): ChannelAdmin;
export {};
//# sourceMappingURL=ChannelAdmin.d.ts.map