@openui5/sap.ui.core 1.96.5 → 1.99.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 (426) hide show
  1. package/.eslintrc.json +93 -3
  2. package/.reuse/dep5 +26 -31
  3. package/THIRDPARTY.txt +15 -21
  4. package/package.json +1 -1
  5. package/src/jquery.sap.global.js +1 -1
  6. package/src/jquery.sap.mobile.js +29 -19
  7. package/src/jquery.sap.properties.js +1 -1
  8. package/src/jquery.sap.resources.js +2 -2
  9. package/src/jquery.sap.script.js +1 -1
  10. package/src/jquery.sap.storage.js +3 -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 +81 -169
  53. package/src/sap/ui/Global.js +11 -16
  54. package/src/sap/ui/VersionInfo.js +13 -10
  55. package/src/sap/ui/base/BindingParser.js +34 -7
  56. package/src/sap/ui/base/Event.js +1 -1
  57. package/src/sap/ui/base/EventProvider.js +1 -1
  58. package/src/sap/ui/base/Interface.js +1 -1
  59. package/src/sap/ui/base/ManagedObject.js +50 -29
  60. package/src/sap/ui/base/ManagedObjectMetadata.js +1 -1
  61. package/src/sap/ui/base/Metadata.js +1 -3
  62. package/src/sap/ui/base/Object.js +1 -1
  63. package/src/sap/ui/base/ObjectPool.js +1 -1
  64. package/src/sap/ui/core/.library +1 -27
  65. package/src/sap/ui/core/AppCacheBuster.js +4 -4
  66. package/src/sap/ui/core/BusyIndicator.js +1 -1
  67. package/src/sap/ui/core/BusyIndicatorUtils.js +1 -1
  68. package/src/sap/ui/core/Component.js +33 -11
  69. package/src/sap/ui/core/ComponentContainer.js +1 -1
  70. package/src/sap/ui/core/ComponentMetadata.js +1 -1
  71. package/src/sap/ui/core/ComponentSupport.js +1 -1
  72. package/src/sap/ui/core/Configuration.js +79 -13
  73. package/src/sap/ui/core/Control.js +4 -3
  74. package/src/sap/ui/core/Core.js +4 -7
  75. package/src/sap/ui/core/CustomData.js +1 -1
  76. package/src/sap/ui/core/DeclarativeSupport.js +1 -1
  77. package/src/sap/ui/core/Element.js +6 -12
  78. package/src/sap/ui/core/ElementMetadata.js +1 -1
  79. package/src/sap/ui/core/EnabledPropagator.js +1 -1
  80. package/src/sap/ui/core/EventBus.js +1 -1
  81. package/src/sap/ui/core/ExtensionPoint.js +1 -1
  82. package/src/sap/ui/core/FocusHandler.js +1 -1
  83. package/src/sap/ui/core/Fragment.js +1 -1
  84. package/src/sap/ui/core/HTML.js +3 -3
  85. package/src/sap/ui/core/HTMLRenderer.js +1 -1
  86. package/src/sap/ui/core/History.js +1 -1
  87. package/src/sap/ui/core/Icon.js +2 -3
  88. package/src/sap/ui/core/IconRenderer.js +1 -1
  89. package/src/sap/ui/core/IndicationColorSupport.js +1 -1
  90. package/src/sap/ui/core/IntervalTrigger.js +1 -1
  91. package/src/sap/ui/core/InvisibleMessage.js +1 -1
  92. package/src/sap/ui/core/InvisibleRenderer.js +1 -1
  93. package/src/sap/ui/core/InvisibleText.js +1 -1
  94. package/src/sap/ui/core/Item.js +1 -1
  95. package/src/sap/ui/core/LabelEnablement.js +9 -2
  96. package/src/sap/ui/core/LayoutData.js +1 -1
  97. package/src/sap/ui/core/ListItem.js +1 -1
  98. package/src/sap/ui/core/LocalBusyIndicator.js +1 -1
  99. package/src/sap/ui/core/LocalBusyIndicatorRenderer.js +2 -2
  100. package/src/sap/ui/core/LocalBusyIndicatorSupport.js +1 -1
  101. package/src/sap/ui/core/Locale.js +1 -1
  102. package/src/sap/ui/core/LocaleData.js +39 -4
  103. package/src/sap/ui/core/Manifest.js +1 -1
  104. package/src/sap/ui/core/Message.js +1 -1
  105. package/src/sap/ui/core/Placeholder.js +28 -28
  106. package/src/sap/ui/core/Popup.js +3 -3
  107. package/src/sap/ui/core/RenderManager.js +3 -3
  108. package/src/sap/ui/core/Renderer.js +1 -1
  109. package/src/sap/ui/core/ResizeHandler.js +1 -1
  110. package/src/sap/ui/core/ScrollBar.js +4 -3
  111. package/src/sap/ui/core/ScrollBarRenderer.js +1 -1
  112. package/src/sap/ui/core/SeparatorItem.js +1 -1
  113. package/src/sap/ui/core/ThemeCheck.js +2 -2
  114. package/src/sap/ui/core/Title.js +1 -1
  115. package/src/sap/ui/core/TooltipBase.js +2 -2
  116. package/src/sap/ui/core/UIArea.js +3 -3
  117. package/src/sap/ui/core/UIComponent.js +1 -1
  118. package/src/sap/ui/core/UIComponentMetadata.js +1 -1
  119. package/src/sap/ui/core/ValueStateSupport.js +1 -1
  120. package/src/sap/ui/core/VariantLayoutData.js +1 -1
  121. package/src/sap/ui/core/XMLComposite.js +1 -1
  122. package/src/sap/ui/core/XMLCompositeMetadata.js +1 -1
  123. package/src/sap/ui/core/XMLTemplateProcessor.js +26 -5
  124. package/src/sap/ui/core/_IconRegistry.js +10 -1
  125. package/src/sap/ui/core/cache/LRUPersistentCache.js +4 -2
  126. package/src/sap/ui/core/date/Japanese.js +1 -1
  127. package/src/sap/ui/core/date/UniversalDateUtils.js +205 -2
  128. package/src/sap/ui/core/delegate/ItemNavigation.js +1 -1
  129. package/src/sap/ui/core/delegate/ScrollEnablement.js +9 -6
  130. package/src/sap/ui/core/dnd/DragAndDrop.js +2 -2
  131. package/src/sap/ui/core/dnd/DragDropBase.js +1 -1
  132. package/src/sap/ui/core/dnd/DragDropInfo.js +1 -1
  133. package/src/sap/ui/core/dnd/DragInfo.js +1 -1
  134. package/src/sap/ui/core/dnd/DropInfo.js +1 -1
  135. package/src/sap/ui/core/format/DateFormat.js +562 -174
  136. package/src/sap/ui/core/format/DateFormatTimezoneDisplay.js +43 -0
  137. package/src/sap/ui/core/format/ListFormat.js +2 -2
  138. package/src/sap/ui/core/format/NumberFormat.js +1 -1
  139. package/src/sap/ui/core/format/TimezoneUtil.js +248 -0
  140. package/src/sap/ui/core/hyphenation/Hyphenation.js +1 -1
  141. package/src/sap/ui/core/library.js +47 -10
  142. package/src/sap/ui/core/message/ControlMessageProcessor.js +5 -5
  143. package/src/sap/ui/core/message/Message.js +1 -1
  144. package/src/sap/ui/core/message/MessageManager.js +1 -1
  145. package/src/sap/ui/core/message/MessageMixin.js +2 -1
  146. package/src/sap/ui/core/message/MessageParser.js +1 -1
  147. package/src/sap/ui/core/message/MessageProcessor.js +22 -12
  148. package/src/sap/ui/core/messagebundle.properties +4 -0
  149. package/src/sap/ui/core/messagebundle_ar.properties +2 -0
  150. package/src/sap/ui/core/messagebundle_bg.properties +7 -5
  151. package/src/sap/ui/core/messagebundle_ca.properties +2 -0
  152. package/src/sap/ui/core/messagebundle_cs.properties +2 -0
  153. package/src/sap/ui/core/messagebundle_cy.properties +2 -0
  154. package/src/sap/ui/core/messagebundle_da.properties +2 -0
  155. package/src/sap/ui/core/messagebundle_de.properties +3 -1
  156. package/src/sap/ui/core/messagebundle_el.properties +2 -0
  157. package/src/sap/ui/core/messagebundle_en.properties +2 -0
  158. package/src/sap/ui/core/messagebundle_en_GB.properties +2 -0
  159. package/src/sap/ui/core/messagebundle_en_US_sappsd.properties +2 -0
  160. package/src/sap/ui/core/messagebundle_en_US_saprigi.properties +1 -0
  161. package/src/sap/ui/core/messagebundle_en_US_saptrc.properties +2 -0
  162. package/src/sap/ui/core/messagebundle_es.properties +2 -0
  163. package/src/sap/ui/core/messagebundle_es_MX.properties +2 -0
  164. package/src/sap/ui/core/messagebundle_et.properties +2 -0
  165. package/src/sap/ui/core/messagebundle_fi.properties +2 -0
  166. package/src/sap/ui/core/messagebundle_fr.properties +9 -7
  167. package/src/sap/ui/core/messagebundle_fr_CA.properties +2 -0
  168. package/src/sap/ui/core/messagebundle_hi.properties +2 -0
  169. package/src/sap/ui/core/messagebundle_hr.properties +2 -0
  170. package/src/sap/ui/core/messagebundle_hu.properties +2 -0
  171. package/src/sap/ui/core/messagebundle_id.properties +4 -2
  172. package/src/sap/ui/core/messagebundle_it.properties +3 -1
  173. package/src/sap/ui/core/messagebundle_iw.properties +2 -0
  174. package/src/sap/ui/core/messagebundle_ja.properties +2 -0
  175. package/src/sap/ui/core/messagebundle_kk.properties +2 -0
  176. package/src/sap/ui/core/messagebundle_ko.properties +2 -0
  177. package/src/sap/ui/core/messagebundle_lt.properties +2 -0
  178. package/src/sap/ui/core/messagebundle_lv.properties +3 -1
  179. package/src/sap/ui/core/messagebundle_ms.properties +2 -0
  180. package/src/sap/ui/core/messagebundle_nl.properties +2 -0
  181. package/src/sap/ui/core/messagebundle_no.properties +6 -4
  182. package/src/sap/ui/core/messagebundle_pl.properties +2 -0
  183. package/src/sap/ui/core/messagebundle_pt.properties +2 -0
  184. package/src/sap/ui/core/messagebundle_pt_PT.properties +2 -0
  185. package/src/sap/ui/core/messagebundle_ro.properties +2 -0
  186. package/src/sap/ui/core/messagebundle_ru.properties +23 -21
  187. package/src/sap/ui/core/messagebundle_sh.properties +2 -0
  188. package/src/sap/ui/core/messagebundle_sk.properties +2 -0
  189. package/src/sap/ui/core/messagebundle_sl.properties +2 -0
  190. package/src/sap/ui/core/messagebundle_sv.properties +2 -0
  191. package/src/sap/ui/core/messagebundle_th.properties +2 -0
  192. package/src/sap/ui/core/messagebundle_tr.properties +2 -0
  193. package/src/sap/ui/core/messagebundle_uk.properties +2 -0
  194. package/src/sap/ui/core/messagebundle_vi.properties +2 -0
  195. package/src/sap/ui/core/messagebundle_zh_CN.properties +2 -0
  196. package/src/sap/ui/core/messagebundle_zh_TW.properties +2 -0
  197. package/src/sap/ui/core/mvc/Controller.js +4 -4
  198. package/src/sap/ui/core/mvc/HTMLView.js +1 -1
  199. package/src/sap/ui/core/mvc/HTMLViewRenderer.js +1 -1
  200. package/src/sap/ui/core/mvc/JSONView.js +2 -1
  201. package/src/sap/ui/core/mvc/JSONViewRenderer.js +1 -1
  202. package/src/sap/ui/core/mvc/JSView.js +1 -1
  203. package/src/sap/ui/core/mvc/JSViewRenderer.js +1 -1
  204. package/src/sap/ui/core/mvc/TemplateView.js +1 -1
  205. package/src/sap/ui/core/mvc/TemplateViewRenderer.js +1 -1
  206. package/src/sap/ui/core/mvc/View.js +2 -1
  207. package/src/sap/ui/core/mvc/ViewRenderer.js +1 -1
  208. package/src/sap/ui/core/mvc/XMLView.js +16 -3
  209. package/src/sap/ui/core/plugin/DeclarativeSupport.js +1 -1
  210. package/src/sap/ui/core/plugin/LessSupport.js +1 -1
  211. package/src/sap/ui/core/plugin/TemplatingSupport.js +1 -1
  212. package/src/sap/ui/core/postmessage/Bus.js +1 -1
  213. package/src/sap/ui/core/postmessage/confirmationDialog.js +1 -1
  214. package/src/sap/ui/core/routing/Route.js +6 -6
  215. package/src/sap/ui/core/routing/Router.js +4 -3
  216. package/src/sap/ui/core/routing/Targets.js +17 -13
  217. package/src/sap/ui/core/rules/Misc.support.js +51 -1
  218. package/src/sap/ui/core/rules/Model.support.js +95 -8
  219. package/src/sap/ui/core/rules/Rendering.support.js +1 -4
  220. package/src/sap/ui/core/rules/View.support.js +14 -46
  221. package/src/sap/ui/core/search/OpenSearchProvider.js +1 -1
  222. package/src/sap/ui/core/search/SearchProvider.js +1 -1
  223. package/src/sap/ui/core/service/Service.js +1 -1
  224. package/src/sap/ui/core/service/ServiceFactory.js +1 -1
  225. package/src/sap/ui/core/service/ServiceFactoryRegistry.js +1 -1
  226. package/src/sap/ui/core/support/Plugin.js +2 -2
  227. package/src/sap/ui/core/support/RuleEngineOpaExtension.js +0 -1
  228. package/src/sap/ui/core/support/Support.js +1 -1
  229. package/src/sap/ui/core/support/controls/TreeViewer.js +1 -1
  230. package/src/sap/ui/core/support/plugins/ControlTree.js +1 -1
  231. package/src/sap/ui/core/support/plugins/Interaction.js +1 -1
  232. package/src/sap/ui/core/support/plugins/LocalStorage.js +1 -1
  233. package/src/sap/ui/core/support/plugins/Performance.js +1 -2
  234. package/src/sap/ui/core/support/plugins/Selector.js +1 -1
  235. package/src/sap/ui/core/support/plugins/TechInfo.js +1 -1
  236. package/src/sap/ui/core/support/plugins/Trace.js +1 -1
  237. package/src/sap/ui/core/support/plugins/ViewInfo.js +1 -1
  238. package/src/sap/ui/core/support/techinfo/TechnicalInfo.js +2 -6
  239. package/src/sap/ui/core/support/trace/E2eTraceLib.js +3 -3
  240. package/src/sap/ui/core/themes/base/fonts/SAP-icons.woff2 +0 -0
  241. package/src/sap/ui/core/tmpl/DOMAttribute.js +1 -1
  242. package/src/sap/ui/core/tmpl/DOMElement.js +1 -1
  243. package/src/sap/ui/core/tmpl/HandlebarsTemplate.js +1 -1
  244. package/src/sap/ui/core/tmpl/Template.js +1 -1
  245. package/src/sap/ui/core/tmpl/TemplateControl.js +1 -1
  246. package/src/sap/ui/core/util/AsyncHintsHelper.js +1 -1
  247. package/src/sap/ui/core/util/DraftEnabledMockServer.js +21 -16
  248. package/src/sap/ui/core/util/Export.js +1 -1
  249. package/src/sap/ui/core/util/ExportCell.js +1 -1
  250. package/src/sap/ui/core/util/ExportColumn.js +1 -1
  251. package/src/sap/ui/core/util/ExportRow.js +1 -1
  252. package/src/sap/ui/core/util/ExportType.js +1 -1
  253. package/src/sap/ui/core/util/ExportTypeCSV.js +1 -1
  254. package/src/sap/ui/core/util/File.js +1 -1
  255. package/src/sap/ui/core/util/LibraryInfo.js +1 -1
  256. package/src/sap/ui/core/util/MockServer.js +157 -58
  257. package/src/sap/ui/core/util/PasteHelper.js +4 -4
  258. package/src/sap/ui/core/util/XMLPreprocessor.js +16 -4
  259. package/src/sap/ui/core/util/reflection/XmlTreeModifier.js +1 -1
  260. package/src/sap/ui/core/util/serializer/HTMLViewSerializer.js +1 -1
  261. package/src/sap/ui/core/util/serializer/Serializer.js +1 -1
  262. package/src/sap/ui/core/util/serializer/ViewSerializer.js +1 -1
  263. package/src/sap/ui/core/util/serializer/XMLViewSerializer.js +1 -1
  264. package/src/sap/ui/core/util/serializer/delegate/Delegate.js +1 -1
  265. package/src/sap/ui/core/util/serializer/delegate/HTML.js +1 -1
  266. package/src/sap/ui/core/util/serializer/delegate/XML.js +1 -1
  267. package/src/sap/ui/core/ws/ReadyState.js +1 -1
  268. package/src/sap/ui/core/ws/SapPcpWebSocket.js +1 -1
  269. package/src/sap/ui/core/ws/WebSocket.js +1 -1
  270. package/src/sap/ui/debug/ControlTree.js +1 -1
  271. package/src/sap/ui/debug/DebugEnv.js +1 -1
  272. package/src/sap/ui/debug/PropertyList.js +1 -1
  273. package/src/sap/ui/dom/includeStylesheet.js +8 -3
  274. package/src/sap/ui/events/jquery/EventExtension.js +1 -1
  275. package/src/sap/ui/events/jquery/EventSimulation.js +3 -13
  276. package/src/sap/ui/model/Binding.js +4 -3
  277. package/src/sap/ui/model/ChangeReason.js +1 -1
  278. package/src/sap/ui/model/ClientListBinding.js +7 -0
  279. package/src/sap/ui/model/ClientModel.js +6 -5
  280. package/src/sap/ui/model/ClientTreeBinding.js +1 -1
  281. package/src/sap/ui/model/ClientTreeBindingAdapter.js +1 -1
  282. package/src/sap/ui/model/CompositeBinding.js +1 -1
  283. package/src/sap/ui/model/CompositeDataState.js +26 -4
  284. package/src/sap/ui/model/CompositeType.js +1 -1
  285. package/src/sap/ui/model/ContextBinding.js +1 -1
  286. package/src/sap/ui/model/DataState.js +27 -6
  287. package/src/sap/ui/model/ListBinding.js +24 -5
  288. package/src/sap/ui/model/MetaModel.js +2 -3
  289. package/src/sap/ui/model/Model.js +6 -11
  290. package/src/sap/ui/model/SelectionModel.js +1 -1
  291. package/src/sap/ui/model/SimpleType.js +1 -1
  292. package/src/sap/ui/model/TreeAutoExpandMode.js +1 -1
  293. package/src/sap/ui/model/TreeBindingAdapter.js +0 -2
  294. package/src/sap/ui/model/TreeBindingUtils.js +2 -0
  295. package/src/sap/ui/model/Type.js +1 -1
  296. package/src/sap/ui/model/analytics/AnalyticalBinding.js +13 -8
  297. package/src/sap/ui/model/analytics/AnalyticalTreeBindingAdapter.js +16 -18
  298. package/src/sap/ui/model/analytics/ODataModelAdapter.js +2 -15
  299. package/src/sap/ui/model/base/ManagedObjectModel.js +1 -1
  300. package/src/sap/ui/model/json/JSONListBinding.js +1 -1
  301. package/src/sap/ui/model/json/JSONModel.js +7 -7
  302. package/src/sap/ui/model/json/JSONPropertyBinding.js +2 -2
  303. package/src/sap/ui/model/message/MessageListBinding.js +1 -1
  304. package/src/sap/ui/model/message/MessageModel.js +3 -3
  305. package/src/sap/ui/model/message/MessagePropertyBinding.js +2 -2
  306. package/src/sap/ui/model/odata/AnnotationHelper.js +2 -2
  307. package/src/sap/ui/model/odata/AnnotationParser.js +4 -2
  308. package/src/sap/ui/model/odata/ODataAnnotations.js +1 -1
  309. package/src/sap/ui/model/odata/ODataListBinding.js +62 -39
  310. package/src/sap/ui/model/odata/ODataMessageParser.js +2 -2
  311. package/src/sap/ui/model/odata/ODataMetaModel.js +3 -3
  312. package/src/sap/ui/model/odata/ODataMetadata.js +138 -87
  313. package/src/sap/ui/model/odata/ODataModel.js +443 -216
  314. package/src/sap/ui/model/odata/ODataPropertyBinding.js +7 -5
  315. package/src/sap/ui/model/odata/ODataTreeBinding.js +1 -1
  316. package/src/sap/ui/model/odata/ODataTreeBindingAdapter.js +27 -17
  317. package/src/sap/ui/model/odata/ODataTreeBindingFlat.js +440 -260
  318. package/src/sap/ui/model/odata/ODataUtils.js +24 -9
  319. package/src/sap/ui/model/odata/_AnnotationHelperBasics.js +3 -2
  320. package/src/sap/ui/model/odata/_AnnotationHelperExpression.js +11 -9
  321. package/src/sap/ui/model/odata/_ODataMetaModelUtils.js +7 -5
  322. package/src/sap/ui/model/odata/type/Boolean.js +1 -1
  323. package/src/sap/ui/model/odata/type/Byte.js +1 -1
  324. package/src/sap/ui/model/odata/type/Currency.js +1 -1
  325. package/src/sap/ui/model/odata/type/Date.js +1 -1
  326. package/src/sap/ui/model/odata/type/DateTime.js +1 -1
  327. package/src/sap/ui/model/odata/type/DateTimeBase.js +1 -1
  328. package/src/sap/ui/model/odata/type/DateTimeOffset.js +1 -1
  329. package/src/sap/ui/model/odata/type/DateTimeWithTimezone.js +338 -0
  330. package/src/sap/ui/model/odata/type/Decimal.js +5 -1
  331. package/src/sap/ui/model/odata/type/Double.js +1 -1
  332. package/src/sap/ui/model/odata/type/Guid.js +1 -1
  333. package/src/sap/ui/model/odata/type/Int.js +1 -1
  334. package/src/sap/ui/model/odata/type/Int16.js +1 -1
  335. package/src/sap/ui/model/odata/type/Int32.js +1 -1
  336. package/src/sap/ui/model/odata/type/Int64.js +1 -1
  337. package/src/sap/ui/model/odata/type/ODataType.js +1 -1
  338. package/src/sap/ui/model/odata/type/Raw.js +1 -1
  339. package/src/sap/ui/model/odata/type/SByte.js +1 -1
  340. package/src/sap/ui/model/odata/type/Single.js +1 -1
  341. package/src/sap/ui/model/odata/type/Stream.js +1 -1
  342. package/src/sap/ui/model/odata/type/String.js +1 -1
  343. package/src/sap/ui/model/odata/type/Time.js +1 -1
  344. package/src/sap/ui/model/odata/type/TimeOfDay.js +1 -1
  345. package/src/sap/ui/model/odata/type/Unit.js +1 -1
  346. package/src/sap/ui/model/odata/type/UnitMixin.js +1 -2
  347. package/src/sap/ui/model/odata/v2/Context.js +98 -14
  348. package/src/sap/ui/model/odata/v2/ODataAnnotations.js +1 -1
  349. package/src/sap/ui/model/odata/v2/ODataContextBinding.js +8 -4
  350. package/src/sap/ui/model/odata/v2/ODataListBinding.js +418 -172
  351. package/src/sap/ui/model/odata/v2/ODataModel.js +242 -138
  352. package/src/sap/ui/model/odata/v2/ODataTreeBinding.js +164 -92
  353. package/src/sap/ui/model/odata/v2/_CreatedContextsCache.js +117 -7
  354. package/src/sap/ui/model/odata/v4/AnnotationHelper.js +21 -22
  355. package/src/sap/ui/model/odata/v4/Context.js +249 -83
  356. package/src/sap/ui/model/odata/v4/ODataBinding.js +100 -43
  357. package/src/sap/ui/model/odata/v4/ODataContextBinding.js +309 -228
  358. package/src/sap/ui/model/odata/v4/ODataListBinding.js +573 -278
  359. package/src/sap/ui/model/odata/v4/ODataMetaModel.js +131 -100
  360. package/src/sap/ui/model/odata/v4/ODataModel.js +342 -259
  361. package/src/sap/ui/model/odata/v4/ODataParentBinding.js +113 -100
  362. package/src/sap/ui/model/odata/v4/ODataPropertyBinding.js +87 -81
  363. package/src/sap/ui/model/odata/v4/ODataUtils.js +5 -5
  364. package/src/sap/ui/model/odata/v4/SubmitMode.js +0 -1
  365. package/src/sap/ui/model/odata/v4/ValueListType.js +0 -1
  366. package/src/sap/ui/model/odata/v4/_AnnotationHelperExpression.js +20 -20
  367. package/src/sap/ui/model/odata/v4/lib/_AggregationCache.js +3 -5
  368. package/src/sap/ui/model/odata/v4/lib/_AggregationHelper.js +5 -4
  369. package/src/sap/ui/model/odata/v4/lib/_Batch.js +21 -20
  370. package/src/sap/ui/model/odata/v4/lib/_Cache.js +278 -103
  371. package/src/sap/ui/model/odata/v4/lib/_GroupLock.js +1 -1
  372. package/src/sap/ui/model/odata/v4/lib/_Helper.js +55 -21
  373. package/src/sap/ui/model/odata/v4/lib/_MetadataConverter.js +62 -61
  374. package/src/sap/ui/model/odata/v4/lib/_MetadataRequestor.js +1 -1
  375. package/src/sap/ui/model/odata/v4/lib/_Parser.js +52 -43
  376. package/src/sap/ui/model/odata/v4/lib/_Requestor.js +61 -41
  377. package/src/sap/ui/model/odata/v4/lib/_V2MetadataConverter.js +147 -147
  378. package/src/sap/ui/model/odata/v4/lib/_V2Requestor.js +14 -13
  379. package/src/sap/ui/model/odata/v4/lib/_V4MetadataConverter.js +66 -67
  380. package/src/sap/ui/model/resource/ResourceModel.js +1 -1
  381. package/src/sap/ui/model/resource/ResourcePropertyBinding.js +1 -1
  382. package/src/sap/ui/model/type/Boolean.js +1 -1
  383. package/src/sap/ui/model/type/Currency.js +1 -1
  384. package/src/sap/ui/model/type/Date.js +1 -1
  385. package/src/sap/ui/model/type/DateInterval.js +1 -1
  386. package/src/sap/ui/model/type/DateTime.js +1 -1
  387. package/src/sap/ui/model/type/DateTimeInterval.js +1 -1
  388. package/src/sap/ui/model/type/FileSize.js +1 -1
  389. package/src/sap/ui/model/type/Float.js +1 -1
  390. package/src/sap/ui/model/type/Integer.js +1 -1
  391. package/src/sap/ui/model/type/String.js +1 -1
  392. package/src/sap/ui/model/type/Time.js +1 -1
  393. package/src/sap/ui/model/type/TimeInterval.js +1 -1
  394. package/src/sap/ui/model/type/Unit.js +1 -1
  395. package/src/sap/ui/model/xml/XMLListBinding.js +1 -1
  396. package/src/sap/ui/model/xml/XMLModel.js +5 -5
  397. package/src/sap/ui/model/xml/XMLPropertyBinding.js +2 -2
  398. package/src/sap/ui/performance/trace/Passport.js +3 -3
  399. package/src/sap/ui/qunit/utils/ControlIterator.js +1 -1
  400. package/src/sap/ui/qunit/utils/MemoryLeakCheck.js +1 -1
  401. package/src/sap/ui/test/BlanketReporter.js +1 -1
  402. package/src/sap/ui/test/Opa5.js +1 -1
  403. package/src/sap/ui/test/TestUtils.js +2 -2
  404. package/src/sap/ui/test/_LogCollector.js +1 -1
  405. package/src/sap/ui/test/actions/Action.js +11 -2
  406. package/src/sap/ui/test/actions/Press.js +79 -3
  407. package/src/sap/ui/test/autowaiter/_XHRWaiter.js +1 -1
  408. package/src/sap/ui/test/generic/_EnforceSemanticRendering.js +111 -0
  409. package/src/sap/ui/test/starter/createSuite.js +1 -2
  410. package/src/sap/ui/thirdparty/jquery-mobile-custom.js +3 -6
  411. package/src/sap/ui/thirdparty/jqueryui/jquery-ui-datepicker.js +143 -3
  412. package/src/sap/ui/thirdparty/jqueryui/jquery-ui-position.js +8 -1
  413. package/src/sap/ui/util/Mobile.js +28 -39
  414. package/src/sap/ui/util/Storage.js +1 -1
  415. package/src/sap/ui/util/XMLHelper.js +53 -30
  416. package/src/ui5loader.js +9 -9
  417. package/ui5.yaml +244 -1
  418. package/src/sap/ui/core/CustomizingConfiguration.js +0 -47
  419. package/src/sap/ui/thirdparty/baseuri.js +0 -1
  420. package/src/sap/ui/thirdparty/es6-object-assign.js +0 -1
  421. package/src/sap/ui/thirdparty/es6-promise.js +0 -1
  422. package/src/sap/ui/thirdparty/es6-shim-nopromise.js +0 -1
  423. package/src/sap/ui/thirdparty/es6-string-methods.js +0 -1
  424. package/src/sap/ui/thirdparty/flexie.js +0 -1
  425. package/src/sap/ui/thirdparty/unorm.js +0 -1
  426. package/src/sap/ui/thirdparty/unormdata.js +0 -1
