@situm/cordova 3.0.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 (313) hide show
  1. package/CHANGELOG.md +3 -0
  2. package/CHANGELOG_UNRELEASED.md +28 -0
  3. package/Jenkinsfile +84 -0
  4. package/LICENSE +21 -0
  5. package/README.md +472 -0
  6. package/azure/common-steps.yaml +5 -0
  7. package/azure-pipelines.yml +336 -0
  8. package/docs/JSDoc/MapView.html +300 -0
  9. package/docs/JSDoc/MapViewControllerImpl.html +299 -0
  10. package/docs/JSDoc/Situm.html +5257 -0
  11. package/docs/JSDoc/android_Interfaces.js.html +825 -0
  12. package/docs/JSDoc/android_situm.js.html +380 -0
  13. package/docs/JSDoc/fonts/glyphicons-halflings-regular.eot +0 -0
  14. package/docs/JSDoc/fonts/glyphicons-halflings-regular.svg +288 -0
  15. package/docs/JSDoc/fonts/glyphicons-halflings-regular.ttf +0 -0
  16. package/docs/JSDoc/fonts/glyphicons-halflings-regular.woff +0 -0
  17. package/docs/JSDoc/fonts/glyphicons-halflings-regular.woff2 +0 -0
  18. package/docs/JSDoc/global.html +7538 -0
  19. package/docs/JSDoc/img/toast-ui.png +0 -0
  20. package/docs/JSDoc/index.html +90 -0
  21. package/docs/JSDoc/map-view-controller.js.html +307 -0
  22. package/docs/JSDoc/map-view.js.html +172 -0
  23. package/docs/JSDoc/scripts/jquery.min.js +2 -0
  24. package/docs/JSDoc/scripts/linenumber.js +30 -0
  25. package/docs/JSDoc/scripts/prettify/Apache-License-2.0.txt +202 -0
  26. package/docs/JSDoc/scripts/prettify/lang-css.js +2 -0
  27. package/docs/JSDoc/scripts/prettify/prettify.js +28 -0
  28. package/docs/JSDoc/scripts/tui-doc.js +200 -0
  29. package/docs/JSDoc/styles/bootstrap.min.css +6 -0
  30. package/docs/JSDoc/styles/custom.css +23 -0
  31. package/docs/JSDoc/styles/prettify-jsdoc.css +111 -0
  32. package/docs/JSDoc/styles/prettify-tomorrow.css +132 -0
  33. package/docs/JSDoc/styles/tui-doc.css +485 -0
  34. package/docs/conf.json +28 -0
  35. package/docs/getting-started.md +298 -0
  36. package/docs/imagotype-SITUM-transparent-90.png +0 -0
  37. package/docs/static/styles/custom.css +23 -0
  38. package/package.json +60 -0
  39. package/plugin.xml +102 -0
  40. package/scripts/update_changelog.sh +22 -0
  41. package/src/android/app/build.gradle +51 -0
  42. package/src/android/app/proguard-rules.pro +21 -0
  43. package/src/android/app/src/main/AndroidManifest.xml +11 -0
  44. package/src/android/app/src/main/java/es/situm/plugin/DateUtils.java +15 -0
  45. package/src/android/app/src/main/java/es/situm/plugin/PluginHelper.java +919 -0
  46. package/src/android/app/src/main/java/es/situm/plugin/SitumMapper.java +968 -0
  47. package/src/android/app/src/main/java/es/situm/plugin/SitumPlugin.java +109 -0
  48. package/src/android/app/src/main/res/drawable/ic_launcher_background.xml +170 -0
  49. package/src/android/app/src/main/res/drawable-v24/ic_launcher_foreground.xml +34 -0
  50. package/src/android/app/src/main/res/mipmap-anydpi-v26/ic_launcher.xml +5 -0
  51. package/src/android/app/src/main/res/mipmap-anydpi-v26/ic_launcher_round.xml +5 -0
  52. package/src/android/app/src/main/res/mipmap-hdpi/ic_launcher.png +0 -0
  53. package/src/android/app/src/main/res/mipmap-hdpi/ic_launcher_round.png +0 -0
  54. package/src/android/app/src/main/res/mipmap-mdpi/ic_launcher.png +0 -0
  55. package/src/android/app/src/main/res/mipmap-mdpi/ic_launcher_round.png +0 -0
  56. package/src/android/app/src/main/res/mipmap-xhdpi/ic_launcher.png +0 -0
  57. package/src/android/app/src/main/res/mipmap-xhdpi/ic_launcher_round.png +0 -0
  58. package/src/android/app/src/main/res/mipmap-xxhdpi/ic_launcher.png +0 -0
  59. package/src/android/app/src/main/res/mipmap-xxhdpi/ic_launcher_round.png +0 -0
  60. package/src/android/app/src/main/res/mipmap-xxxhdpi/ic_launcher.png +0 -0
  61. package/src/android/app/src/main/res/mipmap-xxxhdpi/ic_launcher_round.png +0 -0
  62. package/src/android/app/src/main/res/values/colors.xml +6 -0
  63. package/src/android/app/src/main/res/values/strings.xml +3 -0
  64. package/src/android/app/src/main/res/values/styles.xml +11 -0
  65. package/src/android/app/src/test/java/es/situm/plugin/PluginHelperTest.java +27 -0
  66. package/src/android/app/src/test/java/es/situm/plugin/SitumMapperTest.java +1485 -0
  67. package/src/android/app/src/test/java/es/situm/plugin/angle/AngleCreator.java +46 -0
  68. package/src/android/app/src/test/java/es/situm/plugin/bounds/BoundsCreator.java +50 -0
  69. package/src/android/app/src/test/java/es/situm/plugin/building/BuildingCreator.java +76 -0
  70. package/src/android/app/src/test/java/es/situm/plugin/cartesianCoordinate/CartesianCoordinateCreator.java +31 -0
  71. package/src/android/app/src/test/java/es/situm/plugin/circle/CircleCreator.java +41 -0
  72. package/src/android/app/src/test/java/es/situm/plugin/coordinate/CoordinateCreator.java +32 -0
  73. package/src/android/app/src/test/java/es/situm/plugin/dimensions/DimensionsCreator.java +31 -0
  74. package/src/android/app/src/test/java/es/situm/plugin/directionsRequest/DirectionsRequestCreator.java +105 -0
  75. package/src/android/app/src/test/java/es/situm/plugin/event/EventCreator.java +108 -0
  76. package/src/android/app/src/test/java/es/situm/plugin/floor/FloorCreator.java +58 -0
  77. package/src/android/app/src/test/java/es/situm/plugin/indication/IndicationCreator.java +40 -0
  78. package/src/android/app/src/test/java/es/situm/plugin/location/LocationCreator.java +197 -0
  79. package/src/android/app/src/test/java/es/situm/plugin/locationRequest/LocationRequestCreator.java +45 -0
  80. package/src/android/app/src/test/java/es/situm/plugin/locationStatus/LocationStatusCreator.java +211 -0
  81. package/src/android/app/src/test/java/es/situm/plugin/navigationProgress/NavigationProgressCreator.java +154 -0
  82. package/src/android/app/src/test/java/es/situm/plugin/poi/PoiCreator.java +126 -0
  83. package/src/android/app/src/test/java/es/situm/plugin/poiCategory/PoiCategoryCreator.java +38 -0
  84. package/src/android/app/src/test/java/es/situm/plugin/point/PointCreator.java +200 -0
  85. package/src/android/app/src/test/java/es/situm/plugin/route/RouteCreator.java +142 -0
  86. package/src/android/app/src/test/java/es/situm/plugin/routeStep/RouteStepCreator.java +173 -0
  87. package/src/android/app/src/test/java/es/situm/plugin/situmConversionArea/SitumConversionAreaCreator.java +35 -0
  88. package/src/android/build.gradle +31 -0
  89. package/src/android/gradle/wrapper/gradle-wrapper.jar +0 -0
  90. package/src/android/gradle/wrapper/gradle-wrapper.properties +6 -0
  91. package/src/android/gradle.properties +16 -0
  92. package/src/android/gradlew +172 -0
  93. package/src/android/gradlew.bat +84 -0
  94. package/src/android/settings.gradle +3 -0
  95. package/src/android/situm.gradle +19 -0
  96. package/src/ios/Classes/Private/CDVDebug.h +25 -0
  97. package/src/ios/Classes/Private/CDVJSON_private.h +31 -0
  98. package/src/ios/Classes/Private/CDVJSON_private.m +99 -0
  99. package/src/ios/Classes/Private/CDVPlugin+Private.h +24 -0
  100. package/src/ios/Classes/Private/CDVPlugins/CDVGestureHandler/CDVGestureHandler.h +26 -0
  101. package/src/ios/Classes/Private/CDVPlugins/CDVGestureHandler/CDVGestureHandler.m +70 -0
  102. package/src/ios/Classes/Private/CDVPlugins/CDVHandleOpenURL/CDVHandleOpenURL.h +27 -0
  103. package/src/ios/Classes/Private/CDVPlugins/CDVHandleOpenURL/CDVHandleOpenURL.m +86 -0
  104. package/src/ios/Classes/Private/CDVPlugins/CDVIntentAndNavigationFilter/CDVIntentAndNavigationFilter.h +34 -0
  105. package/src/ios/Classes/Private/CDVPlugins/CDVIntentAndNavigationFilter/CDVIntentAndNavigationFilter.m +153 -0
  106. package/src/ios/Classes/Private/CDVPlugins/CDVLocalStorage/CDVLocalStorage.h +50 -0
  107. package/src/ios/Classes/Private/CDVPlugins/CDVLocalStorage/CDVLocalStorage.m +487 -0
  108. package/src/ios/Classes/Private/CDVPlugins/CDVLogger/CDVLogger.h +26 -0
  109. package/src/ios/Classes/Private/CDVPlugins/CDVLogger/CDVLogger.m +37 -0
  110. package/src/ios/Classes/Private/CDVPlugins/CDVUIWebViewEngine/CDVUIWebViewDelegate.h +41 -0
  111. package/src/ios/Classes/Private/CDVPlugins/CDVUIWebViewEngine/CDVUIWebViewDelegate.m +399 -0
  112. package/src/ios/Classes/Private/CDVPlugins/CDVUIWebViewEngine/CDVUIWebViewEngine.h +27 -0
  113. package/src/ios/Classes/Private/CDVPlugins/CDVUIWebViewEngine/CDVUIWebViewEngine.m +202 -0
  114. package/src/ios/Classes/Private/CDVPlugins/CDVUIWebViewEngine/CDVUIWebViewNavigationDelegate.h +29 -0
  115. package/src/ios/Classes/Private/CDVPlugins/CDVUIWebViewEngine/CDVUIWebViewNavigationDelegate.m +153 -0
  116. package/src/ios/Classes/Public/CDV.h +32 -0
  117. package/src/ios/Classes/Public/CDVAppDelegate.h +28 -0
  118. package/src/ios/Classes/Public/CDVAppDelegate.m +118 -0
  119. package/src/ios/Classes/Public/CDVAvailability.h +111 -0
  120. package/src/ios/Classes/Public/CDVAvailabilityDeprecated.h +26 -0
  121. package/src/ios/Classes/Public/CDVCommandDelegate.h +51 -0
  122. package/src/ios/Classes/Public/CDVCommandDelegateImpl.h +36 -0
  123. package/src/ios/Classes/Public/CDVCommandDelegateImpl.m +186 -0
  124. package/src/ios/Classes/Public/CDVCommandQueue.h +39 -0
  125. package/src/ios/Classes/Public/CDVCommandQueue.m +194 -0
  126. package/src/ios/Classes/Public/CDVConfigParser.h +30 -0
  127. package/src/ios/Classes/Public/CDVConfigParser.m +81 -0
  128. package/src/ios/Classes/Public/CDVInvokedUrlCommand.h +52 -0
  129. package/src/ios/Classes/Public/CDVInvokedUrlCommand.m +116 -0
  130. package/src/ios/Classes/Public/CDVPlugin+Resources.h +39 -0
  131. package/src/ios/Classes/Public/CDVPlugin+Resources.m +38 -0
  132. package/src/ios/Classes/Public/CDVPlugin.h +85 -0
  133. package/src/ios/Classes/Public/CDVPlugin.m +202 -0
  134. package/src/ios/Classes/Public/CDVPluginResult.h +66 -0
  135. package/src/ios/Classes/Public/CDVPluginResult.m +186 -0
  136. package/src/ios/Classes/Public/CDVScreenOrientationDelegate.h +33 -0
  137. package/src/ios/Classes/Public/CDVTimer.h +27 -0
  138. package/src/ios/Classes/Public/CDVTimer.m +123 -0
  139. package/src/ios/Classes/Public/CDVURLProtocol.h +27 -0
  140. package/src/ios/Classes/Public/CDVURLProtocol.m +113 -0
  141. package/src/ios/Classes/Public/CDVUserAgentUtil.h +27 -0
  142. package/src/ios/Classes/Public/CDVUserAgentUtil.m +124 -0
  143. package/src/ios/Classes/Public/CDVViewController.h +92 -0
  144. package/src/ios/Classes/Public/CDVViewController.m +821 -0
  145. package/src/ios/Classes/Public/CDVWebViewEngineProtocol.h +42 -0
  146. package/src/ios/Classes/Public/CDVWhitelist.h +34 -0
  147. package/src/ios/Classes/Public/CDVWhitelist.m +285 -0
  148. package/src/ios/Classes/Public/NSDictionary+CordovaPreferences.h +35 -0
  149. package/src/ios/Classes/Public/NSDictionary+CordovaPreferences.m +63 -0
  150. package/src/ios/Classes/Public/NSMutableArray+QueueAdditions.h +29 -0
  151. package/src/ios/Classes/Public/NSMutableArray+QueueAdditions.m +58 -0
  152. package/src/ios/Cordova/Cordova.h +51 -0
  153. package/src/ios/Cordova/Info.plist +24 -0
  154. package/src/ios/Podfile +5 -0
  155. package/src/ios/SitumCordovaPlugin.xcodeproj/project.pbxproj +1324 -0
  156. package/src/ios/SitumCordovaPlugin.xcodeproj/project.xcworkspace/contents.xcworkspacedata +7 -0
  157. package/src/ios/SitumCordovaPlugin.xcodeproj/project.xcworkspace/xcshareddata/IDEWorkspaceChecks.plist +8 -0
  158. package/src/ios/SitumCordovaPlugin.xcodeproj/project.xcworkspace/xcshareddata/WorkspaceSettings.xcsettings +8 -0
  159. package/src/ios/SitumCordovaPlugin.xcodeproj/xcshareddata/xcschemes/CordovaLib.xcscheme +100 -0
  160. package/src/ios/SitumCordovaPlugin.xcworkspace/xcshareddata/IDEWorkspaceChecks.plist +8 -0
  161. package/src/ios/SitumCordovaPlugin_Prefix.pch +22 -0
  162. package/src/ios/VERSION +1 -0
  163. package/src/ios/cordova.js +2432 -0
  164. package/src/ios/situmcordovaplugin/AppDelegate.h +22 -0
  165. package/src/ios/situmcordovaplugin/AppDelegate.m +98 -0
  166. package/src/ios/situmcordovaplugin/Assets.xcassets/AppIcon.appiconset/Contents.json +98 -0
  167. package/src/ios/situmcordovaplugin/Base.lproj/LaunchScreen.storyboard +25 -0
  168. package/src/ios/situmcordovaplugin/Base.lproj/Main.storyboard +24 -0
  169. package/src/ios/situmcordovaplugin/Constants.h +14 -0
  170. package/src/ios/situmcordovaplugin/Constants.m +14 -0
  171. package/src/ios/situmcordovaplugin/Info.plist +45 -0
  172. package/src/ios/situmcordovaplugin/SITUtils.h +7 -0
  173. package/src/ios/situmcordovaplugin/SITUtils.m +13 -0
  174. package/src/ios/situmcordovaplugin/SitumLocationWrapper.h +109 -0
  175. package/src/ios/situmcordovaplugin/SitumLocationWrapper.m +983 -0
  176. package/src/ios/situmcordovaplugin/SitumPlugin.h +41 -0
  177. package/src/ios/situmcordovaplugin/SitumPlugin.m +752 -0
  178. package/src/ios/situmcordovaplugin/ViewController.h +15 -0
  179. package/src/ios/situmcordovaplugin/ViewController.m +29 -0
  180. package/src/ios/situmcordovaplugin/main.m +16 -0
  181. package/src/ios/situmcordovaplugin/situmcordovaplugin.xcdatamodeld/.xccurrentversion +8 -0
  182. package/src/ios/situmcordovaplugin/situmcordovaplugin.xcdatamodeld/situmcordovaplugin.xcdatamodel/contents +4 -0
  183. package/src/ios/situmcordovaplugintests/AngleTests.m +53 -0
  184. package/src/ios/situmcordovaplugintests/BoundTests.m +51 -0
  185. package/src/ios/situmcordovaplugintests/BuildingTests.m +41 -0
  186. package/src/ios/situmcordovaplugintests/CartesianCoordinateTests.m +42 -0
  187. package/src/ios/situmcordovaplugintests/ConversionAreaTests.m +43 -0
  188. package/src/ios/situmcordovaplugintests/CoordinateTests.m +42 -0
  189. package/src/ios/situmcordovaplugintests/DimensionTests.m +43 -0
  190. package/src/ios/situmcordovaplugintests/EventTests.m +42 -0
  191. package/src/ios/situmcordovaplugintests/FloorTests.m +52 -0
  192. package/src/ios/situmcordovaplugintests/Info.plist +38 -0
  193. package/src/ios/situmcordovaplugintests/InputTests/DirectionsRequestTest.m +108 -0
  194. package/src/ios/situmcordovaplugintests/InputTests/InputCartesianCoordinateTests.m +45 -0
  195. package/src/ios/situmcordovaplugintests/InputTests/InputCoordinateTests.m +45 -0
  196. package/src/ios/situmcordovaplugintests/InputTests/InputFloorTests.m +59 -0
  197. package/src/ios/situmcordovaplugintests/InputTests/InputIndicationTests.m +45 -0
  198. package/src/ios/situmcordovaplugintests/InputTests/InputLocationTests.m +163 -0
  199. package/src/ios/situmcordovaplugintests/InputTests/InputPoiCategoryTests.m +46 -0
  200. package/src/ios/situmcordovaplugintests/InputTests/InputPointTests.m +137 -0
  201. package/src/ios/situmcordovaplugintests/InputTests/LocationRequestTest.m +79 -0
  202. package/src/ios/situmcordovaplugintests/LocationStatusTests.m +60 -0
  203. package/src/ios/situmcordovaplugintests/LocationTests.m +114 -0
  204. package/src/ios/situmcordovaplugintests/NavigationProgressTests.m +50 -0
  205. package/src/ios/situmcordovaplugintests/PoiCategoryIconTests.m +43 -0
  206. package/src/ios/situmcordovaplugintests/PoiCategoryTests.m +42 -0
  207. package/src/ios/situmcordovaplugintests/PoiTests.m +83 -0
  208. package/src/ios/situmcordovaplugintests/PointTests.m +107 -0
  209. package/src/ios/situmcordovaplugintests/RouteStepTests.m +78 -0
  210. package/src/ios/situmcordovaplugintests/RouteTests.m +42 -0
  211. package/src/ios/situmcordovaplugintests/SitumCreatorTests.h +91 -0
  212. package/src/ios/situmcordovaplugintests/SitumCreatorTests.m +928 -0
  213. package/src/ios/situmcordovaplugintests/TestingHelper.h +48 -0
  214. package/src/ios/situmcordovaplugintests/TestingHelper.m +342 -0
  215. package/src/ios/situmcordovaplugintests/indicationTests.m +43 -0
  216. package/tests/common-resources/angle/angle1.json +6 -0
  217. package/tests/common-resources/angle/angle2.json +6 -0
  218. package/tests/common-resources/bounds/bounds1.json +18 -0
  219. package/tests/common-resources/bounds/bounds2.json +18 -0
  220. package/tests/common-resources/building/building1.json +64 -0
  221. package/tests/common-resources/cartesianCoordinate/cartesianCoordinate1.json +4 -0
  222. package/tests/common-resources/circle/circle1.json +17 -0
  223. package/tests/common-resources/coordinate/coordinate1.json +4 -0
  224. package/tests/common-resources/dimensions/dimensions1.json +4 -0
  225. package/tests/common-resources/directionsRequest/directionsRequest1.json +166 -0
  226. package/tests/common-resources/directionsRequest/directionsRequest2.json +167 -0
  227. package/tests/common-resources/directionsRequest/directionsRequest3.json +166 -0
  228. package/tests/common-resources/directionsRequest/directionsRequest4.json +166 -0
  229. package/tests/common-resources/directionsRequest/directionsRequest5.json +167 -0
  230. package/tests/common-resources/directionsRequest/directionsRequest6.json +153 -0
  231. package/tests/common-resources/events/event1.json +66 -0
  232. package/tests/common-resources/floor/floor1.json +13 -0
  233. package/tests/common-resources/floor/floor2.json +13 -0
  234. package/tests/common-resources/indication/indication1.json +10 -0
  235. package/tests/common-resources/location/location1.json +48 -0
  236. package/tests/common-resources/location/location10.json +48 -0
  237. package/tests/common-resources/location/location2.json +48 -0
  238. package/tests/common-resources/location/location3.json +48 -0
  239. package/tests/common-resources/location/location4.json +48 -0
  240. package/tests/common-resources/location/location5.json +48 -0
  241. package/tests/common-resources/location/location6.json +48 -0
  242. package/tests/common-resources/location/location7.json +48 -0
  243. package/tests/common-resources/location/location8.json +48 -0
  244. package/tests/common-resources/location/location9.json +48 -0
  245. package/tests/common-resources/locationRequest/locationRequest1.json +6 -0
  246. package/tests/common-resources/locationRequest/locationRequest2.json +32 -0
  247. package/tests/common-resources/locationRequest/locationRequest3.json +33 -0
  248. package/tests/common-resources/locationRequest/locationRequest4.json +31 -0
  249. package/tests/common-resources/locationStatus/locationStatus1.json +4 -0
  250. package/tests/common-resources/locationStatus/locationStatus10.json +4 -0
  251. package/tests/common-resources/locationStatus/locationStatus11.json +4 -0
  252. package/tests/common-resources/locationStatus/locationStatus12.json +4 -0
  253. package/tests/common-resources/locationStatus/locationStatus13.json +4 -0
  254. package/tests/common-resources/locationStatus/locationStatus2.json +4 -0
  255. package/tests/common-resources/locationStatus/locationStatus3.json +4 -0
  256. package/tests/common-resources/locationStatus/locationStatus4.json +4 -0
  257. package/tests/common-resources/locationStatus/locationStatus5.json +4 -0
  258. package/tests/common-resources/locationStatus/locationStatus6.json +4 -0
  259. package/tests/common-resources/locationStatus/locationStatus7.json +4 -0
  260. package/tests/common-resources/locationStatus/locationStatus8.json +4 -0
  261. package/tests/common-resources/locationStatus/locationStatus9.json +4 -0
  262. package/tests/common-resources/navigationProgress/navigationProgress1.json +77 -0
  263. package/tests/common-resources/navigationProgress/navigationProgress2.json +77 -0
  264. package/tests/common-resources/poi/poi1.json +35 -0
  265. package/tests/common-resources/poi/poi2.json +35 -0
  266. package/tests/common-resources/poi/poi3.json +35 -0
  267. package/tests/common-resources/poi/poi4.json +38 -0
  268. package/tests/common-resources/poi/poi5.json +35 -0
  269. package/tests/common-resources/poiCategory/poiCategory1.json +7 -0
  270. package/tests/common-resources/poiCategoryIcon/poiCategoryIcon1.json +1 -0
  271. package/tests/common-resources/poiCategoryIcon/poiCategoryIcon1.png +0 -0
  272. package/tests/common-resources/point/point1.json +14 -0
  273. package/tests/common-resources/point/point2.json +14 -0
  274. package/tests/common-resources/point/point3.json +14 -0
  275. package/tests/common-resources/point/point4.json +14 -0
  276. package/tests/common-resources/point/point5.json +14 -0
  277. package/tests/common-resources/point/point6.json +14 -0
  278. package/tests/common-resources/point/point7.json +14 -0
  279. package/tests/common-resources/point/point8.json +14 -0
  280. package/tests/common-resources/route/route1.json +530 -0
  281. package/tests/common-resources/routeStep/routeStep1.json +35 -0
  282. package/tests/common-resources/routeStep/routeStep2.json +35 -0
  283. package/tests/common-resources/routeStep/routeStep3.json +35 -0
  284. package/tests/common-resources/routeStep/routeStep4.json +35 -0
  285. package/tests/common-resources/routeStep/routeStep5.json +35 -0
  286. package/tests/common-resources/situmConversionArea/situmConversionArea1.json +19 -0
  287. package/tests/js/resources/fetchBuildings.json +176 -0
  288. package/tests/js/resources/fetchEventsFromBuilding.json +201 -0
  289. package/tests/js/resources/fetchFloorsFromBuilding.json +34 -0
  290. package/tests/js/resources/fetchIndoorPOIsFromBuilding.json +574 -0
  291. package/tests/js/resources/fetchMapFromFloor.json +3 -0
  292. package/tests/js/resources/fetchOutdoorPOIsFromBuilding.json +68 -0
  293. package/tests/js/resources/fetchPoiCategories.json +72 -0
  294. package/tests/js/resources/fetchPoiCategoryIconNormal.json +3 -0
  295. package/tests/js/resources/fetchPoiCategoryIconSelected.json +3 -0
  296. package/tests/js/resources/requestDirections.json +1167 -0
  297. package/tests/js/resources/startPositioning/0_starting.json +4 -0
  298. package/tests/js/resources/startPositioning/1_preparingPositioningModel.json +4 -0
  299. package/tests/js/resources/startPositioning/2_startingPositioning.json +4 -0
  300. package/tests/js/resources/startPositioning/3_calculating.json +4 -0
  301. package/tests/js/resources/startPositioning/4_position.json +48 -0
  302. package/tests/js/resources/startPositioning/5_position.json +48 -0
  303. package/tests/js/test.js +416 -0
  304. package/tests/scripts/clean_android_resources.sh +3 -0
  305. package/tests/scripts/clean_ios_resources.sh +3 -0
  306. package/tests/scripts/copy_android_resources.sh +3 -0
  307. package/tests/scripts/copy_ios_resources.sh +3 -0
  308. package/tests/scripts/self-destruct.sh +1 -0
  309. package/www/android/Interfaces.js +742 -0
  310. package/www/android/situm.js +296 -0
  311. package/www/ios/situm.js +99 -0
  312. package/www/map-view-controller.js +223 -0
  313. package/www/map-view.js +88 -0
