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,CAAC,KAAK,EAAE,CAAC;aACjF,iBAAiB,CAAC,UAAU,EAAE,aAAa,CAAC;aAC5C,WAAW,CAAC,8BAAO,CAAC,QAAQ,CAAC;aAC7B,iBAAiB,CAAC,IAAI,CAAC,aAAa,CAAC,CAAC;IAC3C,CAAC;CACF;AAhCD,kCAgCC","sourcesContent":["// Copyright (c) Microsoft Corporation. All rights reserved. Licensed under the MIT license.\n// See LICENSE in the project root for license information.\n\nimport {\n DeclarationReference,\n Meaning,\n Navigation,\n type Component\n} from '@microsoft/tsdoc/lib-commonjs/beta/DeclarationReference';\n\nimport { ApiItemKind } from '../items/ApiItem';\nimport { type IApiDeclaredItemOptions, ApiDeclaredItem } from '../items/ApiDeclaredItem';\nimport { type IApiParameterListMixinOptions, ApiParameterListMixin } from '../mixins/ApiParameterListMixin';\nimport { type IApiReleaseTagMixinOptions, ApiReleaseTagMixin } from '../mixins/ApiReleaseTagMixin';\nimport { type IApiReturnTypeMixinOptions, ApiReturnTypeMixin } from '../mixins/ApiReturnTypeMixin';\nimport { type IApiNameMixinOptions, ApiNameMixin } from '../mixins/ApiNameMixin';\nimport {\n type IApiTypeParameterListMixinOptions,\n ApiTypeParameterListMixin\n} from '../mixins/ApiTypeParameterListMixin';\nimport { type IApiExportedMixinOptions, ApiExportedMixin } from '../mixins/ApiExportedMixin';\n\n/**\n * Constructor options for {@link ApiFunction}.\n * @public\n */\nexport interface IApiFunctionOptions\n extends IApiNameMixinOptions,\n IApiTypeParameterListMixinOptions,\n IApiParameterListMixinOptions,\n IApiReleaseTagMixinOptions,\n IApiReturnTypeMixinOptions,\n IApiDeclaredItemOptions,\n IApiExportedMixinOptions {}\n\n/**\n * Represents a TypeScript function declaration.\n *\n * @remarks\n *\n * This is part of the {@link ApiModel} hierarchy of classes, which are serializable representations of\n * API declarations.\n *\n * `ApiFunction` represents a TypeScript declaration such as this example:\n *\n * ```ts\n * export function getAverage(x: number, y: number): number {\n * return (x + y) / 2.0;\n * }\n * ```\n *\n * Functions are exported by an entry point module or by a namespace. Compare with {@link ApiMethod}, which\n * represents a function that is a member of a class.\n *\n * @public\n */\nexport class ApiFunction extends ApiNameMixin(\n ApiTypeParameterListMixin(\n ApiParameterListMixin(ApiReleaseTagMixin(ApiReturnTypeMixin(ApiExportedMixin(ApiDeclaredItem))))\n )\n) {\n public constructor(options: IApiFunctionOptions) {\n super(options);\n }\n\n public static getContainerKey(name: string, overloadIndex: number): string {\n return `${name}|${ApiItemKind.Function}|${overloadIndex}`;\n }\n\n /** @override */\n public get kind(): ApiItemKind {\n return ApiItemKind.Function;\n }\n\n /** @override */\n public get containerKey(): string {\n return ApiFunction.getContainerKey(this.name, this.overloadIndex);\n }\n\n /** @beta @override */\n public buildCanonicalReference(): DeclarationReference {\n const nameComponent: Component = DeclarationReference.parseComponent(this.name);\n const navigation: Navigation = this.isExported ? Navigation.Exports : Navigation.Locals;\n return (this.parent ? this.parent.canonicalReference : DeclarationReference.empty())\n .addNavigationStep(navigation, nameComponent)\n .withMeaning(Meaning.Function)\n .withOverloadIndex(this.overloadIndex);\n }\n}\n"]}
{"version":3,"file":"ApiIndexSignature.js","sourceRoot":"","sources":["../../src/model/ApiIndexSignature.ts"],"names":[],"mappings":";AAAA,4FAA4F;AAC5F,2DAA2D;;;AAE3D,kGAIiE;AAEjE,8CAA+C;AAC/C,8DAAyF;AACzF,2EAA4G;AAC5G,qEAAmG;AACnG,qEAAmG;AACnG,iEAA6F;AAa7F;;;;;;;;;;;;;;;;;;;;;GAqBG;AACH,MAAa,iBAAkB,SAAQ,IAAA,6CAAqB,EAC1D,IAAA,uCAAkB,EAAC,IAAA,uCAAkB,EAAC,IAAA,mCAAgB,EAAC,iCAAe,CAAC,CAAC,CAAC,CAC1E;IACC,YAAmB,OAAkC;QACnD,KAAK,CAAC,OAAO,CAAC,CAAC;IACjB,CAAC;IAEM,MAAM,CAAC,eAAe,CAAC,aAAqB;QACjD,OAAO,IAAI,qBAAW,CAAC,cAAc,IAAI,aAAa,EAAE,CAAC;IAC3D,CAAC;IAED,gBAAgB;IAChB,IAAW,IAAI;QACb,OAAO,qBAAW,CAAC,cAAc,CAAC;IACpC,CAAC;IAED,gBAAgB;IAChB,IAAW,YAAY;QACrB,OAAO,iBAAiB,CAAC,eAAe,CAAC,IAAI,CAAC,aAAa,CAAC,CAAC;IAC/D,CAAC;IAED,sBAAsB;IACf,uBAAuB;QAC5B,MAAM,MAAM,GAAyB,IAAI,CAAC,MAAM;YAC9C,CAAC,CAAC,IAAI,CAAC,MAAM,CAAC,kBAAkB;YAChC,CAAC,CAAC,iDAAiD;gBACjD,2CAAoB,CAAC,KAAK,EAAE,CAAC,iBAAiB,CAAC,iCAAU,CAAC,OAAO,EAAE,UAAU,CAAC,CAAC;QACnF,OAAO,MAAM,CAAC,WAAW,CAAC,8BAAO,CAAC,cAAc,CAAC,CAAC,iBAAiB,CAAC,IAAI,CAAC,aAAa,CAAC,CAAC;IAC1F,CAAC;CACF;AA7BD,8CA6BC","sourcesContent":["// Copyright (c) Microsoft Corporation. All rights reserved. Licensed under the MIT license.\n// See LICENSE in the project root for license information.\n\nimport {\n DeclarationReference,\n Meaning,\n Navigation\n} from '@microsoft/tsdoc/lib-commonjs/beta/DeclarationReference';\n\nimport { ApiItemKind } from '../items/ApiItem';\nimport { type IApiDeclaredItemOptions, ApiDeclaredItem } from '../items/ApiDeclaredItem';\nimport { type IApiParameterListMixinOptions, ApiParameterListMixin } from '../mixins/ApiParameterListMixin';\nimport { type IApiReleaseTagMixinOptions, ApiReleaseTagMixin } from '../mixins/ApiReleaseTagMixin';\nimport { type IApiReturnTypeMixinOptions, ApiReturnTypeMixin } from '../mixins/ApiReturnTypeMixin';\nimport { type IApiReadonlyMixinOptions, ApiReadonlyMixin } from '../mixins/ApiReadonlyMixin';\n\n/**\n * Constructor options for {@link ApiIndexSignature}.\n * @public\n */\nexport interface IApiIndexSignatureOptions\n extends IApiParameterListMixinOptions,\n IApiReleaseTagMixinOptions,\n IApiReturnTypeMixinOptions,\n IApiReadonlyMixinOptions,\n IApiDeclaredItemOptions {}\n\n/**\n * Represents a TypeScript index signature.\n *\n * @remarks\n *\n * This is part of the {@link ApiModel} hierarchy of classes, which are serializable representations of\n * API declarations.\n *\n * `ApiIndexSignature` represents a TypeScript declaration such as `[x: number]: number` in this example:\n *\n * ```ts\n * export interface INumberTable {\n * // An index signature\n * [value: number]: number;\n *\n * // An overloaded index signature\n * [name: string]: number;\n * }\n * ```\n *\n * @public\n */\nexport class ApiIndexSignature extends ApiParameterListMixin(\n ApiReleaseTagMixin(ApiReturnTypeMixin(ApiReadonlyMixin(ApiDeclaredItem)))\n) {\n public constructor(options: IApiIndexSignatureOptions) {\n super(options);\n }\n\n public static getContainerKey(overloadIndex: number): string {\n return `|${ApiItemKind.IndexSignature}|${overloadIndex}`;\n }\n\n /** @override */\n public get kind(): ApiItemKind {\n return ApiItemKind.IndexSignature;\n }\n\n /** @override */\n public get containerKey(): string {\n return ApiIndexSignature.getContainerKey(this.overloadIndex);\n }\n\n /** @beta @override */\n public buildCanonicalReference(): DeclarationReference {\n const parent: DeclarationReference = this.parent\n ? this.parent.canonicalReference\n : // .withMeaning() requires some kind of component\n DeclarationReference.empty().addNavigationStep(Navigation.Members, '(parent)');\n return parent.withMeaning(Meaning.IndexSignature).withOverloadIndex(this.overloadIndex);\n }\n}\n"]}
{"version":3,"file":"ApiInterface.js","sourceRoot":"","sources":["../../src/model/ApiInterface.ts"],"names":[],"mappings":";AAAA,4FAA4F;AAC5F,2DAA2D;;;AAE3D,kGAKiE;AAEjE,8CAA+C;AAC/C,2EAIyC;AACzC,8DAIkC;AAClC,qEAIsC;AAEtC,iDAA8C;AAC9C,yDAAyG;AACzG,mFAI6C;AAE7C,iEAIoC;AA0BpC;;;;;;;;;;;;;;;;GAgBG;AACH,MAAa,YAAa,SAAQ,IAAA,6CAAqB,EACrD,IAAA,2BAAY,EAAC,IAAA,qDAAyB,EAAC,IAAA,uCAAkB,EAAC,IAAA,mCAAgB,EAAC,iCAAe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CAAoB,CAAC,cAAc,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC;QAChF,MAAM,UAAU,GAAe,IAAI,CAAC,UAAU,CAAC,CAAC,CAAC,iCAAU,CAAC,OAAO,CAAC,CAAC,CAAC,iCAAU,CAAC,MAAM,CAAC;QACxF,OAAO,CAAC,IAAI,CAAC,MAAM,CAAC,CAAC,CAAC,IAAI,CAAC,MAAM,CAAC,kBAAkB,CAAC,CAAC,CAAC,2CAAoB,CAAC,KAAK,EAAE,CAAC;aACjF,iBAAiB,CAAC,UAAU,EAAE,aAAa,CAAC;aAC5C,WAAW,CAAC,8BAAO,CAAC,SAAS,CAAC,CAAC;IACpC,CAAC;CACF;AA5DD,oCA4DC","sourcesContent":["// Copyright (c) Microsoft Corporation. All rights reserved. Licensed under the MIT license.\n// See LICENSE in the project root for license information.\n\nimport {\n DeclarationReference,\n Meaning,\n Navigation,\n type Component\n} from '@microsoft/tsdoc/lib-commonjs/beta/DeclarationReference';\n\nimport { ApiItemKind } from '../items/ApiItem';\nimport {\n ApiItemContainerMixin,\n type IApiItemContainerMixinOptions,\n type IApiItemContainerJson\n} from '../mixins/ApiItemContainerMixin';\nimport {\n ApiDeclaredItem,\n type IApiDeclaredItemOptions,\n type IApiDeclaredItemJson\n} from '../items/ApiDeclaredItem';\nimport {\n type IApiReleaseTagMixinOptions,\n ApiReleaseTagMixin,\n type IApiReleaseTagMixinJson\n} from '../mixins/ApiReleaseTagMixin';\nimport type { IExcerptTokenRange } from '../mixins/Excerpt';\nimport { HeritageType } from './HeritageType';\nimport { type IApiNameMixinOptions, ApiNameMixin, type IApiNameMixinJson } from '../mixins/ApiNameMixin';\nimport {\n type IApiTypeParameterListMixinOptions,\n type IApiTypeParameterListMixinJson,\n ApiTypeParameterListMixin\n} from '../mixins/ApiTypeParameterListMixin';\nimport type { DeserializerContext } from './DeserializerContext';\nimport {\n type IApiExportedMixinJson,\n type IApiExportedMixinOptions,\n ApiExportedMixin\n} from '../mixins/ApiExportedMixin';\n\n/**\n * Constructor options for {@link ApiInterface}.\n * @public\n */\nexport interface IApiInterfaceOptions\n extends IApiItemContainerMixinOptions,\n IApiNameMixinOptions,\n IApiTypeParameterListMixinOptions,\n IApiReleaseTagMixinOptions,\n IApiDeclaredItemOptions,\n IApiExportedMixinOptions {\n extendsTokenRanges: IExcerptTokenRange[];\n}\n\nexport interface IApiInterfaceJson\n extends IApiItemContainerJson,\n IApiNameMixinJson,\n IApiTypeParameterListMixinJson,\n IApiReleaseTagMixinJson,\n IApiDeclaredItemJson,\n IApiExportedMixinJson {\n extendsTokenRanges: IExcerptTokenRange[];\n}\n\n/**\n * Represents a TypeScript class declaration.\n *\n * @remarks\n *\n * This is part of the {@link ApiModel} hierarchy of classes, which are serializable representations of\n * API declarations.\n *\n * `ApiInterface` represents a TypeScript declaration such as this:\n *\n * ```ts\n * export interface X extends Y {\n * }\n * ```\n *\n * @public\n */\nexport class ApiInterface extends ApiItemContainerMixin(\n ApiNameMixin(ApiTypeParameterListMixin(ApiReleaseTagMixin(ApiExportedMixin(ApiDeclaredItem))))\n) {\n private readonly _extendsTypes: HeritageType[] = [];\n\n public constructor(options: IApiInterfaceOptions) {\n super(options);\n\n for (const extendsTokenRange of options.extendsTokenRanges) {\n this._extendsTypes.push(new HeritageType(this.buildExcerpt(extendsTokenRange)));\n }\n }\n\n public static getContainerKey(name: string): string {\n return `${name}|${ApiItemKind.Interface}`;\n }\n\n /** @override */\n public static onDeserializeInto(\n options: Partial<IApiInterfaceOptions>,\n context: DeserializerContext,\n jsonObject: IApiInterfaceJson\n ): void {\n super.onDeserializeInto(options, context, jsonObject);\n\n options.extendsTokenRanges = jsonObject.extendsTokenRanges;\n }\n\n /** @override */\n public get kind(): ApiItemKind {\n return ApiItemKind.Interface;\n }\n\n /** @override */\n public get containerKey(): string {\n return ApiInterface.getContainerKey(this.name);\n }\n\n /**\n * The list of base interfaces that this interface inherits from using the `extends` keyword.\n */\n public get extendsTypes(): ReadonlyArray<HeritageType> {\n return this._extendsTypes;\n }\n\n /** @override */\n public serializeInto(jsonObject: Partial<IApiInterfaceJson>): void {\n super.serializeInto(jsonObject);\n\n jsonObject.extendsTokenRanges = this.extendsTypes.map((x) => x.excerpt.tokenRange);\n }\n\n /** @beta @override */\n public buildCanonicalReference(): DeclarationReference {\n const nameComponent: Component = DeclarationReference.parseComponent(this.name);\n const navigation: Navigation = this.isExported ? Navigation.Exports : Navigation.Locals;\n return (this.parent ? this.parent.canonicalReference : DeclarationReference.empty())\n .addNavigationStep(navigation, nameComponent)\n .withMeaning(Meaning.Interface);\n }\n}\n"]}
{"version":3,"file":"ApiMethod.js","sourceRoot":"","sources":["../../src/model/ApiMethod.ts"],"names":[],"mappings":";AAAA,4FAA4F;AAC5F,2DAA2D;;;AAE3D,kGAKiE;AAEjE,8CAA+C;AAC/C,mEAAgG;AAChG,6DAAuF;AACvF,8DAAyF;AACzF,2EAA4G;AAC5G,qEAAmG;AACnG,qEAAmG;AACnG,yDAAiF;AACjF,iEAA6F;AAC7F,mFAG6C;AAC7C,iEAA6F;AAkB7F;;;;;;;;;;;;;;;;;;;;GAoBG;AACH,MAAa,SAAU,SAAQ,IAAA,2BAAY,EACzC,IAAA,mCAAgB,EACd,IAAA,mCAAgB,EACd,IAAA,6CAAqB,EACnB,IAAA,qCAAiB,EACf,IAAA,uCAAkB,EAAC,IAAA,uCAAkB,EAAC,IAAA,+BAAc,EAAC,IAAA,qDAAyB,EAAC,iCAAe,CAAC,CAAC,CAAC,CAAC,CACnG,CACF,CACF,CACF,CACF;IACC,YAAmB,OAA0B;QAC3C,KAAK,CAAC,OAAO,CAAC,CAAC;IACjB,CAAC;IAEM,MAAM,CAAC,eAAe,CAAC,IAAY,EAAE,QAAiB,EAAE,aAAqB;QAClF,IAAI,QAAQ,EAAE,CAAC;YACb,OAAO,GAAG,IAAI,IAAI,qBAAW,CAAC,MAAM,WAAW,aAAa,EAAE,CAAC;QACjE,CAAC;aAAM,CAAC;YACN,OAAO,GAAG,IAAI,IAAI,qBAAW,CAAC,MAAM,aAAa,aAAa,EAAE,CAAC;QACnE,CAAC;IACH,CAAC;IAED,gBAAgB;IAChB,IAAW,IAAI;QACb,OAAO,qBAAW,CAAC,MAAM,CAAC;IAC5B,CAAC;IAED,gBAAgB;IAChB,IAAW,YAAY;QACrB,OAAO,SAAS,CAAC,eAAe,CAAC,IAAI,CAAC,IAAI,EAAE,IAAI,CAAC,QAAQ,EAAE,IAAI,CAAC,aAAa,CAAC,CAAC;IACjF,CAAC;IAED,sBAAsB;IACf,uBAAuB;QAC5B,MAAM,aAAa,GAAc,2CAAoB,CAAC,cAAc,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC;QAChF,OAAO,CAAC,IAAI,CAAC,MAAM,CAAC,CAAC,CAAC,IAAI,CAAC,MAAM,CAAC,kBAAkB,CAAC,CAAC,CAAC,2CAAoB,CAAC,KAAK,EAAE,CAAC;aACjF,iBAAiB,CAAC,IAAI,CAAC,QAAQ,CAAC,CAAC,CAAC,iCAAU,CAAC,OAAO,CAAC,CAAC,CAAC,iCAAU,CAAC,OAAO,EAAE,aAAa,CAAC;aACzF,WAAW,CAAC,8BAAO,CAAC,MAAM,CAAC;aAC3B,iBAAiB,CAAC,IAAI,CAAC,aAAa,CAAC,CAAC;IAC3C,CAAC;CACF;AAzCD,8BAyCC","sourcesContent":["// Copyright (c) Microsoft Corporation. All rights reserved. Licensed under the MIT license.\n// See LICENSE in the project root for license information.\n\nimport {\n DeclarationReference,\n Meaning,\n Navigation,\n type Component\n} from '@microsoft/tsdoc/lib-commonjs/beta/DeclarationReference';\n\nimport { ApiItemKind } from '../items/ApiItem';\nimport { ApiProtectedMixin, type IApiProtectedMixinOptions } from '../mixins/ApiProtectedMixin';\nimport { ApiStaticMixin, type IApiStaticMixinOptions } from '../mixins/ApiStaticMixin';\nimport { type IApiDeclaredItemOptions, ApiDeclaredItem } from '../items/ApiDeclaredItem';\nimport { type IApiParameterListMixinOptions, ApiParameterListMixin } from '../mixins/ApiParameterListMixin';\nimport { type IApiReleaseTagMixinOptions, ApiReleaseTagMixin } from '../mixins/ApiReleaseTagMixin';\nimport { ApiReturnTypeMixin, type IApiReturnTypeMixinOptions } from '../mixins/ApiReturnTypeMixin';\nimport { type IApiNameMixinOptions, ApiNameMixin } from '../mixins/ApiNameMixin';\nimport { type IApiAbstractMixinOptions, ApiAbstractMixin } from '../mixins/ApiAbstractMixin';\nimport {\n ApiTypeParameterListMixin,\n type IApiTypeParameterListMixinOptions\n} from '../mixins/ApiTypeParameterListMixin';\nimport { ApiOptionalMixin, type IApiOptionalMixinOptions } from '../mixins/ApiOptionalMixin';\n\n/**\n * Constructor options for {@link ApiMethod}.\n * @public\n */\nexport interface IApiMethodOptions\n extends IApiNameMixinOptions,\n IApiAbstractMixinOptions,\n IApiOptionalMixinOptions,\n IApiParameterListMixinOptions,\n IApiProtectedMixinOptions,\n IApiReleaseTagMixinOptions,\n IApiReturnTypeMixinOptions,\n IApiStaticMixinOptions,\n IApiTypeParameterListMixinOptions,\n IApiDeclaredItemOptions {}\n\n/**\n * Represents a TypeScript member function declaration that belongs to an `ApiClass`.\n *\n * @remarks\n *\n * This is part of the {@link ApiModel} hierarchy of classes, which are serializable representations of\n * API declarations.\n *\n * `ApiMethod` represents a TypeScript declaration such as the `render` member function in this example:\n *\n * ```ts\n * export class Widget {\n * public render(): void { }\n * }\n * ```\n *\n * Compare with {@link ApiMethodSignature}, which represents a method belonging to an interface.\n * For example, a class method can be `static` but an interface method cannot.\n *\n * @public\n */\nexport class ApiMethod extends ApiNameMixin(\n ApiAbstractMixin(\n ApiOptionalMixin(\n ApiParameterListMixin(\n ApiProtectedMixin(\n ApiReleaseTagMixin(ApiReturnTypeMixin(ApiStaticMixin(ApiTypeParameterListMixin(ApiDeclaredItem))))\n )\n )\n )\n )\n) {\n public constructor(options: IApiMethodOptions) {\n super(options);\n }\n\n public static getContainerKey(name: string, isStatic: boolean, overloadIndex: number): string {\n if (isStatic) {\n return `${name}|${ApiItemKind.Method}|static|${overloadIndex}`;\n } else {\n return `${name}|${ApiItemKind.Method}|instance|${overloadIndex}`;\n }\n }\n\n /** @override */\n public get kind(): ApiItemKind {\n return ApiItemKind.Method;\n }\n\n /** @override */\n public get containerKey(): string {\n return ApiMethod.getContainerKey(this.name, this.isStatic, this.overloadIndex);\n }\n\n /** @beta @override */\n public buildCanonicalReference(): DeclarationReference {\n const nameComponent: Component = DeclarationReference.parseComponent(this.name);\n return (this.parent ? this.parent.canonicalReference : DeclarationReference.empty())\n .addNavigationStep(this.isStatic ? Navigation.Exports : Navigation.Members, nameComponent)\n .withMeaning(Meaning.Member)\n .withOverloadIndex(this.overloadIndex);\n }\n}\n"]}
{"version":3,"file":"ApiMethodSignature.js","sourceRoot":"","sources":["../../src/model/ApiMethodSignature.ts"],"names":[],"mappings":";AAAA,4FAA4F;AAC5F,2DAA2D;;;AAE3D,kGAKiE;AAEjE,8CAA+C;AAC/C,8DAAyF;AACzF,2EAA4G;AAC5G,qEAAmG;AACnG,qEAAmG;AACnG,yDAAiF;AACjF,mFAG6C;AAC7C,iEAA6F;AAY7F;;;;;;;;;;;;;;;;;;;;GAoBG;AACH,MAAa,kBAAmB,SAAQ,IAAA,2BAAY,EAClD,IAAA,qDAAyB,EACvB,IAAA,6CAAqB,EAAC,IAAA,uCAAkB,EAAC,IAAA,uCAAkB,EAAC,IAAA,mCAAgB,EAAC,iCAAe,CAAC,CAAC,CAAC,CAAC,CACjG,CACF;IACC,YAAmB,OAAmC;QACpD,KAAK,CAAC,OAAO,CAAC,CAAC;IACjB,CAAC;IAEM,MAAM,CAAC,eAAe,CAAC,IAAY,EAAE,aAAqB;QAC/D,OAAO,GAAG,IAAI,IAAI,qBAAW,CAAC,eAAe,IAAI,aAAa,EAAE,CAAC;IACnE,CAAC;IAED,gBAAgB;IAChB,IAAW,IAAI;QACb,OAAO,qBAAW,CAAC,eAAe,CAAC;IACrC,CAAC;IAED,gBAAgB;IAChB,IAAW,YAAY;QACrB,OAAO,kBAAkB,CAAC,eAAe,CAAC,IAAI,CAAC,IAAI,EAAE,IAAI,CAAC,aAAa,CAAC,CAAC;IAC3E,CAAC;IAED,sBAAsB;IACf,uBAAuB;QAC5B,MAAM,aAAa,GAAc,2CAAoB,CAAC,cAAc,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC;QAChF,OAAO,CAAC,IAAI,CAAC,MAAM,CAAC,CAAC,CAAC,IAAI,CAAC,MAAM,CAAC,kBAAkB,CAAC,CAAC,CAAC,2CAAoB,CAAC,KAAK,EAAE,CAAC;aACjF,iBAAiB,CAAC,iCAAU,CAAC,OAAO,EAAE,aAAa,CAAC;aACpD,WAAW,CAAC,8BAAO,CAAC,MAAM,CAAC;aAC3B,iBAAiB,CAAC,IAAI,CAAC,aAAa,CAAC,CAAC;IAC3C,CAAC;CACF;AA/BD,gDA+BC","sourcesContent":["// Copyright (c) Microsoft Corporation. All rights reserved. Licensed under the MIT license.\n// See LICENSE in the project root for license information.\n\nimport {\n DeclarationReference,\n Meaning,\n Navigation,\n type Component\n} from '@microsoft/tsdoc/lib-commonjs/beta/DeclarationReference';\n\nimport { ApiItemKind } from '../items/ApiItem';\nimport { ApiDeclaredItem, type IApiDeclaredItemOptions } from '../items/ApiDeclaredItem';\nimport { ApiParameterListMixin, type IApiParameterListMixinOptions } from '../mixins/ApiParameterListMixin';\nimport { ApiReleaseTagMixin, type IApiReleaseTagMixinOptions } from '../mixins/ApiReleaseTagMixin';\nimport { type IApiReturnTypeMixinOptions, ApiReturnTypeMixin } from '../mixins/ApiReturnTypeMixin';\nimport { type IApiNameMixinOptions, ApiNameMixin } from '../mixins/ApiNameMixin';\nimport {\n type IApiTypeParameterListMixinOptions,\n ApiTypeParameterListMixin\n} from '../mixins/ApiTypeParameterListMixin';\nimport { ApiOptionalMixin, type IApiOptionalMixinOptions } from '../mixins/ApiOptionalMixin';\n\n/** @public */\nexport interface IApiMethodSignatureOptions\n extends IApiNameMixinOptions,\n IApiTypeParameterListMixinOptions,\n IApiParameterListMixinOptions,\n IApiReleaseTagMixinOptions,\n IApiReturnTypeMixinOptions,\n IApiOptionalMixinOptions,\n IApiDeclaredItemOptions {}\n\n/**\n * Represents a TypeScript member function declaration that belongs to an `ApiInterface`.\n *\n * @remarks\n *\n * This is part of the {@link ApiModel} hierarchy of classes, which are serializable representations of\n * API declarations.\n *\n * `ApiMethodSignature` represents a TypeScript declaration such as the `render` member function in this example:\n *\n * ```ts\n * export interface IWidget {\n * render(): void;\n * }\n * ```\n *\n * Compare with {@link ApiMethod}, which represents a method belonging to a class.\n * For example, a class method can be `static` but an interface method cannot.\n *\n * @public\n */\nexport class ApiMethodSignature extends ApiNameMixin(\n ApiTypeParameterListMixin(\n ApiParameterListMixin(ApiReleaseTagMixin(ApiReturnTypeMixin(ApiOptionalMixin(ApiDeclaredItem))))\n )\n) {\n public constructor(options: IApiMethodSignatureOptions) {\n super(options);\n }\n\n public static getContainerKey(name: string, overloadIndex: number): string {\n return `${name}|${ApiItemKind.MethodSignature}|${overloadIndex}`;\n }\n\n /** @override */\n public get kind(): ApiItemKind {\n return ApiItemKind.MethodSignature;\n }\n\n /** @override */\n public get containerKey(): string {\n return ApiMethodSignature.getContainerKey(this.name, this.overloadIndex);\n }\n\n /** @beta @override */\n public buildCanonicalReference(): DeclarationReference {\n const nameComponent: Component = DeclarationReference.parseComponent(this.name);\n return (this.parent ? this.parent.canonicalReference : DeclarationReference.empty())\n .addNavigationStep(Navigation.Members, nameComponent)\n .withMeaning(Meaning.Member)\n .withOverloadIndex(this.overloadIndex);\n }\n}\n"]}