@@ -73,7 +73,7 @@ sap.ui.define([
73
73
  ODataUtils.createSortParams = function(aSorters) {
74
74
  var sSortParam;
75
75
  if (!aSorters || aSorters.length == 0) {
76
- return;
76
+ return undefined;
77
77
  }
78
78
  sSortParam = "$orderby=";
79
79
  for (var i = 0; i < aSorters.length; i++) {
@@ -122,7 +122,7 @@ sap.ui.define([
122
122
  }
123
123
 
124
124
  if (!oFilter) {
125
- return;
125
+ return undefined;
126
126
  }
127
127
  return "$filter=" + this._createFilterParams(oFilter, oMetadata, oEntityType);
128
128
  };
@@ -180,18 +180,20 @@ sap.ui.define([
180
180
  }
181
181
 
182
182
  if (!oFilter) {
183
- return;
183
+ return undefined;
184
184
  }
185
185
 
186
186
  return create(oFilter, true);
187
187
  };
188
188
 
189
189
  /**
190
- * Converts a string or object-map with URL Parameters into an array.
191
- * If vParams is an object map, it will be also encoded properly.
190
+ * Converts a string or object-map with URL parameters into an array.
191
+ * If <code>vParams</code> is an object map, it will be also encoded properly.
192
+ *
193
+ * @param {string|object|array} vParams URL parameters
194
+ * @returns {string[]} Encoded URL parameters
192
195
  *
193
196
  * @private
194
- * @param {string|object|array} vParams parameters
195
197
  */
196
198
  ODataUtils._createUrlParamsArray = function(vParams) {
197
199
  var aUrlParams, sType = typeof vParams, sParams;
@@ -387,7 +389,12 @@ sap.ui.define([
387
389
 
388
390
 
389
391
  /**
390
- * convert multi filter to filter string
392
+ * Convert multi filter to filter string.
393
+ *
394
+ * @param {object} oMultiFilter A multi filter
395
+ * @param {sap.ui.model.odata.ODataMetadata} oMetadata The metadata
396
+ * @param {object} oEntityType The entity type to filter
397
+ * @returns {string} A filter string
391
398
  *
392
399
  * @private
393
400
  */
@@ -419,7 +426,16 @@ sap.ui.define([
419
426
  };
420
427
 
421
428
  /**
422
- * Create a single filter segment of the OData filter parameters
429
+ * Create a single filter segment of the OData filter parameters.
430
+ *
431
+ * @param {string} sPath The path to the value
432
+ * @param {sap.ui.model.odata.ODataMetadata} oMetadata The metadata
433
+ * @param {object} oEntityType The value's entity type
434
+ * @param {string} sOperator The filter operator
435
+ * @param {object} oValue1 The first value
436
+ * @param {object} oValue2 The second value
437
+ * @param {boolean} [bCaseSensitive=true] Whether the case should be considered
438
+ * @returns {string} The encoded string representation of the given filter
423
439
  *
424
440
  * @private
425
441
  */
@@ -455,7 +471,6 @@ sap.ui.define([
455
471
  sPath = "toupper(" + sPath + ")";
456
472
  }
457
473
 
458
- // TODO embed 2nd value
459
474
  switch (sOperator) {
460
475
  case "EQ":
461
476
  case "NE":
@@ -419,7 +419,8 @@ sap.ui.define([
419
419
  case "expression":
420
420
  return bExpression ? vValue : "{=" + vValue + "}";
421
421
 
422
- // no default
422
+ default:
423
+ return undefined;
423
424
  }
424
425
  },
425
426
 
@@ -499,4 +500,4 @@ sap.ui.define([
499
500
 
500
501
  return Basics;
501
502
 
502
- }, /* bExport= */ false);
503
+ });
@@ -187,11 +187,11 @@ sap.ui.define([
187
187
  * Handling of "14.5.3 Expression edm:Apply".
188
188
  *
189
189
  * @param {sap.ui.core.util.XMLPreprocessor.IContext|sap.ui.model.Context} oInterface
190
- * the callback interface related to the current formatter call
190
+ * The callback interface related to the current formatter call
191
191
  * @param {object} oPathValue
192
- * path and value information pointing to the apply (see Expression object)
193
- * @returns {object}
194
- * the result object
192
+ * Path and value information pointing to the apply (see Expression object)
193
+ * @returns {object|undefined}
194
+ * The result object or <code>undefined</code> in error cases
195
195
  */
196
196
  apply : function (oInterface, oPathValue) {
197
197
  var oName = Basics.descend(oPathValue, "Name", "string"),
@@ -206,6 +206,7 @@ sap.ui.define([
206
206
  return Expression.uriEncode(oInterface, oParameters);
207
207
  default:
208
208
  Basics.error(oName, "unknown function: " + oName.value);
209
+ return undefined;
209
210
  }
210
211
  },
211
212
 
@@ -360,11 +361,11 @@ sap.ui.define([
360
361
  * Calculates an expression.
361
362
  *
362
363
  * @param {sap.ui.core.util.XMLPreprocessor.IContext|sap.ui.model.Context} oInterface
363
- * the callback interface related to the current formatter call
364
+ * The callback interface related to the current formatter call
364
365
  * @param {object} oPathValue
365
- * path and value information pointing to the parameters array (see Expression object)
366
- * @returns {object}
367
- * the result object
366
+ * Path and value information pointing to the parameters array (see Expression object)
367
+ * @returns {object|undefined}
368
+ * The result object or <code>undefined</code> in error cases
368
369
  */
369
370
  expression : function (oInterface, oPathValue) {
370
371
  var oRawValue = oPathValue.value,
@@ -428,6 +429,7 @@ sap.ui.define([
428
429
  };
429
430
  default:
430
431
  Basics.error(oPathValue, "Unsupported OData expression");
432
+ return undefined;
431
433
  }
432
434
  },
433
435
 
@@ -945,4 +947,4 @@ sap.ui.define([
945
947
  Expression._setDateTimeFormatter();
946
948
 
947
949
  return Expression;
948
- }, /* bExport= */ false);
950
+ });
@@ -702,11 +702,12 @@ sap.ui.define([
702
702
  if (oSchema) {
703
703
  aArray = oSchema[sArrayName];
704
704
  if (aArray) {
705
- aArray.forEach(function (oThing) {
705
+ aArray.some(function (oThing) {
706
706
  if (oThing.name === sName) {
707
707
  vResult = bAsPath ? oThing.$path : oThing;
708
- return false; // break
708
+ return true;
709
709
  }
710
+ return false;
710
711
  });
711
712
  }
712
713
  }
@@ -731,11 +732,12 @@ sap.ui.define([
731
732
  : vModel.getObject("/dataServices/schema");
732
733
 
733
734
  if (aSchemas) {
734
- aSchemas.forEach(function (o) {
735
+ aSchemas.some(function (o) {
735
736
  if (o.namespace === sNamespace) {
736
737
  oSchema = o;
737
- return false; // break
738
+ return true;
738
739
  }
740
+ return false;
739
741
  });
740
742
  }
741
743
 
@@ -1144,4 +1146,4 @@ sap.ui.define([
1144
1146
  };
1145
1147
 
1146
1148
  return Utils;
1147
- }, /* bExport= */ false);
1149
+ });
@@ -87,7 +87,7 @@ sap.ui.define([
87
87
  * @extends sap.ui.model.odata.type.ODataType
88
88
  *
89
89
  * @author SAP SE
90
- * @version 1.96.5
90
+ * @version 1.99.0
91
91
  *
92
92
  * @alias sap.ui.model.odata.type.Boolean
93
93
  * @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.96.5
27
+ * @version 1.99.0
28
28
  *
29
29
  * @alias sap.ui.model.odata.type.Byte
30
30
  * @param {object} [oFormatOptions]
@@ -61,7 +61,7 @@ sap.ui.define([
61
61
  * @extends sap.ui.model.type.Currency
62
62
  * @public
63
63
  * @since 1.63.0
64
- * @version 1.96.5
64
+ * @version 1.99.0
65
65
  */
66
66
  var Currency = BaseCurrency.extend("sap.ui.model.odata.type.Currency", {
67
67
  constructor : function (oFormatOptions, oConstraints) {
@@ -106,7 +106,7 @@ sap.ui.define([
106
106
  * @extends sap.ui.model.odata.type.ODataType
107
107
  *
108
108
  * @author SAP SE
109
- * @version 1.96.5
109
+ * @version 1.99.0
110
110
  *
111
111
  * @alias sap.ui.model.odata.type.Date
112
112
  * @param {object} [oFormatOptions]
@@ -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.96.5
62
+ * @version 1.99.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.96.5
135
+ * @version 1.99.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.96.5
31
+ * @version 1.99.0
32
32
  *
33
33
  * @alias sap.ui.model.odata.type.DateTimeOffset
34
34
  * @param {object} [oFormatOptions]
@@ -0,0 +1,338 @@
1
+ /*!
2
+ * OpenUI5
3
+ * (c) Copyright 2009-2022 SAP SE or an SAP affiliate company.
4
+ * Licensed under the Apache License, Version 2.0 - see LICENSE.txt.
5
+ */
6
+
7
+ sap.ui.define([
8
+ "sap/ui/core/format/DateFormat",
9
+ "sap/ui/core/format/DateFormatTimezoneDisplay",
10
+ "sap/ui/model/CompositeType",
11
+ "sap/ui/model/FormatException",
12
+ "sap/ui/model/ParseException"
13
+ ], function (DateFormat, DateFormatTimezoneDisplay, CompositeType, FormatException,
14
+ ParseException) {
15
+ "use strict";
16
+
17
+ var oDemoDateTime = new Date(Date.UTC(new Date().getFullYear(), 11, 31, 23, 59, 58)),
18
+ sObjectRequiresHide = "Type 'object' requires format option 'showTimezone' set to "
19
+ + "sap.ui.core.format.DateFormatTimezoneDisplay.Hide";
20
+
21
+ /*
22
+ * Returns the formatter. Creates it lazily.
23
+ *
24
+ * @param {sap.ui.model.odata.type.DateTimeWithTimezone} oType
25
+ * The type instance
26
+ * @returns {sap.ui.core.format.DateFormat}
27
+ * The formatter
28
+ */
29
+ function getFormatter(oType) {
30
+ if (!oType.oFormat) {
31
+ oType.oFormat = DateFormat.getDateTimeWithTimezoneInstance(oType.oFormatOptions);
32
+ }
33
+ return oType.oFormat;
34
+ }
35
+
36
+ /**
37
+ * Constructor for a <code>DateTimeWithTimezone</code> composite type.
38
+ *
39
+ * @param {object} [oFormatOptions]
40
+ * Format options. For a list of all available options, see
41
+ * {@link sap.ui.core.format.DateFormat.getDateTimeWithTimezoneInstance DateFormat}.
42
+ * Format options are immutable, that is, they can only be set once on construction.
43
+ * @param {object} [oConstraints]
44
+ * Constraints are not supported
45
+ * @throws {Error}
46
+ * If constraints are given
47
+ *
48
+ * @alias sap.ui.model.odata.type.DateTimeWithTimezone
49
+ * @author SAP SE
50
+ * @class This class represents the <code>DateTimeWithTimezone</code> composite type which has
51
+ * the parts timestamp and time zone. The type formats the timestamp part using the time zone
52
+ * part. For this, the timestamp part has to be provided in the UTC time zone.
53
+ * @extends sap.ui.model.CompositeType
54
+ * @public
55
+ * @since 1.99.0
56
+ * @experimental The behavior of this type may change in the future.
57
+ * @version 1.99.0
58
+ */
59
+ var DateTimeWithTimezone = CompositeType.extend("sap.ui.model.odata.type.DateTimeWithTimezone",
60
+ {
61
+ constructor : function (oFormatOptions, oConstraints) {
62
+ if (oConstraints && Object.keys(oConstraints).length) {
63
+ throw new Error("Type " + this.getName() + " does not support constraints");
64
+ }
65
+ oFormatOptions = Object.assign({}, oFormatOptions);
66
+ CompositeType.call(this, oFormatOptions);
67
+ this.oFormat = null;
68
+ this.bParseWithValues = true;
69
+ this.bUseInternalValues = true;
70
+
71
+ // must not overwrite setConstraints and setFormatOptions on prototype as they are
72
+ // called in SimpleType constructor
73
+ this.setConstraints = function () {
74
+ throw new Error("Constraints are immutable");
75
+ };
76
+ this.setFormatOptions = function () {
77
+ throw new Error("Format options are immutable");
78
+ };
79
+ }
80
+ });
81
+
82
+ /*
83
+ * Returns the locale-dependent error message corresponding to the type's format option
84
+ * <code>showTimezone</code>.
85
+ *
86
+ * @returns {string}
87
+ * The locale-dependent error message
88
+ *
89
+ * @private
90
+ */
91
+ DateTimeWithTimezone.prototype._getErrorMessage = function () {
92
+ var sMessageKey = this.oFormatOptions.showTimezone === DateFormatTimezoneDisplay.Only
93
+ ? "EnterDateTimeTimezone"
94
+ : "EnterDateTime";
95
+
96
+ return sap.ui.getCore().getLibraryResourceBundle()
97
+ .getText(sMessageKey, [this.formatValue([oDemoDateTime, "America/New_York"],
98
+ "string")]);
99
+ };
100
+
101
+ /**
102
+ * Formats the given values of the parts of the <code>DateTimeWithTimezone</code> composite type
103
+ * to the given target type.
104
+ *
105
+ * @param {array} aValues
106
+ * The array of the part values to be formatted; the first entry has to be a <code>Date</code>
107
+ * object for the timestamp, and the second entry has to be a string representing a time zone
108
+ * ID
109
+ * @param {string} sTargetType
110
+ * The target type, must be "object", "string", or a type with one of these types as its
111
+ * {@link sap.ui.base.DataType#getPrimitiveType primitive type}; see
112
+ * {@link sap.ui.model.odata.type} for more information
113
+ * @returns {any}
114
+ * The formatted output value; <code>null</code>,
115
+ * <ul>
116
+ * <li>if <code>aValues</code> is not set, or</li>
117
+ * <li>if the time zone in <code>aValues</code> is not set, or</li>
118
+ * <li>if the timestamp in <code>aValues</code> is not set and the <code>showTimezone</code>
119
+ * format option is set to <code>sap.ui.core.format.DateFormatTimezoneDisplay.Hide</code>
120
+ * </li>
121
+ * </ul>
122
+ * @throws {sap.ui.model.FormatException}
123
+ * If
124
+ * <ul>
125
+ * <li><code>sTargetType</code> is unsupported,</li>
126
+ * <li>a timestamp is given in <code>aValues</code> that is not an instance of
127
+ * <code>Date</code>,</li>
128
+ * <li>the <code>sTargetType</code> is "object" or an equivalent primitive type, and the
129
+ * <code>showTimezone</code> format option is not
130
+ * <code>sap.ui.core.format.DateFormatTimezoneDisplay.Hide</code></li>
131
+ * </ul>
132
+ * @public
133
+ */
134
+ DateTimeWithTimezone.prototype.formatValue = function (aValues, sTargetType) {
135
+ var sShowTimezone = this.oFormatOptions.showTimezone,
136
+ oTimestamp = aValues && aValues[0],
137
+ sTimezone = aValues && aValues[1];
138
+
139
+ if (!aValues
140
+ || !sTimezone // time zone is mandatory
141
+ || oTimestamp === undefined // data is not yet available (OData V4)
142
+ // if time zone is not shown falsy timestamps cannot be formatted -> return null
143
+ || (!oTimestamp && sShowTimezone === DateFormatTimezoneDisplay.Hide)) {
144
+ return null;
145
+ }
146
+
147
+ if (oTimestamp && !(oTimestamp instanceof Date)) {
148
+ throw new FormatException("Timestamp value for " + this.getName()
149
+ + " is not an instance of Date: " + oTimestamp);
150
+ }
151
+
152
+ switch (this.getPrimitiveType(sTargetType)) {
153
+ case "object":
154
+ if (sShowTimezone !== DateFormatTimezoneDisplay.Hide) {
155
+ throw new FormatException(sObjectRequiresHide);
156
+ }
157
+
158
+ return oTimestamp;
159
+ case "string":
160
+ return getFormatter(this).format(oTimestamp, sTimezone);
161
+ default:
162
+ throw new FormatException("Don't know how to format " + this.getName() + " to "
163
+ + sTargetType);
164
+ }
165
+ };
166
+
167
+ /**
168
+ * Returns the type's name.
169
+ *
170
+ * @returns {string}
171
+ * The type's name
172
+ *
173
+ * @public
174
+ */
175
+ DateTimeWithTimezone.prototype.getName = function () {
176
+ return "sap.ui.model.odata.type.DateTimeWithTimezone";
177
+ };
178
+
179
+
180
+ /**
181
+ * Gets an array of indices that determine which parts of this type shall not propagate their
182
+ * model messages to the attached control. Prerequisite is that the corresponding binding
183
+ * supports this feature, see {@link sap.ui.model.Binding#supportsIgnoreMessages}. If the
184
+ * <code>showTimezone</code> format option is set to
185
+ * <code>sap.ui.core.format.DateFormatTimezoneDisplay.Hide</code> and the time zone is not shown
186
+ * in the control, the part for the time zone shall not propagate model messages to the control.
187
+ * Analogously, if the format option <code>showTimezone</code> is set to
188
+ * <code>sap.ui.core.format.DateFormatTimezoneDisplay.Only</code>, the date and time are not
189
+ * shown in the control and the parts for the date and time shall not propagate model messages
190
+ * to the control.
191
+ *
192
+ * @return {number[]}
193
+ * An array of indices that determine which parts of this type shall not propagate their
194
+ * model messages to the attached control
195
+ *
196
+ * @public
197
+ * @see sap.ui.model.Binding#supportsIgnoreMessages
198
+ */
199
+ // @override sap.ui.model.CompositeType#getPartsIgnoringMessages
200
+ DateTimeWithTimezone.prototype.getPartsIgnoringMessages = function () {
201
+ var sShowTimezone = this.oFormatOptions.showTimezone;
202
+
203
+ if (sShowTimezone === DateFormatTimezoneDisplay.Only) {
204
+ return [0];
205
+ } else if (sShowTimezone === DateFormatTimezoneDisplay.Hide) {
206
+ return [1];
207
+ }
208
+
209
+ return [];
210
+ };
211
+
212
+ /**
213
+ * Parses the given value.
214
+ *
215
+ * @param {string|Date} vValue
216
+ * The value to be parsed
217
+ * @param {string} sSourceType
218
+ * The source type (the expected type of <code>vValue</code>); must be "object", "string", or
219
+ * a type with one of these types as its
220
+ * {@link sap.ui.base.DataType#getPrimitiveType primitive type}; see
221
+ * {@link sap.ui.model.odata.type} for more information
222
+ * @param {any[]} [aCurrentValues]
223
+ * The array of current part values; the first entry has to be a <code>Date</code> object for
224
+ * the timestamp, and the second entry has to be a string representing a time zone ID;
225
+ * <b>Note:</b> This parameter is required, see definition of this parameter in
226
+ * {@link sap.ui.model.CompositeType#parseValue}
227
+ * @returns {any[]}
228
+ * An array with two entries; the first one is a <code>Date</code> object for the timestamp
229
+ * and the second one is a string representing a time zone ID; if a part is hidden via the
230
+ * format option <code>showTimezone</code>, the corresponding entry in the array is set to
231
+ * <code>undefined</code>
232
+ * @throws {sap.ui.model.ParseException}
233
+ * If
234
+ * <ul>
235
+ * <li><code>sSourceType</code> is unsupported,</li>
236
+ * <li>the value is not parsable,</li>
237
+ * <li>the <code>showTimezone</code> format option is
238
+ * <code>sap.ui.core.format.DateFormatTimezoneDisplay.Only</code> but no value is given,
239
+ * </li>
240
+ * <li><code>aCurrentValues</code> is not given,</li>
241
+ * <li>the <code>sSourceType</code> is "object" or an equivalent primitive type, and the
242
+ * <code>showTimezone</code> format option is not
243
+ * <code>sap.ui.core.format.DateFormatTimezoneDisplay.Hide</code>,</li>
244
+ * <li>the <code>sSourceType</code> is "object" or an equivalent primitive type, and the
245
+ * value is not an instance of <code>Date</code></li>
246
+ * </ul>
247
+ *
248
+ * @public
249
+ */
250
+ DateTimeWithTimezone.prototype.parseValue = function (vValue, sSourceType, aCurrentValues) {
251
+ var sCurrentTimezone, aDateWithTimezone,
252
+ sShowTimezone = this.oFormatOptions.showTimezone;
253
+
254
+ if (!aCurrentValues) {
255
+ throw new ParseException("'aCurrentValues' is mandatory");
256
+ }
257
+
258
+ switch (this.getPrimitiveType(sSourceType)) {
259
+ case "object":
260
+ if (sShowTimezone !== DateFormatTimezoneDisplay.Hide) {
261
+ throw new ParseException(sObjectRequiresHide);
262
+ }
263
+
264
+ if (!vValue) {
265
+ return [null, /*unchanged*/undefined];
266
+ }
267
+
268
+ if (!aCurrentValues[1]) {
269
+ throw new ParseException(sap.ui.getCore().getLibraryResourceBundle()
270
+ .getText("EnterDateTimeTimezoneFirst"));
271
+ }
272
+
273
+ if (!(vValue instanceof Date)) {
274
+ throw new ParseException("Given value must be an instance of Date");
275
+ }
276
+
277
+ return [vValue, undefined];
278
+ case "string":
279
+ if (!vValue) {
280
+ if (sShowTimezone === DateFormatTimezoneDisplay.Only) {
281
+ throw new ParseException(this._getErrorMessage());
282
+ }
283
+
284
+ return [null, /*unchanged*/undefined];
285
+ }
286
+
287
+ if (!aCurrentValues[1] && sShowTimezone === DateFormatTimezoneDisplay.Hide) {
288
+ throw new ParseException(sap.ui.getCore().getLibraryResourceBundle()
289
+ .getText("EnterDateTimeTimezoneFirst"));
290
+ }
291
+
292
+ sCurrentTimezone = aCurrentValues[1]
293
+ || sap.ui.getCore().getConfiguration().getTimezone();
294
+ aDateWithTimezone = getFormatter(this).parse(vValue, sCurrentTimezone);
295
+ if (!aDateWithTimezone) {
296
+ throw new ParseException(this._getErrorMessage());
297
+ }
298
+ // if time zone has been defaulted because current value does not have a time zone
299
+ // then the default time zone has to be added to the result if the time zone part of
300
+ // the parsed value indicates that it has not been changed; this can happen only
301
+ // if showTimezone format option is 'Show' or not set; in case of 'Hide' a
302
+ // ParseException is thrown earlier; in case of 'Only' the time zone part is never
303
+ // undefined
304
+ if (!aCurrentValues[1] && aDateWithTimezone[1] === undefined) {
305
+ aDateWithTimezone[1] = sCurrentTimezone;
306
+ }
307
+
308
+ return aDateWithTimezone;
309
+ default:
310
+ throw new ParseException("Don't know how to parse " + this.getName() + " from "
311
+ + sSourceType);
312
+ }
313
+ };
314
+
315
+ /**
316
+ * Validates whether the given raw values meet the defined constraints. This method does nothing
317
+ * as no constraints are supported.
318
+ *
319
+ * @param {any[]} aValues
320
+ * The set of values to be validated
321
+ *
322
+ * @public
323
+ * @see sap.ui.model.SimpleType#validateValue
324
+ */
325
+ DateTimeWithTimezone.prototype.validateValue = function (aValues) {
326
+ };
327
+
328
+ /**
329
+ * Called by the framework when any localization setting has changed.
330
+ *
331
+ * @private
332
+ */
333
+ DateTimeWithTimezone.prototype._handleLocalizationChange = function () {
334
+ this.oFormat = null;
335
+ };
336
+
337
+ return DateTimeWithTimezone;
338
+ });
@@ -135,6 +135,8 @@ sap.ui.define([
135
135
  }
136
136
  logWarning(sValue, sName);
137
137
  }
138
+
139
+ return undefined;
138
140
  }
139
141
 
140
142
  function validateBoolean(vValue, sName) {
@@ -144,6 +146,8 @@ sap.ui.define([
144
146
  if (vValue !== undefined && vValue !== false && vValue !== "false") {
145
147
  logWarning(vValue, sName);
146
148
  }
149
+
150
+ return undefined;
147
151
  }
148
152
 
149
153
  function setConstraint(sName, vValue, vDefault) {
@@ -197,7 +201,7 @@ sap.ui.define([
197
201
  * @extends sap.ui.model.odata.type.ODataType
198
202
  *
199
203
  * @author SAP SE
200
- * @version 1.96.5
204
+ * @version 1.99.0
201
205
  *
202
206
  * @alias sap.ui.model.odata.type.Decimal
203
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.96.5
98
+ * @version 1.99.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.96.5
65
+ * @version 1.99.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.96.5
83
+ * @version 1.99.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.96.5
27
+ * @version 1.99.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.96.5
27
+ * @version 1.99.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.96.5
140
+ * @version 1.99.0
141
141
  *
142
142
  * @alias sap.ui.model.odata.type.Int64
143
143
  * @param {object} [oFormatOptions]