UNPKG

@kephas/reflection

Version:

Provides reflection capabilities, like TypeInfoRegistry, ITypeInfo, and IProperty.

1 lines 32.2 kB
{"version":3,"file":"kephas-reflection.mjs","sources":["../../../../projects/kephas/reflection/src/lib/displayInfo.ts","../../../../projects/kephas/reflection/src/lib/reflectionError.ts","../../../../projects/kephas/reflection/src/lib/elementInfo.ts","../../../../projects/kephas/reflection/src/lib/typeName.ts","../../../../projects/kephas/reflection/src/lib/typeInfoRegistry.ts","../../../../projects/kephas/reflection/src/lib/valueElementInfo.ts","../../../../projects/kephas/reflection/src/lib/propertyInfo.ts","../../../../projects/kephas/reflection/src/lib/typeInfo.ts","../../../../projects/kephas/reflection/src/public-api.ts","../../../../projects/kephas/reflection/src/kephas-reflection.ts"],"sourcesContent":["/**\r\n * Provides display information.\r\n *\r\n * @export\r\n * @class DisplayInfo\r\n */\r\nexport class DisplayInfo {\r\n /**\r\n * Gets the localized name.\r\n *\r\n * @type {string}\r\n * @memberof DisplayInfo\r\n */\r\n public name?: string;\r\n\r\n /**\r\n * Gets the localized description.\r\n *\r\n * @type {string}\r\n * @memberof DisplayInfo\r\n */\r\n public description?: string;\r\n\r\n /**\r\n * Gets the localized prompt.\r\n *\r\n * @type {string}\r\n * @memberof DisplayInfo\r\n */\r\n public prompt?: string;\r\n\r\n /**\r\n * Gets the localized short name.\r\n *\r\n * @type {string}\r\n * @memberof DisplayInfo\r\n */\r\n public shortName?: string;\r\n}","/**\r\n * Signals a reflection error.\r\n *\r\n * @export\r\n * @class ReflectionError\r\n * @extends {Error}\r\n */\r\nexport class ReflectionError extends Error {\r\n /**\r\n * Creates an instance of ReflectionError.\r\n * @param {string} message The error message.\r\n * @memberof ReflectionError\r\n */\r\n constructor(message: string) {\r\n super(message);\r\n }\r\n}","import { DisplayInfo } from \"./displayInfo\";\r\nimport { IElementInfo, ITypeInfoRegistry } from \"./interfaces\";\r\nimport { ReflectionError } from \"./reflectionError\";\r\n\r\n/**\r\n * Provides basic implementation of reflection elements.\r\n *\r\n * @export\r\n * @class ElementInfo\r\n */\r\nexport abstract class ElementInfo implements IElementInfo {\r\n /**\r\n * Gets the element name.\r\n *\r\n * @type {string}\r\n * @memberof IElementInfo\r\n */\r\n readonly name: string = '';\r\n\r\n /**\r\n * Gets the element full name.\r\n *\r\n * @type {string}\r\n * @memberof ElementInfo\r\n */\r\n readonly fullName: string;\r\n\r\n /**\r\n * Gets the localized display information.\r\n *\r\n * @memberof ElementInfo\r\n */\r\n readonly displayInfo?: DisplayInfo;\r\n\r\n /**\r\n * Creates an instance of ElementInfo.\r\n *\r\n * @param {string} name The element name.\r\n * @param {string} [fullName] Optional. The full name of the element.\r\n * @param {DisplayInfo} [displayInfo] Optional. The display information.\r\n * @param {ITypeInfoRegistry} [registry] The root type info registry.\r\n * @memberof ElementInfo\r\n */\r\n constructor(\r\n {\r\n name,\r\n fullName,\r\n displayInfo,\r\n registry,\r\n ...args\r\n }: {\r\n name: string;\r\n fullName?: string;\r\n displayInfo?: DisplayInfo;\r\n registry?: ITypeInfoRegistry;\r\n [key: string]: any;\r\n }) {\r\n if (!name) {\r\n throw new ReflectionError('The name must be provided.');\r\n }\r\n\r\n this.name = name;\r\n this.fullName = fullName || this.name;\r\n this.displayInfo = displayInfo || new DisplayInfo();\r\n Object.assign(this, args);\r\n }\r\n}\r\n","/**\r\n * Provides a list of well known type names.\r\n *\r\n * @export\r\n * @class TypeName\r\n */\r\nexport class TypeName {\r\n /**\r\n * The name of the 'any' type.\r\n *\r\n * @static\r\n * @memberof TypeName\r\n */\r\n static readonly AnyTypeName = 'any';\r\n\r\n /**\r\n * The name of the 'boolean' type.\r\n *\r\n * @static\r\n * @memberof TypeName\r\n */\r\n static readonly BooleanTypeName = 'boolean';\r\n\r\n /**\r\n * The name of the 'number' type.\r\n *\r\n * @static\r\n * @memberof TypeName\r\n */\r\n static readonly NumberTypeName = 'number';\r\n\r\n /**\r\n * The name of the 'string' type.\r\n *\r\n * @static\r\n * @memberof TypeName\r\n */\r\n static readonly StringTypeName = 'string';\r\n\r\n /**\r\n * The name of the 'array' type.\r\n *\r\n * @static\r\n * @memberof TypeName\r\n */\r\n static readonly ArrayTypeName = 'array';\r\n\r\n /**\r\n * The name of the 'any[]' type.\r\n *\r\n * @static\r\n * @memberof TypeName\r\n */\r\n static readonly ArrayOfAnyTypeName = 'any[]';\r\n\r\n /**\r\n * The name of the 'Uint8Array' type.\r\n *\r\n * @static\r\n * @memberof TypeName\r\n */\r\n static readonly ArrayOfByteTypeName = 'Uint8Array';\r\n\r\n /**\r\n * The name of the 'symbol' type.\r\n *\r\n * @static\r\n * @memberof TypeName\r\n */\r\n static readonly SymbolTypeName = 'symbol';\r\n\r\n /**\r\n * The name of the 'Date' type.\r\n *\r\n * @static\r\n * @memberof TypeName\r\n */\r\n static readonly DateTypeName = 'Date';\r\n}","import { Requires, SingletonAppServiceContract, AppService, Priority, Serializable } from '@kephas/core';\r\nimport { ITypeInfo, ITypeInfoRegistry } from './interfaces';\r\nimport { ReflectionError } from './reflectionError';\r\nimport { TypeName } from './typeName';\r\n\r\n/**\r\n * Provides centralized access to the application's type system.\r\n *\r\n * @export\r\n * @class TypeInfoRegistry\r\n */\r\n@AppService({ overridePriority: Priority.Low, provider: _ => TypeInfoRegistry.Instance })\r\n@SingletonAppServiceContract()\r\nexport class TypeInfoRegistry implements ITypeInfoRegistry {\r\n /**\r\n * Gets the registerd types.\r\n *\r\n * @type {ITypeInfo[]}\r\n * @memberof TypeInfoRegistry\r\n */\r\n readonly types: ITypeInfo[] = [];\r\n\r\n /**\r\n * Gets the singleton instance of the type registry.\r\n *\r\n * @static\r\n * @type {TypeInfoRegistry}\r\n * @memberof TypeInfoRegistry\r\n */\r\n static get Instance(): ITypeInfoRegistry {\r\n return TypeInfoRegistry._instance || (TypeInfoRegistry._instance = new TypeInfoRegistry());\r\n }\r\n\r\n private static _instance: ITypeInfoRegistry;\r\n private _typesByFullName: { [key: string]: ITypeInfo } = {}\r\n private _typesByName: { [key: string]: ITypeInfo } = {}\r\n\r\n /**\r\n * Creates an instance of TypeInfoRegistry.\r\n * @memberof TypeInfoRegistry\r\n */\r\n constructor() {\r\n this.types = [];\r\n this.initialize(this);\r\n }\r\n\r\n /**\r\n * Gets the type in the registry by its name.\r\n *\r\n * @param {string | Function} typeRef The full name of the type or the runtime type.\r\n * @param {boolean} [throwOnNotFound=true] True to throw if the type cannot be found.\r\n * @returns {TypeInfo}\r\n * @memberof TypeInfoRegistry\r\n */\r\n public getType(typeRef: string | Function, throwOnNotFound?: boolean): ITypeInfo | undefined {\r\n Requires.HasValue(typeRef, 'typeRef');\r\n if (throwOnNotFound === undefined) {\r\n throwOnNotFound = true;\r\n }\r\n\r\n let fullName = typeof typeRef === 'function'\r\n ? Serializable.getTypeFullName(typeRef)\r\n : typeRef;\r\n if (fullName && fullName.endsWith('[]')) {\r\n fullName = TypeName.ArrayOfAnyTypeName;\r\n }\r\n\r\n let type = fullName ? this._typesByFullName[fullName] : undefined;\r\n if (!type && fullName) {\r\n type = this._typesByName[fullName];\r\n }\r\n\r\n if (!type && throwOnNotFound) {\r\n throw new ReflectionError(`The type with name '${typeRef}' was not found.`);\r\n }\r\n\r\n return type;\r\n }\r\n\r\n /**\r\n * Registers the provided types.\r\n *\r\n * @param {ITypeInfo[]} types The types to register.\r\n * @returns {this} This registry.\r\n * @memberof TypeInfoRegistry\r\n */\r\n public register(...types: ITypeInfo[]): this {\r\n if (!types) {\r\n return this;\r\n }\r\n\r\n for (const type of types) {\r\n const typeKey = type.fullName || type.name;\r\n if (this._typesByFullName[typeKey]) {\r\n throw new ReflectionError(`The type ${typeKey} is already registered.`);\r\n }\r\n\r\n this._typesByFullName[typeKey] = type;\r\n this._typesByName[type.name] = type;\r\n }\r\n\r\n this.types.push.apply(this.types, types);\r\n\r\n return this;\r\n }\r\n\r\n /**\r\n * Initializes the registry.\r\n *\r\n * @protected\r\n * @param {TypeInfoRegistry} registry\r\n * @memberof TypeInfoRegistry\r\n */\r\n protected initialize(registry: TypeInfoRegistry) {\r\n }\r\n}\r\n","import { DisplayInfo } from './displayInfo';\r\nimport { ElementInfo } from './elementInfo';\r\nimport { ITypeInfo, ITypeInfoRegistry, IValueElementInfo } from './interfaces';\r\nimport { TypeInfoRegistry } from './typeInfoRegistry';\r\nimport { TypeName } from './typeName';\r\n\r\n/**\r\n * Reflective element information holding a value.\r\n *\r\n * @export\r\n * @class ValueElementInfo\r\n * @extends {ElementInfo}\r\n */\r\nexport abstract class ValueElementInfo extends ElementInfo implements IValueElementInfo {\r\n private _valueType?: ITypeInfo;\r\n private _valueTypeGetter?: () => ITypeInfo;\r\n\r\n /**\r\n * Gets the type of the element's value.\r\n *\r\n * @type {TypeInfo}\r\n * @memberof ValueElementInfo\r\n */\r\n get valueType(): ITypeInfo {\r\n return this._valueType || (this._valueType = this._valueTypeGetter!());\r\n }\r\n\r\n /**\r\n * Creates an instance of ValueElementInfo.\r\n *\r\n * @param {string} name The element name.\r\n * @param {string} [fullName] Optional. The full name of the element.\r\n * @param {DisplayInfo} [displayInfo] Optional. The display information.\r\n * @param {ITypeInfo} [valueType] The value type.\r\n * @param {ITypeInfoRegistry} [registry] The root type info registry.\r\n * @memberof ValueElementInfo\r\n */\r\n constructor(\r\n {\r\n name,\r\n fullName,\r\n displayInfo,\r\n valueType,\r\n registry,\r\n ...args\r\n }: {\r\n name: string;\r\n fullName?: string;\r\n displayInfo?: DisplayInfo;\r\n valueType?: ITypeInfo | string;\r\n registry?: ITypeInfoRegistry;\r\n [key: string]: any;\r\n }) {\r\n super({ name, fullName, displayInfo, registry, ...args });\r\n if (!valueType) {\r\n this._valueTypeGetter =\r\n () => (this._valueType || (this._valueType = this.getValueType(TypeName.AnyTypeName, registry)!));\r\n }\r\n else if (typeof valueType === 'string') {\r\n this._valueTypeGetter =\r\n () => (this._valueType || (this._valueType = this.getValueType(valueType as unknown as string, registry)!));\r\n }\r\n else {\r\n this._valueType = valueType;\r\n }\r\n }\r\n\r\n /**\r\n * Gets the value type based on the type name.\r\n *\r\n * @protected\r\n * @param {string} valueType The name or full name of the value type.\r\n * @param {ITypeInfoRegistry} [registry] The type info registry. If not provided, TypeInfoRegistry.Instance will be used.\r\n * @returns\r\n * @memberof ValueElementInfo\r\n */\r\n protected getValueType(valueType: string, registry?: ITypeInfoRegistry) {\r\n return (registry || TypeInfoRegistry.Instance).getType(valueType);\r\n }\r\n}\r\n","import { DisplayInfo } from \"./displayInfo\";\r\nimport { IPropertyInfo, ITypeInfo, ITypeInfoRegistry } from \"./interfaces\";\r\nimport { ReflectionError } from \"./reflectionError\";\r\nimport { ValueElementInfo } from \"./valueElementInfo\";\r\n\r\n/**\r\n * Provides reflection information about a property.\r\n *\r\n * @export\r\n * @class PropertyInfo\r\n * @extends {ElementInfo}\r\n * @implements {IPropertyInfo}\r\n */\r\nexport class PropertyInfo extends ValueElementInfo implements IPropertyInfo {\r\n\r\n /**\r\n * Gets the declaring type.\r\n *\r\n * @type {TypeInfo}\r\n * @memberof PropertyInfo\r\n */\r\n readonly declaringType: ITypeInfo;\r\n\r\n /**\r\n * Gets a value indicating whether the property can be written to.\r\n *\r\n * @type {boolean}\r\n * @memberof IPropertyInfo\r\n */\r\n readonly canWrite: boolean = true;\r\n\r\n /**\r\n * Gets a value indicating whether the property value can be read.\r\n *\r\n * @type {boolean}\r\n * @memberof IPropertyInfo\r\n */\r\n readonly canRead: boolean = true;\r\n\r\n /**\r\n * Gets a value indicating whether a value is required for this property.\r\n *\r\n * @type {boolean}\r\n * @memberof PropertyInfo\r\n */\r\n readonly isRequired: boolean = false;\r\n\r\n /**\r\n * Gets a value indicating whether this property is class bound, not instance bound.\r\n *\r\n * @type {boolean}\r\n * @memberof PropertyInfo\r\n */\r\n readonly isStatic: boolean = false;\r\n\r\n /**\r\n * Gets the default value of the property.\r\n *\r\n * @type {*}\r\n * @memberof PropertyInfo\r\n */\r\n readonly defaultValue?: any;\r\n\r\n /**\r\n * Creates an instance of PropertyInfo.\r\n *\r\n * @param {ITypeInfo} declaringType The declaring type.\r\n * @param {string} name The element name.\r\n * @param {string} [fullName] Optional. The full name of the element.\r\n * @param {DisplayInfo} [displayInfo] Optional. The display information.\r\n * @param {ITypeInfo} [valueType] The value type.\r\n * @param {boolean} [canRead] True if the property can be read.\r\n * @param {boolean} [canWrite] True if the property can be written.\r\n * @param {boolean} [isRequired] True if the property requires a value to be set.\r\n * @param {*} [defaultValue] The default value of the property.\r\n * @param {ITypeInfoRegistry} [registry] The root type info registry.\r\n * @memberof PropertyInfo\r\n */\r\n constructor(\r\n {\r\n declaringType,\r\n name,\r\n fullName,\r\n displayInfo,\r\n valueType,\r\n canRead,\r\n canWrite,\r\n isRequired,\r\n isStatic,\r\n defaultValue,\r\n registry,\r\n ...args\r\n }: {\r\n declaringType: ITypeInfo;\r\n name: string;\r\n fullName?: string;\r\n displayInfo?: DisplayInfo;\r\n valueType?: ITypeInfo | string;\r\n canRead?: boolean;\r\n canWrite?: boolean;\r\n isRequired?: boolean;\r\n isStatic?: boolean;\r\n defaultValue?: any;\r\n registry?: ITypeInfoRegistry;\r\n [key: string]: any;\r\n }) {\r\n super({ name, fullName, displayInfo, valueType, registry, ...args });\r\n\r\n if (!declaringType) {\r\n throw new ReflectionError('The declaring type is not set.');\r\n }\r\n\r\n this.declaringType = declaringType;\r\n this.canRead = canRead === undefined ? true : canRead;\r\n this.canWrite = canWrite === undefined ? true : canWrite;\r\n this.isRequired = !!isRequired;\r\n this.isStatic = !!isStatic;\r\n this.defaultValue = defaultValue;\r\n }\r\n}\r\n","import { Serializable, Type } from '@kephas/core';\r\nimport { DisplayInfo } from './displayInfo';\r\nimport { ElementInfo } from './elementInfo';\r\nimport { IPropertyInfo, ITypeInfo, ITypeInfoRegistry } from './interfaces';\r\nimport { PropertyInfo } from './propertyInfo';\r\nimport { ReflectionError } from './reflectionError';\r\nimport { TypeName } from './typeName';\r\n\r\n/**\r\n * Provides reflective information about a type.\r\n *\r\n * @export\r\n * @class TypeInfo\r\n * @extends {ElementInfo}\r\n */\r\nexport class TypeInfo extends ElementInfo implements ITypeInfo {\r\n /**\r\n * Gets the type's namespace.\r\n *\r\n * @type {string}\r\n * @memberof TypeInfo\r\n */\r\n readonly namespace?: string;\r\n\r\n /**\r\n * Gets the type's properties.\r\n *\r\n * @type {IIPropertyInfo[]}\r\n * @memberof TypeInfo\r\n */\r\n readonly properties: IPropertyInfo[];\r\n\r\n /**\r\n * Gets the instance constructor.\r\n *\r\n * @memberof TypeInfo\r\n */\r\n readonly type?: Type<any>;\r\n\r\n /**\r\n * Gets the default value of the property.\r\n *\r\n * @type {*}\r\n * @memberof TypeInfo\r\n */\r\n readonly defaultValue?: any;\r\n\r\n /**\r\n * Gets a value indicating whether this type is an array.\r\n *\r\n * @type {boolean} True if the type is an array, false otherwise.\r\n * @memberof TypeInfo\r\n */\r\n readonly isArray: boolean;\r\n\r\n /**\r\n * Gets a value indicating whether this type is an enumeration.\r\n *\r\n * @type {boolean} True if the type is an enumeration, false otherwise.\r\n * @memberof TypeInfo\r\n */\r\n readonly isEnum: boolean;\r\n\r\n /**\r\n * Gets a value indicating whether this type is the boolean type.\r\n *\r\n * @type {boolean} True if the type is the boolean type, false otherwise.\r\n * @memberof TypeInfo\r\n */\r\n get isBoolean(): boolean {\r\n return this.fullName === TypeName.BooleanTypeName;\r\n }\r\n\r\n /**\r\n * Gets a value indicating whether this type is the number type.\r\n *\r\n * @type {boolean} True if the type is the number type, false otherwise.\r\n * @memberof TypeInfo\r\n */\r\n get isNumber(): boolean {\r\n return this.fullName === TypeName.NumberTypeName;\r\n }\r\n\r\n /**\r\n * Gets a value indicating whether this type is the string type.\r\n *\r\n * @type {boolean} True if the type is the string type, false otherwise.\r\n * @memberof TypeInfo\r\n */\r\n get isString(): boolean {\r\n return this.fullName === TypeName.StringTypeName;\r\n }\r\n\r\n /**\r\n * Gets a value indicating whether this type is the symbol type.\r\n *\r\n * @type {boolean} True if the type is the symbol type, false otherwise.\r\n * @memberof TypeInfo\r\n */\r\n get isSymbol(): boolean {\r\n return this.fullName === TypeName.SymbolTypeName;\r\n }\r\n\r\n /**\r\n * Gets a value indicating whether this type is the any type.\r\n *\r\n * @type {boolean} True if the type is the any type, false otherwise.\r\n * @memberof TypeInfo\r\n */\r\n get isAny(): boolean {\r\n return this.fullName === TypeName.AnyTypeName;\r\n }\r\n\r\n /**\r\n * Creates an instance of TypeInfo.\r\n *\r\n * @param {string} name The type name.\r\n * @param {string} [namespace] The type namespace.\r\n * @param {string} [fullName] Optional. The full name of the type.\r\n * @param {DisplayInfo} [displayInfo] Optional. The display information.\r\n * @param {IPropertyInfo[]} [properties] Optional. The properties.\r\n * @param {Type<*>} [type] Optional. The instantiable type.\r\n * @param {boolean} [isArray] Optional. Indicates whether the type is an array.\r\n * @param {boolean} [isEnum] Optional. Indicates whether the type is an enumeration.\r\n * @param {*} [defaultValue] Optional. The type's default value.\r\n * @param {ITypeInfoRegistry} [registry] The root type info registry.\r\n * @memberof TypeInfo\r\n */\r\n constructor(\r\n {\r\n name,\r\n namespace,\r\n fullName,\r\n displayInfo,\r\n properties,\r\n type,\r\n isArray,\r\n isEnum,\r\n defaultValue,\r\n registry,\r\n ...args\r\n }: {\r\n name?: string;\r\n namespace?: string;\r\n fullName?: string;\r\n displayInfo?: DisplayInfo;\r\n properties?: {\r\n name: string;\r\n fullName?: string;\r\n displayInfo?: DisplayInfo;\r\n valueType?: ITypeInfo | string;\r\n canRead?: boolean;\r\n canWrite?: boolean;\r\n isRequired?: boolean;\r\n isStatic?: boolean;\r\n defaultValue?: any;\r\n [key: string]: any;\r\n }[];\r\n type?: Type<any>;\r\n isArray?: boolean;\r\n isEnum?: boolean;\r\n defaultValue?: any;\r\n registry?: ITypeInfoRegistry;\r\n [key: string]: any;\r\n }) {\r\n super({\r\n name: TypeInfo._getName(name, type),\r\n fullName: fullName || TypeInfo._getFullName(name, namespace, type),\r\n displayInfo,\r\n registry,\r\n ...args\r\n });\r\n this.type = type;\r\n this.namespace = TypeInfo._getNamespace(namespace, type);\r\n properties = properties && properties.map(p => new PropertyInfo({ ...p, declaringType: this, registry }));\r\n this.properties = (properties || []) as IPropertyInfo[];\r\n if (this.type) {\r\n Serializable.setTypeFullName(this.type, this.fullName);\r\n }\r\n this.isEnum = !!isEnum;\r\n this.isArray = !!isArray;\r\n this.defaultValue = defaultValue;\r\n }\r\n\r\n private static _getName(name?: string, type?: Type<any>): string {\r\n if (name) {\r\n return name;\r\n }\r\n\r\n if (type) {\r\n return type.name;\r\n }\r\n\r\n throw new ReflectionError('Either the name or the type name should be provided.');\r\n }\r\n\r\n private static _getFullName(name?: string, namespace?: string, type?: Type<any>): string {\r\n name = TypeInfo._getName(name, type);\r\n namespace = TypeInfo._getNamespace(namespace, type);\r\n return namespace ? `${namespace}.${name}` : name;\r\n }\r\n\r\n private static _getNamespace(namespace?: string, type?: Type<any>): string | undefined {\r\n return namespace || (type ? Serializable.getTypeNamespace(type) : undefined);\r\n }\r\n}\r\n","export { DisplayInfo } from './lib/displayInfo';\nexport { ITypeInfoRegistry, IElementInfo, IValueElementInfo, IPropertyInfo, ITypeInfo } from './lib/interfaces';\nexport { ReflectionError } from './lib/reflectionError';\nexport { ElementInfo } from './lib/elementInfo';\nexport { ValueElementInfo } from './lib/valueElementInfo';\nexport { PropertyInfo } from './lib/propertyInfo';\nexport { TypeName } from './lib/typeName';\nexport { TypeInfo } from './lib/typeInfo';\nexport { TypeInfoRegistry } from './lib/typeInfoRegistry';\n\nimport { TypeInfoRegistry } from './lib/typeInfoRegistry';\nimport { TypeInfo } from './lib/typeInfo';\nimport { TypeName } from './lib/typeName';\n\n(TypeInfoRegistry.prototype as any).initialize = (registry: TypeInfoRegistry) => {\n registry.register(\n new TypeInfo({ name: TypeName.AnyTypeName, fullName: 'System.Object', defaultValue: null, registry }),\n new TypeInfo({ name: TypeName.BooleanTypeName, fullName: 'System.Boolean', defaultValue: false, registry }),\n new TypeInfo({ name: TypeName.NumberTypeName, fullName: 'System.Double', defaultValue: 0.0, registry }),\n new TypeInfo({ name: TypeName.StringTypeName, fullName: 'System.String', defaultValue: null, registry }),\n new TypeInfo({ name: TypeName.ArrayTypeName, fullName: 'System.Array', defaultValue: null, registry }),\n new TypeInfo({ name: TypeName.ArrayOfAnyTypeName, fullName: 'System.Array`1[[System.Object]]', defaultValue: null, registry }),\n new TypeInfo({ name: TypeName.ArrayOfByteTypeName, fullName: 'System.Array`1[[System.Byte]]', defaultValue: null, registry }),\n new TypeInfo({ name: TypeName.SymbolTypeName, fullName: 'System.Symbol', defaultValue: null, registry }),\n new TypeInfo({ name: TypeName.DateTypeName, fullName: 'System.DateTime', defaultValue: null, registry }));\n}\n\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public-api';\n"],"names":[],"mappings":";;;AAAA;;;;;;MAMa,WAAW;;;ACNxB;;;;;;;MAOa,eAAgB,SAAQ,KAAK;;;;;;IAMtC,YAAY,OAAe;QACvB,KAAK,CAAC,OAAO,CAAC,CAAC;KAClB;;;ACXL;;;;;;MAMsB,WAAW;;;;;;;;;;IAiC7B,YACI,EACI,IAAI,EACJ,QAAQ,EACR,WAAW,EACX,QAAQ,EACR,GAAG,IAAI,EAOV;;;;;;;QAvCI,SAAI,GAAW,EAAE,CAAC;QAwCvB,IAAI,CAAC,IAAI,EAAE;YACP,MAAM,IAAI,eAAe,CAAC,4BAA4B,CAAC,CAAC;SAC3D;QAED,IAAI,CAAC,IAAI,GAAG,IAAI,CAAC;QACjB,IAAI,CAAC,QAAQ,GAAG,QAAQ,IAAI,IAAI,CAAC,IAAI,CAAC;QACtC,IAAI,CAAC,WAAW,GAAG,WAAW,IAAI,IAAI,WAAW,EAAE,CAAC;QACpD,MAAM,CAAC,MAAM,CAAC,IAAI,EAAE,IAAI,CAAC,CAAC;KAC7B;;;ACjEL;;;;;;MAMa,QAAQ;;AACjB;;;;;;AAMgB,oBAAW,GAAG,KAAK,CAAC;AAEpC;;;;;;AAMgB,wBAAe,GAAG,SAAS,CAAC;AAE5C;;;;;;AAMgB,uBAAc,GAAG,QAAQ,CAAC;AAE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