@openui5/sap.ui.core 1.107.1 → 1.108.0

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 (287) hide show
  1. package/.dtsgenrc +63 -0
  2. package/THIRDPARTY.txt +1 -1
  3. package/package.json +1 -1
  4. package/src/jquery.sap.global.js +1 -1
  5. package/src/jquery.sap.properties.js +1 -1
  6. package/src/jquery.sap.resources.js +1 -1
  7. package/src/jquery.sap.script.js +1 -1
  8. package/src/jquery.sap.storage.js +3 -3
  9. package/src/sap/base/i18n/ResourceBundle.js +10 -0
  10. package/src/sap/base/security/URLListValidator.js +36 -3
  11. package/src/sap/base/util/restricted/_CancelablePromise.js +1 -1
  12. package/src/sap/base/util/restricted/_castArray.js +1 -1
  13. package/src/sap/base/util/restricted/_compact.js +1 -1
  14. package/src/sap/base/util/restricted/_curry.js +1 -1
  15. package/src/sap/base/util/restricted/_debounce.js +1 -1
  16. package/src/sap/base/util/restricted/_difference.js +1 -1
  17. package/src/sap/base/util/restricted/_differenceBy.js +1 -1
  18. package/src/sap/base/util/restricted/_differenceWith.js +1 -1
  19. package/src/sap/base/util/restricted/_flatMap.js +1 -1
  20. package/src/sap/base/util/restricted/_flatMapDeep.js +1 -1
  21. package/src/sap/base/util/restricted/_flatMapDepth.js +1 -1
  22. package/src/sap/base/util/restricted/_flatten.js +1 -1
  23. package/src/sap/base/util/restricted/_flattenDeep.js +1 -1
  24. package/src/sap/base/util/restricted/_flattenDepth.js +1 -1
  25. package/src/sap/base/util/restricted/_intersection.js +1 -1
  26. package/src/sap/base/util/restricted/_intersectionBy.js +1 -1
  27. package/src/sap/base/util/restricted/_intersectionWith.js +1 -1
  28. package/src/sap/base/util/restricted/_isEqual.js +1 -1
  29. package/src/sap/base/util/restricted/_isEqualWith.js +1 -1
  30. package/src/sap/base/util/restricted/_isNil.js +1 -1
  31. package/src/sap/base/util/restricted/_max.js +1 -1
  32. package/src/sap/base/util/restricted/_merge.js +1 -1
  33. package/src/sap/base/util/restricted/_mergeWith.js +1 -1
  34. package/src/sap/base/util/restricted/_min.js +1 -1
  35. package/src/sap/base/util/restricted/_omit.js +1 -1
  36. package/src/sap/base/util/restricted/_pick.js +1 -1
  37. package/src/sap/base/util/restricted/_pickBy.js +1 -1
  38. package/src/sap/base/util/restricted/_throttle.js +1 -1
  39. package/src/sap/base/util/restricted/_toArray.js +1 -1
  40. package/src/sap/base/util/restricted/_union.js +1 -1
  41. package/src/sap/base/util/restricted/_unionBy.js +1 -1
  42. package/src/sap/base/util/restricted/_unionWith.js +1 -1
  43. package/src/sap/base/util/restricted/_uniq.js +1 -1
  44. package/src/sap/base/util/restricted/_uniqBy.js +1 -1
  45. package/src/sap/base/util/restricted/_uniqWith.js +1 -1
  46. package/src/sap/base/util/restricted/_without.js +1 -1
  47. package/src/sap/base/util/restricted/_xor.js +1 -1
  48. package/src/sap/base/util/restricted/_xorBy.js +1 -1
  49. package/src/sap/base/util/restricted/_xorWith.js +1 -1
  50. package/src/sap/base/util/restricted/_zipObject.js +1 -1
  51. package/src/sap/base/util/restricted/_zipObjectDeep.js +1 -1
  52. package/src/sap/ui/Device.js +3 -3
  53. package/src/sap/ui/Global.js +4 -4
  54. package/src/sap/ui/base/Event.js +1 -1
  55. package/src/sap/ui/base/EventProvider.js +1 -1
  56. package/src/sap/ui/base/Interface.js +1 -1
  57. package/src/sap/ui/base/ManagedObject.js +2 -2
  58. package/src/sap/ui/base/ManagedObjectMetadata.js +1 -1
  59. package/src/sap/ui/base/Metadata.js +1 -1
  60. package/src/sap/ui/base/Object.js +1 -1
  61. package/src/sap/ui/base/ObjectPool.js +1 -1
  62. package/src/sap/ui/core/.library +50 -50
  63. package/src/sap/ui/core/BusyIndicator.js +1 -1
  64. package/src/sap/ui/core/BusyIndicatorUtils.js +22 -8
  65. package/src/sap/ui/core/Component.js +21 -4
  66. package/src/sap/ui/core/ComponentContainer.js +5 -1
  67. package/src/sap/ui/core/ComponentMetadata.js +1 -1
  68. package/src/sap/ui/core/ComponentSupport.js +1 -1
  69. package/src/sap/ui/core/Configuration.js +2 -15
  70. package/src/sap/ui/core/Control.js +20 -2
  71. package/src/sap/ui/core/Core.js +311 -413
  72. package/src/sap/ui/core/CustomData.js +1 -1
  73. package/src/sap/ui/core/DeclarativeSupport.js +1 -1
  74. package/src/sap/ui/core/Element.js +1 -1
  75. package/src/sap/ui/core/ElementMetadata.js +1 -1
  76. package/src/sap/ui/core/EnabledPropagator.js +1 -1
  77. package/src/sap/ui/core/EventBus.js +1 -1
  78. package/src/sap/ui/core/FocusHandler.js +12 -14
  79. package/src/sap/ui/core/Fragment.js +5 -2
  80. package/src/sap/ui/core/HTML.js +1 -1
  81. package/src/sap/ui/core/History.js +1 -1
  82. package/src/sap/ui/core/Icon.js +1 -1
  83. package/src/sap/ui/core/IconPool.js +7 -1
  84. package/src/sap/ui/core/IndicationColorSupport.js +1 -1
  85. package/src/sap/ui/core/IntervalTrigger.js +1 -1
  86. package/src/sap/ui/core/InvisibleMessage.js +1 -1
  87. package/src/sap/ui/core/InvisibleRenderer.js +1 -1
  88. package/src/sap/ui/core/InvisibleText.js +1 -1
  89. package/src/sap/ui/core/Item.js +1 -1
  90. package/src/sap/ui/core/LabelEnablement.js +1 -1
  91. package/src/sap/ui/core/LayoutData.js +1 -1
  92. package/src/sap/ui/core/ListItem.js +1 -1
  93. package/src/sap/ui/core/LocalBusyIndicator.js +1 -1
  94. package/src/sap/ui/core/Locale.js +1 -1
  95. package/src/sap/ui/core/LocaleData.js +1 -1
  96. package/src/sap/ui/core/Manifest.js +16 -83
  97. package/src/sap/ui/core/Message.js +1 -1
  98. package/src/sap/ui/core/Popup.js +14 -4
  99. package/src/sap/ui/core/RenderManager.js +111 -109
  100. package/src/sap/ui/core/Renderer.js +1 -1
  101. package/src/sap/ui/core/ResizeHandler.js +1 -1
  102. package/src/sap/ui/core/ScrollBar.js +1 -1
  103. package/src/sap/ui/core/SeparatorItem.js +1 -1
  104. package/src/sap/ui/core/ShortcutHintsMixin.js +20 -0
  105. package/src/sap/ui/core/Title.js +1 -1
  106. package/src/sap/ui/core/TooltipBase.js +1 -1
  107. package/src/sap/ui/core/UIArea.js +4 -2
  108. package/src/sap/ui/core/UIComponent.js +1 -1
  109. package/src/sap/ui/core/UIComponentMetadata.js +1 -1
  110. package/src/sap/ui/core/ValueStateSupport.js +1 -1
  111. package/src/sap/ui/core/VariantLayoutData.js +1 -1
  112. package/src/sap/ui/core/XMLComposite.js +1 -1
  113. package/src/sap/ui/core/XMLCompositeMetadata.js +1 -1
  114. package/src/sap/ui/core/_IconRegistry.js +11 -7
  115. package/src/sap/ui/core/_UrlResolver.js +139 -0
  116. package/src/sap/ui/core/date/CalendarUtils.js +87 -0
  117. package/src/sap/ui/core/date/CalendarWeekNumbering.js +73 -0
  118. package/src/sap/ui/core/date/UniversalDate.js +198 -74
  119. package/src/sap/ui/core/delegate/ItemNavigation.js +1 -1
  120. package/src/sap/ui/core/delegate/ScrollEnablement.js +1 -1
  121. package/src/sap/ui/core/dnd/DragDropBase.js +1 -1
  122. package/src/sap/ui/core/dnd/DragDropInfo.js +1 -1
  123. package/src/sap/ui/core/dnd/DragInfo.js +1 -1
  124. package/src/sap/ui/core/dnd/DropInfo.js +1 -1
  125. package/src/sap/ui/core/format/DateFormat.js +187 -57
  126. package/src/sap/ui/core/format/NumberFormat.js +64 -23
  127. package/src/sap/ui/core/format/TimezoneUtil.js +3 -1
  128. package/src/sap/ui/core/hyphenation/Hyphenation.js +1 -1
  129. package/src/sap/ui/core/library.js +19 -10
  130. package/src/sap/ui/core/message/ControlMessageProcessor.js +1 -1
  131. package/src/sap/ui/core/message/Message.js +5 -3
  132. package/src/sap/ui/core/message/MessageManager.js +1 -1
  133. package/src/sap/ui/core/message/MessageParser.js +1 -1
  134. package/src/sap/ui/core/message/MessageProcessor.js +1 -1
  135. package/src/sap/ui/core/messagebundle_fr.properties +1 -1
  136. package/src/sap/ui/core/mvc/HTMLView.js +10 -2
  137. package/src/sap/ui/core/mvc/JSONView.js +1 -1
  138. package/src/sap/ui/core/mvc/JSView.js +1 -1
  139. package/src/sap/ui/core/mvc/TemplateView.js +1 -1
  140. package/src/sap/ui/core/mvc/View.js +1 -1
  141. package/src/sap/ui/core/mvc/XMLView.js +1 -1
  142. package/src/sap/ui/core/plugin/DeclarativeSupport.js +1 -1
  143. package/src/sap/ui/core/plugin/LessSupport.js +21 -20
  144. package/src/sap/ui/core/plugin/TemplatingSupport.js +1 -1
  145. package/src/sap/ui/core/postmessage/Bus.js +1 -1
  146. package/src/sap/ui/core/postmessage/confirmationDialog.js +1 -1
  147. package/src/sap/ui/core/search/OpenSearchProvider.js +1 -1
  148. package/src/sap/ui/core/search/SearchProvider.js +1 -1
  149. package/src/sap/ui/core/service/Service.js +1 -1
  150. package/src/sap/ui/core/service/ServiceFactory.js +1 -1
  151. package/src/sap/ui/core/service/ServiceFactoryRegistry.js +1 -1
  152. package/src/sap/ui/core/support/Plugin.js +1 -1
  153. package/src/sap/ui/core/support/Support.js +1 -1
  154. package/src/sap/ui/core/support/plugins/ControlTree.js +1 -1
  155. package/src/sap/ui/core/support/plugins/Interaction.js +1 -1
  156. package/src/sap/ui/core/support/plugins/LocalStorage.js +1 -1
  157. package/src/sap/ui/core/support/plugins/Performance.js +1 -1
  158. package/src/sap/ui/core/support/plugins/Selector.js +1 -1
  159. package/src/sap/ui/core/support/plugins/TechInfo.js +1 -1
  160. package/src/sap/ui/core/support/plugins/Trace.js +1 -1
  161. package/src/sap/ui/core/support/plugins/ViewInfo.js +1 -1
  162. package/src/sap/ui/core/themes/base/LocalBusyIndicator.less +3 -3
  163. package/src/sap/ui/core/themes/base/fonts/SAP-icons.woff2 +0 -0
  164. package/src/sap/ui/core/theming/Parameters.js +31 -12
  165. package/src/sap/ui/core/theming/ThemeHelper.js +56 -1
  166. package/src/sap/ui/core/theming/ThemeManager.js +817 -0
  167. package/src/sap/ui/core/tmpl/DOMAttribute.js +1 -1
  168. package/src/sap/ui/core/tmpl/DOMElement.js +1 -1
  169. package/src/sap/ui/core/tmpl/HandlebarsTemplate.js +1 -1
  170. package/src/sap/ui/core/tmpl/Template.js +1 -1
  171. package/src/sap/ui/core/tmpl/TemplateControl.js +1 -1
  172. package/src/sap/ui/core/util/AsyncHintsHelper.js +1 -1
  173. package/src/sap/ui/core/util/Export.js +1 -1
  174. package/src/sap/ui/core/util/ExportCell.js +1 -1
  175. package/src/sap/ui/core/util/ExportColumn.js +1 -1
  176. package/src/sap/ui/core/util/ExportRow.js +1 -1
  177. package/src/sap/ui/core/util/ExportType.js +1 -1
  178. package/src/sap/ui/core/util/ExportTypeCSV.js +1 -1
  179. package/src/sap/ui/core/util/File.js +1 -1
  180. package/src/sap/ui/core/util/LibraryInfo.js +1 -1
  181. package/src/sap/ui/core/util/MockServer.js +1 -1
  182. package/src/sap/ui/core/util/PasteHelper.js +1 -1
  183. package/src/sap/ui/core/util/serializer/HTMLViewSerializer.js +2 -1
  184. package/src/sap/ui/core/util/serializer/Serializer.js +1 -1
  185. package/src/sap/ui/core/util/serializer/ViewSerializer.js +1 -1
  186. package/src/sap/ui/core/util/serializer/XMLViewSerializer.js +1 -1
  187. package/src/sap/ui/core/util/serializer/delegate/Delegate.js +1 -1
  188. package/src/sap/ui/core/util/serializer/delegate/HTML.js +1 -1
  189. package/src/sap/ui/core/util/serializer/delegate/XML.js +1 -1
  190. package/src/sap/ui/core/ws/ReadyState.js +1 -1
  191. package/src/sap/ui/core/ws/SapPcpWebSocket.js +1 -1
  192. package/src/sap/ui/core/ws/WebSocket.js +1 -1
  193. package/src/sap/ui/debug/ControlTree.js +1 -1
  194. package/src/sap/ui/debug/DebugEnv.js +1 -1
  195. package/src/sap/ui/debug/PropertyList.js +1 -1
  196. package/src/sap/ui/dom/getFirstEditableInput.js +25 -6
  197. package/src/sap/ui/dom/includeStylesheet.js +2 -2
  198. package/src/sap/ui/model/ClientListBinding.js +11 -4
  199. package/src/sap/ui/model/ClientModel.js +1 -1
  200. package/src/sap/ui/model/ClientTreeBinding.js +60 -5
  201. package/src/sap/ui/model/CompositeDataState.js +1 -1
  202. package/src/sap/ui/model/CompositeType.js +1 -1
  203. package/src/sap/ui/model/DataState.js +1 -1
  204. package/src/sap/ui/model/Filter.js +6 -6
  205. package/src/sap/ui/model/MetaModel.js +1 -1
  206. package/src/sap/ui/model/Model.js +1 -1
  207. package/src/sap/ui/model/SelectionModel.js +1 -1
  208. package/src/sap/ui/model/SimpleType.js +1 -1
  209. package/src/sap/ui/model/Sorter.js +6 -4
  210. package/src/sap/ui/model/TreeAutoExpandMode.js +1 -1
  211. package/src/sap/ui/model/TreeBinding.js +18 -0
  212. package/src/sap/ui/model/TreeBindingCompatibilityAdapter.js +1 -1
  213. package/src/sap/ui/model/Type.js +1 -1
  214. package/src/sap/ui/model/analytics/AnalyticalTreeBindingAdapter.js +28 -34
  215. package/src/sap/ui/model/controlhelper/TreeBindingProxy.js +590 -0
  216. package/src/sap/ui/model/json/JSONModel.js +1 -1
  217. package/src/sap/ui/model/message/MessageModel.js +1 -1
  218. package/src/sap/ui/model/odata/ODataAnnotations.js +1 -1
  219. package/src/sap/ui/model/odata/ODataMessageParser.js +1 -1
  220. package/src/sap/ui/model/odata/ODataMetaModel.js +1 -1
  221. package/src/sap/ui/model/odata/ODataMetadata.js +1 -1
  222. package/src/sap/ui/model/odata/ODataModel.js +1 -1
  223. package/src/sap/ui/model/odata/type/Boolean.js +1 -1
  224. package/src/sap/ui/model/odata/type/Byte.js +1 -1
  225. package/src/sap/ui/model/odata/type/Currency.js +1 -1
  226. package/src/sap/ui/model/odata/type/Date.js +1 -1
  227. package/src/sap/ui/model/odata/type/DateTime.js +1 -1
  228. package/src/sap/ui/model/odata/type/DateTimeBase.js +1 -1
  229. package/src/sap/ui/model/odata/type/DateTimeOffset.js +1 -1
  230. package/src/sap/ui/model/odata/type/DateTimeWithTimezone.js +1 -1
  231. package/src/sap/ui/model/odata/type/Decimal.js +1 -1
  232. package/src/sap/ui/model/odata/type/Double.js +1 -1
  233. package/src/sap/ui/model/odata/type/Guid.js +1 -1
  234. package/src/sap/ui/model/odata/type/Int.js +1 -1
  235. package/src/sap/ui/model/odata/type/Int16.js +1 -1
  236. package/src/sap/ui/model/odata/type/Int32.js +1 -1
  237. package/src/sap/ui/model/odata/type/Int64.js +1 -1
  238. package/src/sap/ui/model/odata/type/ODataType.js +1 -1
  239. package/src/sap/ui/model/odata/type/Raw.js +1 -1
  240. package/src/sap/ui/model/odata/type/SByte.js +1 -1
  241. package/src/sap/ui/model/odata/type/Single.js +1 -1
  242. package/src/sap/ui/model/odata/type/Stream.js +1 -1
  243. package/src/sap/ui/model/odata/type/String.js +1 -1
  244. package/src/sap/ui/model/odata/type/Time.js +1 -1
  245. package/src/sap/ui/model/odata/type/TimeOfDay.js +1 -1
  246. package/src/sap/ui/model/odata/type/Unit.js +1 -1
  247. package/src/sap/ui/model/odata/v2/BatchMode.js +2 -2
  248. package/src/sap/ui/model/odata/v2/Context.js +169 -4
  249. package/src/sap/ui/model/odata/v2/ODataAnnotations.js +1 -1
  250. package/src/sap/ui/model/odata/v2/ODataListBinding.js +39 -17
  251. package/src/sap/ui/model/odata/v2/ODataModel.js +219 -82
  252. package/src/sap/ui/model/odata/v2/ODataTreeBinding.js +1 -1
  253. package/src/sap/ui/model/odata/v4/Context.js +35 -22
  254. package/src/sap/ui/model/odata/v4/ODataBinding.js +28 -22
  255. package/src/sap/ui/model/odata/v4/ODataContextBinding.js +6 -6
  256. package/src/sap/ui/model/odata/v4/ODataListBinding.js +111 -89
  257. package/src/sap/ui/model/odata/v4/ODataMetaModel.js +5 -4
  258. package/src/sap/ui/model/odata/v4/ODataModel.js +84 -46
  259. package/src/sap/ui/model/odata/v4/ODataParentBinding.js +19 -20
  260. package/src/sap/ui/model/odata/v4/ODataPropertyBinding.js +3 -3
  261. package/src/sap/ui/model/odata/v4/_AnnotationHelperExpression.js +1 -1
  262. package/src/sap/ui/model/odata/v4/lib/_AggregationCache.js +12 -5
  263. package/src/sap/ui/model/odata/v4/lib/_Cache.js +130 -64
  264. package/src/sap/ui/model/odata/v4/lib/_Helper.js +1 -1
  265. package/src/sap/ui/model/odata/v4/lib/_Requestor.js +56 -15
  266. package/src/sap/ui/model/resource/ResourceModel.js +1 -1
  267. package/src/sap/ui/model/type/Boolean.js +1 -1
  268. package/src/sap/ui/model/type/Currency.js +1 -1
  269. package/src/sap/ui/model/type/Date.js +1 -1
  270. package/src/sap/ui/model/type/DateInterval.js +1 -1
  271. package/src/sap/ui/model/type/DateTime.js +1 -1
  272. package/src/sap/ui/model/type/DateTimeInterval.js +1 -1
  273. package/src/sap/ui/model/type/FileSize.js +1 -1
  274. package/src/sap/ui/model/type/Float.js +1 -1
  275. package/src/sap/ui/model/type/Integer.js +1 -1
  276. package/src/sap/ui/model/type/String.js +1 -1
  277. package/src/sap/ui/model/type/Time.js +1 -1
  278. package/src/sap/ui/model/type/TimeInterval.js +1 -1
  279. package/src/sap/ui/model/type/Unit.js +1 -1
  280. package/src/sap/ui/model/xml/XMLModel.js +1 -1
  281. package/src/sap/ui/qunit/utils/ControlIterator.js +1 -1
  282. package/src/sap/ui/qunit/utils/MemoryLeakCheck.js +1 -1
  283. package/src/sap/ui/test/TestUtils.js +20 -0
  284. package/src/sap/ui/test/generic/TestBase.js +1 -1
  285. package/src/sap/ui/thirdparty/mobify-carousel.js +0 -4
  286. package/src/sap/ui/util/Storage.js +1 -1
  287. package/src/sap/ui/core/ThemeCheck.js +0 -389
