typia 9.7.1 → 10.0.0-dev.20251107

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (424) hide show
  1. package/LICENSE +21 -21
  2. package/README.md +153 -153
  3. package/lib/AssertionGuard.d.mts +27 -25
  4. package/lib/AssertionGuard.d.ts +27 -25
  5. package/lib/CamelCase.d.mts +1 -1
  6. package/lib/CamelCase.d.ts +1 -1
  7. package/lib/IRandomGenerator.d.mts +44 -42
  8. package/lib/IRandomGenerator.d.ts +44 -42
  9. package/lib/IReadableURLSearchParams.d.mts +2 -2
  10. package/lib/IReadableURLSearchParams.d.ts +2 -2
  11. package/lib/PascalCase.d.mts +1 -1
  12. package/lib/PascalCase.d.ts +1 -1
  13. package/lib/Primitive.d.mts +20 -22
  14. package/lib/Primitive.d.ts +20 -22
  15. package/lib/Resolved.d.mts +16 -18
  16. package/lib/Resolved.d.ts +16 -18
  17. package/lib/SnakeCase.d.mts +3 -2
  18. package/lib/SnakeCase.d.ts +3 -2
  19. package/lib/TypeGuardError.d.mts +88 -61
  20. package/lib/TypeGuardError.d.ts +88 -61
  21. package/lib/TypeGuardError.js +40 -29
  22. package/lib/TypeGuardError.js.map +1 -1
  23. package/lib/TypeGuardError.mjs +70 -48
  24. package/lib/factories/MetadataCollection.js +4 -12
  25. package/lib/factories/MetadataCollection.js.map +1 -1
  26. package/lib/factories/MetadataCollection.mjs +4 -12
  27. package/lib/factories/MetadataCommentTagFactory.js +5 -15
  28. package/lib/factories/MetadataCommentTagFactory.js.map +1 -1
  29. package/lib/factories/MetadataCommentTagFactory.mjs +5 -15
  30. package/lib/factories/MetadataFactory.js +1 -3
  31. package/lib/factories/MetadataFactory.js.map +1 -1
  32. package/lib/factories/MetadataFactory.mjs +1 -3
  33. package/lib/factories/ProtobufFactory.js +2 -4
  34. package/lib/factories/ProtobufFactory.js.map +1 -1
  35. package/lib/factories/ProtobufFactory.mjs +2 -4
  36. package/lib/functional.d.mts +196 -195
  37. package/lib/functional.d.ts +196 -195
  38. package/lib/functional.js +18 -54
  39. package/lib/functional.js.map +1 -1
  40. package/lib/functional.mjs +18 -54
  41. package/lib/http.d.mts +303 -319
  42. package/lib/http.d.ts +303 -319
  43. package/lib/http.js +26 -78
  44. package/lib/http.js.map +1 -1
  45. package/lib/http.mjs +26 -78
  46. package/lib/internal/_ProtobufReader.d.mts +3 -9
  47. package/lib/internal/_ProtobufReader.d.ts +3 -9
  48. package/lib/internal/_ProtobufReader.js.map +1 -1
  49. package/lib/internal/_ProtobufReader.mjs +3 -9
  50. package/lib/internal/_ProtobufSizer.d.mts +4 -12
  51. package/lib/internal/_ProtobufSizer.d.ts +4 -12
  52. package/lib/internal/_ProtobufSizer.js.map +1 -1
  53. package/lib/internal/_ProtobufSizer.mjs +4 -12
  54. package/lib/internal/_ProtobufWriter.d.mts +5 -15
  55. package/lib/internal/_ProtobufWriter.d.ts +5 -15
  56. package/lib/internal/_ProtobufWriter.js.map +1 -1
  57. package/lib/internal/_ProtobufWriter.mjs +5 -15
  58. package/lib/internal/_jsonStringifyString.d.mts +4 -4
  59. package/lib/internal/_jsonStringifyString.d.ts +4 -4
  60. package/lib/internal/_jsonStringifyString.js +4 -4
  61. package/lib/internal/_jsonStringifyString.mjs +4 -4
  62. package/lib/json.d.mts +174 -195
  63. package/lib/json.d.ts +174 -195
  64. package/lib/json.js +16 -48
  65. package/lib/json.js.map +1 -1
  66. package/lib/json.mjs +16 -48
  67. package/lib/llm.d.mts +275 -192
  68. package/lib/llm.d.ts +275 -192
  69. package/lib/llm.js +4 -12
  70. package/lib/llm.js.map +1 -1
  71. package/lib/llm.mjs +4 -12
  72. package/lib/misc.d.mts +149 -172
  73. package/lib/misc.d.ts +149 -172
  74. package/lib/misc.js +17 -51
  75. package/lib/misc.js.map +1 -1
  76. package/lib/misc.mjs +17 -51
  77. package/lib/module.d.mts +263 -275
  78. package/lib/module.d.ts +263 -275
  79. package/lib/module.js +18 -54
  80. package/lib/module.js.map +1 -1
  81. package/lib/module.mjs +18 -54
  82. package/lib/notations.d.mts +153 -174
  83. package/lib/notations.d.ts +153 -174
  84. package/lib/notations.js +24 -72
  85. package/lib/notations.js.map +1 -1
  86. package/lib/notations.mjs +24 -72
  87. package/lib/programmers/FeatureProgrammer.d.mts +19 -41
  88. package/lib/programmers/FeatureProgrammer.d.ts +19 -41
  89. package/lib/programmers/FeatureProgrammer.js.map +1 -1
  90. package/lib/programmers/ImportProgrammer.js +3 -9
  91. package/lib/programmers/ImportProgrammer.js.map +1 -1
  92. package/lib/programmers/ImportProgrammer.mjs +3 -9
  93. package/lib/programmers/RandomProgrammer.js +6 -0
  94. package/lib/programmers/RandomProgrammer.js.map +1 -1
  95. package/lib/programmers/RandomProgrammer.mjs +6 -0
  96. package/lib/programmers/helpers/ProtobufWire.d.mts +13 -13
  97. package/lib/programmers/helpers/ProtobufWire.d.ts +13 -13
  98. package/lib/programmers/internal/check_array_length.js +2 -6
  99. package/lib/programmers/internal/check_array_length.js.map +1 -1
  100. package/lib/programmers/internal/check_array_length.mjs +2 -6
  101. package/lib/programmers/internal/check_bigint.js +2 -6
  102. package/lib/programmers/internal/check_bigint.js.map +1 -1
  103. package/lib/programmers/internal/check_bigint.mjs +2 -6
  104. package/lib/programmers/internal/check_dynamic_key.js +2 -6
  105. package/lib/programmers/internal/check_dynamic_key.js.map +1 -1
  106. package/lib/programmers/internal/check_dynamic_key.mjs +2 -6
  107. package/lib/programmers/internal/check_dynamic_properties.js +3 -9
  108. package/lib/programmers/internal/check_dynamic_properties.js.map +1 -1
  109. package/lib/programmers/internal/check_dynamic_properties.mjs +3 -9
  110. package/lib/programmers/internal/check_everything.js +1 -3
  111. package/lib/programmers/internal/check_everything.js.map +1 -1
  112. package/lib/programmers/internal/check_everything.mjs +1 -3
  113. package/lib/programmers/internal/check_native.js +2 -6
  114. package/lib/programmers/internal/check_native.js.map +1 -1
  115. package/lib/programmers/internal/check_native.mjs +2 -6
  116. package/lib/programmers/internal/check_number.js +2 -6
  117. package/lib/programmers/internal/check_number.js.map +1 -1
  118. package/lib/programmers/internal/check_number.mjs +2 -6
  119. package/lib/programmers/internal/check_object.js +2 -6
  120. package/lib/programmers/internal/check_object.js.map +1 -1
  121. package/lib/programmers/internal/check_object.mjs +2 -6
  122. package/lib/programmers/internal/check_string.js +2 -6
  123. package/lib/programmers/internal/check_string.js.map +1 -1
  124. package/lib/programmers/internal/check_string.mjs +2 -6
  125. package/lib/programmers/internal/check_template.js +1 -3
  126. package/lib/programmers/internal/check_template.js.map +1 -1
  127. package/lib/programmers/internal/check_template.mjs +1 -3
  128. package/lib/programmers/internal/check_union_array_like.js +1 -3
  129. package/lib/programmers/internal/check_union_array_like.js.map +1 -1
  130. package/lib/programmers/internal/check_union_array_like.mjs +1 -3
  131. package/lib/programmers/internal/decode_union_object.js +2 -6
  132. package/lib/programmers/internal/decode_union_object.js.map +1 -1
  133. package/lib/programmers/internal/decode_union_object.mjs +2 -6
  134. package/lib/programmers/internal/feature_object_entries.js +1 -3
  135. package/lib/programmers/internal/feature_object_entries.js.map +1 -1
  136. package/lib/programmers/internal/feature_object_entries.mjs +1 -3
  137. package/lib/programmers/internal/json_schema_escaped.js +2 -6
  138. package/lib/programmers/internal/json_schema_escaped.js.map +1 -1
  139. package/lib/programmers/internal/json_schema_escaped.mjs +2 -6
  140. package/lib/programmers/internal/json_schema_object.js +3 -9
  141. package/lib/programmers/internal/json_schema_object.js.map +1 -1
  142. package/lib/programmers/internal/json_schema_object.mjs +3 -9
  143. package/lib/programmers/internal/json_schema_station.d.mts +2 -2
  144. package/lib/programmers/internal/json_schema_station.d.ts +2 -2
  145. package/lib/programmers/internal/metadata_to_pattern.js +1 -3
  146. package/lib/programmers/internal/metadata_to_pattern.js.map +1 -1
  147. package/lib/programmers/internal/metadata_to_pattern.mjs +1 -3
  148. package/lib/programmers/internal/postfix_of_tuple.js +1 -3
  149. package/lib/programmers/internal/postfix_of_tuple.js.map +1 -1
  150. package/lib/programmers/internal/postfix_of_tuple.mjs +1 -3
  151. package/lib/programmers/internal/prune_object_properties.js +1 -3
  152. package/lib/programmers/internal/prune_object_properties.js.map +1 -1
  153. package/lib/programmers/internal/prune_object_properties.mjs +1 -3
  154. package/lib/programmers/internal/stringify_dynamic_properties.js +2 -6
  155. package/lib/programmers/internal/stringify_dynamic_properties.js.map +1 -1
  156. package/lib/programmers/internal/stringify_dynamic_properties.mjs +2 -6
  157. package/lib/programmers/internal/stringify_native.js +1 -3
  158. package/lib/programmers/internal/stringify_native.js.map +1 -1
  159. package/lib/programmers/internal/stringify_native.mjs +1 -3
  160. package/lib/programmers/internal/stringify_regular_properties.js +2 -6
  161. package/lib/programmers/internal/stringify_regular_properties.js.map +1 -1
  162. package/lib/programmers/internal/stringify_regular_properties.mjs +2 -6
  163. package/lib/programmers/internal/template_to_pattern.js +1 -3
  164. package/lib/programmers/internal/template_to_pattern.js.map +1 -1
  165. package/lib/programmers/internal/template_to_pattern.mjs +1 -3
  166. package/lib/programmers/internal/wrap_metadata_rest_tuple.js +1 -3
  167. package/lib/programmers/internal/wrap_metadata_rest_tuple.js.map +1 -1
  168. package/lib/programmers/internal/wrap_metadata_rest_tuple.mjs +1 -3
  169. package/lib/programmers/json/JsonStringifyProgrammer.js +2 -2
  170. package/lib/programmers/json/JsonStringifyProgrammer.js.map +1 -1
  171. package/lib/programmers/json/JsonStringifyProgrammer.mjs +2 -2
  172. package/lib/programmers/llm/LlmApplicationProgrammer.js +5 -1
  173. package/lib/programmers/llm/LlmApplicationProgrammer.js.map +1 -1
  174. package/lib/programmers/llm/LlmApplicationProgrammer.mjs +5 -1
  175. package/lib/programmers/llm/LlmSchemaProgrammer.js +1 -4
  176. package/lib/programmers/llm/LlmSchemaProgrammer.js.map +1 -1
  177. package/lib/programmers/llm/LlmSchemaProgrammer.mjs +1 -35
  178. package/lib/protobuf.d.mts +290 -297
  179. package/lib/protobuf.d.ts +290 -297
  180. package/lib/protobuf.js +17 -51
  181. package/lib/protobuf.js.map +1 -1
  182. package/lib/protobuf.mjs +17 -51
  183. package/lib/reflect.d.mts +2 -4
  184. package/lib/reflect.d.ts +2 -4
  185. package/lib/reflect.js +1 -3
  186. package/lib/reflect.js.map +1 -1
  187. package/lib/reflect.mjs +1 -3
  188. package/lib/schemas/json/IJsonApplication.d.mts +4 -4
  189. package/lib/schemas/json/IJsonApplication.d.ts +4 -4
  190. package/lib/schemas/json/IJsonSchemaCollection.d.mts +73 -56
  191. package/lib/schemas/json/IJsonSchemaCollection.d.ts +73 -56
  192. package/lib/schemas/json/IJsonSchemaUnit.d.mts +83 -70
  193. package/lib/schemas/json/IJsonSchemaUnit.d.ts +83 -70
  194. package/lib/schemas/metadata/Metadata.d.mts +1 -3
  195. package/lib/schemas/metadata/Metadata.d.ts +1 -3
  196. package/lib/schemas/metadata/Metadata.js +9 -27
  197. package/lib/schemas/metadata/Metadata.js.map +1 -1
  198. package/lib/schemas/metadata/Metadata.mjs +9 -27
  199. package/lib/schemas/metadata/MetadataAliasType.d.mts +1 -3
  200. package/lib/schemas/metadata/MetadataAliasType.d.ts +1 -3
  201. package/lib/schemas/metadata/MetadataAliasType.js +3 -9
  202. package/lib/schemas/metadata/MetadataAliasType.js.map +1 -1
  203. package/lib/schemas/metadata/MetadataAliasType.mjs +3 -9
  204. package/lib/schemas/metadata/MetadataApplication.d.mts +1 -3
  205. package/lib/schemas/metadata/MetadataApplication.d.ts +1 -3
  206. package/lib/schemas/metadata/MetadataApplication.js +2 -6
  207. package/lib/schemas/metadata/MetadataApplication.js.map +1 -1
  208. package/lib/schemas/metadata/MetadataApplication.mjs +2 -6
  209. package/lib/schemas/metadata/MetadataArray.d.mts +1 -3
  210. package/lib/schemas/metadata/MetadataArray.d.ts +1 -3
  211. package/lib/schemas/metadata/MetadataArray.js +1 -3
  212. package/lib/schemas/metadata/MetadataArray.js.map +1 -1
  213. package/lib/schemas/metadata/MetadataArray.mjs +1 -3
  214. package/lib/schemas/metadata/MetadataArrayType.d.mts +1 -3
  215. package/lib/schemas/metadata/MetadataArrayType.d.ts +1 -3
  216. package/lib/schemas/metadata/MetadataArrayType.js +3 -9
  217. package/lib/schemas/metadata/MetadataArrayType.js.map +1 -1
  218. package/lib/schemas/metadata/MetadataArrayType.mjs +3 -9
  219. package/lib/schemas/metadata/MetadataAtomic.js +1 -3
  220. package/lib/schemas/metadata/MetadataAtomic.js.map +1 -1
  221. package/lib/schemas/metadata/MetadataAtomic.mjs +1 -3
  222. package/lib/schemas/metadata/MetadataEscaped.d.mts +1 -3
  223. package/lib/schemas/metadata/MetadataEscaped.d.ts +1 -3
  224. package/lib/schemas/metadata/MetadataEscaped.js +3 -9
  225. package/lib/schemas/metadata/MetadataEscaped.js.map +1 -1
  226. package/lib/schemas/metadata/MetadataEscaped.mjs +3 -9
  227. package/lib/schemas/metadata/MetadataFunction.d.mts +1 -3
  228. package/lib/schemas/metadata/MetadataFunction.d.ts +1 -3
  229. package/lib/schemas/metadata/MetadataFunction.js +2 -6
  230. package/lib/schemas/metadata/MetadataFunction.js.map +1 -1
  231. package/lib/schemas/metadata/MetadataFunction.mjs +2 -6
  232. package/lib/schemas/metadata/MetadataObject.d.mts +1 -3
  233. package/lib/schemas/metadata/MetadataObject.d.ts +1 -3
  234. package/lib/schemas/metadata/MetadataObject.js +1 -3
  235. package/lib/schemas/metadata/MetadataObject.js.map +1 -1
  236. package/lib/schemas/metadata/MetadataObject.mjs +1 -3
  237. package/lib/schemas/metadata/MetadataObjectType.d.mts +1 -3
  238. package/lib/schemas/metadata/MetadataObjectType.d.ts +1 -3
  239. package/lib/schemas/metadata/MetadataObjectType.js +5 -15
  240. package/lib/schemas/metadata/MetadataObjectType.js.map +1 -1
  241. package/lib/schemas/metadata/MetadataObjectType.mjs +6 -18
  242. package/lib/schemas/metadata/MetadataParameter.js +1 -3
  243. package/lib/schemas/metadata/MetadataParameter.js.map +1 -1
  244. package/lib/schemas/metadata/MetadataParameter.mjs +1 -3
  245. package/lib/schemas/metadata/MetadataProperty.d.mts +1 -3
  246. package/lib/schemas/metadata/MetadataProperty.d.ts +1 -3
  247. package/lib/schemas/metadata/MetadataProperty.js +3 -9
  248. package/lib/schemas/metadata/MetadataProperty.js.map +1 -1
  249. package/lib/schemas/metadata/MetadataProperty.mjs +3 -9
  250. package/lib/schemas/metadata/MetadataTemplate.js +1 -3
  251. package/lib/schemas/metadata/MetadataTemplate.js.map +1 -1
  252. package/lib/schemas/metadata/MetadataTemplate.mjs +1 -3
  253. package/lib/schemas/metadata/MetadataTuple.d.mts +1 -3
  254. package/lib/schemas/metadata/MetadataTuple.d.ts +1 -3
  255. package/lib/schemas/metadata/MetadataTuple.js +2 -6
  256. package/lib/schemas/metadata/MetadataTuple.js.map +1 -1
  257. package/lib/schemas/metadata/MetadataTuple.mjs +2 -6
  258. package/lib/schemas/metadata/MetadataTupleType.js +2 -6
  259. package/lib/schemas/metadata/MetadataTupleType.js.map +1 -1
  260. package/lib/schemas/metadata/MetadataTupleType.mjs +3 -9
  261. package/lib/tags/Constant.d.mts +16 -16
  262. package/lib/tags/Constant.d.ts +16 -16
  263. package/lib/tags/ContentMediaType.d.mts +7 -7
  264. package/lib/tags/ContentMediaType.d.ts +7 -7
  265. package/lib/tags/Default.d.mts +19 -19
  266. package/lib/tags/Default.d.ts +19 -19
  267. package/lib/tags/Example.d.mts +18 -18
  268. package/lib/tags/Example.d.ts +18 -18
  269. package/lib/tags/Examples.d.mts +23 -23
  270. package/lib/tags/Examples.d.ts +23 -23
  271. package/lib/tags/ExclusiveMaximum.d.mts +8 -5
  272. package/lib/tags/ExclusiveMaximum.d.ts +8 -5
  273. package/lib/tags/ExclusiveMinimum.d.mts +8 -5
  274. package/lib/tags/ExclusiveMinimum.d.ts +8 -5
  275. package/lib/tags/Format.d.mts +12 -8
  276. package/lib/tags/Format.d.ts +12 -8
  277. package/lib/tags/JsonSchemaPlugin.d.mts +20 -18
  278. package/lib/tags/JsonSchemaPlugin.d.ts +20 -18
  279. package/lib/tags/MaxItems.d.mts +9 -9
  280. package/lib/tags/MaxItems.d.ts +9 -9
  281. package/lib/tags/MaxLength.d.mts +6 -5
  282. package/lib/tags/MaxLength.d.ts +6 -5
  283. package/lib/tags/Maximum.d.mts +9 -7
  284. package/lib/tags/Maximum.d.ts +9 -7
  285. package/lib/tags/MinItems.d.mts +9 -9
  286. package/lib/tags/MinItems.d.ts +9 -9
  287. package/lib/tags/MinLength.d.mts +6 -5
  288. package/lib/tags/MinLength.d.ts +6 -5
  289. package/lib/tags/Minimum.d.mts +9 -7
  290. package/lib/tags/Minimum.d.ts +9 -7
  291. package/lib/tags/MultipleOf.d.mts +10 -7
  292. package/lib/tags/MultipleOf.d.ts +10 -7
  293. package/lib/tags/Pattern.d.mts +7 -4
  294. package/lib/tags/Pattern.d.ts +7 -4
  295. package/lib/tags/Sequence.d.mts +19 -17
  296. package/lib/tags/Sequence.d.ts +19 -17
  297. package/lib/tags/TagBase.d.mts +21 -28
  298. package/lib/tags/TagBase.d.ts +21 -28
  299. package/lib/tags/Type.d.mts +12 -11
  300. package/lib/tags/Type.d.ts +12 -11
  301. package/lib/tags/UniqueItems.d.mts +10 -9
  302. package/lib/tags/UniqueItems.d.ts +10 -9
  303. package/lib/tags/internal/FormatCheatSheet.d.mts +1 -3
  304. package/lib/tags/internal/FormatCheatSheet.d.ts +1 -3
  305. package/lib/tags/internal/FormatCheatSheet.js +1 -3
  306. package/lib/tags/internal/FormatCheatSheet.js.map +1 -1
  307. package/lib/tags/internal/FormatCheatSheet.mjs +1 -3
  308. package/lib/transformers/ITransformOptions.d.mts +27 -19
  309. package/lib/transformers/ITransformOptions.d.ts +27 -19
  310. package/lib/transformers/ImportTransformer.js +5 -10
  311. package/lib/transformers/ImportTransformer.js.map +1 -1
  312. package/lib/transformers/ImportTransformer.mjs +5 -10
  313. package/lib/transformers/NoTransformConfigurationError.js +1 -3
  314. package/lib/transformers/NoTransformConfigurationError.js.map +1 -1
  315. package/lib/transformers/NoTransformConfigurationError.mjs +1 -3
  316. package/lib/transformers/features/llm/LlmApplicationTransformer.js +1 -3
  317. package/lib/transformers/features/llm/LlmApplicationTransformer.js.map +1 -1
  318. package/lib/transformers/features/llm/LlmApplicationTransformer.mjs +1 -3
  319. package/lib/typings/Equal.d.mts +6 -6
  320. package/lib/typings/Equal.d.ts +6 -6
  321. package/package.json +121 -120
  322. package/src/AssertionGuard.ts +41 -39
  323. package/src/CamelCase.ts +75 -75
  324. package/src/IRandomGenerator.ts +337 -335
  325. package/src/IReadableURLSearchParams.ts +9 -9
  326. package/src/PascalCase.ts +71 -71
  327. package/src/Primitive.ts +90 -92
  328. package/src/Resolved.ts +72 -74
  329. package/src/SnakeCase.ts +127 -126
  330. package/src/TypeGuardError.ts +216 -179
  331. package/src/factories/MetadataCollection.ts +270 -278
  332. package/src/factories/MetadataCommentTagFactory.ts +632 -648
  333. package/src/factories/MetadataFactory.ts +402 -404
  334. package/src/factories/ProtobufFactory.ts +873 -875
  335. package/src/functional.ts +705 -740
  336. package/src/http.ts +972 -1040
  337. package/src/internal/_ProtobufReader.ts +188 -194
  338. package/src/internal/_ProtobufSizer.ts +137 -145
  339. package/src/internal/_ProtobufWriter.ts +135 -145
  340. package/src/internal/_jsonStringifyString.ts +42 -42
  341. package/src/json.ts +643 -696
  342. package/src/llm.ts +615 -540
  343. package/src/misc.ts +594 -651
  344. package/src/module.ts +889 -937
  345. package/src/notations.ts +751 -820
  346. package/src/programmers/FeatureProgrammer.ts +605 -627
  347. package/src/programmers/ImportProgrammer.ts +179 -185
  348. package/src/programmers/RandomProgrammer.ts +1195 -1190
  349. package/src/programmers/helpers/ProtobufWire.ts +34 -34
  350. package/src/programmers/internal/check_array_length.ts +43 -47
  351. package/src/programmers/internal/check_bigint.ts +46 -50
  352. package/src/programmers/internal/check_dynamic_key.ts +197 -201
  353. package/src/programmers/internal/check_dynamic_properties.ts +231 -237
  354. package/src/programmers/internal/check_everything.ts +21 -23
  355. package/src/programmers/internal/check_native.ts +23 -27
  356. package/src/programmers/internal/check_number.ts +108 -112
  357. package/src/programmers/internal/check_object.ts +72 -78
  358. package/src/programmers/internal/check_string.ts +46 -50
  359. package/src/programmers/internal/check_template.ts +46 -48
  360. package/src/programmers/internal/check_union_array_like.ts +331 -335
  361. package/src/programmers/internal/decode_union_object.ts +110 -116
  362. package/src/programmers/internal/feature_object_entries.ts +59 -61
  363. package/src/programmers/internal/json_schema_escaped.ts +78 -82
  364. package/src/programmers/internal/json_schema_object.ts +150 -158
  365. package/src/programmers/internal/json_schema_station.ts +2 -2
  366. package/src/programmers/internal/metadata_to_pattern.ts +40 -42
  367. package/src/programmers/internal/postfix_of_tuple.ts +3 -5
  368. package/src/programmers/internal/prune_object_properties.ts +69 -71
  369. package/src/programmers/internal/stringify_dynamic_properties.ts +158 -162
  370. package/src/programmers/internal/stringify_native.ts +5 -7
  371. package/src/programmers/internal/stringify_regular_properties.ts +77 -81
  372. package/src/programmers/internal/template_to_pattern.ts +21 -23
  373. package/src/programmers/internal/wrap_metadata_rest_tuple.ts +21 -23
  374. package/src/programmers/json/JsonStringifyProgrammer.ts +1124 -1124
  375. package/src/programmers/llm/LlmApplicationProgrammer.ts +10 -1
  376. package/src/programmers/llm/LlmSchemaProgrammer.ts +2 -7
  377. package/src/protobuf.ts +820 -861
  378. package/src/reflect.ts +46 -50
  379. package/src/schemas/json/IJsonApplication.ts +77 -77
  380. package/src/schemas/json/IJsonSchemaCollection.ts +212 -195
  381. package/src/schemas/json/IJsonSchemaUnit.ts +263 -250
  382. package/src/schemas/metadata/IMetadataTypeTag.ts +14 -16
  383. package/src/schemas/metadata/Metadata.ts +669 -687
  384. package/src/schemas/metadata/MetadataAliasType.ts +57 -63
  385. package/src/schemas/metadata/MetadataApplication.ts +40 -44
  386. package/src/schemas/metadata/MetadataArray.ts +47 -49
  387. package/src/schemas/metadata/MetadataArrayType.ts +51 -57
  388. package/src/schemas/metadata/MetadataAtomic.ts +85 -87
  389. package/src/schemas/metadata/MetadataEscaped.ts +45 -51
  390. package/src/schemas/metadata/MetadataFunction.ts +45 -49
  391. package/src/schemas/metadata/MetadataObject.ts +46 -48
  392. package/src/schemas/metadata/MetadataObjectType.ts +137 -149
  393. package/src/schemas/metadata/MetadataParameter.ts +52 -54
  394. package/src/schemas/metadata/MetadataProperty.ts +53 -59
  395. package/src/schemas/metadata/MetadataTemplate.ts +78 -80
  396. package/src/schemas/metadata/MetadataTuple.ts +28 -32
  397. package/src/schemas/metadata/MetadataTupleType.ts +61 -67
  398. package/src/tags/Constant.ts +47 -47
  399. package/src/tags/ContentMediaType.ts +27 -27
  400. package/src/tags/Default.ts +52 -52
  401. package/src/tags/Example.ts +56 -56
  402. package/src/tags/Examples.ts +56 -56
  403. package/src/tags/ExclusiveMaximum.ts +44 -41
  404. package/src/tags/ExclusiveMinimum.ts +44 -41
  405. package/src/tags/Format.ts +78 -74
  406. package/src/tags/JsonSchemaPlugin.ts +36 -34
  407. package/src/tags/MaxItems.ts +31 -31
  408. package/src/tags/MaxLength.ts +25 -24
  409. package/src/tags/Maximum.ts +39 -37
  410. package/src/tags/MinItems.ts +31 -31
  411. package/src/tags/MinLength.ts +25 -24
  412. package/src/tags/Minimum.ts +39 -37
  413. package/src/tags/MultipleOf.ts +42 -39
  414. package/src/tags/Pattern.ts +49 -46
  415. package/src/tags/Sequence.ts +37 -35
  416. package/src/tags/TagBase.ts +102 -109
  417. package/src/tags/Type.ts +64 -63
  418. package/src/tags/UniqueItems.ts +34 -33
  419. package/src/tags/internal/FormatCheatSheet.ts +71 -73
  420. package/src/transformers/ITransformOptions.ts +70 -62
  421. package/src/transformers/ImportTransformer.ts +253 -258
  422. package/src/transformers/NoTransformConfigurationError.ts +16 -18
  423. package/src/transformers/features/llm/LlmApplicationTransformer.ts +224 -226
  424. package/src/typings/Equal.ts +18 -18
