@sitevision/api 2.0.0-alpha.1 → 2.0.0-alpha.2

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 (332) hide show
  1. package/index.d.ts +8 -0
  2. package/package.json +1 -1
  3. package/server/AliasUtil/index.d.ts +13 -11
  4. package/server/ArchiveUtil/index.d.ts +45 -43
  5. package/server/ArraysInstance/index.d.ts +1667 -1808
  6. package/server/ArticleUtil/index.d.ts +294 -226
  7. package/server/AuthenticationUtil/index.d.ts +73 -85
  8. package/server/BookmarkUtil/index.d.ts +76 -81
  9. package/server/BuddyIconRenderer/index.d.ts +124 -132
  10. package/server/BuddyIconRenderer.BuddyIconSize/index.d.ts +41 -0
  11. package/server/BuddyIconRenderer.BuddyIconSize/index.js +25 -0
  12. package/server/ClientUtil/index.d.ts +11 -9
  13. package/server/CollaborationFactory/index.d.ts +37 -40
  14. package/server/CollaborationGroupFolderUtil/index.d.ts +30 -28
  15. package/server/CollaborationGroupState/index.d.ts +27 -0
  16. package/server/CollaborationGroupState/index.js +11 -0
  17. package/server/CollaborationGroupTemplateUtil/index.d.ts +48 -50
  18. package/server/CollaborationGroupType/index.d.ts +28 -0
  19. package/server/CollaborationGroupType/index.js +12 -0
  20. package/server/CollaborationGroupUtil/index.d.ts +86 -82
  21. package/server/CollectionsInstance/index.d.ts +642 -705
  22. package/server/ColorUtil/index.d.ts +36 -37
  23. package/server/CompoundAndFilterBuilder/index.d.ts +31 -29
  24. package/server/CompoundComparatorBuilder/index.d.ts +35 -33
  25. package/server/CompoundOrFilterBuilder/index.d.ts +31 -29
  26. package/server/ContentNodeUtil/index.d.ts +36 -34
  27. package/server/CurrencyFactory/index.d.ts +72 -70
  28. package/server/DateUtil/index.d.ts +132 -142
  29. package/server/DecorationUtil/index.d.ts +13 -11
  30. package/server/DeviceUtil/index.d.ts +21 -19
  31. package/server/DimensionMode/index.d.ts +17 -0
  32. package/server/DimensionMode/index.js +12 -0
  33. package/server/DirectoryUtil/index.d.ts +90 -88
  34. package/server/DocType/index.d.ts +30 -0
  35. package/server/DocType/index.js +14 -0
  36. package/server/DocTypeUtil/index.d.ts +129 -135
  37. package/server/EndecUtil/index.d.ts +330 -347
  38. package/server/ExtendedDismaxParserBuilder/index.d.ts +156 -170
  39. package/server/FileIconRenderer/index.d.ts +153 -172
  40. package/server/FileUtil/index.d.ts +274 -300
  41. package/server/FilterBuilder/index.d.ts +42 -40
  42. package/server/FolderUtil/index.d.ts +93 -94
  43. package/server/FontUtil/index.d.ts +36 -37
  44. package/server/FormatterBuilderFactory/index.d.ts +76 -84
  45. package/server/HighlightBuilder/index.d.ts +79 -86
  46. package/server/IconUtil/index.d.ts +27 -25
  47. package/server/ImageLinkRenderer/index.d.ts +34 -32
  48. package/server/ImageRenderer/index.d.ts +343 -379
  49. package/server/ImageUtil/index.d.ts +247 -265
  50. package/server/IndexUtil/index.d.ts +40 -37
  51. package/server/IndexUtil.IndexType/index.d.ts +29 -0
  52. package/server/IndexUtil.IndexType/index.js +13 -0
  53. package/server/IndexingUtil/index.d.ts +69 -47
  54. package/server/InstanceCreatorUtil/index.d.ts +421 -457
  55. package/server/InstanceTypeUtil/index.d.ts +168 -189
  56. package/server/JwtUtil/index.d.ts +131 -129
  57. package/server/LandingPageUtil/index.d.ts +84 -87
  58. package/server/LandingPageUtil/index.js +1 -0
  59. package/server/LinkPageUtil/index.d.ts +297 -251
  60. package/server/LinkRenderer/index.d.ts +651 -715
  61. package/server/LinkTargetBuilder/index.d.ts +69 -77
  62. package/server/LinkValueBuilder/index.d.ts +70 -77
  63. package/server/ListWrapper/index.d.ts +82 -91
  64. package/server/LocaleUtil/index.d.ts +382 -394
  65. package/server/LogUtil/index.d.ts +119 -128
  66. package/server/MailBuilder/index.d.ts +109 -124
  67. package/server/MailUtil/index.d.ts +58 -63
  68. package/server/MathInstance/index.d.ts +625 -657
  69. package/server/MessageDigesterFactory/index.d.ts +30 -28
  70. package/server/MetadataDefinitionUtil/index.d.ts +79 -83
  71. package/server/MetadataUtil/index.d.ts +322 -346
  72. package/server/MimeTypeUtil/index.d.ts +209 -215
  73. package/server/MonitorBuilder/index.d.ts +20 -20
  74. package/server/NodeComparatorUtil/index.d.ts +215 -225
  75. package/server/NodeFactoryUtil/index.d.ts +18 -16
  76. package/server/NodeFilterUtil/index.d.ts +652 -739
  77. package/server/NodeIteratorUtil/index.d.ts +214 -229
  78. package/server/NodeResolverUtil/index.d.ts +400 -406
  79. package/server/NodeTreeUtil/index.d.ts +214 -229
  80. package/server/NodeTypeUtil/index.d.ts +1432 -548
  81. package/server/OfflineVersionPropertyUtil/index.d.ts +8 -6
  82. package/server/OnlineVersionPropertyUtil/index.d.ts +8 -6
  83. package/server/OutputUtil/index.d.ts +385 -380
  84. package/server/PageUtil/index.d.ts +266 -188
  85. package/server/PermissionUtil/index.d.ts +393 -430
  86. package/server/PermissionUtil.Permission/index.d.ts +54 -0
  87. package/server/PermissionUtil.Permission/index.js +38 -0
  88. package/server/PortletContextUtil/index.d.ts +112 -107
  89. package/server/PortletUtil/index.d.ts +32 -22
  90. package/server/PrincipalUtil/index.d.ts +35 -33
  91. package/server/Properties/index.d.ts +69 -76
  92. package/server/PropertyUtil/index.d.ts +1422 -1464
  93. package/server/PublishingUtil/index.d.ts +248 -249
  94. package/server/QueryStringUtil/index.d.ts +404 -415
  95. package/server/RedirectUtil/index.d.ts +64 -68
  96. package/server/RelatedValueBuilder/index.d.ts +45 -43
  97. package/server/Requester/index.d.ts +125 -125
  98. package/server/ResourceLocatorUtil/index.d.ts +436 -476
  99. package/server/RestApi/index.d.ts +158 -138
  100. package/server/RestAppInvokerFactory/index.d.ts +28 -26
  101. package/server/RoleAssignmentBuilder/index.d.ts +39 -37
  102. package/server/RoleMatcherBuilder/index.d.ts +39 -37
  103. package/server/RoleUtil/index.d.ts +35 -37
  104. package/server/ScriptUtil/index.d.ts +458 -495
  105. package/server/SearchFactory/index.d.ts +90 -105
  106. package/server/SearchUtil/index.d.ts +75 -73
  107. package/server/SearcherBuilder/index.d.ts +117 -124
  108. package/server/Session/index.d.ts +261 -1103
  109. package/server/Session/index.js +1 -20
  110. package/server/SimpleUserUtil/index.d.ts +28 -29
  111. package/server/SiteCookieUtil/index.d.ts +152 -175
  112. package/server/SortBuilder/index.d.ts +27 -25
  113. package/server/SourceSetMode/index.d.ts +12 -0
  114. package/server/SourceSetMode/index.js +12 -0
  115. package/server/SpellCheckBuilder/index.d.ts +30 -30
  116. package/server/StandardParserBuilder/index.d.ts +36 -34
  117. package/server/StructureUtil/index.d.ts +85 -83
  118. package/server/SubscriberUtil/index.d.ts +60 -67
  119. package/server/SubscriptionUtil/index.d.ts +123 -130
  120. package/server/SystemUserUtil/index.d.ts +148 -146
  121. package/server/TagUtil/index.d.ts +115 -120
  122. package/server/TemplateUtil/index.d.ts +115 -120
  123. package/server/TemporaryFileNodeBuilder/index.d.ts +32 -30
  124. package/server/TemporaryNodeBuilder/index.d.ts +139 -177
  125. package/server/TextModuleRendererBuilder/index.d.ts +22 -20
  126. package/server/TimestampUtil/index.d.ts +103 -117
  127. package/server/TranslationUtil/index.d.ts +98 -104
  128. package/server/TrashcanUtil/index.d.ts +114 -117
  129. package/server/UserDataUtil/index.d.ts +110 -111
  130. package/server/UserFactory/index.d.ts +47 -54
  131. package/server/UserFieldRenderer/index.d.ts +120 -128
  132. package/server/UserIdentityUtil/index.d.ts +38 -36
  133. package/server/UserUtil/index.d.ts +32 -30
  134. package/server/Utils/index.d.ts +634 -723
  135. package/server/VelocityRenderer/index.d.ts +96 -94
  136. package/server/VersionUtil/index.d.ts +25 -9
  137. package/server/WebContentUtil/index.d.ts +277 -284
  138. package/server/WebResourceFactory/index.d.ts +41 -46
  139. package/server/XSLTUtil/index.d.ts +34 -32
  140. package/server/XmlParserUtil/index.d.ts +50 -48
  141. package/types/javax/jcr/Binary/index.d.ts +3 -21
  142. package/types/javax/jcr/Binary/index.js +0 -1
  143. package/types/javax/jcr/Credentials/index.d.ts +3 -1
  144. package/types/javax/jcr/ImportUUIDBehavior/index.d.ts +27 -1
  145. package/types/javax/jcr/Item/index.d.ts +6 -119
  146. package/types/javax/jcr/Item/index.js +0 -6
  147. package/types/javax/jcr/ItemVisitor/index.d.ts +5 -3
  148. package/types/javax/jcr/NamespaceRegistry/index.d.ts +69 -43
  149. package/types/javax/jcr/NamespaceRegistry/index.js +0 -2
  150. package/types/javax/jcr/Node/index.d.ts +37 -1506
  151. package/types/javax/jcr/Node/index.js +1 -34
  152. package/types/javax/jcr/NodeIterator/index.d.ts +5 -3
  153. package/types/javax/jcr/Property/index.d.ts +494 -494
  154. package/types/javax/jcr/Property/index.js +0 -5
  155. package/types/javax/jcr/PropertyIterator/index.d.ts +5 -3
  156. package/types/javax/jcr/RangeIterator/index.d.ts +2 -42
  157. package/types/javax/jcr/RangeIterator/index.js +1 -5
  158. package/types/javax/jcr/Repository/index.d.ts +465 -263
  159. package/types/javax/jcr/Repository/index.js +0 -4
  160. package/types/javax/jcr/RepositoryFactory/index.d.ts +4 -2
  161. package/types/javax/jcr/Value/index.d.ts +4 -31
  162. package/types/javax/jcr/Value/index.js +0 -2
  163. package/types/javax/jcr/ValueFactory/index.d.ts +6 -74
  164. package/types/javax/jcr/ValueFactory/index.js +1 -2
  165. package/types/javax/jcr/Workspace/index.d.ts +103 -577
  166. package/types/javax/jcr/Workspace/index.js +1 -12
  167. package/types/javax/jcr/lock/Lock/index.d.ts +4 -2
  168. package/types/javax/jcr/lock/LockManager/index.d.ts +4 -2
  169. package/types/javax/jcr/nodetype/ItemDefinition/index.d.ts +4 -105
  170. package/types/javax/jcr/nodetype/ItemDefinition/index.js +0 -5
  171. package/types/javax/jcr/nodetype/NodeDefinition/index.d.ts +5 -3
  172. package/types/javax/jcr/nodetype/NodeDefinitionTemplate/index.d.ts +4 -2
  173. package/types/javax/jcr/nodetype/NodeType/index.d.ts +262 -269
  174. package/types/javax/jcr/nodetype/NodeType/index.js +1 -12
  175. package/types/javax/jcr/nodetype/NodeTypeDefinition/index.d.ts +5 -107
  176. package/types/javax/jcr/nodetype/NodeTypeDefinition/index.js +1 -7
  177. package/types/javax/jcr/nodetype/NodeTypeIterator/index.d.ts +5 -3
  178. package/types/javax/jcr/nodetype/NodeTypeManager/index.d.ts +9 -130
  179. package/types/javax/jcr/nodetype/NodeTypeManager/index.js +1 -8
  180. package/types/javax/jcr/nodetype/NodeTypeTemplate/index.d.ts +4 -2
  181. package/types/javax/jcr/nodetype/PropertyDefinition/index.d.ts +5 -272
  182. package/types/javax/jcr/nodetype/PropertyDefinition/index.js +1 -7
  183. package/types/javax/jcr/nodetype/PropertyDefinitionTemplate/index.d.ts +5 -3
  184. package/types/javax/jcr/observation/Event/index.d.ts +85 -42
  185. package/types/javax/jcr/observation/EventIterator/index.d.ts +5 -3
  186. package/types/javax/jcr/observation/EventJournal/index.d.ts +4 -2
  187. package/types/javax/jcr/observation/EventListener/index.d.ts +4 -2
  188. package/types/javax/jcr/observation/EventListenerIterator/index.d.ts +5 -3
  189. package/types/javax/jcr/observation/ObservationManager/index.d.ts +6 -4
  190. package/types/javax/jcr/query/Query/index.d.ts +35 -12
  191. package/types/javax/jcr/query/QueryManager/index.d.ts +6 -4
  192. package/types/javax/jcr/query/QueryResult/index.d.ts +5 -3
  193. package/types/javax/jcr/query/Row/index.d.ts +5 -3
  194. package/types/javax/jcr/query/RowIterator/index.d.ts +5 -3
  195. package/types/javax/jcr/query/qom/And/index.d.ts +4 -2
  196. package/types/javax/jcr/query/qom/BindVariableValue/index.d.ts +4 -2
  197. package/types/javax/jcr/query/qom/ChildNode/index.d.ts +4 -2
  198. package/types/javax/jcr/query/qom/ChildNodeJoinCondition/index.d.ts +4 -2
  199. package/types/javax/jcr/query/qom/Column/index.d.ts +3 -1
  200. package/types/javax/jcr/query/qom/Comparison/index.d.ts +6 -4
  201. package/types/javax/jcr/query/qom/Constraint/index.d.ts +3 -1
  202. package/types/javax/jcr/query/qom/DescendantNode/index.d.ts +4 -2
  203. package/types/javax/jcr/query/qom/DescendantNodeJoinCondition/index.d.ts +4 -2
  204. package/types/javax/jcr/query/qom/DynamicOperand/index.d.ts +4 -2
  205. package/types/javax/jcr/query/qom/EquiJoinCondition/index.d.ts +4 -2
  206. package/types/javax/jcr/query/qom/FullTextSearch/index.d.ts +5 -3
  207. package/types/javax/jcr/query/qom/FullTextSearchScore/index.d.ts +4 -2
  208. package/types/javax/jcr/query/qom/Join/index.d.ts +5 -3
  209. package/types/javax/jcr/query/qom/JoinCondition/index.d.ts +3 -1
  210. package/types/javax/jcr/query/qom/Length/index.d.ts +5 -3
  211. package/types/javax/jcr/query/qom/Literal/index.d.ts +5 -3
  212. package/types/javax/jcr/query/qom/LowerCase/index.d.ts +4 -2
  213. package/types/javax/jcr/query/qom/NodeLocalName/index.d.ts +4 -2
  214. package/types/javax/jcr/query/qom/NodeName/index.d.ts +4 -2
  215. package/types/javax/jcr/query/qom/Not/index.d.ts +4 -2
  216. package/types/javax/jcr/query/qom/Operand/index.d.ts +3 -1
  217. package/types/javax/jcr/query/qom/Or/index.d.ts +4 -2
  218. package/types/javax/jcr/query/qom/Ordering/index.d.ts +4 -2
  219. package/types/javax/jcr/query/qom/PropertyExistence/index.d.ts +4 -2
  220. package/types/javax/jcr/query/qom/PropertyValue/index.d.ts +4 -2
  221. package/types/javax/jcr/query/qom/QueryObjectModel/index.d.ts +8 -6
  222. package/types/javax/jcr/query/qom/QueryObjectModelConstants/index.d.ts +76 -2
  223. package/types/javax/jcr/query/qom/QueryObjectModelFactory/index.d.ts +37 -35
  224. package/types/javax/jcr/query/qom/SameNode/index.d.ts +4 -2
  225. package/types/javax/jcr/query/qom/SameNodeJoinCondition/index.d.ts +4 -2
  226. package/types/javax/jcr/query/qom/Selector/index.d.ts +4 -2
  227. package/types/javax/jcr/query/qom/Source/index.d.ts +3 -1
  228. package/types/javax/jcr/query/qom/StaticOperand/index.d.ts +4 -2
  229. package/types/javax/jcr/query/qom/UpperCase/index.d.ts +4 -2
  230. package/types/javax/jcr/retention/Hold/index.d.ts +3 -1
  231. package/types/javax/jcr/retention/RetentionManager/index.d.ts +5 -3
  232. package/types/javax/jcr/retention/RetentionPolicy/index.d.ts +3 -1
  233. package/types/javax/jcr/security/AccessControlEntry/index.d.ts +4 -2
  234. package/types/javax/jcr/security/AccessControlList/index.d.ts +6 -4
  235. package/types/javax/jcr/security/AccessControlManager/index.d.ts +6 -4
  236. package/types/javax/jcr/security/AccessControlPolicy/index.d.ts +3 -1
  237. package/types/javax/jcr/security/AccessControlPolicyIterator/index.d.ts +5 -3
  238. package/types/javax/jcr/security/NamedAccessControlPolicy/index.d.ts +4 -2
  239. package/types/javax/jcr/security/Privilege/index.d.ts +130 -44
  240. package/types/javax/jcr/version/Version/index.d.ts +5 -3
  241. package/types/javax/jcr/version/VersionHistory/index.d.ts +7 -5
  242. package/types/javax/jcr/version/VersionIterator/index.d.ts +5 -3
  243. package/types/javax/jcr/version/VersionManager/index.d.ts +7 -5
  244. package/types/senselogic/sitevision/api/base/Builder/index.d.ts +3 -1
  245. package/types/senselogic/sitevision/api/base/Filter/index.d.ts +3 -1
  246. package/types/senselogic/sitevision/api/base/FilterSplit/index.d.ts +4 -2
  247. package/types/senselogic/sitevision/api/base/Loadable/index.d.ts +3 -1
  248. package/types/senselogic/sitevision/api/base/Requireable/ScriptEngine/index.d.ts +9 -0
  249. package/types/senselogic/sitevision/api/base/Requireable/ScriptEngine/index.js +11 -0
  250. package/types/senselogic/sitevision/api/base/Resolver/index.d.ts +3 -1
  251. package/types/senselogic/sitevision/api/base/Wrapper/index.d.ts +3 -1
  252. package/types/senselogic/sitevision/api/collaboration/CollaborationGroupWrapper/index.d.ts +13 -7
  253. package/types/senselogic/sitevision/api/format/NumericFormatter/index.d.ts +3 -1
  254. package/types/senselogic/sitevision/api/format/NumericFormatterBuilder/index.d.ts +5 -3
  255. package/types/senselogic/sitevision/api/i18n/Currency/index.d.ts +3 -1
  256. package/types/senselogic/sitevision/api/link/CustomLinkProcessor/index.d.ts +5 -3
  257. package/types/senselogic/sitevision/api/link/CustomLinkRenderData/index.d.ts +3 -1
  258. package/types/senselogic/sitevision/api/mail/Mail/index.d.ts +3 -1
  259. package/types/senselogic/sitevision/api/message/MessageTextLinker/index.d.ts +3 -1
  260. package/types/senselogic/sitevision/api/metadata/value/LinkValue/index.d.ts +3 -1
  261. package/types/senselogic/sitevision/api/metadata/value/RelatedValue/index.d.ts +3 -1
  262. package/types/senselogic/sitevision/api/property/VersionedPropertyUtil/index.d.ts +4 -2
  263. package/types/senselogic/sitevision/api/render/BuddyIconRenderer.BuddyIconInfo/index.d.ts +51 -0
  264. package/types/senselogic/sitevision/api/render/BuddyIconRenderer.BuddyIconInfo/index.js +12 -0
  265. package/types/senselogic/sitevision/api/render/ImageScaler/index.d.ts +4 -2
  266. package/types/senselogic/sitevision/api/render/TextModuleRenderer/index.d.ts +4 -2
  267. package/types/senselogic/sitevision/api/render/velocity/VelocityAccess/index.d.ts +3 -1
  268. package/types/senselogic/sitevision/api/render/velocity/VelocityAccess.ArticleUtilConstants/index.d.ts +85 -0
  269. package/types/senselogic/sitevision/api/render/velocity/VelocityAccess.ArticleUtilConstants/index.js +21 -0
  270. package/types/senselogic/sitevision/api/render/velocity/VelocityAccess.ExceptionSuppressingProxyConstants/index.d.ts +31 -0
  271. package/types/senselogic/sitevision/api/render/velocity/VelocityAccess.ExceptionSuppressingProxyConstants/index.js +12 -0
  272. package/types/senselogic/sitevision/api/render/velocity/VelocityAccess.IndexingUtilConstants/index.d.ts +31 -0
  273. package/types/senselogic/sitevision/api/render/velocity/VelocityAccess.IndexingUtilConstants/index.js +12 -0
  274. package/types/senselogic/sitevision/api/render/velocity/VelocityAccess.LinkPageUtilConstants/index.d.ts +67 -0
  275. package/types/senselogic/sitevision/api/render/velocity/VelocityAccess.LinkPageUtilConstants/index.js +18 -0
  276. package/types/senselogic/sitevision/api/render/velocity/VelocityAccess.MathInstanceConstants/index.d.ts +25 -0
  277. package/types/senselogic/sitevision/api/render/velocity/VelocityAccess.MathInstanceConstants/index.js +11 -0
  278. package/types/senselogic/sitevision/api/render/velocity/VelocityAccess.MimeTypeUtilConstants/index.d.ts +19 -0
  279. package/types/senselogic/sitevision/api/render/velocity/VelocityAccess.MimeTypeUtilConstants/index.js +10 -0
  280. package/types/senselogic/sitevision/api/render/velocity/VelocityAccess.NodeTypeUtilConstants/index.d.ts +1243 -0
  281. package/types/senselogic/sitevision/api/render/velocity/VelocityAccess.NodeTypeUtilConstants/index.js +189 -0
  282. package/types/senselogic/sitevision/api/render/velocity/VelocityAccess.OutputUtilConstants/index.d.ts +31 -0
  283. package/types/senselogic/sitevision/api/render/velocity/VelocityAccess.OutputUtilConstants/index.js +12 -0
  284. package/types/senselogic/sitevision/api/render/velocity/VelocityAccess.PageUtilConstants/index.d.ts +91 -0
  285. package/types/senselogic/sitevision/api/render/velocity/VelocityAccess.PageUtilConstants/index.js +22 -0
  286. package/types/senselogic/sitevision/api/render/velocity/VelocityAccess.PortletContextUtilConstants/index.d.ts +27 -0
  287. package/types/senselogic/sitevision/api/render/velocity/VelocityAccess.PortletContextUtilConstants/index.js +11 -0
  288. package/types/senselogic/sitevision/api/render/velocity/VelocityAccess.PortletUtilConstants/index.d.ts +19 -0
  289. package/types/senselogic/sitevision/api/render/velocity/VelocityAccess.PortletUtilConstants/index.js +10 -0
  290. package/types/senselogic/sitevision/api/render/velocity/VelocityAccess.QueryStringUtilConstants/index.d.ts +19 -0
  291. package/types/senselogic/sitevision/api/render/velocity/VelocityAccess.QueryStringUtilConstants/index.js +10 -0
  292. package/types/senselogic/sitevision/api/render/velocity/VelocityAccess.SearchHitConstants/index.d.ts +25 -0
  293. package/types/senselogic/sitevision/api/render/velocity/VelocityAccess.SearchHitConstants/index.js +11 -0
  294. package/types/senselogic/sitevision/api/render/velocity/VelocityAccess.SearchResultConstants/index.d.ts +37 -0
  295. package/types/senselogic/sitevision/api/render/velocity/VelocityAccess.SearchResultConstants/index.js +13 -0
  296. package/types/senselogic/sitevision/api/render/velocity/VelocityAccess.VersionUtilConstants/index.d.ts +25 -0
  297. package/types/senselogic/sitevision/api/render/velocity/VelocityAccess.VersionUtilConstants/index.js +11 -0
  298. package/types/senselogic/sitevision/api/render/velocity/VelocityContext/index.d.ts +3 -1
  299. package/types/senselogic/sitevision/api/render/velocity/VelocityEvaluator/index.d.ts +3 -1
  300. package/types/senselogic/sitevision/api/script/RequesterChainable/index.d.ts +4 -2
  301. package/types/senselogic/sitevision/api/script/app/RestAppInvoker/index.d.ts +3 -1
  302. package/types/senselogic/sitevision/api/script/factory/TypedArgument/index.d.ts +3 -1
  303. package/types/senselogic/sitevision/api/script/proxy/ExceptionSuppressingCollection/index.d.ts +3 -1
  304. package/types/senselogic/sitevision/api/script/proxy/ExceptionSuppressingIterator/index.d.ts +4 -2
  305. package/types/senselogic/sitevision/api/script/proxy/ExceptionSuppressingProxy/index.d.ts +24 -2
  306. package/types/senselogic/sitevision/api/search/SearchFieldUtil/index.d.ts +3 -1
  307. package/types/senselogic/sitevision/api/search/SearchHighlighter/index.d.ts +4 -2
  308. package/types/senselogic/sitevision/api/search/SearchHit/index.d.ts +19 -3
  309. package/types/senselogic/sitevision/api/search/SearchResult/index.d.ts +31 -7
  310. package/types/senselogic/sitevision/api/search/facet/SearchFacetField/index.d.ts +3 -1
  311. package/types/senselogic/sitevision/api/search/facet/SearchFacetValue/index.d.ts +3 -1
  312. package/types/senselogic/sitevision/api/search/searcher/Searcher/index.d.ts +4 -2
  313. package/types/senselogic/sitevision/api/search/searcher/component/Filter/index.d.ts +3 -1
  314. package/types/senselogic/sitevision/api/search/searcher/component/Highlight/index.d.ts +3 -1
  315. package/types/senselogic/sitevision/api/search/searcher/component/Monitor/index.d.ts +3 -1
  316. package/types/senselogic/sitevision/api/search/searcher/component/Parser/index.d.ts +3 -1
  317. package/types/senselogic/sitevision/api/search/searcher/component/Sort/index.d.ts +3 -1
  318. package/types/senselogic/sitevision/api/search/searcher/component/SpellCheck/index.d.ts +3 -1
  319. package/types/senselogic/sitevision/api/search/sort/CustomSort/index.d.ts +3 -1
  320. package/types/senselogic/sitevision/api/search/suggestion/SearchSuggestion/index.d.ts +3 -1
  321. package/types/senselogic/sitevision/api/security/DirectoryAttributes/index.d.ts +3 -1
  322. package/types/senselogic/sitevision/api/security/MessageDigester/index.d.ts +3 -1
  323. package/types/senselogic/sitevision/api/security/RoleAssignment/index.d.ts +4 -2
  324. package/types/senselogic/sitevision/api/security/RoleMatcher/index.d.ts +4 -2
  325. package/types/senselogic/sitevision/api/security/SecretStore/index.d.ts +3 -1
  326. package/types/senselogic/sitevision/api/security/UserUtil/index.d.ts +4 -2
  327. package/types/senselogic/sitevision/api/security/jaas/filter/AuthenticationFilter/index.d.ts +35 -3
  328. package/types/senselogic/sitevision/api/security/jaas/filter/AuthenticationFilterChain/index.d.ts +3 -1
  329. package/types/senselogic/sitevision/api/user/UserIdentityWrapper/index.d.ts +5 -3
  330. package/types/senselogic/sitevision/api/webresource/LinkTarget/index.d.ts +3 -1
  331. package/types/senselogic/sitevision/api/xml/XmlElement/index.d.ts +3 -1
  332. package/types/senselogic/sitevision/api/xml/XmlElementHandler/index.d.ts +4 -2
