@cparra/apexdocs 2.25.0-alpha.2 → 2.25.0-alpha.4

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 (355) hide show
  1. package/README.md +37 -0
  2. package/dist/cli/generate.js +291 -0
  3. package/dist/index.d.ts +2 -0
  4. package/dist/index.js +1 -0
  5. package/examples/plain-markdown/docs/Miscellaneous/ns.SampleException.md +18 -0
  6. package/examples/plain-markdown/docs/Miscellaneous/ns.SampleInterface.md +6 -2
  7. package/examples/plain-markdown/docs/Miscellaneous/ns.Url.md +320 -0
  8. package/examples/plain-markdown/docs/Sample-Enums/ns.SampleEnum.md +3 -1
  9. package/examples/plain-markdown/docs/SampleGroup/ns.SampleClass.md +1 -1
  10. package/examples/plain-markdown/docs/index.md +84 -0
  11. package/examples/plain-markdown/force-app/classes/SampleException.cls +16 -0
  12. package/examples/plain-markdown/force-app/classes/Url.cls +194 -0
  13. package/examples/plain-markdown/package.json +2 -1
  14. package/jest.config.js +1 -1
  15. package/package.json +11 -13
  16. package/src/__spec__/core/generating-class-docs.spec.ts +57 -37
  17. package/src/__spec__/core/generating-enum-docs.spec.ts +25 -22
  18. package/src/__spec__/core/generating-interface-docs.spec.ts +33 -30
  19. package/src/__spec__/core/generating-reference-guide.spec.ts +8 -7
  20. package/src/__spec__/core/test-helpers.ts +9 -0
  21. package/src/application/Apexdocs.ts +34 -5
  22. package/src/application/{flows → generators}/generate-markdown-files.ts +19 -13
  23. package/src/cli/args.ts +138 -0
  24. package/src/cli/generate.ts +12 -138
  25. package/src/core/adapters/__tests__/documentables.spec.ts +109 -0
  26. package/src/{adapters → core/adapters}/__tests__/interface-adapter.spec.ts +13 -11
  27. package/src/{adapters → core/adapters}/__tests__/references.spec.ts +23 -2
  28. package/src/{adapters → core/adapters}/apex-types.ts +18 -15
  29. package/src/{adapters → core/adapters}/documentables.ts +54 -12
  30. package/src/{adapters → core/adapters}/fields-and-properties.ts +17 -10
  31. package/src/{adapters/references.ts → core/adapters/inline.ts} +43 -13
  32. package/src/{adapters → core/adapters}/methods-and-constructors.ts +21 -9
  33. package/src/core/adapters/type-utils.ts +13 -0
  34. package/src/core/{renderable → adapters}/types.d.ts +42 -4
  35. package/src/core/generate-docs.ts +55 -19
  36. package/src/core/template.ts +15 -9
  37. package/src/core/templates/reference-guide.ts +1 -1
  38. package/src/model/__tests__/manifest.spec.ts +1 -1
  39. package/src/model/markdown-generation-util/field-declaration-util.ts +1 -1
  40. package/src/model/markdown-generation-util/method-declaration-util.ts +1 -1
  41. package/src/model/markdown-type-file.ts +5 -1
  42. package/src/service/__tests__/apex-file-reader.spec.ts +1 -0
  43. package/src/service/apex-file-reader.ts +2 -6
  44. package/src/service/manifest-factory.ts +2 -2
  45. package/src/service/parser.ts +1 -1
  46. package/src/settings.ts +6 -10
  47. package/src/test-helpers/SettingsBuilder.ts +1 -2
  48. package/src/transpiler/factory.ts +2 -4
  49. package/src/transpiler/markdown/class-file-generatorHelper.ts +1 -18
  50. package/src/transpiler/markdown/plain-markdown/constructors-partial-template.ts +2 -2
  51. package/src/transpiler/markdown/plain-markdown/documentable-partial-template.ts +6 -4
  52. package/src/transpiler/markdown/plain-markdown/fieldsPartialTemplate.ts +1 -1
  53. package/src/transpiler/markdown/plain-markdown/methods-partial-template.ts +2 -2
  54. package/src/util/fp.ts +3 -0
  55. package/tsconfig.json +1 -1
  56. package/docs/.nojekyll +0 -0
  57. package/docs/__old/README.md +0 -1
  58. package/docs/__old/index.html +0 -22
  59. package/docs/__old/restapi.json +0 -589
  60. package/docs/__old/types/Classes/nspc.AnotherInterface.md +0 -22
  61. package/docs/__old/types/Classes/nspc.ChildClass.md +0 -97
  62. package/docs/__old/types/Main/nspc.GroupedClass.md +0 -10
  63. package/docs/__old/types/Main/nspc.SampleClass.md +0 -189
  64. package/docs/__old/types/Misc-Group/nspc.EscapedAnnotations.md +0 -4
  65. package/docs/__old/types/Misc-Group/nspc.GrandparentClass.md +0 -13
  66. package/docs/__old/types/Misc-Group/nspc.InterfaceWithInheritance.md +0 -29
  67. package/docs/__old/types/Misc-Group/nspc.MemberGrouping.md +0 -13
  68. package/docs/__old/types/Misc-Group/nspc.ParentClass.md +0 -37
  69. package/docs/__old/types/Misc-Group/nspc.Reference1.md +0 -18
  70. package/docs/__old/types/Misc-Group/nspc.Reference2.md +0 -12
  71. package/docs/__old/types/Misc-Group/nspc.Reference3.md +0 -7
  72. package/docs/__old/types/Misc-Group/nspc.Reference4.md +0 -7
  73. package/docs/__old/types/Misc-Group/nspc.Reference5.md +0 -7
  74. package/docs/__old/types/Misc-Group/nspc.Reference6.md +0 -9
  75. package/docs/__old/types/Misc-Group/nspc.Reference7.md +0 -7
  76. package/docs/__old/types/Misc-Group/nspc.SampleClassWithoutModifier.md +0 -11
  77. package/docs/__old/types/Misc-Group/nspc.SampleRestResource.md +0 -104
  78. package/docs/__old/types/Misc-Group/nspc.SampleRestResourceWithInnerClass.md +0 -33
  79. package/docs/__old/types/Misc-Group/nspc.SampleRestResourceWithoutApexDocs.md +0 -14
  80. package/docs/__old/types/README.md +0 -97
  81. package/docs/__old/types/Sample-Interfaces/nspc.SampleInterface.md +0 -23
  82. package/examples/includes/header.md +0 -3
  83. package/lib/__spec__/core/expect-extensions.d.ts +0 -3
  84. package/lib/__spec__/core/expect-extensions.js +0 -54
  85. package/lib/__spec__/core/expect-extensions.js.map +0 -1
  86. package/lib/__spec__/core/generating-class-docs.spec.d.ts +0 -1
  87. package/lib/__spec__/core/generating-class-docs.spec.js +0 -427
  88. package/lib/__spec__/core/generating-class-docs.spec.js.map +0 -1
  89. package/lib/__spec__/core/generating-enum-docs.spec.d.ts +0 -1
  90. package/lib/__spec__/core/generating-enum-docs.spec.js +0 -303
  91. package/lib/__spec__/core/generating-enum-docs.spec.js.map +0 -1
  92. package/lib/__spec__/core/generating-interface-docs.spec.d.ts +0 -1
  93. package/lib/__spec__/core/generating-interface-docs.spec.js +0 -361
  94. package/lib/__spec__/core/generating-interface-docs.spec.js.map +0 -1
  95. package/lib/__spec__/core/generating-reference-guide.spec.d.ts +0 -1
  96. package/lib/__spec__/core/generating-reference-guide.spec.js +0 -161
  97. package/lib/__spec__/core/generating-reference-guide.spec.js.map +0 -1
  98. package/lib/adapters/apex-types.d.ts +0 -5
  99. package/lib/adapters/apex-types.js +0 -109
  100. package/lib/adapters/apex-types.js.map +0 -1
  101. package/lib/adapters/documentables.d.ts +0 -7
  102. package/lib/adapters/documentables.js +0 -56
  103. package/lib/adapters/documentables.js.map +0 -1
  104. package/lib/adapters/fields-and-properties.d.ts +0 -4
  105. package/lib/adapters/fields-and-properties.js +0 -31
  106. package/lib/adapters/fields-and-properties.js.map +0 -1
  107. package/lib/adapters/methods-and-constructors.d.ts +0 -5
  108. package/lib/adapters/methods-and-constructors.js +0 -91
  109. package/lib/adapters/methods-and-constructors.js.map +0 -1
  110. package/lib/adapters/references.d.ts +0 -5
  111. package/lib/adapters/references.js +0 -82
  112. package/lib/adapters/references.js.map +0 -1
  113. package/lib/adapters/type-utils.d.ts +0 -2
  114. package/lib/adapters/type-utils.js +0 -7
  115. package/lib/adapters/type-utils.js.map +0 -1
  116. package/lib/application/Apexdocs.d.ts +0 -13
  117. package/lib/application/Apexdocs.js +0 -86
  118. package/lib/application/Apexdocs.js.map +0 -1
  119. package/lib/application/flows/generate-markdown-files.d.ts +0 -3
  120. package/lib/application/flows/generate-markdown-files.js +0 -57
  121. package/lib/application/flows/generate-markdown-files.js.map +0 -1
  122. package/lib/cli/generate.d.ts +0 -2
  123. package/lib/cli/generate.js +0 -157
  124. package/lib/cli/generate.js.map +0 -1
  125. package/lib/core/__test__/inheritance-chain.test.d.ts +0 -1
  126. package/lib/core/__test__/inheritance-chain.test.js +0 -42
  127. package/lib/core/__test__/inheritance-chain.test.js.map +0 -1
  128. package/lib/core/generate-docs.d.ts +0 -24
  129. package/lib/core/generate-docs.js +0 -267
  130. package/lib/core/generate-docs.js.map +0 -1
  131. package/lib/core/inheritance-chain.d.ts +0 -2
  132. package/lib/core/inheritance-chain.js +0 -35
  133. package/lib/core/inheritance-chain.js.map +0 -1
  134. package/lib/core/template.d.ts +0 -10
  135. package/lib/core/template.js +0 -92
  136. package/lib/core/template.js.map +0 -1
  137. package/lib/core/templates/reference-guide.d.ts +0 -1
  138. package/lib/core/templates/reference-guide.js +0 -18
  139. package/lib/core/templates/reference-guide.js.map +0 -1
  140. package/lib/index.d.ts +0 -2
  141. package/lib/index.js +0 -29
  142. package/lib/index.js.map +0 -1
  143. package/lib/model/apex-bundle.d.ts +0 -6
  144. package/lib/model/apex-bundle.js +0 -11
  145. package/lib/model/apex-bundle.js.map +0 -1
  146. package/lib/model/apex-type-wrappers/ClassMirrorWrapper.d.ts +0 -7
  147. package/lib/model/apex-type-wrappers/ClassMirrorWrapper.js +0 -14
  148. package/lib/model/apex-type-wrappers/ClassMirrorWrapper.js.map +0 -1
  149. package/lib/model/apex-type-wrappers/MethodMirrorWrapper.d.ts +0 -7
  150. package/lib/model/apex-type-wrappers/MethodMirrorWrapper.js +0 -12
  151. package/lib/model/apex-type-wrappers/MethodMirrorWrapper.js.map +0 -1
  152. package/lib/model/inheritance.d.ts +0 -11
  153. package/lib/model/inheritance.js +0 -3
  154. package/lib/model/inheritance.js.map +0 -1
  155. package/lib/model/manifest.d.ts +0 -22
  156. package/lib/model/manifest.js +0 -53
  157. package/lib/model/manifest.js.map +0 -1
  158. package/lib/model/markdown-file.d.ts +0 -16
  159. package/lib/model/markdown-file.js +0 -111
  160. package/lib/model/markdown-file.js.map +0 -1
  161. package/lib/model/markdown-generation-util/doc-comment-annotation-util.d.ts +0 -8
  162. package/lib/model/markdown-generation-util/doc-comment-annotation-util.js +0 -46
  163. package/lib/model/markdown-generation-util/doc-comment-annotation-util.js.map +0 -1
  164. package/lib/model/markdown-generation-util/field-declaration-util.d.ts +0 -3
  165. package/lib/model/markdown-generation-util/field-declaration-util.js +0 -54
  166. package/lib/model/markdown-generation-util/field-declaration-util.js.map +0 -1
  167. package/lib/model/markdown-generation-util/index.d.ts +0 -3
  168. package/lib/model/markdown-generation-util/index.js +0 -20
  169. package/lib/model/markdown-generation-util/index.js.map +0 -1
  170. package/lib/model/markdown-generation-util/method-declaration-util.d.ts +0 -4
  171. package/lib/model/markdown-generation-util/method-declaration-util.js +0 -114
  172. package/lib/model/markdown-generation-util/method-declaration-util.js.map +0 -1
  173. package/lib/model/markdown-generation-util/type-declaration-util.d.ts +0 -3
  174. package/lib/model/markdown-generation-util/type-declaration-util.js +0 -81
  175. package/lib/model/markdown-generation-util/type-declaration-util.js.map +0 -1
  176. package/lib/model/markdown-home-file.d.ts +0 -11
  177. package/lib/model/markdown-home-file.js +0 -57
  178. package/lib/model/markdown-home-file.js.map +0 -1
  179. package/lib/model/markdown-type-file.d.ts +0 -26
  180. package/lib/model/markdown-type-file.js +0 -137
  181. package/lib/model/markdown-type-file.js.map +0 -1
  182. package/lib/model/openapi/apex-doc-types.d.ts +0 -19
  183. package/lib/model/openapi/apex-doc-types.js +0 -5
  184. package/lib/model/openapi/apex-doc-types.js.map +0 -1
  185. package/lib/model/openapi/open-api-types.d.ts +0 -93
  186. package/lib/model/openapi/open-api-types.js +0 -3
  187. package/lib/model/openapi/open-api-types.js.map +0 -1
  188. package/lib/model/openapi/open-api.d.ts +0 -16
  189. package/lib/model/openapi/open-api.js +0 -34
  190. package/lib/model/openapi/open-api.js.map +0 -1
  191. package/lib/model/openapi/openapi-type-file.d.ts +0 -7
  192. package/lib/model/openapi/openapi-type-file.js +0 -17
  193. package/lib/model/openapi/openapi-type-file.js.map +0 -1
  194. package/lib/model/outputFile.d.ts +0 -10
  195. package/lib/model/outputFile.js +0 -22
  196. package/lib/model/outputFile.js.map +0 -1
  197. package/lib/model/types-repository.d.ts +0 -16
  198. package/lib/model/types-repository.js +0 -54
  199. package/lib/model/types-repository.js.map +0 -1
  200. package/lib/service/apex-file-reader.d.ts +0 -14
  201. package/lib/service/apex-file-reader.js +0 -49
  202. package/lib/service/apex-file-reader.js.map +0 -1
  203. package/lib/service/file-system.d.ts +0 -14
  204. package/lib/service/file-system.js +0 -48
  205. package/lib/service/file-system.js.map +0 -1
  206. package/lib/service/file-writer.d.ts +0 -6
  207. package/lib/service/file-writer.js +0 -57
  208. package/lib/service/file-writer.js.map +0 -1
  209. package/lib/service/manifest-factory.d.ts +0 -10
  210. package/lib/service/manifest-factory.js +0 -16
  211. package/lib/service/manifest-factory.js.map +0 -1
  212. package/lib/service/metadata-processor.d.ts +0 -3
  213. package/lib/service/metadata-processor.js +0 -17
  214. package/lib/service/metadata-processor.js.map +0 -1
  215. package/lib/service/parser.d.ts +0 -21
  216. package/lib/service/parser.js +0 -138
  217. package/lib/service/parser.js.map +0 -1
  218. package/lib/service/state.d.ts +0 -9
  219. package/lib/service/state.js +0 -20
  220. package/lib/service/state.js.map +0 -1
  221. package/lib/service/walkers/class-walker.d.ts +0 -4
  222. package/lib/service/walkers/class-walker.js +0 -33
  223. package/lib/service/walkers/class-walker.js.map +0 -1
  224. package/lib/service/walkers/enum-walker.d.ts +0 -4
  225. package/lib/service/walkers/enum-walker.js +0 -11
  226. package/lib/service/walkers/enum-walker.js.map +0 -1
  227. package/lib/service/walkers/interface-walker.d.ts +0 -4
  228. package/lib/service/walkers/interface-walker.js +0 -15
  229. package/lib/service/walkers/interface-walker.js.map +0 -1
  230. package/lib/service/walkers/walker-factory.d.ts +0 -5
  231. package/lib/service/walkers/walker-factory.js +0 -21
  232. package/lib/service/walkers/walker-factory.js.map +0 -1
  233. package/lib/service/walkers/walker.d.ts +0 -19
  234. package/lib/service/walkers/walker.js +0 -17
  235. package/lib/service/walkers/walker.js.map +0 -1
  236. package/lib/settings.d.ts +0 -64
  237. package/lib/settings.js +0 -89
  238. package/lib/settings.js.map +0 -1
  239. package/lib/test-helpers/AnnotationBuilder.d.ts +0 -12
  240. package/lib/test-helpers/AnnotationBuilder.js +0 -31
  241. package/lib/test-helpers/AnnotationBuilder.js.map +0 -1
  242. package/lib/test-helpers/ClassMirrorBuilder.d.ts +0 -22
  243. package/lib/test-helpers/ClassMirrorBuilder.js +0 -64
  244. package/lib/test-helpers/ClassMirrorBuilder.js.map +0 -1
  245. package/lib/test-helpers/DocCommentAnnotationBuilder.d.ts +0 -8
  246. package/lib/test-helpers/DocCommentAnnotationBuilder.js +0 -26
  247. package/lib/test-helpers/DocCommentAnnotationBuilder.js.map +0 -1
  248. package/lib/test-helpers/DocCommentBuilder.d.ts +0 -12
  249. package/lib/test-helpers/DocCommentBuilder.js +0 -38
  250. package/lib/test-helpers/DocCommentBuilder.js.map +0 -1
  251. package/lib/test-helpers/FieldMirrorBuilder.d.ts +0 -18
  252. package/lib/test-helpers/FieldMirrorBuilder.js +0 -54
  253. package/lib/test-helpers/FieldMirrorBuilder.js.map +0 -1
  254. package/lib/test-helpers/InterfaceMirrorBuilder.d.ts +0 -16
  255. package/lib/test-helpers/InterfaceMirrorBuilder.js +0 -43
  256. package/lib/test-helpers/InterfaceMirrorBuilder.js.map +0 -1
  257. package/lib/test-helpers/MethodMirrorBuilder.d.ts +0 -29
  258. package/lib/test-helpers/MethodMirrorBuilder.js +0 -72
  259. package/lib/test-helpers/MethodMirrorBuilder.js.map +0 -1
  260. package/lib/test-helpers/SettingsBuilder.d.ts +0 -8
  261. package/lib/test-helpers/SettingsBuilder.js +0 -27
  262. package/lib/test-helpers/SettingsBuilder.js.map +0 -1
  263. package/lib/transpiler/factory.d.ts +0 -6
  264. package/lib/transpiler/factory.js +0 -35
  265. package/lib/transpiler/factory.js.map +0 -1
  266. package/lib/transpiler/file-container.d.ts +0 -6
  267. package/lib/transpiler/file-container.js +0 -16
  268. package/lib/transpiler/file-container.js.map +0 -1
  269. package/lib/transpiler/generator-choices.d.ts +0 -1
  270. package/lib/transpiler/generator-choices.js +0 -3
  271. package/lib/transpiler/generator-choices.js.map +0 -1
  272. package/lib/transpiler/markdown/class-file-generatorHelper.d.ts +0 -11
  273. package/lib/transpiler/markdown/class-file-generatorHelper.js +0 -75
  274. package/lib/transpiler/markdown/class-file-generatorHelper.js.map +0 -1
  275. package/lib/transpiler/markdown/docsify/docsify-docs-processor.d.ts +0 -6
  276. package/lib/transpiler/markdown/docsify/docsify-docs-processor.js +0 -13
  277. package/lib/transpiler/markdown/docsify/docsify-docs-processor.js.map +0 -1
  278. package/lib/transpiler/markdown/jekyll/jekyll-docsProcessor.d.ts +0 -11
  279. package/lib/transpiler/markdown/jekyll/jekyll-docsProcessor.js +0 -51
  280. package/lib/transpiler/markdown/jekyll/jekyll-docsProcessor.js.map +0 -1
  281. package/lib/transpiler/markdown/markdown-transpiler-base.d.ts +0 -11
  282. package/lib/transpiler/markdown/markdown-transpiler-base.js +0 -27
  283. package/lib/transpiler/markdown/markdown-transpiler-base.js.map +0 -1
  284. package/lib/transpiler/markdown/plain-markdown/class-template.d.ts +0 -1
  285. package/lib/transpiler/markdown/plain-markdown/class-template.js +0 -77
  286. package/lib/transpiler/markdown/plain-markdown/class-template.js.map +0 -1
  287. package/lib/transpiler/markdown/plain-markdown/constructors-partial-template.d.ts +0 -1
  288. package/lib/transpiler/markdown/plain-markdown/constructors-partial-template.js +0 -36
  289. package/lib/transpiler/markdown/plain-markdown/constructors-partial-template.js.map +0 -1
  290. package/lib/transpiler/markdown/plain-markdown/documentable-partial-template.d.ts +0 -1
  291. package/lib/transpiler/markdown/plain-markdown/documentable-partial-template.js +0 -28
  292. package/lib/transpiler/markdown/plain-markdown/documentable-partial-template.js.map +0 -1
  293. package/lib/transpiler/markdown/plain-markdown/enum-template.d.ts +0 -1
  294. package/lib/transpiler/markdown/plain-markdown/enum-template.js +0 -16
  295. package/lib/transpiler/markdown/plain-markdown/enum-template.js.map +0 -1
  296. package/lib/transpiler/markdown/plain-markdown/fieldsPartialTemplate.d.ts +0 -1
  297. package/lib/transpiler/markdown/plain-markdown/fieldsPartialTemplate.js +0 -27
  298. package/lib/transpiler/markdown/plain-markdown/fieldsPartialTemplate.js.map +0 -1
  299. package/lib/transpiler/markdown/plain-markdown/grouped-members-partial-template.d.ts +0 -1
  300. package/lib/transpiler/markdown/plain-markdown/grouped-members-partial-template.js +0 -10
  301. package/lib/transpiler/markdown/plain-markdown/grouped-members-partial-template.js.map +0 -1
  302. package/lib/transpiler/markdown/plain-markdown/interface-template.d.ts +0 -1
  303. package/lib/transpiler/markdown/plain-markdown/interface-template.js +0 -20
  304. package/lib/transpiler/markdown/plain-markdown/interface-template.js.map +0 -1
  305. package/lib/transpiler/markdown/plain-markdown/methods-partial-template.d.ts +0 -1
  306. package/lib/transpiler/markdown/plain-markdown/methods-partial-template.js +0 -47
  307. package/lib/transpiler/markdown/plain-markdown/methods-partial-template.js.map +0 -1
  308. package/lib/transpiler/markdown/plain-markdown/plain-docsProcessor.d.ts +0 -9
  309. package/lib/transpiler/markdown/plain-markdown/plain-docsProcessor.js +0 -42
  310. package/lib/transpiler/markdown/plain-markdown/plain-docsProcessor.js.map +0 -1
  311. package/lib/transpiler/markdown/plain-markdown/type-doc-partial.d.ts +0 -1
  312. package/lib/transpiler/markdown/plain-markdown/type-doc-partial.js +0 -31
  313. package/lib/transpiler/markdown/plain-markdown/type-doc-partial.js.map +0 -1
  314. package/lib/transpiler/openapi/open-api-docs-processor.d.ts +0 -13
  315. package/lib/transpiler/openapi/open-api-docs-processor.js +0 -78
  316. package/lib/transpiler/openapi/open-api-docs-processor.js.map +0 -1
  317. package/lib/transpiler/openapi/parsers/Builder.d.ts +0 -16
  318. package/lib/transpiler/openapi/parsers/Builder.js +0 -30
  319. package/lib/transpiler/openapi/parsers/Builder.js.map +0 -1
  320. package/lib/transpiler/openapi/parsers/MethodParser.d.ts +0 -20
  321. package/lib/transpiler/openapi/parsers/MethodParser.js +0 -190
  322. package/lib/transpiler/openapi/parsers/MethodParser.js.map +0 -1
  323. package/lib/transpiler/openapi/parsers/ParameterObjectBuilder.d.ts +0 -7
  324. package/lib/transpiler/openapi/parsers/ParameterObjectBuilder.js +0 -11
  325. package/lib/transpiler/openapi/parsers/ParameterObjectBuilder.js.map +0 -1
  326. package/lib/transpiler/openapi/parsers/ReferenceBuilder.d.ts +0 -39
  327. package/lib/transpiler/openapi/parsers/ReferenceBuilder.js +0 -250
  328. package/lib/transpiler/openapi/parsers/ReferenceBuilder.js.map +0 -1
  329. package/lib/transpiler/openapi/parsers/RequestBodyBuilder.d.ts +0 -10
  330. package/lib/transpiler/openapi/parsers/RequestBodyBuilder.js +0 -20
  331. package/lib/transpiler/openapi/parsers/RequestBodyBuilder.js.map +0 -1
  332. package/lib/transpiler/openapi/parsers/ResponsesBuilder.d.ts +0 -7
  333. package/lib/transpiler/openapi/parsers/ResponsesBuilder.js +0 -22
  334. package/lib/transpiler/openapi/parsers/ResponsesBuilder.js.map +0 -1
  335. package/lib/transpiler/processor-type-transpiler.d.ts +0 -10
  336. package/lib/transpiler/processor-type-transpiler.js +0 -9
  337. package/lib/transpiler/processor-type-transpiler.js.map +0 -1
  338. package/lib/transpiler/transpiler.d.ts +0 -5
  339. package/lib/transpiler/transpiler.js +0 -30
  340. package/lib/transpiler/transpiler.js.map +0 -1
  341. package/lib/util/error-logger.d.ts +0 -8
  342. package/lib/util/error-logger.js +0 -90
  343. package/lib/util/error-logger.js.map +0 -1
  344. package/lib/util/logger.d.ts +0 -21
  345. package/lib/util/logger.js +0 -61
  346. package/lib/util/logger.js.map +0 -1
  347. package/lib/util/string-utils.d.ts +0 -2
  348. package/lib/util/string-utils.js +0 -15
  349. package/lib/util/string-utils.js.map +0 -1
  350. package/src/adapters/type-utils.ts +0 -5
  351. package/src/adapters/types.d.ts +0 -8
  352. package/src/model/inheritance.ts +0 -8
  353. package/src/transpiler/markdown/plain-markdown/plain-docsProcessor.ts +0 -42
  354. /package/src/{model → core}/apex-bundle.ts +0 -0
  355. /package/src/{model → core}/manifest.ts +0 -0