@@ -0,0 +1,298 @@
1
+ <h1>Quick start guide</h1>
2
+
3
+ <div id="guide__introduction" class="guide__section">
4
+ <h2>Introduction</h2>
5
+ </div>
6
+
7
+ In this tutorial, we will guide you step by step to set up your first Cordova application using Cordova Situm Plugin.
8
+ Before starting to write code, we recommend you to set up an account on our Dashboard ([https://dashboard.situm.es](https://dashboard.situm.es)), retrieve your API KEY and configure your first building.
9
+
10
+ 1. Go to the [sign in form](http://dashboard.situm.es/accounts/register) and enter your username and password to sign in.
11
+
12
+ 2. Go to the [account section](https://dashboard.situm.es/accounts/profile) and on the bottom, click on “generate one” to generate your API KEY.
13
+
14
+ 3. Go to the [buildings section](http://dashboard.situm.es/buildings) and create your first building.
15
+
16
+ 4. Download Situm Mapping Tool in Play Store (Only Android devices) and calibrate your building. Check out our user guide for detailed information.
17
+
18
+ 5. You are ready to build your own Cordova applications. Please check the next steps for requirements:
19
+
20
+
21
+ <div id="guide__pre_requisites" class="guide__section">
22
+ <h2>Installing pre-requisites</h2>
23
+ </div>
24
+
25
+ ### Configure cordova:
26
+
27
+ * [Installing the Cordova CLI](https://cordova.apache.org/docs/en/latest/guide/cli/index.html#installing-the-cordova-cli)
28
+
29
+ ### Cordova requirements:
30
+
31
+ * [Android](https://cordova.apache.org/docs/en/latest/guide/platforms/android/#installing-the-requirements)
32
+
33
+ * [iOS](https://cordova.apache.org/docs/en/latest/guide/platforms/android/#installing-the-requirements)
34
+
35
+
36
+ <div id="guide__installing_the_plugin" class="guide__section">
37
+ <h2>Installing the plugin</h2>
38
+ </div>
39
+
40
+ We assume that you have already created a hybrid application with your favorite framework (Ionic, PhoneGap, Appcelerator, Telerik...). There are some different ways to install the plugin:
41
+
42
+ ### 1) Manually from npm:
43
+
44
+ ```bash
45
+ $ cordova plugin add @situm/cordova
46
+ ```
47
+
48
+ ### 2) Defined in config.xml for automatic installation:
49
+
50
+ ```xml
51
+ <plugin name="@situm/cordova" source="npm">
52
+
53
+ </plugin>
54
+ ```
55
+
56
+ ### 3) With Cordova CLI utility from master (or another branch):
57
+
58
+ ```
59
+ $ cordova plugin add https://github.com/situmtech/situm-cordova-plugin.git
60
+ ```
61
+
62
+ <div id="guide__using_the_plugin" class="guide__section">
63
+ <h2>Using the plugin</h2>
64
+ </div>
65
+
66
+ ### Accessing plugin object
67
+
68
+ When the device ready event is fired, the global cordova variable is injected into the namespace. Plugins are available in this variable: cordova.plugins. The Situm Cordova Plugin is autowired within this object.
69
+
70
+ So, all methods are called in the same way, e.g. 'setApiKey':
71
+
72
+ ```javascript
73
+ cordova.plugins.Situm.setApiKey(email, apiKey);
74
+ ```
75
+
76
+ <div id="guide__methods" class="guide__section">
77
+ <h2>Methods</h2>
78
+ </div>
79
+
80
+ #### - setApiKey
81
+
82
+ Allows you to log in to your Situm Account. This key is generated in Situm Dashboard. Returns true if apiKey was set successfully, otherwise false
83
+
84
+ ```javascript
85
+ setApiKey("your_email@domain.com", "YOUR_API_KEY");
86
+ ```
87
+
88
+ #### - setUserPass
89
+
90
+ Provides user's email and password.
91
+
92
+ ```javascript
93
+ setUserPass("email@domain.com", "yourPassword");
94
+ ````
95
+
96
+ #### - setCacheMaxAge
97
+
98
+ Sets the maximum age of a cached response in seconds. Some information, such as floor plans, floors, POIs, etc. is stored in the cache. After the cache expires, we will fetch this information from the server again.
99
+
100
+ ```javascript
101
+ setCacheMaxAge(200);
102
+ ```
103
+
104
+ #### - startPositioning
105
+
106
+ Starts the positioning on the [locationRequest](http://developers.situm.es/sdk_documentation/cordova/jsdoc/1.3.10/symbols/LocationRequest.html), a [building](http://developers.situm.es/sdk_documentation/cordova/jsdoc/1.3.10/symbols/Building.html) should be sent as the first parameter and a locationRequest should be sent as the second one. Returns a set of locationStatus and [location](http://developers.situm.es/sdk_documentation/cordova/jsdoc/1.3.10/symbols/Location.html) through the success callback.
107
+
108
+ ```javascript
109
+ startPositioning([building, locationRequest], position => {
110
+ // position as location object:
111
+ }, (error) => {
112
+ // If errors will come here
113
+ });
114
+ ```
115
+
116
+ #### - stopPositioning
117
+
118
+ Stops locationListener on current active listener.
119
+
120
+ ```javascript
121
+ stopPositioning(() => {
122
+ // Your code here
123
+ }, (error) => {
124
+ // If errors will come here
125
+ });
126
+ ```
127
+
128
+ #### - fetchBuildings
129
+
130
+ Downloads all the [buildings](http://developers.situm.es/sdk_documentation/cordova/jsdoc/1.3.10/symbols/Building.html) for the current user.
131
+
132
+ ```javascript
133
+ fetchBuildings((buildings) => {
134
+ // Array of buildings
135
+ }, (error) => {
136
+ // If errors will come here
137
+ });
138
+ ```
139
+
140
+ #### - fetchFloorsFromBuilding
141
+
142
+ Downloads all the [floors](http://developers.situm.es/sdk_documentation/cordova/jsdoc/1.3.10/symbols/Floor.html) of a [building](http://developers.situm.es/sdk_documentation/cordova/jsdoc/1.3.10/symbols/Building.html).
143
+
144
+ ```javascript
145
+ fetchFloorsFromBuilding(building, (floors) => {
146
+ // Array of floors
147
+ }, (error) => {
148
+ // If errors will come here
149
+ });
150
+ ```
151
+
152
+ #### - fetchIndoorPOIsFromBuilding
153
+
154
+ Downloads the indoor [POIs](http://developers.situm.es/sdk_documentation/cordova/jsdoc/1.3.10/symbols/Poi.html) of a [building](http://developers.situm.es/sdk_documentation/cordova/jsdoc/1.3.10/symbols/Building.html).
155
+
156
+ ```javascript
157
+ fetchIndoorPOIsFromBuilding(building, (pois) => {
158
+ // Array of pois
159
+ }, (error) => {
160
+ // If errors will come here
161
+ });
162
+ ```
163
+
164
+ #### - fetchOutdoorPOIsFromBuilding
165
+
166
+ Downloads the outdoor [POIs](http://developers.situm.es/sdk_documentation/cordova/jsdoc/1.3.10/symbols/Poi.html) of a [building](http://developers.situm.es/sdk_documentation/cordova/jsdoc/1.3.10/symbols/Building.html).
167
+
168
+ ```javascript
169
+ fetchOutdoorPOIsFromBuilding(building, (pois) => {
170
+ // Array of pois
171
+ }, (error) => {
172
+ // If errors will come here
173
+ });
174
+ ```
175
+
176
+ #### - fetchEventsFromBuilding
177
+
178
+ Downloads the events of a [building](http://developers.situm.es/sdk_documentation/cordova/jsdoc/1.3.10/symbols/Building.html).
179
+
180
+ ```javascript
181
+ fetchEventsFromBuilding(building, (events) => {
182
+ // Array of Situm events
183
+ }, (error) => {
184
+ // If errors will come here
185
+ });
186
+ ```
187
+
188
+ #### - fetchPoiCategories
189
+
190
+ Gets all [POI categories](http://developers.situm.es/sdk_documentation/cordova/jsdoc/1.3.10/symbols/PoiCategory.html), download and cache their icons asynchronously.
191
+
192
+ ```javascript
193
+ fetchPoiCategories((poiCategories) => {
194
+ // Array of POI cateogires
195
+ }, (error) => {
196
+ // If errors will come here
197
+ });
198
+ ```
199
+
200
+ #### - fetchMapFromFloor
201
+
202
+ Downloads the map image of a [floor](http://developers.situm.es/sdk_documentation/cordova/jsdoc/1.3.10/symbols/Floor.html).
203
+
204
+ ```javascript
205
+ fetchMapFromFloor (floor, (mapImage) => {
206
+ // Map image as a bitmap
207
+ }, (error) => {
208
+ // If errors will come here
209
+ });
210
+ ```
211
+
212
+ #### - fetchPoiCategoryIconNormal
213
+
214
+ Gets the normal category icon for a [category](http://developers.situm.es/sdk_documentation/cordova/jsdoc/1.3.10/symbols/PoiCategory.html).
215
+
216
+ ```javascript
217
+ fetchPoiCategoryIconNormal (poiCategory, (iconNormal) => {
218
+ // Icon as a bitmap
219
+ }, (error) => {
220
+ // If errors will come here
221
+ });
222
+ ```
223
+
224
+ #### - fetchPoiCategoryIconSelected
225
+
226
+ Gets the selected category icon for a [category](http://developers.situm.es/sdk_documentation/cordova/jsdoc/1.3.10/symbols/PoiCategory.html).
227
+
228
+ ```javascript
229
+ fetchPoiCategoryIconSelected (poiCategory, (iconSelected) => {
230
+ // Icon as a bitmap
231
+ }, (error) => {
232
+ // If errors will come here
233
+ });
234
+ ```
235
+
236
+ #### - invalidateCache
237
+
238
+ Invalidates all the resources in the cache.
239
+
240
+ ```javascript
241
+ invalidateCache((response) => {});
242
+ ```
243
+ #### - requestDirections
244
+
245
+ Calculates a route between two [points](http://developers.situm.es/sdk_documentation/cordova/jsdoc/1.3.10/symbols/Point.html).
246
+
247
+ ```javascript
248
+ requestDirections([building, from, to], (route) => {
249
+ // Route Situm object
250
+ }, (error) => {
251
+ // If errors will come here
252
+ });
253
+ ```
254
+
255
+ #### - requestNavigationUpdates
256
+
257
+ Requests navigation updates. This method should be called after `requestDirections` in order to provide navigation updates when a new position is computed.
258
+
259
+ ```javascript
260
+ var navigationOptions = new Object();
261
+ navigationOptions.distanceToFloorChangeThreshold = 0; // number in meters
262
+ navigationOptions.distanceToChangeIndicationThreshold = 0; // number in meters
263
+ navigationOptions.distanceToGoalThreshold = 0; // number in meters
264
+ navigationOptions.outsideRouteThreshold = 0; // number in meters
265
+ navigationOptions.indicationsInterval = 0; // number in millis
266
+ navigationOptions.timeToFirstIndication = 0; // number in millis
267
+ navigationOptions.roundIndicationsStep = 0; // number in meters
268
+ navigationOptions.timeToIgnoreUnexpectedFloorChanges = 0; // number in millis
269
+ requestNavigationUpdates([navigationOptions], (res: any) => {
270
+ // Progress and other navigation status messages can be processed here
271
+ }, (error: any) => {
272
+ // If errors will come here
273
+ });
274
+ ```
275
+
276
+ #### - updateNavigationWithLocation
277
+
278
+ Updates navigation progress with a location, which would usually be provided by the [`startPositioning`](#--startpositioning) method. Returns progress and other navigation status messages. This method should be called after `requestNavigationUpdates`.
279
+
280
+ ```javascript
281
+ updateNavigationWithLocation([position], (result) => {
282
+ // Result
283
+ }, (error) => {
284
+ // If errors will come here
285
+ });
286
+ ```
287
+
288
+ #### - removeNavigationUpdates
289
+
290
+ Removes all location updates. This removes the internal state of the manager, including the listener provided in `requestNavigationUpdates`,so it won't receive more progress updates.
291
+
292
+ ```javascript
293
+ removeNavigationUpdates();
294
+ ```
295
+
296
+ ## License
297
+
298
+ Situm-Cordova-Plugin is licensed under [MIT License](https://opensource.org/licenses/MIT)
@@ -0,0 +1,23 @@
1
+ footer {
2
+ background-color: rgb(0,161,223);
3
+ }
4
+
5
+ footer > img {
6
+ display: none !important;
7
+ }
8
+
9
+ .main section article table td.name, .main section article table td.type, .main section article table td.attributes, .main section article table td.default {
10
+ max-width: 300px;
11
+ }
12
+
13
+ .lnb h3 {
14
+ color: rgb(0,161,223);
15
+ }
16
+
17
+ .main section article h3.subsection-title {
18
+ color: rgb(0,161,223);
19
+ }
20
+
21
+ #resizer {
22
+ background-color: rgb(0,161,223);
23
+ }
package/package.json ADDED
@@ -0,0 +1,60 @@
1
+ {
2
+ "name": "@situm/cordova",
3
+ "version": "3.0.0",
4
+ "description": "Set of utilities that allow any developer to build Cordova location based apps using Situm's indoor positioning system.",
5
+ "private": false,
6
+ "repository": "https://github.com/situmtech/cordova",
7
+ "author": "Situm Technologies <mobile@situm.com>",
8
+ "license": "MIT",
9
+ "bugs": {
10
+ "url": "https://github.com/situmtech/cordova/issues"
11
+ },
12
+ "homepage": "https://github.com/situmtech/cordova#readme",
13
+ "publishConfig": {
14
+ "registry": "https://registry.npmjs.org/"
15
+ },
16
+ "cordova": {
17
+ "id": "@situm/cordova",
18
+ "platforms": [
19
+ "android",
20
+ "ios"
21
+ ]
22
+ },
23
+ "keywords": [
24
+ "situm",
25
+ "indoor positioning",
26
+ "ecosystem:cordova",
27
+ "cordova-android",
28
+ "cordova-ios"
29
+ ],
30
+ "engines": [
31
+ {
32
+ "name": "cordova-android",
33
+ "version": ">=6.0.0"
34
+ }
35
+ ],
36
+ "dependencies": {
37
+ "cordova-common": "^2.2.5",
38
+ "describe": "^1.2.0",
39
+ "q": "^1.5.1",
40
+ "tui-jsdoc-template": "^1.2.2"
41
+ },
42
+ "scripts": {
43
+ "test": "cd tests/js && mocha",
44
+ "eslint": "node node_modules/eslint/bin/eslint www && node node_modules/eslint/bin/eslint src && node node_modules/eslint/bin/eslint tests",
45
+ "jsdoc": "rm -rf docs/JSDoc && ./node_modules/.bin/jsdoc www/android/situm.js www/android/Interfaces.js www/map-view.js www/map-view-controller.js -c ./docs/conf.json -d docs/JSDoc"
46
+ },
47
+ "devDependencies": {
48
+ "eslint": "^5.3.0",
49
+ "eslint-config-semistandard": "^11.0.0",
50
+ "eslint-config-standard": "^10.2.1",
51
+ "eslint-plugin-import": "^2.3.0",
52
+ "eslint-plugin-node": "^5.0.0",
53
+ "eslint-plugin-promise": "^3.5.0",
54
+ "eslint-plugin-standard": "^3.0.1",
55
+ "jsdoc": "^3.5.5",
56
+ "mocha": "^5.2.0",
57
+ "expect.js": "^0.3.1",
58
+ "jsdoc-toolkit": "0.0.2"
59
+ }
60
+ }
package/plugin.xml ADDED
@@ -0,0 +1,102 @@
1
+ <?xml version="1.0" encoding="UTF-8"?>
2
+
3
+ <plugin xmlns="http://apache.org/cordova/ns/plugins/1.0"
4
+ id="@situm/cordova"
5
+ version="3.0.0">
6
+ <name>Situm Cordova plugin Official</name>
7
+ <description>This is the stable branch.</description>
8
+ <license>MIT</license>
9
+ <keywords>situm, indoor positioning</keywords>
10
+ <repo>https://github.com/situmtech/situm-cordova-plugin.git</repo>
11
+ <issue>https://github.com/situmtech/situm-cordova-plugin/issues</issue>
12
+
13
+ <engines>
14
+ <engine name="cordova-android" version=">=10.0.0" />
15
+ </engines>
16
+
17
+ <js-module src="www/map-view.js" name="map-view">
18
+ <runs/>
19
+ <clobbers target="cordova.plugins.MapView" />
20
+ </js-module>
21
+
22
+ <js-module src="www/map-view-controller.js" name="map-view-controller">
23
+ <runs/>
24
+ <clobbers target="cordova.plugins.MapViewController" />
25
+ </js-module>
26
+
27
+ <!-- android -->
28
+ <platform name="android">
29
+ <js-module src="www/android/situm.js" name="situm">
30
+ <runs/>
31
+ <clobbers target="cordova.plugins.Situm" />
32
+ </js-module>
33
+
34
+ <framework src="src/android/situm.gradle" custom="true" type="gradleReference" />
35
+
36
+ <config-file target="res/xml/config.xml" parent="/*">
37
+ <feature name="Situm">
38
+ <param name="android-package" value="es.situm.plugin.SitumPlugin" />
39
+ <param name="onload" value="true" />
40
+ </feature>
41
+ </config-file>
42
+
43
+ <source-file src="src/android/app/src/main/java/es/situm/plugin/SitumPlugin.java" target-dir="src/es/situm/plugin" />
44
+ <source-file src="src/android/app/src/main/java/es/situm/plugin/PluginHelper.java" target-dir="src/es/situm/plugin" />
45
+ <source-file src="src/android/app/src/main/java/es/situm/plugin/SitumMapper.java" target-dir="src/es/situm/plugin" />
46
+ <source-file src="src/android/app/src/main/java/es/situm/plugin/DateUtils.java" target-dir="src/es/situm/plugin" />
47
+
48
+ </platform>
49
+
50
+ <!-- ios -->
51
+ <platform name="ios">
52
+ <js-module src="www/ios/situm.js" name="situm">
53
+ <runs/>
54
+ <clobbers target="cordova.plugins.Situm" />
55
+ </js-module>
56
+ <config-file target="config.xml" parent="/*">
57
+ <feature name="SitumPlugin">
58
+ <param name="ios-package" value="SitumPlugin" onload="true" />
59
+ </feature>
60
+ </config-file>
61
+
62
+ <config-file target="*-Info.plist" parent="NSLocationAlwaysUsageDescription">
63
+ <string>Location is required to find out where you are</string>
64
+ </config-file>
65
+ <config-file target="*-Info.plist" parent="NSLocationWhenInUseUsageDescription">
66
+ <string>Location is required to find out where you are</string>
67
+ </config-file>
68
+ <config-file target="*-Info.plist" parent="NSLocationUsageDescription">
69
+ <string>Location is required to find out where you are</string>
70
+ </config-file>
71
+
72
+ <framework src="CFNetwork.framework" />
73
+ <framework src="CoreData.framework" />
74
+ <framework src="UIKit.framework" />
75
+ <framework src="CoreLocation.framework" />
76
+ <framework src="CoreMotion.framework" />
77
+ <framework src="CoreBluetooth.framework" />
78
+ <framework src="Security.framework" />
79
+ <framework src="SystemConfiguration.framework"/>
80
+ <framework src="libz.dylib" />
81
+ <framework src="libc++.dylib" />
82
+
83
+ <podspec>
84
+ <config>
85
+ </config>
86
+ <pods use-frameworks="false">
87
+ <pod name="SitumSDK" spec="~> 3.3.0"/>
88
+ </pods>
89
+ </podspec>
90
+
91
+
92
+ <header-file src="src/ios/situmcordovaplugin/SitumPlugin.h" />
93
+ <header-file src="src/ios/situmcordovaplugin/SitumLocationWrapper.h" />
94
+ <header-file src="src/ios/situmcordovaplugin/Constants.h" />
95
+ <source-file src="src/ios/situmcordovaplugin/SitumPlugin.m" />
96
+ <source-file src="src/ios/situmcordovaplugin/SitumLocationWrapper.m" />
97
+ <source-file src="src/ios/situmcordovaplugin/Constants.m" />
98
+ <source-file src="src/ios/situmcordovaplugin/SITUtils.m" />
99
+ <source-file src="src/ios/situmcordovaplugin/SITUtils.h" />
100
+
101
+ </platform>
102
+ </plugin>
@@ -0,0 +1,22 @@
1
+ #!/usr/bin/env bash
2
+ # Copy the content from CHANGELOG_UNRELEASED.md to the top of CHANGELOG.md.
3
+ root_path=`git rev-parse --show-toplevel`
4
+ cd $root_path
5
+
6
+ if [ "$#" -ne 1 ]; then
7
+ echo >&2 "Error: illegal number of parameters"
8
+ echo "Usage: bash update_changelog.sh [RELEASE_VERSION]"
9
+ exit 1
10
+ fi
11
+
12
+ release_version=$1
13
+
14
+ #Remove all newlines at end of file
15
+ echo "$(awk '/^$/ {nlstack=nlstack "\n";next;} {printf "%s",nlstack; nlstack=""; print;}' CHANGELOG_UNRELEASED.md)" > CHANGELOG_UNRELEASED.md
16
+
17
+ sed -i -e '/---------/a \\n' CHANGELOG.md
18
+ sed -i -e '/---------/rCHANGELOG_UNRELEASED.md' CHANGELOG.md
19
+ sed -i -e "/---------/a ## [$release_version] - `date +%Y-%m-%d`\\n" CHANGELOG.md > CHANGELOG_UNRELEASED.md
20
+
21
+
22
+ git commit CHANGELOG.md CHANGELOG_UNRELEASED.md -m "Update CHANGELOG. (Commited by release script)" > /dev/null
@@ -0,0 +1,51 @@
1
+ apply plugin: 'com.android.application'
2
+
3
+ android {
4
+ compileSdkVersion 33
5
+ buildToolsVersion '30.0.3'
6
+ defaultConfig {
7
+ applicationId "es.plugin.situm"
8
+ minSdkVersion 22
9
+ targetSdkVersion 33
10
+ versionCode 1
11
+ versionName "1.0"
12
+ testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner"
13
+ }
14
+ buildTypes {
15
+ release {
16
+ minifyEnabled false
17
+ proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
18
+ }
19
+ }
20
+ testOptions {
21
+ unitTests.returnDefaultValues = true
22
+ }
23
+ compileOptions {
24
+ sourceCompatibility 1.8
25
+ targetCompatibility 1.8
26
+ }
27
+ }
28
+
29
+ dependencies {
30
+ implementation fileTree(include: ['*.jar'], dir: 'libs')
31
+
32
+ // Core library
33
+ androidTestImplementation 'androidx.test:core:1.4.0'
34
+ androidTestImplementation 'androidx.test:runner:1.4.0'
35
+ androidTestImplementation 'androidx.test.espresso:espresso-core:3.4.0'
36
+ androidTestImplementation 'androidx.test.espresso:espresso-web:3.4.0'
37
+
38
+ testImplementation 'junit:junit:4.12'
39
+ testImplementation 'org.json:json:20140107'
40
+ testImplementation "com.google.truth:truth:0.42"
41
+
42
+ implementation "androidx.appcompat:appcompat:1.3.1"
43
+
44
+ implementation ('com.googlecode.json-simple:json-simple:1.1.1'){
45
+ exclude group: 'junit', module:'junit'
46
+ }
47
+ implementation ('es.situm:situm-sdk:3.7.0@aar') {
48
+ transitive = true
49
+ }
50
+ implementation 'org.apache.cordova:framework:10.1.1'
51
+ }
@@ -0,0 +1,21 @@
1
+ # Add project specific ProGuard rules here.
2
+ # You can control the set of applied configuration files using the
3
+ # proguardFiles setting in build.gradle.
4
+ #
5
+ # For more details, see
6
+ # http://developer.android.com/guide/developing/tools/proguard.html
7
+
8
+ # If your project uses WebView with JS, uncomment the following
9
+ # and specify the fully qualified class name to the JavaScript interface
10
+ # class:
11
+ #-keepclassmembers class fqcn.of.javascript.interface.for.webview {
12
+ # public *;
13
+ #}
14
+
15
+ # Uncomment this to preserve the line number information for
16
+ # debugging stack traces.
17
+ #-keepattributes SourceFile,LineNumberTable
18
+
19
+ # If you keep the line number information, uncomment this to
20
+ # hide the original source file name.
21
+ #-renamesourcefileattribute SourceFile
@@ -0,0 +1,11 @@
1
+ <manifest xmlns:android="http://schemas.android.com/apk/res/android"
2
+ package="es.plugin.situm">
3
+
4
+ <application
5
+ android:allowBackup="true"
6
+ android:icon="@mipmap/ic_launcher"
7
+ android:label="@string/app_name"
8
+ android:roundIcon="@mipmap/ic_launcher_round"
9
+ android:supportsRtl="true"
10
+ android:theme="@style/AppTheme" />
11
+ </manifest>
@@ -0,0 +1,15 @@
1
+ package es.situm.plugin;
2
+
3
+ import java.text.DateFormat;
4
+ import java.text.SimpleDateFormat;
5
+ import java.util.Locale;
6
+ import java.util.TimeZone;
7
+
8
+ public class DateUtils {
9
+ public static final DateFormat dateFormat;
10
+
11
+ static {
12
+ dateFormat = new SimpleDateFormat("E MMM dd HH:mm:ss Z yyyy", Locale.US);
13
+ dateFormat.setTimeZone(TimeZone.getTimeZone("UTC"));
14
+ }
15
+ }