@@ -1,321 +1,295 @@
1
- import type { Node } from "../../types/javax/jcr/Node";
1
+ import type Node from "../../types/javax/jcr/Node";
2
2
 
3
3
  /**
4
- * <p>
5
- * Adds several files to a sv:localFileRepository, sv:fileRepository, sv:personalFileRepository or a sv:folder
6
- * residing as sub node to a file repository.
7
- * </p>
8
- * <p>
9
- * Files are specified by a map where the keys denotes the file names (will correspond to the property fileName
10
- * of the sv:file nodes) and the values denotes the URIs pointing to the file resources. The file resources
11
- * (i.e. the URIs) must be accessible from the Sitevision server. Sitevision opens a stream with the URI value
12
- * when creating/uploading the binary content of the file. If a firewall or such blocks outgoing communication
13
- * from the server - file creation will fail.
14
- * </p>
15
- * <p>
16
- * <strong>Permission note!</strong> Current user must be authorized to alter the parent node
17
- * (e.g. {@link senselogic.sitevision.api.security.PermissionUtil.Permission#WRITE}).
18
- * </p>
19
- * <p>
20
- * A warning will be written to the system log if Sitevision for any reason is unable to create one of the files.
21
- * </p>
22
- * @param aParent the parent node for the files
23
- * @param aFileMappings a map of file name to URI pairs
24
- * @throws java.lang.NullPointerException if <code>aParent</code> or <code>aFileMappings</code> is <code>null</code>
25
- * @throws ConstraintViolationException if the user is not authorized to alter the parent node, if an invalid parent node is specified or if file exceeds file size limit
26
- * @throws RepositoryException if something else goes wrong
27
- */
28
- export function createFiles(aParent: Node, aFileMappings: unknown): void;
29
-
30
- /**
31
- * Creates a file using a uri string.
4
+ * File utility interface that handles nodes with primary node type <code>sv:file</code> and <code>sv:temporaryFile</code>.
32
5
  *
33
6
  * <p>
34
- * Note that the <code>aParent</code> of the file must be a <code>sv:localFileRepository</code>, <code>sv:fileRepository</code>,
35
- * <code>sv:personalFileRepository</code> or a <code>sv:folder</code> residing as sub node to a file repository.
36
- * </p>
37
- * <p>
38
- * <strong>Permission note!</strong> Current user must be authorized to alter the parent node
39
- * (e.g. {@link senselogic.sitevision.api.security.PermissionUtil.Permission#WRITE}).
40
- * </p>
41
- * <p>
42
- * <strong>URI note!</strong> The file resource must be accessible from the Sitevision server! Sitevision opens
43
- * a stream to an URL with the <code>aUri</code> value when creating/uploading the binary content of the file.
44
- * If a firewall or such blocks outgoing communication from the server - file creation will fail.
7
+ * <em>Note!</em> This interface is used to <em>create</em> files. You would typically use
8
+ * {@link senselogic.sitevision.api.webresource.structure.StructureUtil} to <em>move</em> a file
9
+ * and {@link senselogic.sitevision.api.webresource.structure.TrashcanUtil} to <em>delete</em> a file.
10
+ * To check <em>MIME/Content-Type</em> for a file you would typically use {@link senselogic.sitevision.api.webresource.mime.MimeTypeUtil}.
45
11
  * </p>
46
- * @param aParent the parent node of the file
47
- * @param aFileName the filename
48
- * @param aUri the URI pointing to the file resource retrievable from the Sitevision server
49
- * @return a sv:file node corresponding to the newly created file. Will never return <code>null</code>
50
- * @throws java.lang.NullPointerException if <code>aParent</code>, <code>aFileName</code> or <code>aUri</code> is <code>null</code>
51
- * @throws ConstraintViolationException if the user is not authorized to alter the parent node, if an invalid parent node is specified or if file exceeds file size limit
52
- * @throws RepositoryException if something else goes wrong
53
- */
54
- export function createFile(
55
- aParent: Node,
56
- aFileName: string,
57
- aUri: string
58
- ): Node;
59
-
60
- /**
61
- * Creates a file using a base64 string.
62
12
  *
63
13
  * <p>
64
- * The base64 decoder uses "The Base64 Alphabet" as specified in Table 1 of RFC 4648 and RFC 2045 for decoding operation.
65
- * The decoder rejects data that contains characters outside the base64 alphabet.
66
- * </p>
67
- * <p>
68
- * Note that the <code>aParent</code> of the file must be a <code>sv:localFileRepository</code>, <code>sv:fileRepository</code>,
69
- * <code>sv:personalFileRepository</code> or a <code>sv:folder</code> residing as sub node to a file repository.
70
- * </p>
71
- * <p>
72
- * <strong>Permission note!</strong> Current user must be authorized to alter the parent node
73
- * (e.g. {@link senselogic.sitevision.api.security.PermissionUtil.Permission#WRITE}).
14
+ * An instance of the Sitevision class implementing this interface can be obtained via {@link senselogic.sitevision.api.Utils#getFileUtil()}.
15
+ * See {@link senselogic.sitevision.api.Utils} for how to obtain an instance of the <code>Utils</code> interface.
74
16
  * </p>
75
- * @param aParent the parent node of the file
76
- * @param aFileName the filename
77
- * @param aBase64EncodedString a base64 encoded string
78
- * @return a sv:file node corresponding to the newly created file. Will never return <code>null</code>
79
- * @throws java.lang.NullPointerException if <code>aParent</code>, <code>aFileName</code> or <code>aBase64EncodedString</code> is <code>null</code>
80
- * @throws ConstraintViolationException if the user is not authorized to alter the parent node, if an invalid parent node is specified, if <code>aBase64EncodedString</code> is not base64 encoded or if file exceeds file size limit
81
- * @throws RepositoryException if something else goes wrong
82
- * @since Sitevision 4.5.4
17
+ * @author Mikael Wikblom
18
+ * @since Sitevision 2.6.2
83
19
  */