package/src/notations.ts CHANGED
@@ -1,820 +1,751 @@
1
- import { NoTransformConfigurationError } from "./transformers/NoTransformConfigurationError";
2
-
3
- import { CamelCase } from "./CamelCase";
4
- import { IValidation } from "./IValidation";
5
- import { PascalCase } from "./PascalCase";
6
- import { SnakeCase } from "./SnakeCase";
7
- import { TypeGuardError } from "./TypeGuardError";
8
-
9
- /* ===========================================================
10
- NOTATIONS (NAMING CONVENTIONS)
11
- - CAMEL CASE
12
- - PASCAL CASE
13
- - SNAKE CASE
14
- - FACTORY FUNCTIONS
15
- ==============================================================
16
- CAMEL CASE
17
- ----------------------------------------------------------- */
18
- /**
19
- * Convert to camel case.
20
- *
21
- * Convert every property names of nested objects to follow the camel case convention.
22
- *
23
- * For reference, this `typia.notations.camel()` function does not validate the input value
24
- * type. It just believes that the input value is following the type `T`. Therefore,
25
- * if you can't ensure the input value type, it would be better to call one of them below:
26
- *
27
- * - {@link assertCamel}
28
- * - {@link isCamel}
29
- * - {@link validateCamel}
30
- *
31
- * @template T Type of the input value
32
- * @param input Target object
33
- * @returns Camel case object
34
- *
35
- * @author Jeongho Nam - https://github.com/samchon
36
- */
37
- export function camel<T>(input: T): CamelCase<T>;
38
-
39
- /**
40
- * @internal
41
- */
42
- export function camel(): never {
43
- return NoTransformConfigurationError("notations.camel");
44
- }
45
-
46
- /**
47
- * Converts to camel case with type assertion.
48
- *
49
- * Convert every property names of nested objects to follow the camel case convention.
50
- * If the input value does not follow the type `T`, it throws {@link TypeGuardError}.
51
- *
52
- * @template T Type of the input value
53
- * @param input Target object
54
- * @param errorFactory Custom error factory. Default is `TypeGuardError`
55
- * @returns Camel case object
56
- *
57
- * @author Jeongho Nam - https://github.com/samchon
58
- */
59
- export function assertCamel<T>(
60
- input: T,
61
- errorFactory?: undefined | ((props: TypeGuardError.IProps) => Error),
62
- ): CamelCase<T>;
63
-
64
- /**
65
- * Converts to camel case with type assertion.
66
- *
67
- * Convert every property names of nested objects to follow the camel case convention.
68
- * If the input value does not follow the type `T`, it throws {@link TypeGuardError}.
69
- *
70
- * @template T Type of the input value
71
- * @param input Target object
72
- * @param errorFactory Custom error factory. Default is `TypeGuardError`
73
- * @returns Camel case object
74
- *
75
- * @author Jeongho Nam - https://github.com/samchon
76
- */
77
- export function assertCamel<T>(
78
- input: unknown,
79
- errorFactory?: undefined | ((props: TypeGuardError.IProps) => Error),
80
- ): CamelCase<T>;
81
-
82
- /**
83
- * @internal
84
- */
85
- export function assertCamel(): never {
86
- return NoTransformConfigurationError("notations.assertCamel");
87
- }
88
-
89
- /**
90
- * Converts to camel case with type checking.
91
- *
92
- * Convert every property names of nested objects to follow the camel case convention.
93
- * If the input value does not follow the type `T`, it returns `null` value instead.
94
- *
95
- * @template T Type of the input value
96
- * @param input Target object
97
- * @returns Camel case object when exact type, otherwise null
98
- *
99
- * @author Jeongho Nam - https://github.com/samchon
100
- */
101
- export function isCamel<T>(input: T): CamelCase<T> | null;
102
-
103
- /**
104
- * Converts to camel case with type checking.
105
- *
106
- * Convert every property names of nested objects to follow the camel case convention.
107
- * If the input value does not follow the type `T`, it returns `null` value instead.
108
- *
109
- * @template T Type of the input value
110
- * @param input Target object
111
- * @returns Camel case object when exact type, otherwise null
112
- *
113
- * @author Jeongho Nam - https://github.com/samchon
114
- */
115
- export function isCamel<T>(input: unknown): CamelCase<T> | null;
116
-
117
- /**
118
- * @internal
119
- */
120
- export function isCamel(): never {
121
- return NoTransformConfigurationError("notations.isCamel");
122
- }
123
-
124
- /**
125
- * Converts to camel case with type validation.
126
- *
127
- * Convert every property names of nested objects to follow the camel case convention.
128
- * If the input value does not follow the type `T`, it returns {@link IValidation.Failure}
129
- * object. Otherwise, there's no problem on the input value, camel cased converted data
130
- * would be stored in the `data` property of the output {@link IValidation.Success} object.
131
- *
132
- * @template T Type of the input value
133
- * @param input Target object
134
- * @returns Validation result with camel case object
135
- *
136
- * @author Jeongho Nam - https://github.com/samchon
137
- */
138
- export function validateCamel<T>(input: T): IValidation<CamelCase<T>>;
139
-
140
- /**
141
- * Converts to camel case with type validation.
142
- *
143
- * Convert every property names of nested objects to follow the camel case convention.
144
- * If the input value does not follow the type `T`, it returns {@link IValidation.Failure}
145
- * object. Otherwise, there's no problem on the input value, camel cased converted data
146
- * would be stored in the `data` property of the output {@link IValidation.Success} object.
147
- *
148
- * @template T Type of the input value
149
- * @param input Target object
150
- * @returns Validation result with camel case object
151
- *
152
- * @author Jeongho Nam - https://github.com/samchon
153
- */
154
- export function validateCamel<T>(input: unknown): IValidation<CamelCase<T>>;
155
-
156
- /**
157
- * @internal
158
- */
159
- export function validateCamel(): never {
160
- return NoTransformConfigurationError("notations.validateCamel");
161
- }
162
-
163
- /* -----------------------------------------------------------
164
- PASCAL CASE
165
- ----------------------------------------------------------- */
166
- /**
167
- * Convert to pascal case.
168
- *
169
- * Convert every property names of nested objects to follow the pascal case convention.
170
- *
171
- * For reference, this `typia.notations.pascal()` function does not validate the input value
172
- * type. It just believes that the input value is following the type `T`. Therefore,
173
- * if you can't ensure the input value type, it would be better to call one of them below:
174
- *
175
- * - {@link assertPascal}
176
- * - {@link isPascal}
177
- * - {@link validatePascal}
178
- *
179
- * @template T Type of the input value
180
- * @param input Target object
181
- * @returns Pascal case object
182
- *
183
- * @author Jeongho Nam - https://github.com/samchon
184
- */
185
- export function pascal<T>(input: T): PascalCase<T>;
186
-
187
- /**
188
- * @internal
189
- */
190
- export function pascal(): never {
191
- return NoTransformConfigurationError("notations.pascal");
192
- }
193
-
194
- /**
195
- * Converts to pascal case with type assertion.
196
- *
197
- * Convert every property names of nested objects to follow the pascal case convention.
198
- * If the input value does not follow the type `T`, it throws {@link TypeGuardError}.
199
- *
200
- * @template T Type of the input value
201
- * @param input Target object
202
- * @param errorFactory Custom error factory. Default is `TypeGuardError`
203
- * @returns Pascal case object
204
- *
205
- * @author Jeongho Nam - https://github.com/samchon
206
- */
207
- export function assertPascal<T>(
208
- input: T,
209
- errorFactory?: undefined | ((props: TypeGuardError.IProps) => Error),
210
- ): PascalCase<T>;
211
-
212
- /**
213
- * Converts to pascal case with type assertion.
214
- *
215
- * Convert every property names of nested objects to follow the pascal case convention.
216
- * If the input value does not follow the type `T`, it throws {@link TypeGuardError}.
217
- *
218
- * @template T Type of the input value
219
- * @param input Target object
220
- * @param errorFactory Custom error factory. Default is `TypeGuardError`
221
- * @returns Pascal case object
222
- *
223
- * @author Jeongho Nam - https://github.com/samchon
224
- */
225
- export function assertPascal<T>(
226
- input: unknown,
227
- errorFactory?: undefined | ((props: TypeGuardError.IProps) => Error),
228
- ): PascalCase<T>;
229
-
230
- /**
231
- * @internal
232
- */
233
- export function assertPascal(): never {
234
- return NoTransformConfigurationError("notations.assertPascal");
235
- }
236
-
237
- /**
238
- * Converts to pascal case with type checking.
239
- *
240
- * Convert every property names of nested objects to follow the pascal case convention.
241
- * If the input value does not follow the type `T`, it returns `null` value instead.
242
- *
243
- * @template T Type of the input value
244
- * @param input Target object
245
- * @returns Pascal case object when exact type, otherwise null
246
- *
247
- * @author Jeongho Nam - https://github.com/samchon
248
- */
249
- export function isPascal<T>(input: T): PascalCase<T> | null;
250
-
251
- /**
252
- * Converts to pascal case with type checking.
253
- *
254
- * Convert every property names of nested objects to follow the pascal case convention.
255
- * If the input value does not follow the type `T`, it returns `null` value instead.
256
- *
257
- * @template T Type of the input value
258
- * @param input Target object
259
- * @returns Pascal case object when exact type, otherwise null
260
- *
261
- * @author Jeongho Nam - https://github.com/samchon
262
- */
263
- export function isPascal<T>(input: unknown): PascalCase<T> | null;
264
-
265
- /**
266
- * @internal
267
- */
268
- export function isPascal(): never {
269
- return NoTransformConfigurationError("notations.isPascal");
270
- }
271
-
272
- /**
273
- * Converts to pascal case with type validation.
274
- *
275
- * Convert every property names of nested objects to follow the pascal case convention.
276
- * If the input value does not follow the type `T`, it returns {@link IValidation.Failure}
277
- * object. Otherwise, there's no problem on the input value, pascal cased converted data
278
- * would be stored in the `data` property of the output {@link IValidation.Success} object.
279
- *
280
- * @template T Type of the input value
281
- * @param input Target object
282
- * @returns Validation result with pascal case object
283
- *
284
- * @author Jeongho Nam - https://github.com/samchon
285
- */
286
- export function validatePascal<T>(input: T): IValidation<PascalCase<T>>;
287
-
288
- /**
289
- * Converts to pascal case with type validation.
290
- *
291
- * Convert every property names of nested objects to follow the pascal case convention.
292
- * If the input value does not follow the type `T`, it returns {@link IValidation.Failure}
293
- * object. Otherwise, there's no problem on the input value, pascal cased converted data
294
- * would be stored in the `data` property of the output {@link IValidation.Success} object.
295
- *
296
- * @template T Type of the input value
297
- * @param input Target object
298
- * @returns Validation result with pascal case object
299
- *
300
- * @author Jeongho Nam - https://github.com/samchon
301
- */
302
- export function validatePascal<T>(input: unknown): IValidation<PascalCase<T>>;
303
-
304
- /**
305
- * @internal
306
- */
307
- export function validatePascal(): never {
308
- return NoTransformConfigurationError("notations.validatePascal");
309
- }
310
-
311
- /* -----------------------------------------------------------
312
- SNAKE CASE
313
- ----------------------------------------------------------- */
314
- /**
315
- * Convert to snake case.
316
- *
317
- * Convert every property names of nested objects to follow the snake case convention.
318
- *
319
- * For reference, this `typia.notations.snake()` function does not validate the input value
320
- * type. It just believes that the input value is following the type `T`. Therefore,
321
- * if you can't ensure the input value type, it would be better to call one of them below:
322
- *
323
- * - {@link assertSnake}
324
- * - {@link isSnake}
325
- * - {@link validateSnake}
326
- *
327
- * @template T Type of the input value
328
- * @param input Target object
329
- * @returns Snake case object
330
- *
331
- * @author Jeongho Nam - https://github.com/samchon
332
- */
333
- export function snake<T>(input: T): SnakeCase<T>;
334
-
335
- /**
336
- * @internal
337
- */
338
- export function snake(): never {
339
- return NoTransformConfigurationError("notations.snake");
340
- }
341
-
342
- /**
343
- * Converts to snake case with type assertion.
344
- *
345
- * Convert every property names of nested objects to follow the snake case convention.
346
- * If the input value does not follow the type `T`, it throws {@link TypeGuardError}.
347
- *
348
- * @template T Type of the input value
349
- * @param input Target object
350
- * @param errorFactory Custom error factory. Default is `TypeGuardError`
351
- * @returns Snake case object
352
- *
353
- * @author Jeongho Nam - https://github.com/samchon
354
- */
355
- export function assertSnake<T>(
356
- input: T,
357
- errorFactory?: undefined | ((props: TypeGuardError.IProps) => Error),
358
- ): SnakeCase<T>;
359
-
360
- /**
361
- * Converts to snake case with type assertion.
362
- *
363
- * Convert every property names of nested objects to follow the snake case convention.
364
- * If the input value does not follow the type `T`, it throws {@link TypeGuardError}.
365
- *
366
- * @template T Type of the input value
367
- * @param input Target object
368
- * @param errorFactory Custom error factory. Default is `TypeGuardError`
369
- * @returns Snake case object
370
- *
371
- * @author Jeongho Nam - https://github.com/samchon
372
- */
373
- export function assertSnake<T>(
374
- input: unknown,
375
- errorFactory?: undefined | ((props: TypeGuardError.IProps) => Error),
376
- ): SnakeCase<T>;
377
-
378
- /**
379
- * @internal
380
- */
381
- export function assertSnake(): never {
382
- return NoTransformConfigurationError("notations.assertSnake");
383
- }
384
-
385
- /**
386
- * Converts to snake case with type checking.
387
- *
388
- * Convert every property names of nested objects to follow the snake case convention.
389
- * If the input value does not follow the type `T`, it returns `null` value instead.
390
- *
391
- * @template T Type of the input value
392
- * @param input Target object
393
- * @returns Snake case object when exact type, otherwise null
394
- *
395
- * @author Jeongho Nam - https://github.com/samchon
396
- */
397
- export function isSnake<T>(input: T): SnakeCase<T> | null;
398
-
399
- /**
400
- * Converts to snake case with type checking.
401
- *
402
- * Convert every property names of nested objects to follow the snake case convention.
403
- * If the input value does not follow the type `T`, it returns `null` value instead.
404
- *
405
- * @template T Type of the input value
406
- * @param input Target object
407
- * @returns Snake case object when exact type, otherwise null
408
- *
409
- * @author Jeongho Nam - https://github.com/samchon
410
- */
411
- export function isSnake<T>(input: unknown): SnakeCase<T> | null;
412
-
413
- /**
414
- * @internal
415
- */
416
- export function isSnake(): never {
417
- return NoTransformConfigurationError("notations.isSnake");
418
- }
419
-
420
- /**
421
- * Converts to snake case with type validation.
422
- *
423
- * Convert every property names of nested objects to follow the snake case convention.
424
- * If the input value does not follow the type `T`, it returns {@link IValidation.Failure}
425
- * object. Otherwise, there's no problem on the input value, snake cased converted data
426
- * would be stored in the `data` property of the output {@link IValidation.Success} object.
427
- *
428
- * @template T Type of the input value
429
- * @param input Target object
430
- * @returns Validation result with snake case object
431
- *
432
- * @author Jeongho Nam - https://github.com/samchon
433
- */
434
- export function validateSnake<T>(input: T): IValidation<SnakeCase<T>>;
435
-
436
- /**
437
- * Converts to snake case with type validation.
438
- *
439
- * Convert every property names of nested objects to follow the snake case convention.
440
- * If the input value does not follow the type `T`, it returns {@link IValidation.Failure}
441
- * object. Otherwise, there's no problem on the input value, snake cased converted data
442
- * would be stored in the `data` property of the output {@link IValidation.Success} object.
443
- *
444
- * @template T Type of the input value
445
- * @param input Target object
446
- * @returns Validation result with snake case object
447
- *
448
- * @author Jeongho Nam - https://github.com/samchon
449
- */
450
- export function validateSnake<T>(input: unknown): IValidation<SnakeCase<T>>;
451
-
452
- /**
453
- * @internal
454
- */
455
- export function validateSnake(): never {
456
- return NoTransformConfigurationError("notations.validateSnake");
457
- }
458
-
459
- /* -----------------------------------------------------------
460
- FACTORY FUNCTIONS
461
- ----------------------------------------------------------- */
462
- /**
463
- * Creates a reusable {@link camel} function.
464
- *
465
- * @danger You must configure the generic argument `T`
466
- * @returns Nothing until be configure the generic argument `T`
467
- * @throws compile error
468
- *
469
- * @author Jeongho Nam - https://github.com/samchon
470
- */
471
- export function createCamel(): never;
472
-
473
- /**
474
- * Creates a reusable {@link camel} function.
475
- *
476
- * @template T Type of the input value
477
- * @returns A reusable `camel` function
478
- *
479
- * @author Jeongho Nam - https://github.com/samchon
480
- */
481
- export function createCamel<T>(): (input: T) => CamelCase<T>;
482
-
483
- /**
484
- * @internal
485
- */
486
- export function createCamel(): never {
487
- NoTransformConfigurationError("notations.createCamel");
488
- }
489
-
490
- /**
491
- * Creates a reusable {@link assertCamel} function.
492
- *
493
- * @danger You must configure the generic argument `T`
494
- * @param errorFactory Custom error factory. Default is `TypeGuardError`
495
- * @returns Nothing until be configure the generic argument `T`
496
- * @throws compile error
497
- *
498
- * @author Jeongho Nam - https://github.com/samchon
499
- */
500
- export function createAssertCamel(
501
- errorFactory?: undefined | ((props: TypeGuardError.IProps) => Error),
502
- ): never;
503
-
504
- /**
505
- * Creates a reusable {@link assertCamel} function.
506
- *
507
- * @template T Type of the input value
508
- * @param errorFactory Custom error factory. Default is `TypeGuardError`
509
- * @returns A reusable `assertCamel` function
510
- *
511
- * @author Jeongho Nam - https://github.com/samchon
512
- */
513
- export function createAssertCamel<T>(
514
- errorFactory?: undefined | ((props: TypeGuardError.IProps) => Error),
515
- ): (input: T) => CamelCase<T>;
516
-
517
- /**
518
- * @internal
519
- */
520
- export function createAssertCamel(): never {
521
- NoTransformConfigurationError("notations.createAssertCamel");
522
- }
523
-
524
- /**
525
- * Creates a reusable {@link isCamel} function.
526
- *
527
- * @danger You must configure the generic argument `T`
528
- * @returns Nothing until be configure the generic argument `T`
529
- * @throws compile error
530
- *
531
- * @author Jeongho Nam - https://github.com/samchon
532
- */
533
- export function createIsCamel(): never;
534
-
535
- /**
536
- * Creates a reusable {@link isCamel} function.
537
- *
538
- * @template T Type of the input value
539
- * @returns A reusable `isCamel` function
540
- *
541
- * @author Jeongho Nam - https://github.com/samchon
542
- */
543
- export function createIsCamel<T>(): (input: T) => CamelCase<T> | null;
544
-
545
- /**
546
- * @internal
547
- */
548
- export function createIsCamel(): never {
549
- NoTransformConfigurationError("notations.createIsCamel");
550
- }
551
-
552
- /**
553
- * Creates a reusable {@link validateCamel} function.
554
- *
555
- * @danger You must configure the generic argument `T`
556
- * @returns Nothing until be configure the generic argument `T`
557
- * @throws compile error
558
- *
559
- * @author Jeongho Nam - https://github.com/samchon
560
- */
561
- export function createValidateCamel(): never;
562
-
563
- /**
564
- * Creates a reusable {@link validateCamel} function.
565
- *
566
- * @template T Type of the input value
567
- * @returns A reusable `validateCamel` function
568
- *
569
- * @author Jeongho Nam - https://github.com/samchon
570
- */
571
- export function createValidateCamel<T>(): (
572
- input: T,
573
- ) => IValidation<CamelCase<T>>;
574
-
575
- /**
576
- * @internal
577
- */
578
- export function createValidateCamel(): never {
579
- NoTransformConfigurationError("notations.createValidateCamel");
580
- }
581
-
582
- /**
583
- * Creates a reusable {@link pascal} function.
584
- *
585
- * @danger You must configure the generic argument `T`
586
- * @returns Nothing until be configure the generic argument `T`
587
- * @throws compile error
588
- *
589
- * @author Jeongho Nam - https://github.com/samchon
590
- */
591
- export function createPascal(): never;
592
-
593
- /**
594
- * Creates a reusable {@link pascal} function.
595
- *
596
- * @template T Type of the input value
597
- * @returns A reusable `pascal` function
598
- *
599
- * @author Jeongho Nam - https://github.com/samchon
600
- */
601
- export function createPascal<T>(): (input: T) => PascalCase<T>;
602
-
603
- /**
604
- * @internal
605
- */
606
- export function createPascal(): never {
607
- NoTransformConfigurationError("notations.createPascal");
608
- }
609
-
610
- /**
611
- * Creates a reusable {@link assertPascal} function.
612
- *
613
- * @danger You must configure the generic argument `T`
614
- * @param errorFactory Custom error factory. Default is `TypeGuardError`
615
- * @returns Nothing until be configure the generic argument `T`
616
- * @throws compile error
617
- *
618
- * @author Jeongho Nam - https://github.com/samchon
619
- */
620
- export function createAssertPascal(
621
- errorFactory?: undefined | ((props: TypeGuardError.IProps) => Error),
622
- ): never;
623
-
624
- /**
625
- * Creates a reusable {@link assertPascal} function.
626
- *
627
- * @template T Type of the input value
628
- * @param errorFactory Custom error factory. Default is `TypeGuardError`
629
- * @returns A reusable `assertPascal` function
630
- *
631
- * @author Jeongho Nam - https://github.com/samchon
632
- */
633
- export function createAssertPascal<T>(
634
- errorFactory?: undefined | ((props: TypeGuardError.IProps) => Error),
635
- ): (input: T) => PascalCase<T>;
636
-
637
- /**
638
- * @internal
639
- */
640
- export function createAssertPascal(): never {
641
- NoTransformConfigurationError("notations.createAssertPascal");
642
- }
643
-
644
- /**
645
- * Creates a reusable {@link isPascal} function.
646
- *
647
- * @danger You must configure the generic argument `T`
648
- * @returns Nothing until be configure the generic argument `T`
649
- * @throws compile error
650
- *
651
- * @author Jeongho Nam - https://github.com/samchon
652
- */
653
- export function createIsPascal(): never;
654
-
655
- /**
656
- * Creates a reusable {@link isPascal} function.
657
- *
658
- * @template T Type of the input value
659
- * @returns A reusable `isPascal` function
660
- *
661
- * @author Jeongho Nam - https://github.com/samchon
662
- */
663
- export function createIsPascal<T>(): (input: T) => PascalCase<T> | null;
664
-
665
- /**
666
- * @internal
667
- */
668
- export function createIsPascal(): never {
669
- NoTransformConfigurationError("notations.createIsPascal");
670
- }
671
-
672
- /**
673
- * Creates a reusable {@link validatePascal} function.
674
- *
675
- * @danger You must configure the generic argument `T`
676
- * @returns Nothing until be configure the generic argument `T`
677
- * @throws compile error
678
- *
679
- * @author Jeongho Nam - https://github.com/samchon
680
- */
681
- export function createValidatePascal(): never;
682
-
683
- /**
684
- * Creates a reusable {@link validatePascal} function.
685
- *
686
- * @template T Type of the input value
687
- * @returns A reusable `validatePascal` function
688
- *
689
- * @author Jeongho Nam - https://github.com/samchon
690
- */
691
- export function createValidatePascal<T>(): (
692
- input: T,
693
- ) => IValidation<PascalCase<T>>;
694
-
695
- /**
696
- * @internal
697
- */
698
- export function createValidatePascal(): never {
699
- NoTransformConfigurationError("notations.createValidatePascal");
700
- }
701
-
702
- /**
703
- * Creates a reusable {@link snake} function.
704
- *
705
- * @danger You must configure the generic argument `T`
706
- * @returns Nothing until be configure the generic argument `T`
707
- * @throws compile error
708
- *
709
- * @author Jeongho Nam - https://github.com/samchon
710
- */
711
- export function createSnake(): never;
712
-
713
- /**
714
- * Creates a reusable {@link snake} function.
715
- *
716
- * @template T Type of the input value
717
- * @returns A reusable `snake` function
718
- *
719
- * @author Jeongho Nam - https://github.com/samchon
720
- */
721
- export function createSnake<T>(): (input: T) => SnakeCase<T>;
722
-
723
- /**
724
- * @internal
725
- */
726
- export function createSnake(): never {
727
- NoTransformConfigurationError("notations.createSnake");
728
- }
729
-
730
- /**
731
- * Creates a reusable {@link assertSnake} function.
732
- *
733
- * @danger You must configure the generic argument `T`
734
- * @param errorFactory Custom error factory. Default is `TypeGuardError`
735
- * @returns Nothing until be configure the generic argument `T`
736
- * @throws compile error
737
- *
738
- * @author Jeongho Nam - https://github.com/samchon
739
- */
740
- export function createAssertSnake(
741
- errorFactory?: undefined | ((props: TypeGuardError.IProps) => Error),
742
- ): never;
743
-
744
- /**
745
- * Creates a reusable {@link assertSnake} function.
746
- *
747
- * @template T Type of the input value
748
- * @param errorFactory Custom error factory. Default is `TypeGuardError`
749
- * @returns A reusable `assertSnake` function
750
- *
751
- * @author Jeongho Nam - https://github.com/samchon
752
- */
753
- export function createAssertSnake<T>(
754
- errorFactory?: undefined | ((props: TypeGuardError.IProps) => Error),
755
- ): (input: T) => SnakeCase<T>;
756
-
757
- /**
758
- * @internal
759
- */
760
- export function createAssertSnake(): never {
761
- NoTransformConfigurationError("notations.createAssertSnake");
762
- }
763
-
764
- /**
765
- * Creates a reusable {@link isSnake} function.
766
- *
767
- * @danger You must configure the generic argument `T`
768
- * @returns Nothing until be configure the generic argument `T`
769
- * @throws compile error
770
- *
771
- * @author Jeongho Nam - https://github.com/samchon
772
- */
773
- export function createIsSnake(): never;
774
-
775
- /**
776
- * Creates a reusable {@link isSnake} function.
777
- *
778
- * @template T Type of the input value
779
- * @returns A reusable `isSnake` function
780
- *
781
- * @author Jeongho Nam - https://github.com/samchon
782
- */
783
- export function createIsSnake<T>(): (input: T) => SnakeCase<T> | null;
784
-
785
- /**
786
- * @internal
787
- */
788
- export function createIsSnake(): never {
789
- NoTransformConfigurationError("notations.createIsSnake");
790
- }
791
-
792
- /**
793
- * Creates a reusable {@link validateSnake} function.
794
- *
795
- * @danger You must configure the generic argument `T`
796
- * @returns Nothing until be configure the generic argument `T`
797
- * @throws compile error
798
- *
799
- * @author Jeongho Nam - https://github.com/samchon
800
- */
801
- export function createValidateSnake(): never;
802
-
803
- /**
804
- * Creates a reusable {@link validateSnake} function.
805
- *
806
- * @template T Type of the input value
807
- * @returns A reusable `validateSnake` function
808
- *
809
- * @author Jeongho Nam - https://github.com/samchon
810
- */
811
- export function createValidateSnake<T>(): (
812
- input: T,
813
- ) => IValidation<SnakeCase<T>>;
814
-
815
- /**
816
- * @internal
817
- */
818
- export function createValidateSnake(): never {
819
- NoTransformConfigurationError("notations.createValidateSnake");
820
- }
1
+ import { NoTransformConfigurationError } from "./transformers/NoTransformConfigurationError";
2
+
3
+ import { CamelCase } from "./CamelCase";
4
+ import { IValidation } from "./IValidation";
5
+ import { PascalCase } from "./PascalCase";
6
+ import { SnakeCase } from "./SnakeCase";
7
+ import { TypeGuardError } from "./TypeGuardError";
8
+
9
+ /* ===========================================================
10
+ NOTATIONS (NAMING CONVENTIONS)
11
+ - CAMEL CASE
12
+ - PASCAL CASE
13
+ - SNAKE CASE
14
+ - FACTORY FUNCTIONS
15
+ ==============================================================
16
+ CAMEL CASE
17
+ ----------------------------------------------------------- */
18
+ /**
19
+ * Convert to camel case.
20
+ *
21
+ * Convert every property names of nested objects to follow the camel case
22
+ * convention.
23
+ *
24
+ * For reference, this `typia.notations.camel()` function does not validate the
25
+ * input value type. It just believes that the input value is following the type
26
+ * `T`. Therefore, if you can't ensure the input value type, it would be better
27
+ * to call one of them below:
28
+ *
29
+ * - {@link assertCamel}
30
+ * - {@link isCamel}
31
+ * - {@link validateCamel}
32
+ *
33
+ * @author Jeongho Nam - https://github.com/samchon
34
+ * @template T Type of the input value
35
+ * @param input Target object
36
+ * @returns Camel case object
37
+ */
38
+ export function camel<T>(input: T): CamelCase<T>;
39
+
40
+ /** @internal */
41
+ export function camel(): never {
42
+ return NoTransformConfigurationError("notations.camel");
43
+ }
44
+
45
+ /**
46
+ * Converts to camel case with type assertion.
47
+ *
48
+ * Convert every property names of nested objects to follow the camel case
49
+ * convention. If the input value does not follow the type `T`, it throws
50
+ * {@link TypeGuardError}.
51
+ *
52
+ * @author Jeongho Nam - https://github.com/samchon
53
+ * @template T Type of the input value
54
+ * @param input Target object
55
+ * @param errorFactory Custom error factory. Default is `TypeGuardError`
56
+ * @returns Camel case object
57
+ */
58
+ export function assertCamel<T>(
59
+ input: T,
60
+ errorFactory?: undefined | ((props: TypeGuardError.IProps) => Error),
61
+ ): CamelCase<T>;
62
+
63
+ /**
64
+ * Converts to camel case with type assertion.
65
+ *
66
+ * Convert every property names of nested objects to follow the camel case
67
+ * convention. If the input value does not follow the type `T`, it throws
68
+ * {@link TypeGuardError}.
69
+ *
70
+ * @author Jeongho Nam - https://github.com/samchon
71
+ * @template T Type of the input value
72
+ * @param input Target object
73
+ * @param errorFactory Custom error factory. Default is `TypeGuardError`
74
+ * @returns Camel case object
75
+ */
76
+ export function assertCamel<T>(
77
+ input: unknown,
78
+ errorFactory?: undefined | ((props: TypeGuardError.IProps) => Error),
79
+ ): CamelCase<T>;
80
+
81
+ /** @internal */
82
+ export function assertCamel(): never {
83
+ return NoTransformConfigurationError("notations.assertCamel");
84
+ }
85
+
86
+ /**
87
+ * Converts to camel case with type checking.
88
+ *
89
+ * Convert every property names of nested objects to follow the camel case
90
+ * convention. If the input value does not follow the type `T`, it returns
91
+ * `null` value instead.
92
+ *
93
+ * @author Jeongho Nam - https://github.com/samchon
94
+ * @template T Type of the input value
95
+ * @param input Target object
96
+ * @returns Camel case object when exact type, otherwise null
97
+ */
98
+ export function isCamel<T>(input: T): CamelCase<T> | null;
99
+
100
+ /**
101
+ * Converts to camel case with type checking.
102
+ *
103
+ * Convert every property names of nested objects to follow the camel case
104
+ * convention. If the input value does not follow the type `T`, it returns
105
+ * `null` value instead.
106
+ *
107
+ * @author Jeongho Nam - https://github.com/samchon
108
+ * @template T Type of the input value
109
+ * @param input Target object
110
+ * @returns Camel case object when exact type, otherwise null
111
+ */
112
+ export function isCamel<T>(input: unknown): CamelCase<T> | null;
113
+
114
+ /** @internal */
115
+ export function isCamel(): never {
116
+ return NoTransformConfigurationError("notations.isCamel");
117
+ }
118
+
119
+ /**
120
+ * Converts to camel case with type validation.
121
+ *
122
+ * Convert every property names of nested objects to follow the camel case
123
+ * convention. If the input value does not follow the type `T`, it returns
124
+ * {@link IValidation.Failure} object. Otherwise, there's no problem on the input
125
+ * value, camel cased converted data would be stored in the `data` property of
126
+ * the output {@link IValidation.Success} object.
127
+ *
128
+ * @author Jeongho Nam - https://github.com/samchon
129
+ * @template T Type of the input value
130
+ * @param input Target object
131
+ * @returns Validation result with camel case object
132
+ */
133
+ export function validateCamel<T>(input: T): IValidation<CamelCase<T>>;
134
+
135
+ /**
136
+ * Converts to camel case with type validation.
137
+ *
138
+ * Convert every property names of nested objects to follow the camel case
139
+ * convention. If the input value does not follow the type `T`, it returns
140
+ * {@link IValidation.Failure} object. Otherwise, there's no problem on the input
141
+ * value, camel cased converted data would be stored in the `data` property of
142
+ * the output {@link IValidation.Success} object.
143
+ *
144
+ * @author Jeongho Nam - https://github.com/samchon
145
+ * @template T Type of the input value
146
+ * @param input Target object
147
+ * @returns Validation result with camel case object
148
+ */
149
+ export function validateCamel<T>(input: unknown): IValidation<CamelCase<T>>;
150
+
151
+ /** @internal */
152
+ export function validateCamel(): never {
153
+ return NoTransformConfigurationError("notations.validateCamel");
154
+ }
155
+
156
+ /* -----------------------------------------------------------
157
+ PASCAL CASE
158
+ ----------------------------------------------------------- */
159
+ /**
160
+ * Convert to pascal case.
161
+ *
162
+ * Convert every property names of nested objects to follow the pascal case
163
+ * convention.
164
+ *
165
+ * For reference, this `typia.notations.pascal()` function does not validate the
166
+ * input value type. It just believes that the input value is following the type
167
+ * `T`. Therefore, if you can't ensure the input value type, it would be better
168
+ * to call one of them below:
169
+ *
170
+ * - {@link assertPascal}
171
+ * - {@link isPascal}
172
+ * - {@link validatePascal}
173
+ *
174
+ * @author Jeongho Nam - https://github.com/samchon
175
+ * @template T Type of the input value
176
+ * @param input Target object
177
+ * @returns Pascal case object
178
+ */
179
+ export function pascal<T>(input: T): PascalCase<T>;
180
+
181
+ /** @internal */
182
+ export function pascal(): never {
183
+ return NoTransformConfigurationError("notations.pascal");
184
+ }
185
+
186
+ /**
187
+ * Converts to pascal case with type assertion.
188
+ *
189
+ * Convert every property names of nested objects to follow the pascal case
190
+ * convention. If the input value does not follow the type `T`, it throws
191
+ * {@link TypeGuardError}.
192
+ *
193
+ * @author Jeongho Nam - https://github.com/samchon
194
+ * @template T Type of the input value
195
+ * @param input Target object
196
+ * @param errorFactory Custom error factory. Default is `TypeGuardError`
197
+ * @returns Pascal case object
198
+ */
199
+ export function assertPascal<T>(
200
+ input: T,
201
+ errorFactory?: undefined | ((props: TypeGuardError.IProps) => Error),
202
+ ): PascalCase<T>;
203
+
204
+ /**
205
+ * Converts to pascal case with type assertion.
206
+ *
207
+ * Convert every property names of nested objects to follow the pascal case
208
+ * convention. If the input value does not follow the type `T`, it throws
209
+ * {@link TypeGuardError}.
210
+ *
211
+ * @author Jeongho Nam - https://github.com/samchon
212
+ * @template T Type of the input value
213
+ * @param input Target object
214
+ * @param errorFactory Custom error factory. Default is `TypeGuardError`
215
+ * @returns Pascal case object
216
+ */
217
+ export function assertPascal<T>(
218
+ input: unknown,
219
+ errorFactory?: undefined | ((props: TypeGuardError.IProps) => Error),
220
+ ): PascalCase<T>;
221
+
222
+ /** @internal */
223
+ export function assertPascal(): never {
224
+ return NoTransformConfigurationError("notations.assertPascal");
225
+ }
226
+
227
+ /**
228
+ * Converts to pascal case with type checking.
229
+ *
230
+ * Convert every property names of nested objects to follow the pascal case
231
+ * convention. If the input value does not follow the type `T`, it returns
232
+ * `null` value instead.
233
+ *
234
+ * @author Jeongho Nam - https://github.com/samchon
235
+ * @template T Type of the input value
236
+ * @param input Target object
237
+ * @returns Pascal case object when exact type, otherwise null
238
+ */
239
+ export function isPascal<T>(input: T): PascalCase<T> | null;
240
+
241
+ /**
242
+ * Converts to pascal case with type checking.
243
+ *
244
+ * Convert every property names of nested objects to follow the pascal case
245
+ * convention. If the input value does not follow the type `T`, it returns
246
+ * `null` value instead.
247
+ *
248
+ * @author Jeongho Nam - https://github.com/samchon
249
+ * @template T Type of the input value
250
+ * @param input Target object
251
+ * @returns Pascal case object when exact type, otherwise null
252
+ */
253
+ export function isPascal<T>(input: unknown): PascalCase<T> | null;
254
+
255
+ /** @internal */
256
+ export function isPascal(): never {
257
+ return NoTransformConfigurationError("notations.isPascal");
258
+ }
259
+
260
+ /**
261
+ * Converts to pascal case with type validation.
262
+ *
263
+ * Convert every property names of nested objects to follow the pascal case
264
+ * convention. If the input value does not follow the type `T`, it returns
265
+ * {@link IValidation.Failure} object. Otherwise, there's no problem on the input
266
+ * value, pascal cased converted data would be stored in the `data` property of
267
+ * the output {@link IValidation.Success} object.
268
+ *
269
+ * @author Jeongho Nam - https://github.com/samchon
270
+ * @template T Type of the input value
271
+ * @param input Target object
272
+ * @returns Validation result with pascal case object
273
+ */
274
+ export function validatePascal<T>(input: T): IValidation<PascalCase<T>>;
275
+
276
+ /**
277
+ * Converts to pascal case with type validation.
278
+ *
279
+ * Convert every property names of nested objects to follow the pascal case
280
+ * convention. If the input value does not follow the type `T`, it returns
281
+ * {@link IValidation.Failure} object. Otherwise, there's no problem on the input
282
+ * value, pascal cased converted data would be stored in the `data` property of
283
+ * the output {@link IValidation.Success} object.
284
+ *
285
+ * @author Jeongho Nam - https://github.com/samchon
286
+ * @template T Type of the input value
287
+ * @param input Target object
288
+ * @returns Validation result with pascal case object
289
+ */
290
+ export function validatePascal<T>(input: unknown): IValidation<PascalCase<T>>;
291
+
292
+ /** @internal */
293
+ export function validatePascal(): never {
294
+ return NoTransformConfigurationError("notations.validatePascal");
295
+ }
296
+
297
+ /* -----------------------------------------------------------
298
+ SNAKE CASE
299
+ ----------------------------------------------------------- */
300
+ /**
301
+ * Convert to snake case.
302
+ *
303
+ * Convert every property names of nested objects to follow the snake case
304
+ * convention.
305
+ *
306
+ * For reference, this `typia.notations.snake()` function does not validate the
307
+ * input value type. It just believes that the input value is following the type
308
+ * `T`. Therefore, if you can't ensure the input value type, it would be better
309
+ * to call one of them below:
310
+ *
311
+ * - {@link assertSnake}
312
+ * - {@link isSnake}
313
+ * - {@link validateSnake}
314
+ *
315
+ * @author Jeongho Nam - https://github.com/samchon
316
+ * @template T Type of the input value
317
+ * @param input Target object
318
+ * @returns Snake case object
319
+ */
320
+ export function snake<T>(input: T): SnakeCase<T>;
321
+
322
+ /** @internal */
323
+ export function snake(): never {
324
+ return NoTransformConfigurationError("notations.snake");
325
+ }
326
+
327
+ /**
328
+ * Converts to snake case with type assertion.
329
+ *
330
+ * Convert every property names of nested objects to follow the snake case
331
+ * convention. If the input value does not follow the type `T`, it throws
332
+ * {@link TypeGuardError}.
333
+ *
334
+ * @author Jeongho Nam - https://github.com/samchon
335
+ * @template T Type of the input value
336
+ * @param input Target object
337
+ * @param errorFactory Custom error factory. Default is `TypeGuardError`
338
+ * @returns Snake case object
339
+ */
340
+ export function assertSnake<T>(
341
+ input: T,
342
+ errorFactory?: undefined | ((props: TypeGuardError.IProps) => Error),
343
+ ): SnakeCase<T>;
344
+
345
+ /**
346
+ * Converts to snake case with type assertion.
347
+ *
348
+ * Convert every property names of nested objects to follow the snake case
349
+ * convention. If the input value does not follow the type `T`, it throws
350
+ * {@link TypeGuardError}.
351
+ *
352
+ * @author Jeongho Nam - https://github.com/samchon
353
+ * @template T Type of the input value
354
+ * @param input Target object
355
+ * @param errorFactory Custom error factory. Default is `TypeGuardError`
356
+ * @returns Snake case object
357
+ */
358
+ export function assertSnake<T>(
359
+ input: unknown,
360
+ errorFactory?: undefined | ((props: TypeGuardError.IProps) => Error),
361
+ ): SnakeCase<T>;
362
+
363
+ /** @internal */
364
+ export function assertSnake(): never {
365
+ return NoTransformConfigurationError("notations.assertSnake");
366
+ }
367
+
368
+ /**
369
+ * Converts to snake case with type checking.
370
+ *
371
+ * Convert every property names of nested objects to follow the snake case
372
+ * convention. If the input value does not follow the type `T`, it returns
373
+ * `null` value instead.
374
+ *
375
+ * @author Jeongho Nam - https://github.com/samchon
376
+ * @template T Type of the input value
377
+ * @param input Target object
378
+ * @returns Snake case object when exact type, otherwise null
379
+ */
380
+ export function isSnake<T>(input: T): SnakeCase<T> | null;
381
+
382
+ /**
383
+ * Converts to snake case with type checking.
384
+ *
385
+ * Convert every property names of nested objects to follow the snake case
386
+ * convention. If the input value does not follow the type `T`, it returns
387
+ * `null` value instead.
388
+ *
389
+ * @author Jeongho Nam - https://github.com/samchon
390
+ * @template T Type of the input value
391
+ * @param input Target object
392
+ * @returns Snake case object when exact type, otherwise null
393
+ */
394
+ export function isSnake<T>(input: unknown): SnakeCase<T> | null;
395
+
396
+ /** @internal */
397
+ export function isSnake(): never {
398
+ return NoTransformConfigurationError("notations.isSnake");
399
+ }
400
+
401
+ /**
402
+ * Converts to snake case with type validation.
403
+ *
404
+ * Convert every property names of nested objects to follow the snake case
405
+ * convention. If the input value does not follow the type `T`, it returns
406
+ * {@link IValidation.Failure} object. Otherwise, there's no problem on the input
407
+ * value, snake cased converted data would be stored in the `data` property of
408
+ * the output {@link IValidation.Success} object.
409
+ *
410
+ * @author Jeongho Nam - https://github.com/samchon
411
+ * @template T Type of the input value
412
+ * @param input Target object
413
+ * @returns Validation result with snake case object
414
+ */
415
+ export function validateSnake<T>(input: T): IValidation<SnakeCase<T>>;
416
+
417
+ /**
418
+ * Converts to snake case with type validation.
419
+ *
420
+ * Convert every property names of nested objects to follow the snake case
421
+ * convention. If the input value does not follow the type `T`, it returns
422
+ * {@link IValidation.Failure} object. Otherwise, there's no problem on the input
423
+ * value, snake cased converted data would be stored in the `data` property of
424
+ * the output {@link IValidation.Success} object.
425
+ *
426
+ * @author Jeongho Nam - https://github.com/samchon
427
+ * @template T Type of the input value
428
+ * @param input Target object
429
+ * @returns Validation result with snake case object
430
+ */
431
+ export function validateSnake<T>(input: unknown): IValidation<SnakeCase<T>>;
432
+
433
+ /** @internal */
434
+ export function validateSnake(): never {
435
+ return NoTransformConfigurationError("notations.validateSnake");
436
+ }
437
+
438
+ /* -----------------------------------------------------------
439
+ FACTORY FUNCTIONS
440
+ ----------------------------------------------------------- */
441
+ /**
442
+ * Creates a reusable {@link camel} function.
443
+ *
444
+ * @author Jeongho Nam - https://github.com/samchon
445
+ * @returns Nothing until be configure the generic argument `T`
446
+ * @throws Compile error
447
+ * @danger You must configure the generic argument `T`
448
+ */
449
+ export function createCamel(): never;
450
+
451
+ /**
452
+ * Creates a reusable {@link camel} function.
453
+ *
454
+ * @author Jeongho Nam - https://github.com/samchon
455
+ * @template T Type of the input value
456
+ * @returns A reusable `camel` function
457
+ */
458
+ export function createCamel<T>(): (input: T) => CamelCase<T>;
459
+
460
+ /** @internal */
461
+ export function createCamel(): never {
462
+ NoTransformConfigurationError("notations.createCamel");
463
+ }
464
+
465
+ /**
466
+ * Creates a reusable {@link assertCamel} function.
467
+ *
468
+ * @author Jeongho Nam - https://github.com/samchon
469
+ * @param errorFactory Custom error factory. Default is `TypeGuardError`
470
+ * @returns Nothing until be configure the generic argument `T`
471
+ * @throws Compile error
472
+ * @danger You must configure the generic argument `T`
473
+ */
474
+ export function createAssertCamel(
475
+ errorFactory?: undefined | ((props: TypeGuardError.IProps) => Error),
476
+ ): never;
477
+
478
+ /**
479
+ * Creates a reusable {@link assertCamel} function.
480
+ *
481
+ * @author Jeongho Nam - https://github.com/samchon
482
+ * @template T Type of the input value
483
+ * @param errorFactory Custom error factory. Default is `TypeGuardError`
484
+ * @returns A reusable `assertCamel` function
485
+ */
486
+ export function createAssertCamel<T>(
487
+ errorFactory?: undefined | ((props: TypeGuardError.IProps) => Error),
488
+ ): (input: T) => CamelCase<T>;
489
+
490
+ /** @internal */
491
+ export function createAssertCamel(): never {
492
+ NoTransformConfigurationError("notations.createAssertCamel");
493
+ }
494
+
495
+ /**
496
+ * Creates a reusable {@link isCamel} function.
497
+ *
498
+ * @author Jeongho Nam - https://github.com/samchon
499
+ * @returns Nothing until be configure the generic argument `T`
500
+ * @throws Compile error
501
+ * @danger You must configure the generic argument `T`
502
+ */
503
+ export function createIsCamel(): never;
504
+
505
+ /**
506
+ * Creates a reusable {@link isCamel} function.
507
+ *
508
+ * @author Jeongho Nam - https://github.com/samchon
509
+ * @template T Type of the input value
510
+ * @returns A reusable `isCamel` function
511
+ */
512
+ export function createIsCamel<T>(): (input: T) => CamelCase<T> | null;
513
+
514
+ /** @internal */
515
+ export function createIsCamel(): never {
516
+ NoTransformConfigurationError("notations.createIsCamel");
517
+ }
518
+
519
+ /**
520
+ * Creates a reusable {@link validateCamel} function.
521
+ *
522
+ * @author Jeongho Nam - https://github.com/samchon
523
+ * @returns Nothing until be configure the generic argument `T`
524
+ * @throws Compile error
525
+ * @danger You must configure the generic argument `T`
526
+ */
527
+ export function createValidateCamel(): never;
528
+
529
+ /**
530
+ * Creates a reusable {@link validateCamel} function.
531
+ *
532
+ * @author Jeongho Nam - https://github.com/samchon
533
+ * @template T Type of the input value
534
+ * @returns A reusable `validateCamel` function
535
+ */
536
+ export function createValidateCamel<T>(): (
537
+ input: T,
538
+ ) => IValidation<CamelCase<T>>;
539
+
540
+ /** @internal */
541
+ export function createValidateCamel(): never {
542
+ NoTransformConfigurationError("notations.createValidateCamel");
543
+ }
544
+
545
+ /**
546
+ * Creates a reusable {@link pascal} function.
547
+ *
548
+ * @author Jeongho Nam - https://github.com/samchon
549
+ * @returns Nothing until be configure the generic argument `T`
550
+ * @throws Compile error
551
+ * @danger You must configure the generic argument `T`
552
+ */
553
+ export function createPascal(): never;
554
+
555
+ /**
556
+ * Creates a reusable {@link pascal} function.
557
+ *
558
+ * @author Jeongho Nam - https://github.com/samchon
559
+ * @template T Type of the input value
560
+ * @returns A reusable `pascal` function
561
+ */
562
+ export function createPascal<T>(): (input: T) => PascalCase<T>;
563
+
564
+ /** @internal */
565
+ export function createPascal(): never {
566
+ NoTransformConfigurationError("notations.createPascal");
567
+ }
568
+
569
+ /**
570
+ * Creates a reusable {@link assertPascal} function.
571
+ *
572
+ * @author Jeongho Nam - https://github.com/samchon
573
+ * @param errorFactory Custom error factory. Default is `TypeGuardError`
574
+ * @returns Nothing until be configure the generic argument `T`
575
+ * @throws Compile error
576
+ * @danger You must configure the generic argument `T`
577
+ */
578
+ export function createAssertPascal(
579
+ errorFactory?: undefined | ((props: TypeGuardError.IProps) => Error),
580
+ ): never;
581
+
582
+ /**
583
+ * Creates a reusable {@link assertPascal} function.
584
+ *
585
+ * @author Jeongho Nam - https://github.com/samchon
586
+ * @template T Type of the input value
587
+ * @param errorFactory Custom error factory. Default is `TypeGuardError`
588
+ * @returns A reusable `assertPascal` function
589
+ */
590
+ export function createAssertPascal<T>(
591
+ errorFactory?: undefined | ((props: TypeGuardError.IProps) => Error),
592
+ ): (input: T) => PascalCase<T>;
593
+
594
+ /** @internal */
595
+ export function createAssertPascal(): never {
596
+ NoTransformConfigurationError("notations.createAssertPascal");
597
+ }
598
+
599
+ /**
600
+ * Creates a reusable {@link isPascal} function.
601
+ *
602
+ * @author Jeongho Nam - https://github.com/samchon
603
+ * @returns Nothing until be configure the generic argument `T`
604
+ * @throws Compile error
605
+ * @danger You must configure the generic argument `T`
606
+ */
607
+ export function createIsPascal(): never;
608
+
609
+ /**
610
+ * Creates a reusable {@link isPascal} function.
611
+ *
612
+ * @author Jeongho Nam - https://github.com/samchon
613
+ * @template T Type of the input value
614
+ * @returns A reusable `isPascal` function
615
+ */
616
+ export function createIsPascal<T>(): (input: T) => PascalCase<T> | null;
617
+
618
+ /** @internal */
619
+ export function createIsPascal(): never {
620
+ NoTransformConfigurationError("notations.createIsPascal");
621
+ }
622
+
623
+ /**
624
+ * Creates a reusable {@link validatePascal} function.
625
+ *
626
+ * @author Jeongho Nam - https://github.com/samchon
627
+ * @returns Nothing until be configure the generic argument `T`
628
+ * @throws Compile error
629
+ * @danger You must configure the generic argument `T`
630
+ */
631
+ export function createValidatePascal(): never;
632
+
633
+ /**
634
+ * Creates a reusable {@link validatePascal} function.
635
+ *
636
+ * @author Jeongho Nam - https://github.com/samchon
637
+ * @template T Type of the input value
638
+ * @returns A reusable `validatePascal` function
639
+ */
640
+ export function createValidatePascal<T>(): (
641
+ input: T,
642
+ ) => IValidation<PascalCase<T>>;
643
+
644
+ /** @internal */
645
+ export function createValidatePascal(): never {
646
+ NoTransformConfigurationError("notations.createValidatePascal");
647
+ }
648
+
649
+ /**
650
+ * Creates a reusable {@link snake} function.
651
+ *
652
+ * @author Jeongho Nam - https://github.com/samchon
653
+ * @returns Nothing until be configure the generic argument `T`
654
+ * @throws Compile error
655
+ * @danger You must configure the generic argument `T`
656
+ */
657
+ export function createSnake(): never;
658
+
659
+ /**
660
+ * Creates a reusable {@link snake} function.
661
+ *
662
+ * @author Jeongho Nam - https://github.com/samchon
663
+ * @template T Type of the input value
664
+ * @returns A reusable `snake` function
665
+ */
666
+ export function createSnake<T>(): (input: T) => SnakeCase<T>;
667
+
668
+ /** @internal */
669
+ export function createSnake(): never {
670
+ NoTransformConfigurationError("notations.createSnake");
671
+ }
672
+
673
+ /**
674
+ * Creates a reusable {@link assertSnake} function.
675
+ *
676
+ * @author Jeongho Nam - https://github.com/samchon
677
+ * @param errorFactory Custom error factory. Default is `TypeGuardError`
678
+ * @returns Nothing until be configure the generic argument `T`
679
+ * @throws Compile error
680
+ * @danger You must configure the generic argument `T`
681
+ */
682
+ export function createAssertSnake(
683
+ errorFactory?: undefined | ((props: TypeGuardError.IProps) => Error),
684
+ ): never;
685
+
686
+ /**
687
+ * Creates a reusable {@link assertSnake} function.
688
+ *
689
+ * @author Jeongho Nam - https://github.com/samchon
690
+ * @template T Type of the input value
691
+ * @param errorFactory Custom error factory. Default is `TypeGuardError`
692
+ * @returns A reusable `assertSnake` function
693
+ */
694
+ export function createAssertSnake<T>(
695
+ errorFactory?: undefined | ((props: TypeGuardError.IProps) => Error),
696
+ ): (input: T) => SnakeCase<T>;
697
+
698
+ /** @internal */
699
+ export function createAssertSnake(): never {
700
+ NoTransformConfigurationError("notations.createAssertSnake");
701
+ }
702
+
703
+ /**
704
+ * Creates a reusable {@link isSnake} function.
705
+ *
706
+ * @author Jeongho Nam - https://github.com/samchon
707
+ * @returns Nothing until be configure the generic argument `T`
708
+ * @throws Compile error
709
+ * @danger You must configure the generic argument `T`
710
+ */
711
+ export function createIsSnake(): never;
712
+
713
+ /**
714
+ * Creates a reusable {@link isSnake} function.
715
+ *
716
+ * @author Jeongho Nam - https://github.com/samchon
717
+ * @template T Type of the input value
718
+ * @returns A reusable `isSnake` function
719
+ */
720
+ export function createIsSnake<T>(): (input: T) => SnakeCase<T> | null;
721
+
722
+ /** @internal */
723
+ export function createIsSnake(): never {
724
+ NoTransformConfigurationError("notations.createIsSnake");
725
+ }
726
+
727
+ /**
728
+ * Creates a reusable {@link validateSnake} function.
729
+ *
730
+ * @author Jeongho Nam - https://github.com/samchon
731
+ * @returns Nothing until be configure the generic argument `T`
732
+ * @throws Compile error
733
+ * @danger You must configure the generic argument `T`
734
+ */
735
+ export function createValidateSnake(): never;
736
+
737
+ /**
738
+ * Creates a reusable {@link validateSnake} function.
739
+ *
740
+ * @author Jeongho Nam - https://github.com/samchon
741
+ * @template T Type of the input value
742
+ * @returns A reusable `validateSnake` function
743
+ */
744
+ export function createValidateSnake<T>(): (
745
+ input: T,
746
+ ) => IValidation<SnakeCase<T>>;
747
+
748
+ /** @internal */
749
+ export function createValidateSnake(): never {
750
+ NoTransformConfigurationError("notations.createValidateSnake");
751
+ }