@@ -59,7 +59,7 @@ sap.ui.define([
59
59
  * @extends sap.ui.model.odata.type.DateTimeBase
60
60
  *
61
61
  * @author SAP SE
62
- * @version 1.107.1
62
+ * @version 1.108.0
63
63
  *
64
64
  * @alias sap.ui.model.odata.type.DateTime
65
65
  * @param {object} [oFormatOptions]
@@ -132,7 +132,7 @@ sap.ui.define([
132
132
  * @extends sap.ui.model.odata.type.ODataType
133
133
  * @public
134
134
  * @since 1.27.0
135
- * @version 1.107.1
135
+ * @version 1.108.0
136
136
  */
137
137
  var DateTimeBase = ODataType.extend("sap.ui.model.odata.type.DateTimeBase", {
138
138
  constructor : function (oFormatOptions, oConstraints) {
@@ -28,7 +28,7 @@ sap.ui.define([
28
28
  * @extends sap.ui.model.odata.type.DateTimeBase
29
29
  *
30
30
  * @author SAP SE
31
- * @version 1.107.1
31
+ * @version 1.108.0
32
32
  *
33
33
  * @alias sap.ui.model.odata.type.DateTimeOffset
34
34
  * @param {object} [oFormatOptions]
@@ -60,7 +60,7 @@ sap.ui.define([
60
60
  * @public
61
61
  * @see {sap.ui.model.odata.v2.ODataModel#bindProperty}
62
62
  * @since 1.99.0
63
- * @version 1.107.1
63
+ * @version 1.108.0
64
64
  */
65
65
  var DateTimeWithTimezone = CompositeType.extend("sap.ui.model.odata.type.DateTimeWithTimezone",
66
66
  {
@@ -201,7 +201,7 @@ sap.ui.define([
201
201
  * @extends sap.ui.model.odata.type.ODataType
202
202
  *
203
203
  * @author SAP SE
204
- * @version 1.107.1
204
+ * @version 1.108.0
205
205
  *
206
206
  * @alias sap.ui.model.odata.type.Decimal
207
207
  * @param {object} [oFormatOptions]
@@ -95,7 +95,7 @@ sap.ui.define([
95
95
  * @extends sap.ui.model.odata.type.ODataType
96
96
  *
97
97
  * @author SAP SE
98
- * @version 1.107.1
98
+ * @version 1.108.0
99
99
  *
100
100
  * @alias sap.ui.model.odata.type.Double
101
101
  * @param {object} [oFormatOptions]
@@ -62,7 +62,7 @@ sap.ui.define([
62
62
  * @extends sap.ui.model.odata.type.ODataType
63
63
  *
64
64
  * @author SAP SE
65
- * @version 1.107.1
65
+ * @version 1.108.0
66
66
  *
67
67
  * @alias sap.ui.model.odata.type.Guid
68
68
  * @param {object} [oFormatOptions]
@@ -80,7 +80,7 @@ sap.ui.define([
80
80
  * @extends sap.ui.model.odata.type.ODataType
81
81
  *
82
82
  * @author SAP SE
83
- * @version 1.107.1
83
+ * @version 1.108.0
84
84
  *
85
85
  * @abstract
86
86
  * @alias sap.ui.model.odata.type.Int
@@ -24,7 +24,7 @@ sap.ui.define([
24
24
  * @extends sap.ui.model.odata.type.Int
25
25
  *
26
26
  * @author SAP SE
27
- * @version 1.107.1
27
+ * @version 1.108.0
28
28
  *
29
29
  * @alias sap.ui.model.odata.type.Int16
30
30
  * @param {object} [oFormatOptions]
@@ -24,7 +24,7 @@ sap.ui.define([
24
24
  * @extends sap.ui.model.odata.type.Int
25
25
  *
26
26
  * @author SAP SE
27
- * @version 1.107.1
27
+ * @version 1.108.0
28
28
  *
29
29
  * @alias sap.ui.model.odata.type.Int32
30
30
  * @param {object} [oFormatOptions]
@@ -137,7 +137,7 @@ sap.ui.define([
137
137
  * @extends sap.ui.model.odata.type.ODataType
138
138
  *
139
139
  * @author SAP SE
140
- * @version 1.107.1
140
+ * @version 1.108.0
141
141
  *
142
142
  * @alias sap.ui.model.odata.type.Int64
143
143
  * @param {object} [oFormatOptions]
@@ -115,7 +115,7 @@ sap.ui.define([
115
115
  * @extends sap.ui.model.SimpleType
116
116
  *
117
117
  * @author SAP SE
118
- * @version 1.107.1
118
+ * @version 1.108.0
119
119
  *
120
120
  * @abstract
121
121
  * @alias sap.ui.model.odata.type.ODataType
@@ -30,7 +30,7 @@ sap.ui.define([
30
30
  * @extends sap.ui.model.odata.type.ODataType
31
31
  * @public
32
32
  * @since 1.37.0
33
- * @version 1.107.1
33
+ * @version 1.108.0
34
34
  */
35
35
  var Raw = ODataType.extend("sap.ui.model.odata.type.Raw", {
36
36
  constructor : function (oFormatOptions, oConstraints) {
@@ -24,7 +24,7 @@ sap.ui.define([
24
24
  * @extends sap.ui.model.odata.type.Int
25
25
  *
26
26
  * @author SAP SE
27
- * @version 1.107.1
27
+ * @version 1.108.0
28
28
  *
29
29
  * @alias sap.ui.model.odata.type.SByte
30
30
  * @param {object} [oFormatOptions]
@@ -95,7 +95,7 @@ sap.ui.define([
95
95
  * @extends sap.ui.model.odata.type.ODataType
96
96
  *
97
97
  * @author SAP SE
98
- * @version 1.107.1
98
+ * @version 1.108.0
99
99
  *
100
100
  * @alias sap.ui.model.odata.type.Single
101
101
  * @param {object} [oFormatOptions]
@@ -60,7 +60,7 @@ sap.ui.define([
60
60
  * @extends sap.ui.model.odata.type.ODataType
61
61
  * @public
62
62
  * @since 1.51.0
63
- * @version 1.107.1
63
+ * @version 1.108.0
64
64
  */
65
65
  var Stream = ODataType.extend("sap.ui.model.odata.type.Stream", {
66
66
  constructor : function (oFormatOptions, oConstraints) {
@@ -84,7 +84,7 @@ sap.ui.define([
84
84
  * @extends sap.ui.model.odata.type.ODataType
85
85
  *
86
86
  * @author SAP SE
87
- * @version 1.107.1
87
+ * @version 1.108.0
88
88
  *
89
89
  * @alias sap.ui.model.odata.type.String
90
90
  * @param {object} [oFormatOptions]
@@ -154,7 +154,7 @@ sap.ui.define([
154
154
  * @extends sap.ui.model.odata.type.ODataType
155
155
  *
156
156
  * @author SAP SE
157
- * @version 1.107.1
157
+ * @version 1.108.0
158
158
  *
159
159
  * @alias sap.ui.model.odata.type.Time
160
160
  * @param {object} [oFormatOptions]
@@ -110,7 +110,7 @@ sap.ui.define([
110
110
  * @extends sap.ui.model.odata.type.ODataType
111
111
  * @public
112
112
  * @since 1.37.0
113
- * @version 1.107.1
113
+ * @version 1.108.0
114
114
  */
115
115
  var TimeOfDay = ODataType.extend("sap.ui.model.odata.type.TimeOfDay", {
116
116
  constructor : function (oFormatOptions, oConstraints) {
@@ -63,7 +63,7 @@ sap.ui.define([
63
63
  * @extends sap.ui.model.type.Unit
64
64
  * @public
65
65
  * @since 1.63.0
66
- * @version 1.107.1
66
+ * @version 1.108.0
67
67
  */
68
68
  var Unit = BaseUnit.extend("sap.ui.model.odata.type.Unit", {
69
69
  constructor : function (oFormatOptions, oConstraints, aDynamicFormatOptionNames) {
@@ -15,8 +15,8 @@ sap.ui.define(function() {
15
15
  * @enum {string}
16
16
  * @public
17
17
  * @alias sap.ui.model.odata.v2.BatchMode
18
- * @deprecated Use {@link sap.ui.model.odata.CountMode} to specify how the count of collections
19
- * is retrieved. Use the <code>useBatch</code> parameter of the
18
+ * @deprecated since 1.74.0; Use {@link sap.ui.model.odata.CountMode} to specify how the count of
19
+ collections is retrieved. Use the <code>useBatch</code> parameter of the
20
20
  * {@link sap.ui.model.odata.v2.ODataModel} constructor to specify whether requests are sent in
21
21
  * $batch.
22
22
  */
@@ -26,7 +26,8 @@ sap.ui.define([
26
26
  * @param {sap.ui.base.SyncPromise} [oCreatePromise]
27
27
  * A sync promise that is given when this context has been created by
28
28
  * {@link sap.ui.model.odata.v2.ODataModel#createEntry} or
29
- * {@link sap.ui.model.odata.v2.ODataListBinding#create}.
29
+ * {@link sap.ui.model.odata.v2.ODataListBinding#create}; ignored if the parameter
30
+ * <code>oTransientParent</code> is given.
30
31
  *
31
32
  * When the entity represented by this context has been successfully persisted in the back
32
33
  * end, the given promise resolves.
@@ -38,6 +39,9 @@ sap.ui.define([
38
39
  * <code>oError.aborted === true</code>.
39
40
  * @param {boolean} [bInactive]
40
41
  * Whether the created context is inactive
42
+ * @param {boolean} [oTransientParent]
43
+ * The transient parent context of this created context for the case of deep-create; if given,
44
+ * the created promise of the parent context is also used for this context.
41
45
  * @alias sap.ui.model.odata.v2.Context
42
46
  * @author SAP SE
43
47
  * @class Implementation of an OData V2 model's context.
@@ -60,10 +64,11 @@ sap.ui.define([
60
64
  * @hideconstructor
61
65
  * @public
62
66
  * @since 1.93.0
63
- * @version 1.107.1
67
+ * @version 1.108.0
64
68
  */
65
69
  var Context = BaseContext.extend("sap.ui.model.odata.v2.Context", {
66
- constructor : function (oModel, sPath, sDeepPath, oCreatePromise, bInactive) {
70
+ constructor : function (oModel, sPath, sDeepPath, oCreatePromise, bInactive,
71
+ oTransientParent) {
67
72
  var that = this;
68
73
 
69
74
  BaseContext.call(this, oModel, sPath);
@@ -82,7 +87,9 @@ sap.ui.define([
82
87
  // SyncPromise for a context created via
83
88
  // sap.ui.model.odata.v2.ODataModel#createEntry; used internally to detect
84
89
  // synchronously whether the promise is already fulfilled
85
- this.oSyncCreatePromise = oCreatePromise;
90
+ this.oSyncCreatePromise = oTransientParent
91
+ ? oTransientParent.oSyncCreatePromise
92
+ : oCreatePromise;
86
93
  // whether the context is updated, e.g. path changed from a preliminary path to the
87
94
  // canonical one
88
95
  this.bUpdated = false;
@@ -94,6 +101,10 @@ sap.ui.define([
94
101
  this.oActivatedPromise = bInactive
95
102
  ? new SyncPromise(function (resolve) { that.fnActivate = resolve; })
96
103
  : SyncPromise.resolve();
104
+ // for a transient context, maps navigation property name to (array of)
105
+ // sub-context(s) for deep create
106
+ this.mSubContexts = undefined;
107
+ this.oTransientParent = oTransientParent;
97
108
  }
98
109
  });
99
110
 
@@ -109,6 +120,26 @@ sap.ui.define([
109
120
  }
110
121
  };
111
122
 
123
+ /**
124
+ * Adds the given transient context as sub-context to this transient context under the given
125
+ * navigation property.
126
+ *
127
+ * @param {string} sNavProperty The name of the navigation property
128
+ * @param {sap.ui.model.odata.v2.Context} oSubContext The sub-context to be added
129
+ * @param {boolean} bIsCollection Whether the navigation property is a collection
130
+ *
131
+ * @private
132
+ */
133
+ Context.prototype.addSubContext = function (sNavProperty, oSubContext, bIsCollection) {
134
+ this.mSubContexts = this.mSubContexts || {};
135
+ if (bIsCollection) {
136
+ this.mSubContexts[sNavProperty] = this.mSubContexts[sNavProperty] || [];
137
+ this.mSubContexts[sNavProperty].push(oSubContext);
138
+ } else {
139
+ this.mSubContexts[sNavProperty] = oSubContext;
140
+ }
141
+ };
142
+
112
143
  /**
113
144
  * Returns a promise on the creation state of this context if it has been created via
114
145
  * {@link sap.ui.model.odata.v2.ODataModel#createEntry} or
@@ -244,6 +275,77 @@ sap.ui.define([
244
275
  return this.sDeepPath;
245
276
  };
246
277
 
278
+ /**
279
+ * Gets the map of sub-contexts for a deep create.
280
+ *
281
+ * @returns {Object<string,sap.ui.model.odata.v2.Context|sap.ui.model.odata.v2.Context[]>}
282
+ * The map of sub-contexts
283
+ *
284
+ * @private
285
+ */
286
+ Context.prototype.getSubContexts = function () {
287
+ return this.mSubContexts;
288
+ };
289
+
290
+ /**
291
+ * Gets a flat array of the sub-contexts map for a deep create.
292
+ *
293
+ * @param {boolean} [bRecursive] Whether to recursively collect all deep sub-contexts
294
+ * @returns {sap.ui.model.odata.v2.Context[]} The array of sub-contexts
295
+ *
296
+ * @private
297
+ */
298
+ Context.prototype.getSubContextsArray = function (bRecursive) {
299
+ var sNavProperty, vSubContexts,
300
+ aSubContexts = [];
301
+
302
+ function collectContexts(oSubContext) {
303
+ aSubContexts.push(oSubContext);
304
+ if (bRecursive) {
305
+ aSubContexts = aSubContexts.concat(oSubContext.getSubContextsArray(bRecursive));
306
+ }
307
+ }
308
+
309
+ for (sNavProperty in this.mSubContexts) {
310
+ vSubContexts = this.mSubContexts[sNavProperty];
311
+ if (Array.isArray(vSubContexts)) {
312
+ vSubContexts.forEach(collectContexts);
313
+ } else {
314
+ collectContexts(vSubContexts);
315
+ }
316
+ }
317
+
318
+ return aSubContexts;
319
+ };
320
+
321
+ /**
322
+ * Gets an array of keys to the sub-contexts for a deep create.
323
+ *
324
+ * @param {boolean} [bRecursive] Whether to recursively collect all deep sub-context keys
325
+ * @returns {string[]} The array of sub-context keys
326
+ *
327
+ * @private
328
+ */
329
+ Context.prototype.getSubContextsAsKey = function (bRecursive) {
330
+ return this.getSubContextsArray(bRecursive).map(function (oContext) {
331
+ return oContext.getPath().slice(1);
332
+ });
333
+ };
334
+
335
+ /**
336
+ * Gets an array of paths to the sub-contexts for a deep create.
337
+ *
338
+ * @param {boolean} [bRecursive] Whether to recursively collect all deep sub-context paths
339
+ * @returns {string[]} The array of sub-context paths
340
+ *
341
+ * @private
342
+ */
343
+ Context.prototype.getSubContextsAsPath = function (bRecursive) {
344
+ return this.getSubContextsArray(bRecursive).map(function (oContext) {
345
+ return oContext.getPath();
346
+ });
347
+ };
348
+
247
349
  /**
248
350
  * Whether this context has changed, which means it has been updated or a refresh of dependent
249
351
  * bindings needs to be enforced.
@@ -257,6 +359,28 @@ sap.ui.define([
257
359
  return this.bUpdated || this.bForceRefresh;
258
360
  };
259
361
 
362
+ /**
363
+ * Returns whether this context has at least one sub-context.
364
+ *
365
+ * @return {boolean} Whether this context has at least one sub-context
366
+ *
367
+ * @private
368
+ */
369
+ Context.prototype.hasSubContexts = function () {
370
+ return !!this.mSubContexts;
371
+ };
372
+
373
+ /**
374
+ * Returns whether this context has a transient parent context.
375
+ *
376
+ * @return {boolean} Whether this context has a transient parent context
377
+ *
378
+ * @private
379
+ */
380
+ Context.prototype.hasTransientParent = function () {
381
+ return !!this.oTransientParent;
382
+ };
383
+
260
384
  /**
261
385
  * Returns whether this context is inactive. An inactive context will only be sent to the
262
386
  * server after the first property update. From then on it behaves like any other created
@@ -339,6 +463,47 @@ sap.ui.define([
339
463
  return this.bUpdated;
340
464
  };
341
465
 
466
+ /**
467
+ * Removes this context from its transient parent.
468
+ *
469
+ * @private
470
+ */
471
+ Context.prototype.removeFromTransientParent = function () {
472
+ if (this.oTransientParent) {
473
+ this.oTransientParent.removeSubContext(this);
474
+ delete this.oTransientParent;
475
+ }
476
+ };
477
+
478
+ /**
479
+ * Removes the given sub-context from this context.
480
+ *
481
+ * @param {sap.ui.model.odata.v2.Context} oSubContext The context to remove
482
+ *
483
+ * @private
484
+ */
485
+ Context.prototype.removeSubContext = function (oSubContext) {
486
+ var iIndex, sNavProperty, vSubContexts;
487
+
488
+ for (sNavProperty in this.mSubContexts) {
489
+ vSubContexts = this.mSubContexts[sNavProperty];
490
+ if (Array.isArray(vSubContexts)) {
491
+ iIndex = vSubContexts.indexOf(oSubContext);
492
+ if (iIndex > -1) {
493
+ vSubContexts.splice(iIndex, 1);
494
+ }
495
+ if (!vSubContexts.length) {
496
+ delete this.mSubContexts[sNavProperty];
497
+ }
498
+ } else if (vSubContexts === oSubContext) {
499
+ delete this.mSubContexts[sNavProperty];
500
+ }
501
+ }
502
+ if (this.mSubContexts && !Object.keys(this.mSubContexts).length) {
503
+ this.mSubContexts = undefined;
504
+ }
505
+ };
506
+
342
507
  /**
343
508
  * Resets the created promise to indicate that the entity has been re-read from the back end.
344
509
  *
@@ -36,7 +36,7 @@ sap.ui.define([
36
36
  * @class Annotation loader for OData V2 services
37
37
  *
38
38
  * @author SAP SE
39
- * @version 1.107.1
39
+ * @version 1.108.0
40
40
  *
41
41
  * @public
42
42
  * @since 1.37.0
@@ -294,7 +294,7 @@ sap.ui.define([
294
294
  bKeepCurrent) {
295
295
  var aContexts, aContextData, oSkipAndTop;
296
296
 
297
- if (this.bInitial || this._hasTransientParentContext()) {
297
+ if (this.bInitial) {
298
298
  return [];
299
299
  }
300
300
 
@@ -333,7 +333,9 @@ sap.ui.define([
333
333
  }
334
334
  }
335
335
  aContexts = this._getContexts(iStartIndex, iLength);
336
- if (this.useClientMode()) {
336
+ if (this._hasTransientParentContext()) {
337
+ // skip #loadData
338
+ } else if (this.useClientMode()) {
337
339
  if (!this.aAllKeys && !this.bPendingRequest && this.oModel.getServiceMetadata()) {
338
340
  this.loadData();
339
341
  aContexts.dataRequested = true;
@@ -505,7 +507,8 @@ sap.ui.define([
505
507
  return;
506
508
  }
507
509
  if (Context.hasChanged(this.oContext, oContext)) {
508
- bHadNonTransientContext = this.isResolved() && !this._hasTransientParentContext();
510
+ bHadNonTransientContext = this.isResolved()
511
+ && !this._hasTransientParentWithoutSubContexts();
509
512
  this.oContext = oContext;
510
513
  sResolvedPath = this.getResolvedPath(); // resolved path with the new context
511
514
  this.sDeepPath = this.oModel.resolveDeep(this.sPath, this.oContext);
@@ -514,12 +517,12 @@ sap.ui.define([
514
517
  }
515
518
  // ensure that data state is updated with each change of the context
516
519
  this.checkDataState();
517
- // If path does not resolve or parent context is created, reset current list
518
- if (!sResolvedPath || this._hasTransientParentContext()) {
520
+ if (!sResolvedPath || this._hasTransientParentWithoutSubContexts()) {
519
521
  this.aAllKeys = null;
520
522
  this.aKeys = [];
521
523
  this.iLength = 0;
522
524
  this.bLengthFinal = true;
525
+ this.abortPendingRequest();
523
526
  if (bHadNonTransientContext) {
524
527
  this._fireChange({reason : ChangeReason.Context});
525
528
  }
@@ -1110,7 +1113,7 @@ sap.ui.define([
1110
1113
  var oEntityType, sResolvedPath,
1111
1114
  bChangeDetected = false;
1112
1115
 
1113
- if (this._hasTransientParentContext()) {
1116
+ if (this._hasTransientParentWithoutSubContexts()) {
1114
1117
  return;
1115
1118
  }
1116
1119
  if (!bForceUpdate) {
@@ -1229,7 +1232,7 @@ sap.ui.define([
1229
1232
  */
1230
1233
  ODataListBinding.prototype.initialize = function() {
1231
1234
  if (this.oModel.oMetadata && this.oModel.oMetadata.isLoaded() && this.bInitial
1232
- && !this._hasTransientParentContext()) {
1235
+ && !this._hasTransientParentWithoutSubContexts()) {
1233
1236
  if (!this._checkPathType()) {
1234
1237
  Log.error("List Binding is not bound against a list for " + this.getResolvedPath());
1235
1238
  }
@@ -1878,6 +1881,10 @@ sap.ui.define([
1878
1881
  * Note: This method requires that the model metadata has been loaded; see
1879
1882
  * {@link sap.ui.model.odata.v2.ODataModel#metadataLoaded}.
1880
1883
  *
1884
+ * Since 1.108.0, this method supports deep create, which means it may be called if this
1885
+ * binding's context is transient. The restrictions specified for
1886
+ * {@link sap.ui.model.odata.v2.ODataModel#createEntry} regarding deep create apply.
1887
+ *
1881
1888
  * @param {object} [oInitialData={}]
1882
1889
  * The initial data for the created entity; see the <code>mParameters.properties</code>
1883
1890
  * parameter of {@link sap.ui.model.odata.v2.ODataModel#createEntry}
@@ -1888,8 +1895,9 @@ sap.ui.define([
1888
1895
  * the binding does not necessarily correspond to the order of the resulting back end creation
1889
1896
  * requests.
1890
1897
  * @param {object} mParameters
1891
- * A map of parameters as specified for {@link sap.ui.model.odata.v2.ODataModel#createEntry}
1892
- * where only the following subset of these is supported.
1898
+ * A map of parameters as specified for {@link sap.ui.model.odata.v2.ODataModel#createEntry},
1899
+ * where only the subset given below is supported. In case of deep create, <b>none</b> of the
1900
+ * parameters in <code>mParameters</code> must be set.
1893
1901
  * @param {string} [mParameters.changeSetId]
1894
1902
  * The ID of the <code>ChangeSet</code> that this request should belong to
1895
1903
  * @param {function} [mParameters.error]
@@ -1914,7 +1922,8 @@ sap.ui.define([
1914
1922
  * If
1915
1923
  * <ul>
1916
1924
  * <li>a relative binding is unresolved,</li>
1917
- * <li>the binding's context is transient,</li>
1925
+ * <li>the binding's context is transient and any parameter is set in
1926
+ * <code>mParameters</code>,</li>
1918
1927
  * <li><code>bAtEnd</code> is truthy and the binding's length is not final,</li>
1919
1928
  * <li>the collection data has been read via <code>$expand</code> together with the parent
1920
1929
  * entity,</li>
@@ -1930,8 +1939,7 @@ sap.ui.define([
1930
1939
  var oCreatedContext, oCreatedContextsCache, sResolvedPath,
1931
1940
  mCreateParameters = {
1932
1941
  context : this.oContext,
1933
- properties : oInitialData,
1934
- refreshAfterChange : false
1942
+ properties : oInitialData
1935
1943
  },
1936
1944
  bCreationAreaAtEnd = this.isFirstCreateAtEnd(),
1937
1945
  that = this;
@@ -1948,9 +1956,6 @@ sap.ui.define([
1948
1956
  throw new Error("Parameter '" + sParameterKey + "' is not supported");
1949
1957
  }
1950
1958
  });
1951
- if (this._hasTransientParentContext()) {
1952
- throw new Error("Parent context is transient");
1953
- }
1954
1959
  if (this.bUseExpandedList) {
1955
1960
  throw new Error("The collection has been read via $expand while reading the parent"
1956
1961
  + " entity");
@@ -1962,8 +1967,11 @@ sap.ui.define([
1962
1967
  sResolvedPath = this.getResolvedPath();
1963
1968
  oCreatedContextsCache = this.oModel._getCreatedContextsCache();
1964
1969
  Object.assign(mCreateParameters, mParameters);
1965
- if (!("expand" in mCreateParameters) && this.mParameters) {
1966
- mCreateParameters.expand = this.mParameters.expand;
1970
+ if (!this._hasTransientParentContext()) {
1971
+ mCreateParameters.refreshAfterChange = false;
1972
+ if (!("expand" in mCreateParameters) && this.mParameters) {
1973
+ mCreateParameters.expand = this.mParameters.expand;
1974
+ }
1967
1975
  }
1968
1976
  oCreatedContext = this.oModel.createEntry(this.sPath, mCreateParameters);
1969
1977
  oCreatedContextsCache.addContext(oCreatedContext, sResolvedPath,
@@ -2155,6 +2163,20 @@ sap.ui.define([
2155
2163
  && !!(this.oContext && this.oContext.isTransient && this.oContext.isTransient());
2156
2164
  };
2157
2165
 
2166
+ /**
2167
+ * Returns whether this binding is relative and has a transient parent context which has no
2168
+ * sub-contexts for this binding.
2169
+ *
2170
+ * @returns {boolean}
2171
+ * Whether this binding is relative and has a transient parent context which has no
2172
+ * sub-contexts for this binding
2173
+ *
2174
+ * @private
2175
+ */
2176
+ ODataListBinding.prototype._hasTransientParentWithoutSubContexts = function () {
2177
+ return this._hasTransientParentContext() && !this._getCreatedContexts().length;
2178
+ };
2179
+
2158
2180
  /**
2159
2181
  * Returns whether this list binding uses the expanded list data.
2160
2182
  *