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C,CAAC,iCAAU,CAAC,OAAO,CAAC,CAAC,CAAC,iCAAU,CAAC,OAAO,EAAE,aAAa,CAAC;aACzF,WAAW,CAAC,8BAAO,CAAC,MAAM,CAAC,CAAC;IACjC,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 { ApiAbstractMixin, type IApiAbstractMixinOptions } from '../mixins/ApiAbstractMixin';\nimport { ApiProtectedMixin, type IApiProtectedMixinOptions } from '../mixins/ApiProtectedMixin';\nimport { ApiStaticMixin, type IApiStaticMixinOptions } from '../mixins/ApiStaticMixin';\nimport { ApiInitializerMixin, type IApiInitializerMixinOptions } from '../mixins/ApiInitializerMixin';\nimport { ApiPropertyItem, type IApiPropertyItemOptions } from '../items/ApiPropertyItem';\n\n/**\n * Constructor options for {@link ApiProperty}.\n * @public\n */\nexport interface IApiPropertyOptions\n extends IApiPropertyItemOptions,\n IApiAbstractMixinOptions,\n IApiProtectedMixinOptions,\n IApiStaticMixinOptions,\n IApiInitializerMixinOptions {}\n\n/**\n * Represents a TypeScript property 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 * `ApiProperty` represents a TypeScript declaration such as the `width` and `height` members in this example:\n *\n * ```ts\n * export class Widget {\n * public width: number = 100;\n *\n * public get height(): number {\n * if (this.isSquashed()) {\n * return 0;\n * } else {\n * return this.clientArea.height;\n * }\n * }\n * }\n * ```\n *\n * Note that member variables are also considered to be properties.\n *\n * If the property has both a getter function and setter function, they will be represented by a single `ApiProperty`\n * and must have a single documentation comment.\n *\n * Compare with {@link ApiPropertySignature}, which represents a property belonging to an interface.\n * For example, a class property can be `static` but an interface property cannot.\n *\n * @public\n */\nexport class ApiProperty extends ApiAbstractMixin(\n ApiProtectedMixin(ApiStaticMixin(ApiInitializerMixin(ApiPropertyItem)))\n) {\n public constructor(options: IApiPropertyOptions) {\n super(options);\n }\n\n public static getContainerKey(name: string, isStatic: boolean): string {\n if (isStatic) {\n return `${name}|${ApiItemKind.Property}|static`;\n } else {\n return `${name}|${ApiItemKind.Property}|instance`;\n }\n }\n\n /** @override */\n public get kind(): ApiItemKind {\n return ApiItemKind.Property;\n }\n\n /** @override */\n public get containerKey(): string {\n return ApiProperty.getContainerKey(this.name, this.isStatic);\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 }\n}\n"]}
{"version":3,"file":"ApiPropertySignature.js","sourceRoot":"","sources":["../../src/model/ApiPropertySignature.ts"],"names":[],"mappings":";AAAA,4FAA4F;AAC5F,2DAA2D;;;AAE3D,kGAKiE;AAEjE,8CAA+C;AAC/C,8DAAyF;AAQzF;;;;;;;;;;;;;;;;;;;;;GAqBG;AACH,MAAa,oBAAqB,SAAQ,iCAAe;IACvD,YAAmB,OAAqC;QACtD,KAAK,CAAC,OAAO,CAAC,CAAC;IACjB,CAAC;IAEM,MAAM,CAAC,eAAe,CAAC,IAAY;QACxC,OAAO,GAAG,IAAI,IAAI,qBAAW,CAAC,iBAAiB,EAAE,CAAC;IACpD,CAAC;IAED,gBAAgB;IAChB,IAAW,IAAI;QACb,OAAO,qBAAW,CAAC,iBAAiB,CAAC;IACvC,CAAC;IAED,gBAAgB;IAChB,IAAW,YAAY;QACrB,OAAO,oBAAoB,CAAC,eAAe,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC;IACzD,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,CAAC;IACjC,CAAC;CACF;AA1BD,oDA0BC","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 { ApiPropertyItem, type IApiPropertyItemOptions } from '../items/ApiPropertyItem';\n\n/**\n * Constructor options for {@link ApiPropertySignature}.\n * @public\n */\nexport interface IApiPropertySignatureOptions extends IApiPropertyItemOptions {}\n\n/**\n * Represents a TypeScript property 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 * `ApiPropertySignature` represents a TypeScript declaration such as the `width` and `height` members in this example:\n *\n * ```ts\n * export interface IWidget {\n * readonly width: number;\n * height: number;\n * }\n * ```\n *\n * Compare with {@link ApiProperty}, which represents a property belonging to a class.\n * For example, a class property can be `static` but an interface property cannot.\n *\n * @public\n */\nexport class ApiPropertySignature extends ApiPropertyItem {\n public constructor(options: IApiPropertySignatureOptions) {\n super(options);\n }\n\n public static getContainerKey(name: string): string {\n return `${name}|${ApiItemKind.PropertySignature}`;\n }\n\n /** @override */\n public get kind(): ApiItemKind {\n return ApiItemKind.PropertySignature;\n }\n\n /** @override */\n public get containerKey(): string {\n return ApiPropertySignature.getContainerKey(this.name);\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 }\n}\n"]}
{"version":3,"file":"ApiTypeAlias.js","sourceRoot":"","sources":["../../src/model/ApiTypeAlias.ts"],"names":[],"mappings":";AAAA,4FAA4F;AAC5F,2DAA2D;;;AAE3D,kGAKiE;AAGjE,8CAA+C;AAC/C,8DAIkC;AAClC,qEAAmG;AACnG,yDAAiF;AACjF,mFAI6C;AAE7C,iEAIoC;AAsBpC;;;;;;;;;;;;;;;;;;;;;;;;;GAyBG;AACH,MAAa,YAAa,SAAQ,IAAA,qDAAyB,EACzD,IAAA,2BAAY,EAAC,IAAA,uCAAkB,EAAC,IAAA,mCAAgB,EAAC,iCAAe,CAAC,CAAC,CAAC,CACpE;IAcC,YAAmB,OAA6B;QAC9C,KAAK,CAAC,OAAO,CAAC,CAAC;QAEf,IAAI,CAAC,WAAW,GAAG,IAAI,CAAC,YAAY,CAAC,OAAO,CAAC,cAAc,CAAC,CAAC;IAC/D,CAAC;IAED,gBAAgB;IACT,MAAM,CAAC,iBAAiB,CAC7B,OAAsC,EACtC,OAA4B,EAC5B,UAA6B;QAE7B,KAAK,CAAC,iBAAiB,CAAC,OAAO,EAAE,OAAO,EAAE,UAAU,CAAC,CAAC;QAEtD,OAAO,CAAC,cAAc,GAAG,UAAU,CAAC,cAAc,CAAC;IACrD,CAAC;IAEM,MAAM,CAAC,eAAe,CAAC,IAAY;QACxC,OAAO,GAAG,IAAI,IAAI,qBAAW,CAAC,SAAS,EAAE,CAAC;IAC5C,CAAC;IAED,gBAAgB;IAChB,IAAW,IAAI;QACb,OAAO,qBAAW,CAAC,SAAS,CAAC;IAC/B,CAAC;IAED,gBAAgB;IAChB,IAAW,YAAY;QACrB,OAAO,YAAY,CAAC,eAAe,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC;IACjD,CAAC;IAED,gBAAgB;IACT,aAAa,CAAC,UAAsC;QACzD,KAAK,CAAC,aAAa,CAAC,UAAU,CAAC,CAAC;QAEhC,UAAU,CAAC,cAAc,GAAG,IAAI,CAAC,WAAW,CAAC,UAAU,CAAC;IAC1D,CAAC;IAED,sBAAsB;IACf,uBAAuB;QAC5B,MAAM,aAAa,GAAc,2CAAoB,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;AA9DD,oCA8DC","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 type { Excerpt, IExcerptTokenRange } from '../mixins/Excerpt';\nimport { ApiItemKind } from '../items/ApiItem';\nimport {\n ApiDeclaredItem,\n type IApiDeclaredItemOptions,\n type IApiDeclaredItemJson\n} from '../items/ApiDeclaredItem';\nimport { ApiReleaseTagMixin, type IApiReleaseTagMixinOptions } from '../mixins/ApiReleaseTagMixin';\nimport { type IApiNameMixinOptions, ApiNameMixin } from '../mixins/ApiNameMixin';\nimport {\n ApiTypeParameterListMixin,\n type IApiTypeParameterListMixinOptions,\n type IApiTypeParameterListMixinJson\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 ApiTypeAlias}.\n * @public\n */\nexport interface IApiTypeAliasOptions\n extends IApiNameMixinOptions,\n IApiReleaseTagMixinOptions,\n IApiDeclaredItemOptions,\n IApiTypeParameterListMixinOptions,\n IApiExportedMixinOptions {\n typeTokenRange: IExcerptTokenRange;\n}\n\nexport interface IApiTypeAliasJson\n extends IApiDeclaredItemJson,\n IApiTypeParameterListMixinJson,\n IApiExportedMixinJson {\n typeTokenRange: IExcerptTokenRange;\n}\n\n/**\n * Represents a TypeScript type alias 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 * `ApiTypeAlias` represents a definition such as one of these examples:\n *\n * ```ts\n * // A union type:\n * export type Shape = Square | Triangle | Circle;\n *\n * // A generic type alias:\n * export type BoxedValue<T> = { value: T };\n *\n * export type BoxedArray<T> = { array: T[] };\n *\n * // A conditional type alias:\n * export type Boxed<T> = T extends any[] ? BoxedArray<T[number]> : BoxedValue<T>;\n *\n * ```\n *\n * @public\n */\nexport class ApiTypeAlias extends ApiTypeParameterListMixin(\n ApiNameMixin(ApiReleaseTagMixin(ApiExportedMixin(ApiDeclaredItem)))\n) {\n /**\n * An {@link Excerpt} that describes the type of the alias.\n *\n * @remarks\n * In the example below, the `typeExcerpt` would correspond to the subexpression\n * `T extends any[] ? BoxedArray<T[number]> : BoxedValue<T>;`:\n *\n * ```ts\n * export type Boxed<T> = T extends any[] ? BoxedArray<T[number]> : BoxedValue<T>;\n * ```\n */\n public readonly typeExcerpt: Excerpt;\n\n public constructor(options: IApiTypeAliasOptions) {\n super(options);\n\n this.typeExcerpt = this.buildExcerpt(options.typeTokenRange);\n }\n\n /** @override */\n public static onDeserializeInto(\n options: Partial<IApiTypeAliasOptions>,\n context: DeserializerContext,\n jsonObject: IApiTypeAliasJson\n ): void {\n super.onDeserializeInto(options, context, jsonObject);\n\n options.typeTokenRange = jsonObject.typeTokenRange;\n }\n\n public static getContainerKey(name: string): string {\n return `${name}|${ApiItemKind.TypeAlias}`;\n }\n\n /** @override */\n public get kind(): ApiItemKind {\n return ApiItemKind.TypeAlias;\n }\n\n /** @override */\n public get containerKey(): string {\n return ApiTypeAlias.getContainerKey(this.name);\n }\n\n /** @override */\n public serializeInto(jsonObject: Partial<IApiTypeAliasJson>): void {\n super.serializeInto(jsonObject);\n\n jsonObject.typeTokenRange = this.typeExcerpt.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.TypeAlias);\n }\n}\n"]}
{"version":3,"file":"ApiVariable.js","sourceRoot":"","sources":["../../src/model/ApiVariable.ts"],"names":[],"mappings":";AAAA,4FAA4F;AAC5F,2DAA2D;;;AAE3D,kGAKiE;AAEjE,8CAA+C;AAC/C,8DAIkC;AAClC,qEAAmG;AACnG,iEAA6F;AAC7F,yDAAiF;AACjF,uEAAsG;AAGtG,iEAIoC;AAoBpC;;;;;;;;;;;;;;;;;;;GAmBG;AACH,MAAa,WAAY,SAAQ,IAAA,2BAAY,EAC3C,IAAA,uCAAkB,EAAC,IAAA,mCAAgB,EAAC,IAAA,yCAAmB,EAAC,IAAA,mCAAgB,EAAC,iCAAe,CAAC,CAAC,CAAC,CAAC,CAC7F;IAMC,YAAmB,OAA4B;QAC7C,KAAK,CAAC,OAAO,CAAC,CAAC;QAEf,IAAI,CAAC,mBAAmB,GAAG,IAAI,CAAC,YAAY,CAAC,OAAO,CAAC,sBAAsB,CAAC,CAAC;IAC/E,CAAC;IAED,gBAAgB;IACT,MAAM,CAAC,iBAAiB,CAC7B,OAAqC,EACrC,OAA4B,EAC5B,UAA4B;QAE5B,KAAK,CAAC,iBAAiB,CAAC,OAAO,EAAE,OAAO,EAAE,UAAU,CAAC,CAAC;QAEtD,OAAO,CAAC,sBAAsB,GAAG,UAAU,CAAC,sBAAsB,CAAC;IACrE,CAAC;IAEM,MAAM,CAAC,eAAe,CAAC,IAAY;QACxC,OAAO,GAAG,IAAI,IAAI,qBAAW,CAAC,QAAQ,EAAE,CAAC;IAC3C,CAAC;IAED,gBAAgB;IAChB,IAAW,IAAI;QACb,OAAO,qBAAW,CAAC,QAAQ,CAAC;IAC9B,CAAC;IAED,gBAAgB;IAChB,IAAW,YAAY;QACrB,OAAO,WAAW,CAAC,eAAe,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC;IAChD,CAAC;IAED,gBAAgB;IACT,aAAa,CAAC,UAAqC;QACxD,KAAK,CAAC,aAAa,CAAC,UAAU,CAAC,CAAC;QAEhC,UAAU,CAAC,sBAAsB,GAAG,IAAI,CAAC,mBAAmB,CAAC,UAAU,CAAC;IAC1E,CAAC;IAED,sBAAsB;IACf,uBAAuB;QAC5B,MAAM,aAAa,GAAc,2CAAoB,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,QAAQ,CAAC,CAAC;IACnC,CAAC;CACF;AAtDD,kCAsDC","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 ApiDeclaredItem,\n type IApiDeclaredItemOptions,\n type IApiDeclaredItemJson\n} from '../items/ApiDeclaredItem';\nimport { ApiReleaseTagMixin, type IApiReleaseTagMixinOptions } from '../mixins/ApiReleaseTagMixin';\nimport { ApiReadonlyMixin, type IApiReadonlyMixinOptions } from '../mixins/ApiReadonlyMixin';\nimport { type IApiNameMixinOptions, ApiNameMixin } from '../mixins/ApiNameMixin';\nimport { ApiInitializerMixin, type IApiInitializerMixinOptions } from '../mixins/ApiInitializerMixin';\nimport type { IExcerptTokenRange, Excerpt } from '../mixins/Excerpt';\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 ApiVariable}.\n * @public\n */\nexport interface IApiVariableOptions\n extends IApiNameMixinOptions,\n IApiReleaseTagMixinOptions,\n IApiReadonlyMixinOptions,\n IApiDeclaredItemOptions,\n IApiInitializerMixinOptions,\n IApiExportedMixinOptions {\n variableTypeTokenRange: IExcerptTokenRange;\n}\n\nexport interface IApiVariableJson extends IApiDeclaredItemJson, IApiExportedMixinJson {\n variableTypeTokenRange: IExcerptTokenRange;\n}\n\n/**\n * Represents a TypeScript variable 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 * `ApiVariable` represents an exported `const` or `let` object such as these examples:\n *\n * ```ts\n * // A variable declaration\n * export let verboseLogging: boolean;\n *\n * // A constant variable declaration with an initializer\n * export const canvas: IWidget = createCanvas();\n * ```\n *\n * @public\n */\nexport class ApiVariable extends ApiNameMixin(\n ApiReleaseTagMixin(ApiReadonlyMixin(ApiInitializerMixin(ApiExportedMixin(ApiDeclaredItem))))\n) {\n /**\n * An {@link Excerpt} that describes the type of the variable.\n */\n public readonly variableTypeExcerpt: Excerpt;\n\n public constructor(options: IApiVariableOptions) {\n super(options);\n\n this.variableTypeExcerpt = this.buildExcerpt(options.variableTypeTokenRange);\n }\n\n /** @override */\n public static onDeserializeInto(\n options: Partial<IApiVariableOptions>,\n context: DeserializerContext,\n jsonObject: IApiVariableJson\n ): void {\n super.onDeserializeInto(options, context, jsonObject);\n\n options.variableTypeTokenRange = jsonObject.variableTypeTokenRange;\n }\n\n public static getContainerKey(name: string): string {\n return `${name}|${ApiItemKind.Variable}`;\n }\n\n /** @override */\n public get kind(): ApiItemKind {\n return ApiItemKind.Variable;\n }\n\n /** @override */\n public get containerKey(): string {\n return ApiVariable.getContainerKey(this.name);\n }\n\n /** @override */\n public serializeInto(jsonObject: Partial<IApiVariableJson>): void {\n super.serializeInto(jsonObject);\n\n jsonObject.variableTypeTokenRange = this.variableTypeExcerpt.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.Variable);\n }\n}\n"]}
{"version":3,"file":"Deserializer.js","sourceRoot":"","sources":["../../src/model/Deserializer.ts"],"names":[],"mappings":";AAAA,4FAA4F;AAC5F,2DAA2D;;;AAE3D,8CAAsG;AACtG,yCAAiF;AACjF,mDAA4E;AAC5E,2CAAgE;AAChE,yCAAsC;AACtC,iDAAyE;AACzE,6CAAyF;AACzF,iDAAiG;AACjG,iEAAiG;AACjG,6DAA2F;AAC3F,+CAAsE;AACtE,mDAA4E;AAC5E,uCAA0D;AAE1D,qDAA+E;AAC/E,mEAAoG;AACpG,+CAAsE;AACtE,yDAAqF;AACrF,2DAAwF;AACxF,iDAAiG;AACjG,+CAA6F;AAI7F,MAAa,YAAY;IAChB,MAAM,CAAC,WAAW,CAAC,OA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ACvD,KAAK,qBAAW,CAAC,QAAQ;gBACvB,yBAAW,CAAC,iBAAiB,CAAC,OAAO,EAAE,OAAO,EAAE,UAAkC,CAAC,CAAC;gBACpF,OAAO,IAAI,yBAAW,CAAC,OAA8B,CAAC,CAAC;YACzD,KAAK,qBAAW,CAAC,iBAAiB;gBAChC,2CAAoB,CAAC,iBAAiB,CAAC,OAAO,EAAE,OAAO,EAAE,UAAkC,CAAC,CAAC;gBAC7F,OAAO,IAAI,2CAAoB,CAAC,OAAuC,CAAC,CAAC;YAC3E,KAAK,qBAAW,CAAC,SAAS;gBACxB,2BAAY,CAAC,iBAAiB,CAAC,OAAO,EAAE,OAAO,EAAE,UAA+B,CAAC,CAAC;gBAClF,OAAO,IAAI,2BAAY,CAAC,OAA+B,CAAC,CAAC;YAC3D,KAAK,qBAAW,CAAC,QAAQ;gBACvB,yBAAW,CAAC,iBAAiB,CAAC,OAAO,EAAE,OAAO,EAAE,UAA8B,CAAC,CAAC;gBAChF,OAAO,IAAI,yBAAW,CAAC,OAA8B,CAAC,CAAC;YACzD;gBACE,MAAM,IAAI,KAAK,CAAC,mDAAmD,IAAI,CAAC,SAAS,CAAC,UAAU,CAAC,IAAI,CAAC,EAAE,CAAC,CAAC;QAC1G,CAAC;IACH,CAAC;CACF;AAjED,oCAiEC","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 { type IApiItemJson, type IApiItemOptions, type ApiItem, ApiItemKind } from '../items/ApiItem';\nimport { ApiClass, type IApiClassOptions, type IApiClassJson } from './ApiClass';\nimport { ApiEntryPoint, type IApiEntryPointOptions } from './ApiEntryPoint';\nimport { ApiMethod, type IApiMethodOptions } from './ApiMethod';\nimport { ApiModel } from './ApiModel';\nimport { ApiNamespace, type IApiNamespaceOptions } from './ApiNamespace';\nimport { ApiPackage, type IApiPackageOptions, type IApiPackageJson } from './ApiPackage';\nimport { ApiInterface, type IApiInterfaceOptions, type IApiInterfaceJson } from './ApiInterface';\nimport { ApiPropertySignature, type IApiPropertySignatureOptions } from './ApiPropertySignature';\nimport { ApiMethodSignature, type IApiMethodSignatureOptions } from './ApiMethodSignature';\nimport { ApiProperty, type IApiPropertyOptions } from './ApiProperty';\nimport { ApiEnumMember, type IApiEnumMemberOptions } from './ApiEnumMember';\nimport { ApiEnum, type IApiEnumOptions } from './ApiEnum';\nimport type { IApiPropertyItemJson } from '../items/ApiPropertyItem';\nimport { ApiConstructor, type IApiConstructorOptions } from './ApiConstructor';\nimport { ApiConstructSignature, type IApiConstructSignatureOptions } from './ApiConstructSignature';\nimport { ApiFunction, type IApiFunctionOptions } from './ApiFunction';\nimport { ApiCallSignature, type IApiCallSignatureOptions } from './ApiCallSignature';\nimport { ApiIndexSignature, type IApiIndexSignatureOptions } from './ApiIndexSignature';\nimport { ApiTypeAlias, type IApiTypeAliasOptions, type IApiTypeAliasJson } from './ApiTypeAlias';\nimport { ApiVariable, type IApiVariableOptions, type IApiVariableJson } from './ApiVariable';\nimport type { IApiDeclaredItemJson } from '../items/ApiDeclaredItem';\nimport type { DeserializerContext } from './DeserializerContext';\n\nexport class Deserializer {\n public static deserialize(context: DeserializerContext, jsonObject: IApiItemJson): ApiItem {\n const options: Partial<IApiItemOptions> = {};\n\n switch (jsonObject.kind) {\n case ApiItemKind.Class:\n ApiClass.onDeserializeInto(options, context, jsonObject as IApiClassJson);\n return new ApiClass(options as IApiClassOptions);\n case ApiItemKind.CallSignature:\n ApiCallSignature.onDeserializeInto(options, context, jsonObject as IApiDeclaredItemJson);\n return new ApiCallSignature(options as IApiCallSignatureOptions);\n case ApiItemKind.Constructor:\n ApiConstructor.onDeserializeInto(options, context, jsonObject as IApiDeclaredItemJson);\n return new ApiConstructor(options as IApiConstructorOptions);\n case ApiItemKind.ConstructSignature:\n ApiConstructSignature.onDeserializeInto(options, context, jsonObject as IApiDeclaredItemJson);\n return new ApiConstructSignature(options as IApiConstructSignatureOptions);\n case ApiItemKind.EntryPoint:\n ApiEntryPoint.onDeserializeInto(options, context, jsonObject);\n return new ApiEntryPoint(options as IApiEntryPointOptions);\n case ApiItemKind.Enum:\n ApiEnum.onDeserializeInto(options, context, jsonObject as IApiDeclaredItemJson);\n return new ApiEnum(options as IApiEnumOptions);\n case ApiItemKind.EnumMember:\n ApiEnumMember.onDeserializeInto(options, context, jsonObject as IApiDeclaredItemJson);\n return new ApiEnumMember(options as IApiEnumMemberOptions);\n case ApiItemKind.Function:\n ApiFunction.onDeserializeInto(options, context, jsonObject as IApiDeclaredItemJson);\n return new ApiFunction(options as IApiFunctionOptions);\n case ApiItemKind.IndexSignature:\n ApiIndexSignature.onDeserializeInto(options, context, jsonObject as IApiDeclaredItemJson);\n return new ApiIndexSignature(options as IApiIndexSignatureOptions);\n case ApiItemKind.Interface:\n ApiInterface.onDeserializeInto(options, context, jsonObject as IApiInterfaceJson);\n return new ApiInterface(options as IApiInterfaceOptions);\n case ApiItemKind.Method:\n ApiMethod.onDeserializeInto(options, context, jsonObject as IApiDeclaredItemJson);\n return new ApiMethod(options as IApiMethodOptions);\n case ApiItemKind.MethodSignature:\n ApiMethodSignature.onDeserializeInto(options, context, jsonObject as IApiDeclaredItemJson);\n return new ApiMethodSignature(options as IApiMethodSignatureOptions);\n case ApiItemKind.Model:\n return new ApiModel();\n case ApiItemKind.Namespace:\n ApiNamespace.onDeserializeInto(options, context, jsonObject as IApiDeclaredItemJson);\n return new ApiNamespace(options as IApiNamespaceOptions);\n case ApiItemKind.Package:\n ApiPackage.onDeserializeInto(options, context, jsonObject as IApiPackageJson);\n return new ApiPackage(options as IApiPackageOptions);\n case ApiItemKind.Property:\n ApiProperty.onDeserializeInto(options, context, jsonObject as IApiPropertyItemJson);\n return new ApiProperty(options as IApiPropertyOptions);\n case ApiItemKind.PropertySignature:\n ApiPropertySignature.onDeserializeInto(options, context, jsonObject as IApiPropertyItemJson);\n return new ApiPropertySignature(options as IApiPropertySignatureOptions);\n case ApiItemKind.TypeAlias:\n ApiTypeAlias.onDeserializeInto(options, context, jsonObject as IApiTypeAliasJson);\n return new ApiTypeAlias(options as IApiTypeAliasOptions);\n case ApiItemKind.Variable:\n ApiVariable.onDeserializeInto(options, context, jsonObject as IApiVariableJson);\n return new ApiVariable(options as IApiVariableOptions);\n default:\n throw new Error(`Failed to deserialize unsupported API item type ${JSON.stringify(jsonObject.kind)}`);\n }\n }\n}\n"]}