84
- export function createFileFromBase64(
85
- aParent: Node,
86
- aFileName: string,
87
- aBase64EncodedString: string
88
- ): Node;
20
+ export interface FileUtil {
21
+ /**
22
+ * <p>
23
+ * Adds several files to a sv:localFileRepository, sv:fileRepository, sv:personalFileRepository or a sv:folder
24
+ * residing as sub node to a file repository.
25
+ * </p>
26
+ * <p>
27
+ * Files are specified by a map where the keys denotes the file names (will correspond to the property fileName
28
+ * of the sv:file nodes) and the values denotes the URIs pointing to the file resources. The file resources
29
+ * (i.e. the URIs) must be accessible from the Sitevision server. Sitevision opens a stream with the URI value
30
+ * when creating/uploading the binary content of the file. If a firewall or such blocks outgoing communication
31
+ * from the server - file creation will fail.
32
+ * </p>
33
+ * <p>
34
+ * <strong>Permission note!</strong> Current user must be authorized to alter the parent node
35
+ * (e.g. {@link senselogic.sitevision.api.security.PermissionUtil.Permission#WRITE}).
36
+ * </p>
37
+ * <p>
38
+ * A warning will be written to the system log if Sitevision for any reason is unable to create one of the files.
39
+ * </p>
40
+ * @param aParent the parent node for the files
41
+ * @param aFileMappings a map of file name to URI pairs
42
+ * @throws java.lang.NullPointerException if <code>aParent</code> or <code>aFileMappings</code> is <code>null</code>
43
+ * @throws ConstraintViolationException if the user is not authorized to alter the parent node, if an invalid parent node is specified or if file exceeds file size limit
44
+ * @throws RepositoryException if something else goes wrong
45
+ */
46
+ createFiles(aParent: Node, aFileMappings: unknown): void;
89
47
 
90
- /**
91
- * Creates a file using a sv:temporaryFile.
92
- *
93
- * <p>
94
- * Note that the <code>aParent</code> of the file must be a <code>sv:localFileRepository</code>, <code>sv:fileRepository</code>,
95
- * <code>sv:personalFileRepository</code> or a <code>sv:folder</code> residing as sub node to a file repository.
96
- * </p>
97
- * <p>
98
- * <strong>Permission note!</strong> Current user must be authorized to alter the parent node
99
- * (e.g. {@link senselogic.sitevision.api.security.PermissionUtil.Permission#WRITE}).
100
- * </p>
101
- * @param aParent the parent node of the file
102
- * @param aTemporaryFile a sv:temporaryFile (typically created via {@link senselogic.sitevision.api.node.builder.TemporaryFileNodeBuilder})
103
- * @return a sv:file node corresponding to the newly created file. Will never return <code>null</code>
104
- * @throws ConstraintViolationException if the user is not authorized to alter the parent node, if an invalid parent node is specified, if an invalid temporary node is specified or if file exceeds file size limit
105
- * @throws RepositoryException if something else goes wrong
106
- * @since Sitevision 4.5.4
107
- */
108
- export function createFileFromTemporary(
109
- aParent: Node,
110
- aTemporaryFile: Node
111
- ): Node;
48
+ /**
49
+ * Creates a file using a uri string.
50
+ *
51
+ * <p>
52
+ * Note that the <code>aParent</code> of the file must be a <code>sv:localFileRepository</code>, <code>sv:fileRepository</code>,
53
+ * <code>sv:personalFileRepository</code> or a <code>sv:folder</code> residing as sub node to a file repository.
54
+ * </p>
55
+ * <p>
56
+ * <strong>Permission note!</strong> Current user must be authorized to alter the parent node
57
+ * (e.g. {@link senselogic.sitevision.api.security.PermissionUtil.Permission#WRITE}).
58
+ * </p>
59
+ * <p>
60
+ * <strong>URI note!</strong> The file resource must be accessible from the Sitevision server! Sitevision opens
61
+ * a stream to an URL with the <code>aUri</code> value when creating/uploading the binary content of the file.
62
+ * If a firewall or such blocks outgoing communication from the server - file creation will fail.
63
+ * </p>
64
+ * @param aParent the parent node of the file
65
+ * @param aFileName the filename
66
+ * @param aUri the URI pointing to the file resource retrievable from the Sitevision server
67
+ * @return a sv:file node corresponding to the newly created file. Will never return <code>null</code>
68
+ * @throws java.lang.NullPointerException if <code>aParent</code>, <code>aFileName</code> or <code>aUri</code> is <code>null</code>
69
+ * @throws ConstraintViolationException if the user is not authorized to alter the parent node, if an invalid parent node is specified or if file exceeds file size limit
70
+ * @throws RepositoryException if something else goes wrong
71
+ */
72
+ createFile(aParent: Node, aFileName: string, aUri: string): Node;
112
73
 
113
- /**
114
- * Updates the binary content of an existing file using a uri string.
115
- *
116
- * <p>
117
- * Properties related to the binary content will also be updated (e.g. <code>length</code>). A new version will
118
- * be created if the binary content of a <em>group file</em> is updated.
119
- * </p>
120
- * <p>
121
- * <strong>URI note!</strong> The URI must be accessible from the Sitevision server and the ending part
122
- * of the URI must match the file extension of the existing file that should be updated! Sitevision opens
123
- * a stream to an URL with the <code>anUri</code> value when uploading the binary content of the file.
124
- * If a firewall or such blocks outgoing communication from the server - file update will fail.
125
- * </p>
126
- * <p>
127
- * <strong>Permission note!</strong> Current user must be authorized to alter the file node that
128
- * should be updated (e.g. {@link senselogic.sitevision.api.security.PermissionUtil.Permission#WRITE}).
129
- * </p>
130
- * @param aFile the file
131
- * @param aUri the URI pointing to the file resource to fetch new binary content from
132
- * @throws ConstraintViolationException if the user is not authorized to alter the file node, if an invalid node is specified, if the end part of <code>aUri</code> doesn't match the file extension of <code>aFile</code> or if file exceeds file size limit
133
- * @throws RepositoryException if something else goes wrong
134
- * @since Sitevision 3.6.3
135
- */
136
- export function updateBinaryContent(aFile: Node, aUri: string): void;
74
+ /**
75
+ * Creates a file using a base64 string.
76
+ *
77
+ * <p>
78
+ * The base64 decoder uses "The Base64 Alphabet" as specified in Table 1 of RFC 4648 and RFC 2045 for decoding operation.
79
+ * The decoder rejects data that contains characters outside the base64 alphabet.
80
+ * </p>
81
+ * <p>
82
+ * Note that the <code>aParent</code> of the file must be a <code>sv:localFileRepository</code>, <code>sv:fileRepository</code>,
83
+ * <code>sv:personalFileRepository</code> or a <code>sv:folder</code> residing as sub node to a file repository.
84
+ * </p>
85
+ * <p>
86
+ * <strong>Permission note!</strong> Current user must be authorized to alter the parent node
87
+ * (e.g. {@link senselogic.sitevision.api.security.PermissionUtil.Permission#WRITE}).
88
+ * </p>
89
+ * @param aParent the parent node of the file
90
+ * @param aFileName the filename
91
+ * @param aBase64EncodedString a base64 encoded string
92
+ * @return a sv:file node corresponding to the newly created file. Will never return <code>null</code>
93
+ * @throws java.lang.NullPointerException if <code>aParent</code>, <code>aFileName</code> or <code>aBase64EncodedString</code> is <code>null</code>
94
+ * @throws ConstraintViolationException if the user is not authorized to alter the parent node, if an invalid parent node is specified, if <code>aBase64EncodedString</code> is not base64 encoded or if file exceeds file size limit
95
+ * @throws RepositoryException if something else goes wrong
96
+ * @since Sitevision 4.5.4
97
+ */
98
+ createFileFromBase64(
99
+ aParent: Node,
100
+ aFileName: string,
101
+ aBase64EncodedString: string
102
+ ): Node;
137
103
 
138
- /**
139
- * Updates the binary content of an existing file using a base64 string.
140
- *
141
- * <p>
142
- * The base64 decoder uses "The Base64 Alphabet" as specified in Table 1 of RFC 4648 and RFC 2045 for decoding operation.
143
- * The decoder rejects data that contains characters outside the base64 alphabet.
144
- * </p>
145
- * <p>
146
- * Properties related to the binary content will also be updated (e.g. <code>length</code>). A new version will
147
- * be created if the binary content of a <em>group file</em> is updated.
148
- * </p>
149
- * <p>
150
- * <strong>Permission note!</strong> Current user must be authorized to alter the file node that
151
- * should be updated (e.g. {@link senselogic.sitevision.api.security.PermissionUtil.Permission#WRITE}).
152
- * </p>
153
- * @param aFile the file
154
- * @param aBase64EncodedString a base64 encoded string
155
- * @throws ConstraintViolationException if the user is not authorized to alter the file node, if an invalid node is specified, if <code>aBase64EncodedString</code> is not base64 encoded, if file exceeds file size limit or if file exceeds file size limit
156
- * @throws RepositoryException if something else goes wrong
157
- * @since Sitevision 4.5.4
158
- */
159
- export function updateBinaryContentFromBase64(
160
- aFile: Node,
161
- aBase64EncodedString: string
162
- ): void;
104
+ /**
105
+ * Creates a file using a sv:temporaryFile.
106
+ *
107
+ * <p>
108
+ * Note that the <code>aParent</code> of the file must be a <code>sv:localFileRepository</code>, <code>sv:fileRepository</code>,
109
+ * <code>sv:personalFileRepository</code> or a <code>sv:folder</code> residing as sub node to a file repository.
110
+ * </p>
111
+ * <p>
112
+ * <strong>Permission note!</strong> Current user must be authorized to alter the parent node
113
+ * (e.g. {@link senselogic.sitevision.api.security.PermissionUtil.Permission#WRITE}).
114
+ * </p>
115
+ * @param aParent the parent node of the file
116
+ * @param aTemporaryFile a sv:temporaryFile (typically created via {@link senselogic.sitevision.api.node.builder.TemporaryFileNodeBuilder})
117
+ * @return a sv:file node corresponding to the newly created file. Will never return <code>null</code>
118
+ * @throws ConstraintViolationException if the user is not authorized to alter the parent node, if an invalid parent node is specified, if an invalid temporary node is specified or if file exceeds file size limit
119
+ * @throws RepositoryException if something else goes wrong
120
+ * @since Sitevision 4.5.4
121
+ */
122
+ createFileFromTemporary(aParent: Node, aTemporaryFile: Node): Node;
163
123
 
164
- /**
165
- * Updates the binary content of an existing file using a sv:temporaryFile.
166
- *
167
- * <p>
168
- * Properties related to the binary content will also be updated (e.g. <code>length</code>). A new version will
169
- * be created if the binary content of a <em>group file</em> is updated.
170
- * </p>
171
- * <p>
172
- * <strong>Permission note!</strong> Current user must be authorized to alter the file node that
173
- * should be updated (e.g. {@link senselogic.sitevision.api.security.PermissionUtil.Permission#WRITE}).
174
- * </p>
175
- * @param aFile the file
176
- * @param aTemporaryFile the sv:temporaryFile (typically created via {@link senselogic.sitevision.api.node.builder.TemporaryFileNodeBuilder})
177
- * @throws ConstraintViolationException if the user is not authorized to alter the file node, if an invalid node is specified, if the end part of the file represented by <code>aTemporaryFile</code> doesn't match the file extension of <code>aFile</code> or if file exceeds file size limit
178
- * @throws RepositoryException if something else goes wrong
179
- * @since Sitevision 4.5.4
180
- */
181
- export function updateBinaryContentFromTemporary(
182
- aFile: Node,
183
- aTemporaryFile: Node
184
- ): void;
124
+ /**
125
+ * Updates the binary content of an existing file using a uri string.
126
+ *
127
+ * <p>
128
+ * Properties related to the binary content will also be updated (e.g. <code>length</code>). A new version will
129
+ * be created if the binary content of a <em>group file</em> is updated.
130
+ * </p>
131
+ * <p>
132
+ * <strong>URI note!</strong> The URI must be accessible from the Sitevision server and the ending part
133
+ * of the URI must match the file extension of the existing file that should be updated! Sitevision opens
134
+ * a stream to an URL with the <code>anUri</code> value when uploading the binary content of the file.
135
+ * If a firewall or such blocks outgoing communication from the server - file update will fail.
136
+ * </p>
137
+ * <p>
138
+ * <strong>Permission note!</strong> Current user must be authorized to alter the file node that
139
+ * should be updated (e.g. {@link senselogic.sitevision.api.security.PermissionUtil.Permission#WRITE}).
140
+ * </p>
141
+ * @param aFile the file
142
+ * @param aUri the URI pointing to the file resource to fetch new binary content from
143
+ * @throws ConstraintViolationException if the user is not authorized to alter the file node, if an invalid node is specified, if the end part of <code>aUri</code> doesn't match the file extension of <code>aFile</code> or if file exceeds file size limit
144
+ * @throws RepositoryException if something else goes wrong
145
+ * @since Sitevision 3.6.3
146
+ */
147
+ updateBinaryContent(aFile: Node, aUri: string): void;
185
148
 
186
- /**
187
- * Gets the contents of a file as a String using the UTF-8 character encoding.
188
- *
189
- * <p>
190
- * <em>Note! This is mere a convenience method for {@link #getContentAsString(Node, String)} using UTF-8 as character encoding.</em>
191
- * </p>
192
- * @param aFile the file Node (sv:file or sv:temporaryFile)
193
- * @return the UTF-8 file content, or null if aFile isn't a character-based file
194
- * @see #getContentAsString(Node, String)
195
- * @since Sitevision 4.1.1
196
- */
197
- export function getContentAsString(aFile: Node): string;
149
+ /**
150
+ * Updates the binary content of an existing file using a base64 string.
151
+ *
152
+ * <p>
153
+ * The base64 decoder uses "The Base64 Alphabet" as specified in Table 1 of RFC 4648 and RFC 2045 for decoding operation.
154
+ * The decoder rejects data that contains characters outside the base64 alphabet.
155
+ * </p>
156
+ * <p>
157
+ * Properties related to the binary content will also be updated (e.g. <code>length</code>). A new version will
158
+ * be created if the binary content of a <em>group file</em> is updated.
159
+ * </p>
160
+ * <p>
161
+ * <strong>Permission note!</strong> Current user must be authorized to alter the file node that
162
+ * should be updated (e.g. {@link senselogic.sitevision.api.security.PermissionUtil.Permission#WRITE}).
163
+ * </p>
164
+ * @param aFile the file
165
+ * @param aBase64EncodedString a base64 encoded string
166
+ * @throws ConstraintViolationException if the user is not authorized to alter the file node, if an invalid node is specified, if <code>aBase64EncodedString</code> is not base64 encoded, if file exceeds file size limit or if file exceeds file size limit
167
+ * @throws RepositoryException if something else goes wrong
168
+ * @since Sitevision 4.5.4
169
+ */
170
+ updateBinaryContentFromBase64(
171
+ aFile: Node,
172
+ aBase64EncodedString: string
173
+ ): void;
198
174
 
199
- /**
200
- * Gets the contents of a file as a String using a given character encoding.
201
- *
202
- * <p>
203
- * <em>Note!</em> This method operates on character-based file nodes only! That is:
204
- * </p>
205
- * <ul>
206
- * <li>
207
- * Files that are of <em>text type</em> (as of {@link senselogic.sitevision.api.webresource.mime.MimeTypeUtil#isTextType(String)}).
208
- * </li>
209
- * <li>
210
- * Files that are of <em>xml type</em> (as of {@link senselogic.sitevision.api.webresource.mime.MimeTypeUtil#isXmlType(String)}).
211
- * </li>
212
- * <li>
213
- * Common "cross-over/mixed-types" files, such as <em>json</em> (application type) and <em>svg</em> (image type).
214
- * </li>
215
- * </ul>
216
- * @param aFile the file Node (sv:file or sv:temporaryFile)
217
- * @param aCharacterEncoding the character encoding (Note! UTF-8 will be used instead for null, empty and illegal/unsupported encoding)
218
- * @return the file content using the specified character encoding, or null if aFile isn't a character-based file
219
- * @since Sitevision 4.1.1
220
- */
221
- export function getContentAsString(
222
- aFile: Node,
223
- aCharacterEncoding: string
224
- ): string;
175
+ /**
176
+ * Updates the binary content of an existing file using a sv:temporaryFile.
177
+ *
178
+ * <p>
179
+ * Properties related to the binary content will also be updated (e.g. <code>length</code>). A new version will
180
+ * be created if the binary content of a <em>group file</em> is updated.
181
+ * </p>
182
+ * <p>
183
+ * <strong>Permission note!</strong> Current user must be authorized to alter the file node that
184
+ * should be updated (e.g. {@link senselogic.sitevision.api.security.PermissionUtil.Permission#WRITE}).
185
+ * </p>
186
+ * @param aFile the file
187
+ * @param aTemporaryFile the sv:temporaryFile (typically created via {@link senselogic.sitevision.api.node.builder.TemporaryFileNodeBuilder})
188
+ * @throws ConstraintViolationException if the user is not authorized to alter the file node, if an invalid node is specified, if the end part of the file represented by <code>aTemporaryFile</code> doesn't match the file extension of <code>aFile</code> or if file exceeds file size limit
189
+ * @throws RepositoryException if something else goes wrong
190
+ * @since Sitevision 4.5.4
191
+ */
192
+ updateBinaryContentFromTemporary(aFile: Node, aTemporaryFile: Node): void;
225
193
 
226
- /**
227
- * Alters the name of a file.
228
- *
229
- * <p>
230
- * If no file is specified a <code>NullPointerException</code> is thrown.
231
- * If the node is not a sv:file an <code>IllegalArgumentException</code> is thrown.
232
- * If no name is provided a <code>NullPointerException</code> is thrown.
233
- * </p>
234
- *
235
- * <p>
236
- * <strong>Permission note!</strong> Current user (the invoker of this method) must have WRITE permission
237
- * on the file node that should be updated (see {@link senselogic.sitevision.api.security.PermissionUtil.Permission#WRITE}).
238
- * <em>Updating a file for a <code>sv:userIdentity</code> requires
239
- * {@link senselogic.sitevision.api.security.PermissionUtil.Permission#MANAGE_USER_IDENTITIES} on current page.</em>
240
- * </p>
241
- * @param aFile the sv:file that should be renamed. May not be <code>null</code>
242
- * @param aNewName the new name of the file. May not be <code>null</code>
243
- * @throws ConstraintViolationException if the current user is not authorized to alter the name of the file or if the file extension doesn't match
244
- * @throws RepositoryException if something else goes wrong
245
- * @since Sitevision 4.5.2
246
- */
247
- export function renameFile(aFile: Node, aNewName: string): void;
194
+ /**
195
+ * Gets the contents of a file as a String using the UTF-8 character encoding.
196
+ *
197
+ * <p>
198
+ * <em>Note! This is mere a convenience method for {@link #getContentAsString(Node, String)} using UTF-8 as character encoding.</em>
199
+ * </p>
200
+ * @param aFile the file Node (sv:file or sv:temporaryFile)
201
+ * @return the UTF-8 file content, or null if aFile isn't a character-based file
202
+ * @see #getContentAsString(Node, String)
203
+ * @since Sitevision 4.1.1
204
+ */
205
+ getContentAsString(aFile: Node): string;
248
206
 
249
- /**
250
- * Modifies versioning for a file.
251
- *
252
- * <p>
253
- * <strong>Permission note!</strong> Current user (the invoker of this method) must have WRITE permission
254
- * on the file node that should be updated (see {@link senselogic.sitevision.api.security.PermissionUtil.Permission#WRITE}).
255
- * </p>
256
- * @param aFile the sv:file. May not be null
257
- * @param aVersioned the new state of versioning for this file
258
- * @throws ConstraintViolationException if the current user is not authorized to mutate aFile or if aFile is not a sv:file
259
- * @throws RepositoryException if something else goes wrong
260
- * @since Sitevision 9.1
261
- */
262
- export function setVersioned(aFile: Node, aVersioned: boolean): void;
207
+ /**
208
+ * Gets the contents of a file as a String using a given character encoding.
209
+ *
210
+ * <p>
211
+ * <em>Note!</em> This method operates on character-based file nodes only! That is:
212
+ * </p>
213
+ * <ul>
214
+ * <li>
215
+ * Files that are of <em>text type</em> (as of {@link senselogic.sitevision.api.webresource.mime.MimeTypeUtil#isTextType(String)}).
216
+ * </li>
217
+ * <li>
218
+ * Files that are of <em>xml type</em> (as of {@link senselogic.sitevision.api.webresource.mime.MimeTypeUtil#isXmlType(String)}).
219
+ * </li>
220
+ * <li>
221
+ * Common "cross-over/mixed-types" files, such as <em>json</em> (application type) and <em>svg</em> (image type).
222
+ * </li>
223
+ * </ul>
224
+ * @param aFile the file Node (sv:file or sv:temporaryFile)
225
+ * @param aCharacterEncoding the character encoding (Note! UTF-8 will be used instead for null, empty and illegal/unsupported encoding)
226
+ * @return the file content using the specified character encoding, or null if aFile isn't a character-based file
227
+ * @since Sitevision 4.1.1
228
+ */
229
+ getContentAsString(aFile: Node, aCharacterEncoding: string): string;
263
230
 
264
- /**
265
- * Modifies download protection for a file.
266
- *
267
- * <p>
268
- * <strong>Permission note!</strong> Current user (the invoker of this method) must have WRITE permission and MANAGE_DOWNLOAD_PROTECTION
269
- * permission on the file node that should be updated (see {@link senselogic.sitevision.api.security.PermissionUtil.Permission#WRITE}
270
- * and {@link senselogic.sitevision.api.security.PermissionUtil.Permission#MANAGE_DOWNLOAD_PROTECTION}).
271
- * </p>
272
- *
273
- * <p>
274
- * <em>Tip! Use {@link senselogic.sitevision.api.property.PropertyUtil} or {@link senselogic.sitevision.api.property.Properties}
275
- * to check current state, i.e. the "downloadProtected" boolean property.</em>
276
- * </p>
277
- * @param aFile the sv:file. May not be null
278
- * @param aDownloadProtected the new state of download protection for aFile
279
- * @throws ConstraintViolationException if the current user is not authorized to mutate aFile or if aFile is not a sv:file
280
- * @throws RepositoryException if something else goes wrong
281
- * @since Sitevision 2022.08.1
282
- */
283
- export function setDownloadProtected(
284
- aFile: Node,
285
- aDownloadProtected: boolean
286
- ): void;
231
+ /**
232
+ * Alters the name of a file.
233
+ *
234
+ * <p>
235
+ * If no file is specified a <code>NullPointerException</code> is thrown.
236
+ * If the node is not a sv:file an <code>IllegalArgumentException</code> is thrown.
237
+ * If no name is provided a <code>NullPointerException</code> is thrown.
238
+ * </p>
239
+ *
240
+ * <p>
241
+ * <strong>Permission note!</strong> Current user (the invoker of this method) must have WRITE permission
242
+ * on the file node that should be updated (see {@link senselogic.sitevision.api.security.PermissionUtil.Permission#WRITE}).
243
+ * <em>Updating a file for a <code>sv:userIdentity</code> requires
244
+ * {@link senselogic.sitevision.api.security.PermissionUtil.Permission#MANAGE_USER_IDENTITIES} on current page.</em>
245
+ * </p>
246
+ * @param aFile the sv:file that should be renamed. May not be <code>null</code>
247
+ * @param aNewName the new name of the file. May not be <code>null</code>
248
+ * @throws ConstraintViolationException if the current user is not authorized to alter the name of the file or if the file extension doesn't match
249
+ * @throws RepositoryException if something else goes wrong
250
+ * @since Sitevision 4.5.2
251
+ */
252
+ renameFile(aFile: Node, aNewName: string): void;
287
253
 
288
- /**
289
- * File utility interface that handles nodes with primary node type <code>sv:file</code> and <code>sv:temporaryFile</code>.
290
- *
291
- * <p>
292
- * <em>Note!</em> This interface is used to <em>create</em> files. You would typically use
293
- * {@link senselogic.sitevision.api.webresource.structure.StructureUtil} to <em>move</em> a file
294
- * and {@link senselogic.sitevision.api.webresource.structure.TrashcanUtil} to <em>delete</em> a file.
295
- * To check <em>MIME/Content-Type</em> for a file you would typically use {@link senselogic.sitevision.api.webresource.mime.MimeTypeUtil}.
296
- * </p>
297
- *
298
- * <p>
299
- * An instance of the Sitevision class implementing this interface can be obtained via {@link senselogic.sitevision.api.Utils#getFileUtil()}.
300
- * See {@link senselogic.sitevision.api.Utils} for how to obtain an instance of the <code>Utils</code> interface.
301
- * </p>
302
- * @author Mikael Wikblom
303
- * @since Sitevision 2.6.2
304
- */
305
- declare namespace fileUtil {
306
- export {
307
- createFiles,
308
- createFile,
309
- createFileFromBase64,
310
- createFileFromTemporary,
311
- updateBinaryContent,
312
- updateBinaryContentFromBase64,
313
- updateBinaryContentFromTemporary,
314
- getContentAsString,
315
- renameFile,
316
- setVersioned,
317
- setDownloadProtected,
318
- };
254
+ /**
255
+ * Modifies versioning for a file.
256
+ *
257
+ * <p>
258
+ * <strong>Permission note!</strong> Current user (the invoker of this method) must have WRITE permission
259
+ * on the file node that should be updated (see {@link senselogic.sitevision.api.security.PermissionUtil.Permission#WRITE}).
260
+ * </p>
261
+ * @param aFile the sv:file. May not be null
262
+ * @param aVersioned the new state of versioning for this file
263
+ * @throws ConstraintViolationException if the current user is not authorized to mutate aFile or if aFile is not a sv:file
264
+ * @throws RepositoryException if something else goes wrong
265
+ * @since Sitevision 9.1
266
+ */
267
+ setVersioned(aFile: Node, aVersioned: boolean): void;
268
+
269
+ /**
270
+ * Modifies download protection for a file.
271
+ *
272
+ * <p>
273
+ * <strong>Permission note!</strong> Current user (the invoker of this method) must have WRITE permission and MANAGE_DOWNLOAD_PROTECTION
274
+ * permission on the file node that should be updated (see {@link senselogic.sitevision.api.security.PermissionUtil.Permission#WRITE}
275
+ * and {@link senselogic.sitevision.api.security.PermissionUtil.Permission#MANAGE_DOWNLOAD_PROTECTION}).
276
+ * </p>
277
+ *
278
+ * <p>
279
+ * <em>Tip! Use {@link senselogic.sitevision.api.property.PropertyUtil} or {@link senselogic.sitevision.api.property.Properties}
280
+ * to check current state, i.e. the "downloadProtected" boolean property.</em>
281
+ * </p>
282
+ * @param aFile the sv:file. May not be null
283
+ * @param aDownloadProtected the new state of download protection for aFile
284
+ * @throws ConstraintViolationException if the current user is not authorized to mutate aFile or if aFile is not a sv:file
285
+ * @throws RepositoryException if something else goes wrong
286
+ * @since Sitevision 2022.08.1
287
+ */
288
+ setDownloadProtected(aFile: Node, aDownloadProtected: boolean): void;
319
289
  }
320
290
 
321
- export default fileUtil;
291
+ declare namespace FileUtil {}
292
+
293
+ declare var fileUtil: FileUtil;
294
+
295
+ export = fileUtil;