@@ -1,92 +0,0 @@
1
- "use strict";
2
- var __importDefault = (this && this.__importDefault) || function (mod) {
3
- return (mod && mod.__esModule) ? mod : { "default": mod };
4
- };
5
- Object.defineProperty(exports, "__esModule", { value: true });
6
- exports.Template = void 0;
7
- const handlebars_1 = __importDefault(require("handlebars"));
8
- const type_doc_partial_1 = require("../transpiler/markdown/plain-markdown/type-doc-partial");
9
- const documentable_partial_template_1 = require("../transpiler/markdown/plain-markdown/documentable-partial-template");
10
- const methods_partial_template_1 = require("../transpiler/markdown/plain-markdown/methods-partial-template");
11
- const constructors_partial_template_1 = require("../transpiler/markdown/plain-markdown/constructors-partial-template");
12
- const fieldsPartialTemplate_1 = require("../transpiler/markdown/plain-markdown/fieldsPartialTemplate");
13
- const class_template_1 = require("../transpiler/markdown/plain-markdown/class-template");
14
- const enum_template_1 = require("../transpiler/markdown/plain-markdown/enum-template");
15
- const interface_template_1 = require("../transpiler/markdown/plain-markdown/interface-template");
16
- const type_utils_1 = require("../adapters/type-utils");
17
- const grouped_members_partial_template_1 = require("../transpiler/markdown/plain-markdown/grouped-members-partial-template");
18
- class Template {
19
- constructor() {
20
- handlebars_1.default.registerPartial('typeDocumentation', type_doc_partial_1.typeDocPartial);
21
- handlebars_1.default.registerPartial('documentablePartialTemplate', documentable_partial_template_1.documentablePartialTemplate);
22
- handlebars_1.default.registerPartial('methodsPartialTemplate', methods_partial_template_1.methodsPartialTemplate);
23
- handlebars_1.default.registerPartial('constructorsPartialTemplate', constructors_partial_template_1.constructorsPartialTemplate);
24
- handlebars_1.default.registerPartial('groupedMembersPartialTemplate', grouped_members_partial_template_1.groupedMembersPartialTemplate);
25
- handlebars_1.default.registerPartial('fieldsPartialTemplate', fieldsPartialTemplate_1.fieldsPartialTemplate);
26
- handlebars_1.default.registerPartial('classTemplate', class_template_1.classMarkdownTemplate);
27
- handlebars_1.default.registerPartial('enumTemplate', enum_template_1.enumMarkdownTemplate);
28
- handlebars_1.default.registerPartial('interfaceTemplate', interface_template_1.interfaceMarkdownTemplate);
29
- handlebars_1.default.registerHelper('link', link);
30
- handlebars_1.default.registerHelper('code', convertCodeBlock);
31
- handlebars_1.default.registerHelper('withLinks', resolveLinksInContent);
32
- handlebars_1.default.registerHelper('heading', heading);
33
- handlebars_1.default.registerHelper('inlineCode', inlineCode);
34
- handlebars_1.default.registerHelper('splitAndCapitalize', splitAndCapitalize);
35
- }
36
- static getInstance() {
37
- if (!Template.instance) {
38
- Template.instance = new Template();
39
- }
40
- return Template.instance;
41
- }
42
- compile(request) {
43
- const compiled = handlebars_1.default.compile(request.template);
44
- return (compiled(request.source)
45
- .trim()
46
- // clean up extra newlines
47
- .replace(/\n{3,}/g, '\n\n'));
48
- }
49
- }
50
- exports.Template = Template;
51
- const splitAndCapitalize = (text) => {
52
- const words = text.split(/[-_]+/);
53
- const capitalizedWords = [];
54
- for (const word of words) {
55
- capitalizedWords.push(word.charAt(0).toUpperCase() + word.slice(1));
56
- }
57
- return capitalizedWords.join(' ');
58
- };
59
- const heading = (level, text) => {
60
- return `${'#'.repeat(level)} ${text}`;
61
- };
62
- const inlineCode = (text) => {
63
- return new handlebars_1.default.SafeString(`\`${text}\``);
64
- };
65
- const convertCodeBlock = (language, lines) => {
66
- return new handlebars_1.default.SafeString(`
67
- \`\`\`${language}
68
- ${lines.join('\n')}
69
- \`\`\`
70
- `.trim());
71
- };
72
- const resolveLinksInContent = (description) => {
73
- if (!description) {
74
- return '';
75
- }
76
- function reduceDescription(acc, curr) {
77
- if ((0, type_utils_1.isEmptyLine)(curr)) {
78
- return acc + '\n\n';
79
- }
80
- return acc + link(curr).trim() + ' ';
81
- }
82
- return description.reduce(reduceDescription, '').trim();
83
- };
84
- const link = (source) => {
85
- if (typeof source === 'string') {
86
- return source;
87
- }
88
- else {
89
- return `[${source.title}](${source.url})`;
90
- }
91
- };
92
- //# sourceMappingURL=template.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"template.js","sourceRoot":"","sources":["../../src/core/template.ts"],"names":[],"mappings":";;;;;;AAAA,4DAAoC;AACpC,6FAAwF;AACxF,uHAAkH;AAClH,6GAAwG;AACxG,uHAAkH;AAClH,uGAAoG;AACpG,yFAA6F;AAC7F,uFAA2F;AAC3F,iGAAqG;AAErG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AM,qBAAqB,GAAG,CAAC,WAAiC,EAAU,EAAE;IAC1E,IAAI,CAAC,WAAW,EAAE,CAAC;QACjB,OAAO,EAAE,CAAC;IACZ,CAAC;IAED,SAAS,iBAAiB,CAAC,GAAW,EAAE,IAAuB;QAC7D,IAAI,IAAA,wBAAW,EAAC,IAAI,CAAC,EAAE,CAAC;YACtB,OAAO,GAAG,GAAG,MAAM,CAAC;QACtB,CAAC;QAED,OAAO,GAAG,GAAG,IAAI,CAAC,IAAI,CAAC,CAAC,IAAI,EAAE,GAAG,GAAG,CAAC;IACvC,CAAC;IAED,OAAO,WAAW,CAAC,MAAM,CAAC,iBAAiB,EAAE,EAAE,CAAC,CAAC,IAAI,EAAE,CAAC;AAC1D,CAAC,CAAC;AAEF,MAAM,IAAI,GAAG,CAAC,MAAoB,EAAU,EAAE;IAC5C,IAAI,OAAO,MAAM,KAAK,QAAQ,EAAE,CAAC;QAC/B,OAAO,MAAM,CAAC;IAChB,CAAC;SAAM,CAAC;QACN,OAAO,IAAI,MAAM,CAAC,KAAK,KAAK,MAAM,CAAC,GAAG,GAAG,CAAC;IAC5C,CAAC;AACH,CAAC,CAAC"}
@@ -1 +0,0 @@
1
- export declare const referenceGuideTemplate: string;
@@ -1,18 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.referenceGuideTemplate = void 0;
4
- exports.referenceGuideTemplate = `
5
- # Apex Reference Guide
6
-
7
- {{#each this}}
8
- ## {{@key}}
9
-
10
- {{#each this}}
11
- ### {{link title}}
12
-
13
- {{withLinks description}}
14
-
15
- {{/each}}
16
- {{/each}}
17
- `.trim();
18
- //# sourceMappingURL=reference-guide.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"reference-guide.js","sourceRoot":"","sources":["../../../src/core/templates/reference-guide.ts"],"names":[],"mappings":";;;AAAa,QAAA,sBAAsB,GAAG;;;;;;;;;;;;;CAarC,CAAC,IAAI,EAAE,CAAC"}
package/lib/index.d.ts DELETED
@@ -1,2 +0,0 @@
1
- import * as reflection from '@cparra/apex-reflection';
2
- export { reflection };
package/lib/index.js DELETED
@@ -1,29 +0,0 @@
1
- "use strict";
2
- var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
3
- if (k2 === undefined) k2 = k;
4
- var desc = Object.getOwnPropertyDescriptor(m, k);
5
- if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
6
- desc = { enumerable: true, get: function() { return m[k]; } };
7
- }
8
- Object.defineProperty(o, k2, desc);
9
- }) : (function(o, m, k, k2) {
10
- if (k2 === undefined) k2 = k;
11
- o[k2] = m[k];
12
- }));
13
- var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
14
- Object.defineProperty(o, "default", { enumerable: true, value: v });
15
- }) : function(o, v) {
16
- o["default"] = v;
17
- });
18
- var __importStar = (this && this.__importStar) || function (mod) {
19
- if (mod && mod.__esModule) return mod;
20
- var result = {};
21
- if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);
22
- __setModuleDefault(result, mod);
23
- return result;
24
- };
25
- Object.defineProperty(exports, "__esModule", { value: true });
26
- exports.reflection = void 0;
27
- const reflection = __importStar(require("@cparra/apex-reflection"));
28
- exports.reflection = reflection;
29
- //# sourceMappingURL=index.js.map
package/lib/index.js.map DELETED
@@ -1 +0,0 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;AAAA,oEAAsD;AAE7C,gCAAU"}
@@ -1,6 +0,0 @@
1
- export default class ApexBundle {
2
- filePath: string;
3
- rawTypeContent: string;
4
- rawMetadataContent: string | null;
5
- constructor(filePath: string, rawTypeContent: string, rawMetadataContent: string | null);
6
- }
@@ -1,11 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- class ApexBundle {
4
- constructor(filePath, rawTypeContent, rawMetadataContent) {
5
- this.filePath = filePath;
6
- this.rawTypeContent = rawTypeContent;
7
- this.rawMetadataContent = rawMetadataContent;
8
- }
9
- }
10
- exports.default = ApexBundle;
11
- //# sourceMappingURL=apex-bundle.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"apex-bundle.js","sourceRoot":"","sources":["../../src/model/apex-bundle.ts"],"names":[],"mappings":";;AAAA,MAAqB,UAAU;IAC7B,YAAmB,QAAgB,EAAS,cAAsB,EAAS,kBAAiC;QAAzF,aAAQ,GAAR,QAAQ,CAAQ;QAAS,mBAAc,GAAd,cAAc,CAAQ;QAAS,uBAAkB,GAAlB,kBAAkB,CAAe;IAAG,CAAC;CACjH;AAFD,6BAEC"}
@@ -1,7 +0,0 @@
1
- import { ClassMirror, MethodMirror } from '@cparra/apex-reflection';
2
- export declare class ClassMirrorWrapper {
3
- classMirror: ClassMirror;
4
- constructor(classMirror: ClassMirror);
5
- getMethodsByAnnotation(annotation: string): MethodMirror[];
6
- private hasAnnotation;
7
- }
@@ -1,14 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.ClassMirrorWrapper = void 0;
4
- class ClassMirrorWrapper {
5
- constructor(classMirror) {
6
- this.classMirror = classMirror;
7
- this.hasAnnotation = (method, annotationName) => method.annotations.some((annotation) => annotation.name.toLowerCase() === annotationName);
8
- }
9
- getMethodsByAnnotation(annotation) {
10
- return this.classMirror.methods.filter((method) => this.hasAnnotation(method, annotation));
11
- }
12
- }
13
- exports.ClassMirrorWrapper = ClassMirrorWrapper;
14
- //# sourceMappingURL=ClassMirrorWrapper.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"ClassMirrorWrapper.js","sourceRoot":"","sources":["../../../src/model/apex-type-wrappers/ClassMirrorWrapper.ts"],"names":[],"mappings":";;;AAEA,MAAa,kBAAkB;IAC7B,YAAmB,WAAwB;QAAxB,gBAAW,GAAX,WAAW,CAAa;QAMnC,kBAAa,GAAG,CAAC,MAAoB,EAAE,cAAsB,EAAE,EAAE,CACvE,MAAM,CAAC,WAAW,CAAC,IAAI,CAAC,CAAC,UAAU,EAAE,EAAE,CAAC,UAAU,CAAC,IAAI,CAAC,WAAW,EAAE,KAAK,cAAc,CAAC,CAAC;IAP9C,CAAC;IAE/C,sBAAsB,CAAC,UAAkB;QACvC,OAAO,IAAI,CAAC,WAAW,CAAC,OAAO,CAAC,MAAM,CAAC,CAAC,MAAM,EAAE,EAAE,CAAC,IAAI,CAAC,aAAa,CAAC,MAAM,EAAE,UAAU,CAAC,CAAC,CAAC;IAC7F,CAAC;CAIF;AATD,gDASC"}
@@ -1,7 +0,0 @@
1
- import { DocCommentAnnotation, MethodMirror } from '@cparra/apex-reflection';
2
- export declare class MethodMirrorWrapper {
3
- methodMirror: MethodMirror;
4
- constructor(methodMirror: MethodMirror);
5
- hasDocCommentAnnotation: (annotationName: string) => boolean | undefined;
6
- getDocCommentAnnotation: (annotationName: string) => DocCommentAnnotation | undefined;
7
- }
@@ -1,12 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.MethodMirrorWrapper = void 0;
4
- class MethodMirrorWrapper {
5
- constructor(methodMirror) {
6
- this.methodMirror = methodMirror;
7
- this.hasDocCommentAnnotation = (annotationName) => { var _a; return (_a = this.methodMirror.docComment) === null || _a === void 0 ? void 0 : _a.annotations.some((annotation) => annotation.name.toLowerCase() === annotationName); };
8
- this.getDocCommentAnnotation = (annotationName) => { var _a; return (_a = this.methodMirror.docComment) === null || _a === void 0 ? void 0 : _a.annotations.find((annotation) => annotation.name.toLowerCase() === annotationName); };
9
- }
10
- }
11
- exports.MethodMirrorWrapper = MethodMirrorWrapper;
12
- //# sourceMappingURL=MethodMirrorWrapper.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"MethodMirrorWrapper.js","sourceRoot":"","sources":["../../../src/model/apex-type-wrappers/MethodMirrorWrapper.ts"],"names":[],"mappings":";;;AAEA,MAAa,mBAAmB;IAC9B,YAAmB,YAA0B;QAA1B,iBAAY,GAAZ,YAAY,CAAc;QAEtC,4BAAuB,GAAG,CAAC,cAAsB,EAAE,EAAE,WAC1D,OAAA,MAAA,IAAI,CAAC,YAAY,CAAC,UAAU,0CAAE,WAAW,CAAC,IAAI,CAAC,CAAC,UAAU,EAAE,EAAE,CAAC,UAAU,CAAC,IAAI,CAAC,WAAW,EAAE,KAAK,cAAc,CAAC,CAAA,EAAA,CAAC;QAE5G,4BAAuB,GAAG,CAAC,cAAsB,EAAoC,EAAE,WAC5F,OAAA,MAAA,IAAI,CAAC,YAAY,CAAC,UAAU,0CAAE,WAAW,CAAC,IAAI,CAAC,CAAC,UAAU,EAAE,EAAE,CAAC,UAAU,CAAC,IAAI,CAAC,WAAW,EAAE,KAAK,cAAc,CAAC,CAAA,EAAA,CAAC;IANnE,CAAC;CAOlD;AARD,kDAQC"}
@@ -1,11 +0,0 @@
1
- import { ClassMirror, FieldMirror, MethodMirror, PropertyMirror } from '@cparra/apex-reflection';
2
- export type InheritanceSupport = {
3
- inherited: boolean;
4
- };
5
- export type ClassMirrorWithInheritanceChain = ClassMirror & {
6
- inheritanceChain: string[];
7
- };
8
- export type FieldMirrorWithInheritance = FieldMirror & InheritanceSupport;
9
- export type PropertyMirrorWithInheritance = PropertyMirror & InheritanceSupport;
10
- export type MethodMirrorWithInheritance = MethodMirror & InheritanceSupport;
11
- export type FieldOrProperty = FieldMirrorWithInheritance | PropertyMirrorWithInheritance;
@@ -1,3 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- //# sourceMappingURL=inheritance.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"inheritance.js","sourceRoot":"","sources":["../../src/model/inheritance.ts"],"names":[],"mappings":""}
@@ -1,22 +0,0 @@
1
- import { Type, Annotation, DocComment } from '@cparra/apex-reflection';
2
- type AccessAndDocAware = {
3
- access_modifier: string;
4
- annotations: Annotation[];
5
- docComment?: DocComment;
6
- };
7
- /**
8
- * Represents the full library of Apex top-level types (classes, enums, and interface) for a Salesforce project.
9
- */
10
- export default class Manifest {
11
- types: Type[];
12
- isForInnerTypes: boolean;
13
- /**
14
- * Constructs a new Manifest object.
15
- * @param types List of types to be wrapped by this object.
16
- * @param isForInnerTypes Whether this manifest represent an inner type or not.
17
- */
18
- constructor(types: Type[], isForInnerTypes?: boolean);
19
- filteredByAccessModifierAndAnnotations(modifiers: string[]): Type[];
20
- filterAccessibleModifier(accessAndDocAware: AccessAndDocAware[], modifiers: string[]): AccessAndDocAware[];
21
- }
22
- export {};
@@ -1,53 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- /**
4
- * Represents the full library of Apex top-level types (classes, enums, and interface) for a Salesforce project.
5
- */
6
- class Manifest {
7
- /**
8
- * Constructs a new Manifest object.
9
- * @param types List of types to be wrapped by this object.
10
- * @param isForInnerTypes Whether this manifest represent an inner type or not.
11
- */
12
- constructor(types, isForInnerTypes = false) {
13
- this.types = types;
14
- this.isForInnerTypes = isForInnerTypes;
15
- }
16
- filteredByAccessModifierAndAnnotations(modifiers) {
17
- const filteredTypes = this.filterAccessibleModifier(this.types, modifiers);
18
- const typesToReturn = [];
19
- for (const filteredType of filteredTypes) {
20
- const currentType = filteredType;
21
- if (currentType.type_name === 'enum') {
22
- // Ignoring enum values is not supported.
23
- typesToReturn.push(currentType);
24
- continue;
25
- }
26
- if (currentType.type_name === 'interface') {
27
- const currentInterface = currentType;
28
- typesToReturn.push(Object.assign(Object.assign({}, currentType), { methods: this.filterAccessibleModifier(currentInterface.methods, modifiers) }));
29
- continue;
30
- }
31
- const currentClass = currentType;
32
- let filteredClass = Object.assign(Object.assign({}, currentType), { methods: this.filterAccessibleModifier(currentClass.methods, modifiers), properties: this.filterAccessibleModifier(currentClass.properties, modifiers), fields: this.filterAccessibleModifier(currentClass.fields, modifiers), constructors: this.filterAccessibleModifier(currentClass.constructors, modifiers) });
33
- if (!this.isForInnerTypes) {
34
- filteredClass = Object.assign(Object.assign({}, filteredClass), { enums: this.filterAccessibleModifier(currentClass.enums, modifiers), interfaces: this.filterAccessibleModifier(currentClass.interfaces, modifiers), classes: new Manifest(currentClass.classes, true).filteredByAccessModifierAndAnnotations(modifiers) });
35
- }
36
- typesToReturn.push(filteredClass);
37
- }
38
- return typesToReturn;
39
- }
40
- filterAccessibleModifier(accessAndDocAware, modifiers) {
41
- return accessAndDocAware.filter((currentType) => {
42
- var _a;
43
- const hasIgnoreDocAnnotation = (_a = currentType.docComment) === null || _a === void 0 ? void 0 : _a.annotations.some((annotation) => annotation.name.toLowerCase() === 'ignore');
44
- if (hasIgnoreDocAnnotation) {
45
- return false;
46
- }
47
- return (modifiers.includes(currentType.access_modifier) ||
48
- currentType.annotations.some((annotation) => modifiers.includes(annotation.type.toLowerCase())));
49
- });
50
- }
51
- }
52
- exports.default = Manifest;
53
- //# sourceMappingURL=manifest.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"manifest.js","sourceRoot":"","sources":["../../src/model/manifest.ts"],"names":[],"mappings":";;AAYA;;GAEG;AACH,MAAqB,QAAQ;IAC3B;;;;OAIG;IACH,YAAmB,KAAa,EAAS,kBAA2B,KAAK;QAAtD,UAAK,GAAL,KAAK,CAAQ;QAAS,oBAAe,GAAf,eAAe,CAAiB;IAAG,CAAC;IAE7E,sCAAsC,CAAC,SAAmB;QACxD,MAAM,aAAa,GAAG,IAAI,CAAC,wBAAwB,CAAC,IAAI,CAAC,KAAK,EAAE,SAAS,CAAC,CAAC;QAC3E,MAAM,aAAa,GAAW,EAAE,CAAC;QACjC,KAAK,MAAM,YAAY,IAAI,aAAa,EAAE,CAAC;YACzC,MAAM,WAAW,GAAG,YAAoB,CAAC;YACzC,IAAI,WAAW,CAAC,SAAS,KAAK,MAAM,EAAE,CAAC;gBACrC,yCAAyC;gBACzC,aAAa,CAAC,IAAI,CAAC,WAAW,CAAC,CAAC;gBAChC,SAAS;YACX,CAAC;YAED,IAAI,WAAW,CAAC,SAA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AAG,MAAA,WAAW,CAAC,UAAU,0CAAE,WAAW,CAAC,IAAI,CACrE,CAAC,UAAgC,EAAE,EAAE,CAAC,UAAU,CAAC,IAAI,CAAC,WAAW,EAAE,KAAK,QAAQ,CACjF,CAAC;YACF,IAAI,sBAAsB,EAAE,CAAC;gBAC3B,OAAO,KAAK,CAAC;YACf,CAAC;YACD,OAAO,CACL,SAAS,CAAC,QAAQ,CAAC,WAAW,CAAC,eAAe,CAAC;gBAC/C,WAAW,CAAC,WAAW,CAAC,IAAI,CAAC,CAAC,UAAsB,EAAE,EAAE,CAAC,SAAS,CAAC,QAAQ,CAAC,UAAU,CAAC,IAAI,CAAC,WAAW,EAAE,CAAC,CAAC,CAC5G,CAAC;QACJ,CAAC,CAAC,CAAC;IACL,CAAC;CACF;AApED,2BAoEC"}
@@ -1,16 +0,0 @@
1
- import { OutputFile } from './outputFile';
2
- export declare class MarkdownFile extends OutputFile {
3
- fileExtension(): string;
4
- addTitle(text: string, level?: number): void;
5
- addText(text: string): this;
6
- addLink(text: string): void;
7
- startCodeBlock(language?: string): void;
8
- endCodeBlock(): void;
9
- addHorizontalRule(): void;
10
- initializeTable(...headers: string[]): void;
11
- addTableRow(...columns: string[]): void;
12
- addListItem(text: string): void;
13
- protected static replaceInlineLinks(text: string): string;
14
- protected static replaceInlineEmails(text: string): string;
15
- private _replaceInlineReferences;
16
- }
@@ -1,111 +0,0 @@
1
- "use strict";
2
- var __importDefault = (this && this.__importDefault) || function (mod) {
3
- return (mod && mod.__esModule) ? mod : { "default": mod };
4
- };
5
- Object.defineProperty(exports, "__esModule", { value: true });
6
- exports.MarkdownFile = void 0;
7
- const outputFile_1 = require("./outputFile");
8
- const class_file_generatorHelper_1 = __importDefault(require("../transpiler/markdown/class-file-generatorHelper"));
9
- class MarkdownFile extends outputFile_1.OutputFile {
10
- fileExtension() {
11
- return '.md';
12
- }
13
- addTitle(text, level = 1) {
14
- let title = '';
15
- for (let i = 0; i < level; i++) {
16
- title += '#';
17
- }
18
- title += ' ';
19
- title += text;
20
- this._contents += title;
21
- this.addBlankLine();
22
- }
23
- addText(text) {
24
- super.addText(text);
25
- return this;
26
- }
27
- addLink(text) {
28
- this.addText(`{@link ${text}}`);
29
- }
30
- startCodeBlock(language = 'apex') {
31
- this.addText(`\`\`\`${language}`);
32
- }
33
- endCodeBlock() {
34
- this.addText('```');
35
- this.addBlankLine();
36
- }
37
- addHorizontalRule() {
38
- this._contents += '---';
39
- this.addBlankLine();
40
- }
41
- initializeTable(...headers) {
42
- this.addBlankLine();
43
- this._contents += '|';
44
- headers.forEach((header) => {
45
- this._contents += header + '|';
46
- });
47
- this.addBlankLine();
48
- this._contents += '|';
49
- headers.forEach(() => {
50
- this._contents += '---' + '|';
51
- });
52
- this.addBlankLine();
53
- }
54
- addTableRow(...columns) {
55
- this._contents += '|';
56
- columns.forEach((column) => {
57
- this._contents += this._replaceInlineReferences(column) + '|';
58
- });
59
- this.addBlankLine();
60
- }
61
- addListItem(text) {
62
- this._contents += `* ${text}`;
63
- }
64
- static replaceInlineLinks(text) {
65
- // Parsing text to extract possible linking classes.
66
- const possibleLinks = text.match(/<<.*?>>/g);
67
- possibleLinks === null || possibleLinks === void 0 ? void 0 : possibleLinks.forEach((currentMatch) => {
68
- const classNameForMatch = currentMatch.replace('<<', '').replace('>>', '');
69
- text = text.replace(currentMatch, class_file_generatorHelper_1.default.getFileLinkByTypeName(classNameForMatch));
70
- });
71
- // Parsing links using {@link ClassName} format
72
- const linkFormatRegEx = '{@link (.*?)}';
73
- const expression = new RegExp(linkFormatRegEx, 'gi');
74
- let match;
75
- const matches = [];
76
- do {
77
- match = expression.exec(text);
78
- if (match) {
79
- matches.push(match);
80
- }
81
- } while (match);
82
- for (const currentMatch of matches) {
83
- text = text.replace(currentMatch[0], class_file_generatorHelper_1.default.getFileLinkByTypeName(currentMatch[1]));
84
- }
85
- return text;
86
- }
87
- static replaceInlineEmails(text) {
88
- // Parsing links using {@link ClassName} format
89
- const linkFormatRegEx = '{@email (.*?)}';
90
- const expression = new RegExp(linkFormatRegEx, 'gi');
91
- let match;
92
- const matches = [];
93
- do {
94
- match = expression.exec(text);
95
- if (match) {
96
- matches.push(match);
97
- }
98
- } while (match);
99
- for (const currentMatch of matches) {
100
- text = text.replace(currentMatch[0], `[${currentMatch[1]}](mailto:${currentMatch[1]})`);
101
- }
102
- return text;
103
- }
104
- _replaceInlineReferences(text) {
105
- text = MarkdownFile.replaceInlineLinks(text);
106
- text = MarkdownFile.replaceInlineEmails(text);
107
- return text;
108
- }
109
- }
110
- exports.MarkdownFile = MarkdownFile;
111
- //# sourceMappingURL=markdown-file.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"markdown-file.js","sourceRoot":"","sources":["../../src/model/markdown-file.ts"],"names":[],"mappings":";;;;;;AAAA,6CAA0C;AAC1C,mHAAyF;AAEzF,MAAa,YAAa,SAAQ,uBAAU;IAC1C,aAAa;QACX,OAAO,KAAK,CAAC;IACf,CAAC;IAED,QAAQ,CAAC,IAAY,EAAE,KAAK,GAAG,CAAC;QAC9B,IAAI,KAAK,GAAG,EAAE,CAAC;QACf,KAAK,IAAI,CAAC,GAAG,CAAC,EAAE,CAAC,GAAG,KAAK,EAAE,CAAC,EAAE,EAAE,CAAC;YAC/B,KAAK,IAAI,GAAG,CAAC;QACf,CAAC;QAED,KAAK,IAAI,GAAG,CAAC;QACb,KAAK,IAAI,IAAI,CAAC;QACd,IAAI,CAAC,SAAS,IAAI,KAAK,CAAC;QACxB,IAAI,CAAC,YAAY,EAAE,CAAC;IACtB,CAAC;IAEM,OAAO,CAAC,IAAY;QACzB,KAAK,CAAC,OAAO,CAAC,IAAI,CAAC,CAAC;QACpB,OAAO,IAAI,CAAC;IACd,CAAC;IAEM,OAAO,CAAC,IAAY;QACzB,IAAI,CAAC,OAAO,CAAC,UAAU,IAAI,GAAG,CAAC,CAAC;IAClC,CAAC;IAED,cAAc,CAAC,QAAQ,GAAG,MAAM;QAC9B,IAAI,CAAC,OAAO,CAAC,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I,CAAC,IAAI,CAAC,CAAC;YAC9B,IAAI,KAAK,EAAE,CAAC;gBACV,OAAO,CAAC,IAAI,CAAC,KAAK,CAAC,CAAC;YACtB,CAAC;QACH,CAAC,QAAQ,KAAK,EAAE;QAEhB,KAAK,MAAM,YAAY,IAAI,OAAO,EAAE,CAAC;YACnC,IAAI,GAAG,IAAI,CAAC,OAAO,CAAC,YAAY,CAAC,CAAC,CAAC,EAAE,IAAI,YAAY,CAAC,CAAC,CAAC,YAAY,YAAY,CAAC,CAAC,CAAC,GAAG,CAAC,CAAC;QAC1F,CAAC;QACD,OAAO,IAAI,CAAC;IACd,CAAC;IAEO,wBAAwB,CAAC,IAAY;QAC3C,IAAI,GAAG,YAAY,CAAC,kBAAkB,CAAC,IAAI,CAAC,CAAC;QAC7C,IAAI,GAAG,YAAY,CAAC,mBAAmB,CAAC,IAAI,CAAC,CAAC;QAC9C,OAAO,IAAI,CAAC;IACd,CAAC;CACF;AAtHD,oCAsHC"}
@@ -1,8 +0,0 @@
1
- import { DocComment } from '@cparra/apex-reflection';
2
- import { MarkdownFile } from '../markdown-file';
3
- interface DocCommentAware {
4
- docComment?: DocComment;
5
- }
6
- export declare function addMermaid(markdownFile: MarkdownFile, docCommentAware: DocCommentAware): void;
7
- export declare function addCustomDocCommentAnnotations(markdownFile: MarkdownFile, docCommentAware: DocCommentAware): void;
8
- export {};
@@ -1,46 +0,0 @@
1
- "use strict";
2
- var __importDefault = (this && this.__importDefault) || function (mod) {
3
- return (mod && mod.__esModule) ? mod : { "default": mod };
4
- };
5
- Object.defineProperty(exports, "__esModule", { value: true });
6
- exports.addMermaid = addMermaid;
7
- exports.addCustomDocCommentAnnotations = addCustomDocCommentAnnotations;
8
- const class_file_generatorHelper_1 = __importDefault(require("../../transpiler/markdown/class-file-generatorHelper"));
9
- function addMermaid(markdownFile, docCommentAware) {
10
- var _a;
11
- const mermaid = (_a = docCommentAware.docComment) === null || _a === void 0 ? void 0 : _a.annotations.find((annotation) => annotation.name === 'mermaid');
12
- if (!mermaid) {
13
- return;
14
- }
15
- markdownFile.addBlankLine();
16
- markdownFile.startCodeBlock('mermaid');
17
- mermaid.bodyLines.forEach((line) => {
18
- markdownFile.addText(line);
19
- });
20
- markdownFile.endCodeBlock();
21
- markdownFile.addBlankLine();
22
- }
23
- function addCustomDocCommentAnnotations(markdownFile, docCommentAware) {
24
- var _a;
25
- (_a = docCommentAware.docComment) === null || _a === void 0 ? void 0 : _a.annotations.filter((currentAnnotation) => currentAnnotation.name !== 'description').filter((currentAnnotation) => currentAnnotation.name !== 'mermaid').forEach((currentAnnotation) => {
26
- markdownFile.addBlankLine();
27
- markdownFile.addText(buildDocAnnotationText(currentAnnotation));
28
- markdownFile.addBlankLine();
29
- });
30
- function splitAndCapitalize(text) {
31
- const words = text.split(/[-_]+/);
32
- const capitalizedWords = [];
33
- for (const word of words) {
34
- capitalizedWords.push(word.charAt(0).toUpperCase() + word.slice(1));
35
- }
36
- return capitalizedWords.join(' ');
37
- }
38
- function buildDocAnnotationText(annotation) {
39
- let annotationBodyText = annotation.body;
40
- if (annotation.name.toLowerCase() === 'see') {
41
- annotationBodyText = class_file_generatorHelper_1.default.getFileLinkByTypeName(annotation.body);
42
- }
43
- return `**${splitAndCapitalize(annotation.name)}** ${annotationBodyText}`;
44
- }
45
- }
46
- //# sourceMappingURL=doc-comment-annotation-util.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"doc-comment-annotation-util.js","sourceRoot":"","sources":["../../../src/model/markdown-generation-util/doc-comment-annotation-util.ts"],"names":[],"mappings":";;;;;AAQA,gCAaC;AAED,wEA0BC;AAhDD,sHAA4F;AAO5F,SAAgB,UAAU,CAAC,YAA0B,EAAE,eAAgC;;IACrF,MAAM,OAAO,GAAG,MAAA,eAAe,CAAC,UAAU,0CAAE,WAAW,CAAC,IAAI,CAAC,CAAC,UAAU,EAAE,EAAE,CAAC,UAAU,CAAC,IAAI,KAAK,SAAS,CAAC,CAAC;IAC5G,IAAI,CAAC,OAA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AS,sBAAsB,CAAC,UAAgC;QAC9D,IAAI,kBAAkB,GAAG,UAAU,CAAC,IAAI,CAAC;QACzC,IAAI,UAAU,CAAC,IAAI,CAAC,WAAW,EAAE,KAAK,KAAK,EAAE,CAAC;YAC5C,kBAAkB,GAAG,oCAAwB,CAAC,qBAAqB,CAAC,UAAU,CAAC,IAAI,CAAC,CAAC;QACvF,CAAC;QACD,OAAO,KAAK,kBAAkB,CAAC,UAAU,CAAC,IAAI,CAAC,MAAM,kBAAkB,EAAE,CAAC;IAC5E,CAAC;AACH,CAAC"}
@@ -1,3 +0,0 @@
1
- import { MarkdownFile } from '../markdown-file';
2
- import { FieldMirrorWithInheritance, PropertyMirrorWithInheritance } from '../inheritance';
3
- export declare function declareField(markdownFile: MarkdownFile, fields: FieldMirrorWithInheritance[] | PropertyMirrorWithInheritance[], startingHeadingLevel: number, grouped?: boolean): void;
@@ -1,54 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.declareField = declareField;
4
- function declareField(markdownFile, fields, startingHeadingLevel, grouped = false) {
5
- markdownFile.addBlankLine();
6
- fields.forEach((propertyModel) => {
7
- addFieldSection(markdownFile, propertyModel, startingHeadingLevel, grouped);
8
- });
9
- markdownFile.addHorizontalRule();
10
- }
11
- function addFieldSection(markdownFile, mirrorModel, startingHeadingLevel, grouped) {
12
- var _a, _b, _c;
13
- if (!grouped) {
14
- markdownFile.addTitle(`\`${mirrorModel.access_modifier} ${mirrorModel.name}\` → \`${mirrorModel.typeReference.rawDeclaration}\``, startingHeadingLevel + 2);
15
- markdownFile.addBlankLine();
16
- if (mirrorModel.inherited) {
17
- markdownFile.addText('*Inherited*');
18
- }
19
- mirrorModel.annotations.forEach((annotation) => {
20
- markdownFile.addText(`\`${annotation.type.toUpperCase()}\` `);
21
- });
22
- if ((_a = mirrorModel.docComment) === null || _a === void 0 ? void 0 : _a.description) {
23
- markdownFile.addBlankLine();
24
- markdownFile.addText(mirrorModel.docComment.description);
25
- }
26
- markdownFile.addBlankLine();
27
- }
28
- else {
29
- let annotations = '';
30
- const hasAnnotations = !!mirrorModel.annotations.length;
31
- if (hasAnnotations) {
32
- annotations += ' [';
33
- }
34
- mirrorModel.annotations.forEach((annotation) => {
35
- annotations += `\`${annotation.type.toUpperCase()}\` `;
36
- });
37
- if (hasAnnotations) {
38
- annotations += ']';
39
- }
40
- // If grouped we want to display these as a list
41
- let description = '';
42
- if ((_b = mirrorModel.docComment) === null || _b === void 0 ? void 0 : _b.description) {
43
- description = ` - ${(_c = mirrorModel.docComment) === null || _c === void 0 ? void 0 : _c.description}`;
44
- }
45
- let listItemText = `\`${mirrorModel.access_modifier} ${mirrorModel.name}\` → \`${mirrorModel.typeReference.rawDeclaration}\``;
46
- if (mirrorModel.inherited) {
47
- listItemText += '(*Inherited*)';
48
- }
49
- listItemText += `${annotations} ${description}`;
50
- markdownFile.addListItem(listItemText);
51
- markdownFile.addBlankLine();
52
- }
53
- }
54
- //# sourceMappingURL=field-declaration-util.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"field-declaration-util.js","sourceRoot":"","sources":["../../../src/model/markdown-generation-util/field-declaration-util.ts"],"names":[],"mappings":";;AAGA,oCAYC;AAZD,SAAgB,YAAY,CAC1B,YAA0B,EAC1B,MAAsE,EACtE,oBAA4B,EAC5B,OAAO,GAAG,KAAK;IAEf,YAAY,CAAC,YAAY,EAAE,CAAC;IAC5B,MAAM,CAAC,OAAO,CAAC,CAAC,aAAa,EAAE,EAAE;QAC/B,eAAe,CAAC,YAAY,EAAE,aAAa,EAAE,oBAAoB,EAAE,OAAO,CAAC,CAAC;IAC9E,CAAC,CAAC,CAAC;IAEH,YAAY,CAAC,iBAAiB,EAAE,CAAC;AACnC,CAAC;AAED,SAAS,eAAe,CACtB,YAA0B,EAC1B,WAA4B,EAC5B,oBAA4B,EAC5B,OAAgB;;IAEhB,IAAI,CAAC,OAAO,EAAE,CAAC;QACb,YAAY,CAAC,QAAQ,CACnB,KAAK,W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M,MAAA,WAAW,CAAC,UAAU,0CAAE,WAAW,EAAE,CAAC;QAC5D,CAAC;QAED,IAAI,YAAY,GAAG,KAAK,WAAW,CAAC,eAAe,IAAI,WAAW,CAAC,IAAI,UAAU,WAAW,CAAC,aAAa,CAAC,cAAc,IAAI,CAAC;QAC9H,IAAI,WAAW,CAAC,SAAS,EAAE,CAAC;YAC1B,YAAY,IAAI,eAAe,CAAC;QAClC,CAAC;QACD,YAAY,IAAI,GAAG,WAAW,IAAI,WAAW,EAAE,CAAC;QAEhD,YAAY,CAAC,WAAW,CAAC,YAAY,CAAC,CAAC;QACvC,YAAY,CAAC,YAAY,EAAE,CAAC;IAC9B,CAAC;AACH,CAAC"}
@@ -1,3 +0,0 @@
1
- export * from './type-declaration-util';
2
- export * from './method-declaration-util';
3
- export * from './field-declaration-util';