{"version":3,"file":"typescript-package-core.mjs","sources":["../../../package/core/src/lib/result-callback.func.ts","../../../package/core/src/lib/type-of.func.ts","../../../package/core/src/lib/value.class.ts","../../../package/core/src/lib/index.ts","../../../package/core/src/public-api.ts","../../../package/core/src/typescript-package-core.ts"],"sourcesContent":["/**\n * @description Default function to handle `callback` of functions.\n * @param {boolean} result - A value of `boolean` type of the result of the check.\n * @returns {boolean} The returned value is a `boolean` of the result of the check.\n */\nexport const resultCallback = (result: boolean): boolean => result;\n","/**\n * @description Gets the specific object class type of any value.\n * @param {*} value Any value to check its object class type.\n * @returns {string} The return value is a `string` of the object class name.\n * @author https://javascript.plainenglish.io/the-best-way-to-type-check-in-vanilla-js-55197b4f45ec\n */\nexport const typeOf = (value: any): string => \n  Object.prototype.toString.call(value).slice(8, -1);\n","/**\n * @description The class to manage the value of generic type variable `Type`.\n * @export\n * @abstract\n * @class Value\n * @template Type The type of the privately stored `#value`.\n */\n\nexport abstract class Value<Type> {\n  /**\n   * @description Returns the `string` tag representation of the `Value` class when used in `Object.prototype.toString.call(instance)`.\n   * The `tag` getter returns the actual class name defined with the `Symbol.toStringTag()` of the child class.\n   * @public\n   * @readonly\n   * @type {string}\n   */\n  public get [Symbol.toStringTag]() {\n    return 'Value';\n  }\n\n  /**\n   * @description Returns the string tag of the current instance defined by the `Symbol.toStringTag`.\n   * @public\n   * @returns {string | undefined} The extracted class name, such as `'Value'`, or `undefined` if extraction fails.\n   */\n  public get tag(): string | undefined {\n    const tag = Object.prototype.toString.call(this).slice(8, -1);\n    return tag !== 'Object' ? tag : undefined;\n  }\n\n  /**\n   * @description Returns the privately stored value of generic type variable `Type`.\n   * @public\n   * @readonly\n   * @type {Type}\n   */\n  public get value() {\n    return this.#value;\n  }\n\n  /**\n   * @description Privately stored value of generic type variable `Type`.\n   * @type {Type}\n   */\n  #value: Type;\n\n  /**\n   * Creates an instance of child class.\n   * @constructor\n   * @param {Type} value The value of generic type variable `Type`.\n   */\n  constructor(value: Type) {\n    this.#value = value;\n  }\n\n  /**\n   * @description Sets the value of generic type variable `Type`.\n   * @protected\n   * @returns {this} \n   */\n  protected setValue(value: Type) {\n    this.#value = value;\n    return this;\n  }\n}\n","// Function.\nexport { resultCallback } from './result-callback.func';\nexport { typeOf } from './type-of.func';\nexport { Value } from './value.class';","/*\n * Public API Surface of core\n */\nexport * from './lib';","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public-api';\n"],"names":[],"mappings":"AAAA;;;;AAIG;AACU,MAAA,cAAc,GAAG,CAAC,MAAe,KAAc;;ACL5D;;;;;AAKG;AACU,MAAA,MAAM,GAAG,CAAC,KAAU,KAC/B,MAAM,CAAC,SAAS,CAAC,QAAQ,CAAC,IAAI,CAAC,KAAK,CAAC,CAAC,KAAK,CAAC,CAAC,EAAE,CAAC,CAAC;;ACPnD;;;;;;AAMG;MAEmB,KAAK,CAAA;AACzB;;;;;;AAMG;AACH,IAAA,KAAY,MAAM,CAAC,WAAW,CAAC,GAAA;AAC7B,QAAA,OAAO,OAAO;;AAGhB;;;;AAIG;AACH,IAAA,IAAW,GAAG,GAAA;QACZ,MAAM,GAAG,GAAG,MAAM,CAAC,SAAS,CAAC,QAAQ,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC,KAAK,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC;QAC7D,OAAO,GAAG,KAAK,QAAQ,GAAG,GAAG,GAAG,SAAS;;AAG3C;;;;;AAKG;AACH,IAAA,IAAW,KAAK,GAAA;QACd,OAAO,IAAI,CAAC,MAAM;;AAGpB;;;AAGG;AACH,IAAA,MAAM;AAEN;;;;AAIG;AACH,IAAA,WAAA,CAAY,KAAW,EAAA;AACrB,QAAA,IAAI,CAAC,MAAM,GAAG,KAAK;;AAGrB;;;;AAIG;AACO,IAAA,QAAQ,CAAC,KAAW,EAAA;AAC5B,QAAA,IAAI,CAAC,MAAM,GAAG,KAAK;AACnB,QAAA,OAAO,IAAI;;AAEd;;AChED;;ACAA;;AAEG;;ACFH;;AAEG;;;;"}