From ca6ce85dd10a00c3aa68bc0e179626dc73a28966 Mon Sep 17 00:00:00 2001 From: Marcus Handte Date: Mon, 22 Jul 2019 12:36:04 +0200 Subject: [PATCH] Switch build system to gradle. Update wildfly to latest version. Update android project to latest version. Add support for Java 11. --- .gitignore | 6 +- Jenkinsfile | 41 + android-app/build.gradle | 42 + {android/app => android-app}/pom.xml | 16 +- .../app => android-app}/project.properties | 0 .../src/main/AndroidManifest.xml | 7 +- .../src/main/assets/incoming_marker.png | Bin .../src/main/assets/marker_dark.png | Bin .../src/main/assets/marker_normal.png | Bin .../src/main/assets/marker_pin.png | Bin .../src/main/assets/marker_shadow.png | Bin .../src/main/assets/terms.html | 0 .../src/main/icons/logos.cdr | Bin .../maptology/android/app/BootReceiver.java | 0 .../android/app/LocationService.java | 0 .../maptology/android/app/LoginActivity.java | 0 .../maptology/android/app/MainActivity.java | 0 .../maptology/android/app/MaptologyApp.java | 0 .../maptology/android/app/NoticeReceiver.java | 0 .../maptology/android/app/StartActivity.java | 0 .../maptology/android/app/UploadService.java | 0 .../app/adapter/AlertDialogAdapter.java | 0 .../android/app/adapter/DetailViewHolder.java | 1 - .../android/app/adapter/GrantAdapter.java | 0 .../android/app/adapter/NoticeAdapter.java | 0 .../android/app/adapter/ShareAdapter.java | 0 .../app/fragment/AbstractFragment.java | 0 .../app/fragment/DatePickerFragment.java | 0 .../android/app/fragment/DetailFragment.java | 0 .../app/fragment/DetailPagerFragment.java | 0 .../app/fragment/GrantListFragment.java | 2 - .../android/app/fragment/LoginFragment.java | 0 .../android/app/fragment/LogoFragment.java | 50 +- .../android/app/fragment/ManageFragment.java | 0 .../android/app/fragment/MapFragment.java | 24 +- .../app/fragment/NoticeListFragment.java | 0 .../app/fragment/SettingsFragment.java | 0 .../android/app/fragment/ShareFragment.java | 0 .../app/fragment/ShareListFragment.java | 0 .../android/app/fragment/TermsFragment.java | 0 .../app/fragment/TimePickerFragment.java | 0 .../app/location/LocationContract.java | 0 .../android/app/location/LocationHelper.java | 0 .../android/app/location/LocationState.java | 0 .../android/app/location/LocationStore.java | 0 .../android/app/map/IconManager.java | 6 +- .../maptology/android/app/map/MapMode.java | 0 .../maptology/android/app/map/MapState.java | 4 +- .../maptology/android/app/model/Grant.java | 0 .../android/app/model/LocalMessage.java | 0 .../android/app/model/LocalNotice.java | 0 .../android/app/model/LocalShare.java | 0 .../android/app/model/ModelUtils.java | 0 .../maptology/android/app/model/Network.java | 0 .../maptology/android/app/model/Position.java | 0 .../android/app/notice/NoticeContract.java | 0 .../android/app/notice/NoticeHelper.java | 0 .../android/app/notice/NoticeStore.java | 0 .../android/app/repository/AsyncError.java | 0 .../app/repository/AsyncInteraction.java | 0 .../app/repository/IValueListener.java | 0 .../app/repository/JacksonSerializer.java | 0 .../android/app/repository/LocationValue.java | 0 .../app/repository/PersistentValue.java | 0 .../android/app/repository/Repository.java | 0 .../android/app/repository/Serializer.java | 0 .../android/app/repository/Value.java | 0 .../android/app/share/ShareContract.java | 0 .../android/app/share/ShareHelper.java | 0 .../android/app/share/ShareStore.java | 0 .../android/app/task/AbstractApiTask.java | 0 .../android/app/task/CreateDeviceTask.java | 0 .../android/app/task/CreateShareTask.java | 0 .../android/app/task/DeleteShareTask.java | 0 .../android/app/task/SaveShareTask.java | 0 .../android/app/task/SyncNoticeTask.java | 0 .../android/app/task/UpdateGrantsTask.java | 0 .../android/app/task/UpdateUserTask.java | 0 .../android/app/task/UploadLocationTask.java | 0 .../android/app/util/ActionUtil.java | 0 .../android/app/util/ColoredSnackbar.java | 0 .../android/app/util/DateFormatter.java | 0 .../android/app/util/TabletUtil.java | 0 .../src/main/key/maptology.jks | Bin .../res/drawable-hdpi/ic_add_white_24dp.png | Bin .../drawable-hdpi/ic_alarm_off_black_48dp.png | Bin .../drawable-hdpi/ic_all_out_white_24dp.png | Bin .../drawable-hdpi/ic_call_made_white_24dp.png | Bin .../ic_call_received_white_24dp.png | Bin .../ic_card_travel_black_24dp.png | Bin .../ic_chat_bubble_outline_black_24dp.png | Bin .../res/drawable-hdpi/ic_check_black_24dp.png | Bin .../ic_content_copy_black_24dp.png | Bin .../drawable-hdpi/ic_delete_black_24dp.png | Bin .../ic_delete_sweep_white_24dp.png | Bin .../drawable-hdpi/ic_delete_white_24dp.png | Bin .../drawable-hdpi/ic_gps_fixed_black_24dp.png | Bin .../ic_gps_not_fixed_black_24dp.png | Bin .../ic_gps_not_fixed_black_48dp.png | Bin .../ic_import_export_black_24dp.png | Bin .../drawable-hdpi/ic_launch_black_24dp.png | Bin .../res/drawable-hdpi/ic_link_black_24dp.png | Bin .../ic_location_on_black_48dp.png | Bin .../ic_lock_outline_black_24dp.png | Bin .../res/drawable-hdpi/ic_map_black_24dp.png | Bin .../drawable-hdpi/ic_message_black_24dp.png | Bin .../ic_my_location_white_24dp.png | Bin .../ic_open_in_browser_black_24dp.png | Bin .../res/drawable-hdpi/ic_pause_black_48dp.png | Bin .../ic_perm_identity_black_24dp.png | Bin .../res/drawable-hdpi/ic_place_white_24dp.png | Bin .../res/drawable-hdpi/ic_save_black_24dp.png | Bin .../drawable-hdpi/ic_settings_black_24dp.png | Bin .../res/drawable-hdpi/ic_share_black_24dp.png | Bin .../res/drawable-hdpi/ic_share_black_48dp.png | Bin .../drawable-hdpi/ic_update_black_24dp.png | Bin .../drawable-hdpi/ic_update_white_24dp.png | Bin .../ic_visibility_off_black_48dp.png | Bin .../drawable-hdpi/ic_zoom_in_white_24dp.png | Bin .../ic_zoom_out_map_white_24dp.png | Bin .../drawable-hdpi/ic_zoom_out_white_24dp.png | Bin .../res/drawable-mdpi/ic_add_white_24dp.png | Bin .../drawable-mdpi/ic_alarm_off_black_48dp.png | Bin .../drawable-mdpi/ic_all_out_white_24dp.png | Bin .../drawable-mdpi/ic_call_made_white_24dp.png | Bin .../ic_call_received_white_24dp.png | Bin .../ic_card_travel_black_24dp.png | Bin .../ic_chat_bubble_outline_black_24dp.png | Bin .../res/drawable-mdpi/ic_check_black_24dp.png | Bin .../ic_content_copy_black_24dp.png | Bin .../drawable-mdpi/ic_delete_black_24dp.png | Bin .../ic_delete_sweep_white_24dp.png | Bin .../drawable-mdpi/ic_delete_white_24dp.png | Bin .../drawable-mdpi/ic_gps_fixed_black_24dp.png | Bin .../ic_gps_not_fixed_black_24dp.png | Bin .../ic_gps_not_fixed_black_48dp.png | Bin .../ic_import_export_black_24dp.png | Bin .../drawable-mdpi/ic_launch_black_24dp.png | Bin .../res/drawable-mdpi/ic_link_black_24dp.png | Bin .../ic_location_on_black_48dp.png | Bin .../ic_lock_outline_black_24dp.png | Bin .../res/drawable-mdpi/ic_map_black_24dp.png | Bin .../drawable-mdpi/ic_message_black_24dp.png | Bin .../ic_my_location_white_24dp.png | Bin .../ic_open_in_browser_black_24dp.png | Bin .../res/drawable-mdpi/ic_pause_black_48dp.png | Bin .../ic_perm_identity_black_24dp.png | Bin .../res/drawable-mdpi/ic_place_white_24dp.png | Bin .../res/drawable-mdpi/ic_save_black_24dp.png | Bin .../drawable-mdpi/ic_settings_black_24dp.png | Bin .../res/drawable-mdpi/ic_share_black_24dp.png | Bin .../res/drawable-mdpi/ic_share_black_48dp.png | Bin .../drawable-mdpi/ic_update_black_24dp.png | Bin .../drawable-mdpi/ic_update_white_24dp.png | Bin .../ic_visibility_off_black_48dp.png | Bin .../drawable-mdpi/ic_zoom_in_white_24dp.png | Bin .../ic_zoom_out_map_white_24dp.png | Bin .../drawable-mdpi/ic_zoom_out_white_24dp.png | Bin .../res/drawable-xhdpi/ic_add_white_24dp.png | Bin .../ic_alarm_off_black_48dp.png | Bin .../drawable-xhdpi/ic_all_out_white_24dp.png | Bin .../ic_call_made_white_24dp.png | Bin .../ic_call_received_white_24dp.png | Bin .../ic_card_travel_black_24dp.png | Bin .../ic_chat_bubble_outline_black_24dp.png | Bin .../drawable-xhdpi/ic_check_black_24dp.png | Bin .../ic_content_copy_black_24dp.png | Bin .../drawable-xhdpi/ic_delete_black_24dp.png | Bin .../ic_delete_sweep_white_24dp.png | Bin .../drawable-xhdpi/ic_delete_white_24dp.png | Bin .../ic_gps_fixed_black_24dp.png | Bin .../ic_gps_not_fixed_black_24dp.png | Bin .../ic_gps_not_fixed_black_48dp.png | Bin .../ic_import_export_black_24dp.png | Bin .../drawable-xhdpi/ic_launch_black_24dp.png | Bin .../res/drawable-xhdpi/ic_link_black_24dp.png | Bin .../ic_location_on_black_48dp.png | Bin .../ic_lock_outline_black_24dp.png | Bin .../res/drawable-xhdpi/ic_map_black_24dp.png | Bin .../drawable-xhdpi/ic_message_black_24dp.png | Bin .../ic_my_location_white_24dp.png | Bin .../ic_open_in_browser_black_24dp.png | Bin .../drawable-xhdpi/ic_pause_black_48dp.png | Bin .../ic_perm_identity_black_24dp.png | Bin .../drawable-xhdpi/ic_place_white_24dp.png | Bin .../res/drawable-xhdpi/ic_save_black_24dp.png | Bin .../drawable-xhdpi/ic_settings_black_24dp.png | Bin .../drawable-xhdpi/ic_share_black_24dp.png | Bin .../drawable-xhdpi/ic_share_black_48dp.png | Bin .../drawable-xhdpi/ic_update_black_24dp.png | Bin .../drawable-xhdpi/ic_update_white_24dp.png | Bin .../ic_visibility_off_black_48dp.png | Bin .../drawable-xhdpi/ic_zoom_in_white_24dp.png | Bin .../ic_zoom_out_map_white_24dp.png | Bin .../drawable-xhdpi/ic_zoom_out_white_24dp.png | Bin .../res/drawable-xxhdpi/ic_add_white_24dp.png | Bin .../ic_alarm_off_black_48dp.png | Bin .../drawable-xxhdpi/ic_all_out_white_24dp.png | Bin .../ic_call_made_white_24dp.png | Bin .../ic_call_received_white_24dp.png | Bin .../ic_card_travel_black_24dp.png | Bin .../ic_chat_bubble_outline_black_24dp.png | Bin .../drawable-xxhdpi/ic_check_black_24dp.png | Bin .../ic_content_copy_black_24dp.png | Bin .../drawable-xxhdpi/ic_delete_black_24dp.png | Bin .../ic_delete_sweep_white_24dp.png | Bin .../drawable-xxhdpi/ic_delete_white_24dp.png | Bin .../ic_gps_fixed_black_24dp.png | Bin .../ic_gps_not_fixed_black_24dp.png | Bin .../ic_gps_not_fixed_black_48dp.png | Bin .../ic_import_export_black_24dp.png | Bin .../drawable-xxhdpi/ic_launch_black_24dp.png | Bin .../drawable-xxhdpi/ic_link_black_24dp.png | Bin .../ic_location_on_black_48dp.png | Bin .../ic_lock_outline_black_24dp.png | Bin .../res/drawable-xxhdpi/ic_map_black_24dp.png | Bin .../drawable-xxhdpi/ic_message_black_24dp.png | Bin .../ic_my_location_white_24dp.png | Bin .../ic_open_in_browser_black_24dp.png | Bin .../drawable-xxhdpi/ic_pause_black_48dp.png | Bin .../ic_perm_identity_black_24dp.png | Bin .../drawable-xxhdpi/ic_place_white_24dp.png | Bin .../drawable-xxhdpi/ic_save_black_24dp.png | Bin .../ic_settings_black_24dp.png | Bin .../drawable-xxhdpi/ic_share_black_24dp.png | Bin .../drawable-xxhdpi/ic_share_black_48dp.png | Bin .../drawable-xxhdpi/ic_update_black_24dp.png | Bin .../drawable-xxhdpi/ic_update_white_24dp.png | Bin .../ic_visibility_off_black_48dp.png | Bin .../drawable-xxhdpi/ic_zoom_in_white_24dp.png | Bin .../ic_zoom_out_map_white_24dp.png | Bin .../ic_zoom_out_white_24dp.png | Bin .../main/res/drawable-xxhdpi/icon_header.png | Bin .../res/drawable-xxhdpi/icon_launch_map.png | Bin .../drawable-xxhdpi/icon_launch_person.png | Bin .../res/drawable-xxhdpi/icon_launch_text.png | Bin .../res/drawable-xxhdpi/icon_launcher.png | Bin .../icon_notification_small.png | Bin .../ic_access_time_black_24dp.png | Bin .../ic_accessibility_black_24dp.png | Bin .../drawable-xxxhdpi/ic_add_white_24dp.png | Bin .../ic_alarm_off_black_48dp.png | Bin .../ic_all_out_white_24dp.png | Bin .../ic_call_made_white_24dp.png | Bin .../ic_call_received_white_24dp.png | Bin .../ic_card_travel_black_24dp.png | Bin .../ic_chat_bubble_outline_black_24dp.png | Bin .../drawable-xxxhdpi/ic_check_black_24dp.png | Bin .../ic_content_copy_black_24dp.png | Bin .../drawable-xxxhdpi/ic_delete_black_24dp.png | Bin .../ic_delete_sweep_white_24dp.png | Bin .../drawable-xxxhdpi/ic_delete_white_24dp.png | Bin .../ic_gps_fixed_black_24dp.png | Bin .../ic_gps_not_fixed_black_24dp.png | Bin .../ic_gps_not_fixed_black_48dp.png | Bin .../ic_import_export_black_24dp.png | Bin .../drawable-xxxhdpi/ic_launch_black_24dp.png | Bin .../drawable-xxxhdpi/ic_link_black_24dp.png | Bin .../ic_location_on_black_48dp.png | Bin .../ic_lock_outline_black_24dp.png | Bin .../drawable-xxxhdpi/ic_map_black_24dp.png | Bin .../ic_message_black_24dp.png | Bin .../ic_my_location_white_24dp.png | Bin .../ic_open_in_browser_black_24dp.png | Bin .../drawable-xxxhdpi/ic_pause_black_48dp.png | Bin .../ic_perm_identity_black_24dp.png | Bin .../drawable-xxxhdpi/ic_place_white_24dp.png | Bin .../drawable-xxxhdpi/ic_save_black_24dp.png | Bin .../ic_settings_black_24dp.png | Bin .../drawable-xxxhdpi/ic_share_black_24dp.png | Bin .../drawable-xxxhdpi/ic_share_black_48dp.png | Bin .../drawable-xxxhdpi/ic_update_black_24dp.png | Bin .../drawable-xxxhdpi/ic_update_white_24dp.png | Bin .../ic_visibility_off_black_48dp.png | Bin .../ic_zoom_in_white_24dp.png | Bin .../ic_zoom_out_map_white_24dp.png | Bin .../ic_zoom_out_white_24dp.png | Bin .../main/res/drawable/bg_launch_gradient.xml | 0 .../src/main/res/layout/activity_login.xml | 0 .../main/res/layout/activity_main_default.xml | 0 .../main/res/layout/activity_main_tablet.xml | 0 .../src/main/res/layout/activity_start.xml | 26 +- .../src/main/res/layout/fragment_detail.xml | 0 .../main/res/layout/fragment_detail_pager.xml | 0 .../main/res/layout/fragment_list_grant.xml | 0 .../main/res/layout/fragment_list_notice.xml | 0 .../main/res/layout/fragment_list_share.xml | 0 .../src/main/res/layout/fragment_login.xml | 0 .../src/main/res/layout/fragment_logo.xml | 0 .../src/main/res/layout/fragment_manage.xml | 0 .../src/main/res/layout/fragment_map.xml | 0 .../src/main/res/layout/fragment_share.xml | 0 .../src/main/res/layout/fragment_terms.xml | 0 .../src/main/res/layout/view_alert_dialog.xml | 0 .../src/main/res/layout/view_detail_card.xml | 0 .../src/main/res/layout/view_detail_plain.xml | 0 .../main/res/layout/view_drawer_header.xml | 0 .../src/main/res/layout/view_manage_tab.xml | 0 .../src/main/res/layout/view_notice.xml | 0 .../src/main/res/menu/menu_drawer.xml | 0 .../src/main/res/menu/menu_grant.xml | 0 .../src/main/res/menu/menu_map.xml | 0 .../src/main/res/menu/menu_notice.xml | 0 .../src/main/res/menu/menu_share.xml | 0 .../src/main/res/values-de/strings.xml | 0 .../src/main/res/values/colors.xml | 0 .../src/main/res/values/dimens.xml | 0 .../src/main/res/values/generic.xml | 0 .../src/main/res/values/strings.xml | 0 .../src/main/res/values/styles.xml | 0 .../src/main/res/values/themes.xml | 0 .../src/main/res/xml/backup.xml | 0 .../src/main/res/xml/settings.xml | 0 .../android/content/pm/ShortcutManager.java | 0 .../android/app/test/MainActivityTest.java | 2 + .../android/app/test/StartActivityTest.java | 2 + .../app/test/location/LocationStoreTest.java | 2 + .../app/test/notice/NoticeFragmentTest.java | 2 + .../app/test/notice/NoticeStoreTest.java | 2 + .../app/test/notice/NoticeSyncTest.java | 5 +- .../app/test/util/AppConfiguration.java | 0 .../app/test/util/FragmentActivity.java | 0 .../android/app/test/util/ProxyGenerator.java | 0 .../src/test/resources/robolectric.properties | 0 android-feign/build.gradle | 50 + {android/feign => android-feign}/pom.xml | 15 +- .../maptology/android/feign/ApiClient.java | 0 .../android/feign/EncodingUtils.java | 0 .../android/feign/ParamExpander.java | 0 .../android/feign/RFC3339DateFormat.java | 0 .../maptology/android/feign/StringUtil.java | 0 .../android/feign/auth/ApiKeyAuth.java | 0 .../android/feign/auth/HttpBasicAuth.java | 0 .../maptology/android/feign/auth/OAuth.java | 0 .../android/feign/auth/OAuthFlow.java | 0 android/leafless/pom.xml | 61 - android/leafless/src/main/AndroidManifest.xml | 6 - .../android/leafless/AbstractElement.java | 306 - .../leafless/AbstractMovableElement.java | 53 - .../leafless/AccessibleComparator.java | 73 - .../android/leafless/AccessibleMapView.java | 212 - .../leafless/AccessibleMapViewHelper.java | 157 - .../capi/android/leafless/ElementFilter.java | 57 - .../capi/android/leafless/ElementOptions.java | 35 - .../android/leafless/FixedElementOptions.java | 37 - .../android/leafless/IListenerBundle.java | 28 - .../capi/android/leafless/ILoadable.java | 16 - .../capi/android/leafless/ILoader.java | 32 - .../capi/android/leafless/IMapListener.java | 19 - .../android/leafless/IMapStateListener.java | 11 - .../capi/android/leafless/IMoveListener.java | 10 - .../capi/android/leafless/ITouchListener.java | 11 - .../android/leafless/IdentifierGenerator.java | 63 - .../android/leafless/InterimRotation.java | 71 - .../capi/android/leafless/ListenerBundle.java | 55 - .../capi/android/leafless/MapEvent.java | 36 - .../capi/android/leafless/MapOptions.java | 96 - .../capi/android/leafless/MapPoint.java | 98 - .../capi/android/leafless/MapProjection.java | 82 - .../capi/android/leafless/MapStateEvent.java | 95 - .../capi/android/leafless/MapView.java | 944 --- .../capi/android/leafless/MapViewState.java | 433 -- .../capi/android/leafless/MoveEvent.java | 85 - .../capi/android/leafless/TouchEvent.java | 54 - .../leafless/cache/AbstractCreator.java | 32 - .../capi/android/leafless/cache/Cache.java | 174 - .../leafless/cache/CacheConfiguration.java | 56 - .../android/leafless/cache/CacheContract.java | 90 - .../android/leafless/cache/CacheHelper.java | 73 - .../leafless/cache/CacheObjectLoader.java | 314 - .../android/leafless/cache/CacheRequest.java | 43 - .../leafless/cache/IObjectFactory.java | 50 - .../leafless/cache/IObjectRequest.java | 32 - .../capi/android/leafless/circle/Circle.java | 214 - .../leafless/circle/CircleOptions.java | 63 - .../android/leafless/circle/CircleUnit.java | 22 - .../leafless/control/AbstractControl.java | 144 - .../leafless/control/CompassControl.java | 110 - .../control/CompassControlOptions.java | 44 - .../leafless/control/ControlOptions.java | 43 - .../leafless/geojson/GeojsonLoader.java | 142 - .../android/leafless/geojson/IGeojson.java | 20 - .../leafless/geojson/IGeojsonLoader.java | 12 - .../capi/android/leafless/icon/Icon.java | 52 - .../capi/android/leafless/icon/IconImage.java | 99 - .../android/leafless/icon/IconOptions.java | 65 - .../capi/android/leafless/image/IImage.java | 20 - .../android/leafless/image/IImageLoader.java | 12 - .../android/leafless/image/ImageLoader.java | 147 - .../android/leafless/layer/AbstractLayer.java | 41 - .../android/leafless/layer/LayerOptions.java | 60 - .../capi/android/leafless/marker/Marker.java | 253 - .../leafless/marker/MarkerOptions.java | 51 - .../leafless/marker/RotatedMarker.java | 145 - .../leafless/marker/RotatedMarkerOptions.java | 46 - .../android/leafless/polyline/Polyline.java | 186 - .../leafless/polyline/PolylineClipper.java | 125 - .../leafless/polyline/PolylineOptions.java | 67 - .../capi/android/leafless/tile/TileImage.java | 159 - .../capi/android/leafless/tile/TileLayer.java | 152 - .../leafless/tile/TileLayerOptions.java | 29 - .../leafless/touch/BasicRecognizer.java | 408 - .../leafless/touch/DoubleTapRecognizer.java | 195 - .../android/leafless/touch/IBasicView.java | 80 - .../leafless/touch/IDoubleTapView.java | 28 - .../leafless/touch/IMovableTarget.java | 18 - .../android/leafless/touch/IRecognizer.java | 20 - .../capi/android/leafless/touch/Pointer.java | 77 - .../android/leafless/vector/VectorLayer.java | 135 - .../leafless/vector/VectorLayerOptions.java | 31 - .../android/leafless/vector/VectorTile.java | 160 - android/pom.xml | 110 - build.gradle | 84 + common-api/build.gradle | 82 + {api => common-api}/pom.xml | 10 +- .../main/java/com/maptology/api/Entity.java | 0 .../src/main/java/com/maptology/api/Page.java | 0 .../java/com/maptology/api/PageConfig.java | 0 .../src/main/java/com/maptology/api/Tags.java | 0 .../maptology/api/access/Authorizations.java | 0 .../java/com/maptology/api/access/Roles.java | 0 .../maptology/api/access/package-info.java | 0 .../java/com/maptology/api/device/Device.java | 0 .../maptology/api/device/DeviceHandle.java | 0 .../com/maptology/api/device/DeviceInfo.java | 0 .../com/maptology/api/device/DevicePage.java | 0 .../maptology/api/device/IDeviceService.java | 0 .../maptology/api/device/OperatingSystem.java | 0 .../maptology/api/device/package-info.java | 0 .../api/history/IHistoryService.java | 0 .../java/com/maptology/api/history/Place.java | 0 .../com/maptology/api/history/PlacePage.java | 0 .../java/com/maptology/api/history/Visit.java | 0 .../com/maptology/api/history/VisitPage.java | 0 .../maptology/api/history/package-info.java | 0 .../maptology/api/location/Availability.java | 0 .../maptology/api/location/Coordinate.java | 0 .../api/location/DetailedLocation.java | 0 .../api/location/ILocationService.java | 0 .../com/maptology/api/location/Location.java | 0 .../api/location/LocationUpdate.java | 0 .../com/maptology/api/location/Position.java | 0 .../maptology/api/location/PositionPage.java | 0 .../api/location/ReleasedLocation.java | 0 .../maptology/api/location/package-info.java | 0 .../maptology/api/log/EntityStatistic.java | 0 .../com/maptology/api/log/ILogService.java | 0 .../com/maptology/api/log/LoadStatistic.java | 0 .../com/maptology/api/log/LogMessage.java | 0 .../maptology/api/log/SystemStatistic.java | 0 .../com/maptology/api/log/package-info.java | 0 .../maptology/api/notice/INoticeService.java | 0 .../com/maptology/api/notice/Language.java | 0 .../com/maptology/api/notice/Message.java | 0 .../java/com/maptology/api/notice/Notice.java | 0 .../com/maptology/api/notice/NoticePage.java | 0 .../maptology/api/notice/package-info.java | 0 .../java/com/maptology/api/package-info.java | 0 .../api/privilege/IPrivilegeService.java | 0 .../maptology/api/privilege/Privilege.java | 0 .../api/privilege/PrivilegePage.java | 0 .../maptology/api/privilege/package-info.java | 0 .../maptology/api/share/IShareService.java | 0 .../java/com/maptology/api/share/Share.java | 0 .../com/maptology/api/share/ShareInfo.java | 0 .../com/maptology/api/share/SharePage.java | 0 .../com/maptology/api/share/package-info.java | 0 .../java/com/maptology/api/user/Email.java | 0 .../com/maptology/api/user/IUserService.java | 0 .../java/com/maptology/api/user/User.java | 0 .../java/com/maptology/api/user/UserPage.java | 0 .../com/maptology/api/user/UserPassword.java | 0 .../maptology/api/user/UserRegistration.java | 0 .../com/maptology/api/user/package-info.java | 0 .../maptology/api/validation/EmailGroup.java | 0 .../api/validation/EmailGroupValidator.java | 0 .../api/validation/package-info.java | 0 .../maptology/api/version/BuildVersion.java | 0 .../api/version/IVersionService.java | 0 .../maptology/api/version/package-info.java | 0 .../src/main/resources/security-admin.json | 0 .../src/main/resources/security-device.json | 0 .../src/main/resources/security-user.json | 0 .../maptology/api/test/unit/NoticeTest.java | 0 .../maptology/api/test/unit/package-info.java | 0 .../wrapper/gradle-wrapper.properties | 4 +- testing/api-client/gradlew => gradlew | 116 +- testing/api-client/gradlew.bat => gradlew.bat | 28 +- local.properties | 8 + pom.xml | 147 +- service-ejb/build.gradle | 19 + {service/ejb => service-ejb}/pom.xml | 16 +- .../service/conversion/AbstractConverter.java | 0 .../conversion/AbstractDeviceConverter.java | 0 .../conversion/AbstractEntityConverter.java | 0 .../service/conversion/DeviceConverter.java | 0 .../conversion/DeviceHandleConverter.java | 0 .../service/conversion/EmailConverter.java | 0 .../service/conversion/IConverter.java | 0 .../service/conversion/LocationConverter.java | 0 .../service/conversion/MessageConverter.java | 0 .../service/conversion/NoticeConverter.java | 0 .../service/conversion/PlaceConverter.java | 0 .../service/conversion/PositionConverter.java | 0 .../conversion/PrivilegeConverter.java | 0 .../service/conversion/ShareConverter.java | 0 .../conversion/ShareInfoConverter.java | 0 .../service/conversion/UserConverter.java | 0 .../service/conversion/VisitConverter.java | 0 .../service/conversion/package-info.java | 0 .../service/crypto/SecureException.java | 0 .../maptology/service/crypto/SecureHash.java | 0 .../maptology/service/crypto/SecureToken.java | 0 .../maptology/service/crypto/TokenType.java | 0 .../service/crypto/package-info.java | 0 .../service/entity/AbstractEntity.java | 0 .../entity/AbstractUserSpecificEntity.java | 0 .../maptology/service/entity/CodeEntity.java | 0 .../maptology/service/entity/CodeType.java | 0 .../service/entity/DeviceEntity.java | 0 .../maptology/service/entity/EmailEntity.java | 0 .../service/entity/EmbeddedCoordinate.java | 0 .../service/entity/EmbeddedMessage.java | 0 .../entity/EntityConflictException.java | 0 .../service/entity/EntityException.java | 0 .../entity/EntityForbiddenException.java | 0 .../entity/EntityNotFoundException.java | 0 .../service/entity/LocationEntity.java | 0 .../service/entity/NoticeEntity.java | 0 .../service/entity/OrderCriterion.java | 0 .../maptology/service/entity/PlaceEntity.java | 0 .../service/entity/PositionEntity.java | 0 .../service/entity/PrivilegeEntity.java | 0 .../maptology/service/entity/RoleEntity.java | 0 .../maptology/service/entity/ShareEntity.java | 0 .../maptology/service/entity/UserEntity.java | 0 .../maptology/service/entity/VisitEntity.java | 0 .../service/entity/package-info.java | 0 .../service/injection/Datasources.java | 0 .../maptology/service/injection/Loggers.java | 0 .../maptology/service/injection/Public.java | 0 .../maptology/service/injection/Sessions.java | 0 .../service/injection/package-info.java | 0 .../service/principal/LoginManager.java | 0 .../service/principal/MaptologyPrincipal.java | 0 .../session/AbstractPrincipalSessionBean.java | 0 .../service/session/AbstractSessionBean.java | 0 .../AbstractUserSpecificSessionBean.java | 0 .../service/session/DataSessionBean.java | 0 .../service/session/DebugDataSessionBean.java | 0 .../session/DebugEmailSessionBean.java | 0 .../session/DebugPositionSessionBean.java | 0 .../service/session/DeviceSessionBean.java | 0 .../service/session/EmailSessionBean.java | 0 .../service/session/GeocoderSessionBean.java | 0 .../service/session/IDataSessionBean.java | 0 .../session/IDebugEmailSessionBean.java | 0 .../service/session/IEmailSessionBean.java | 0 .../service/session/IPositionSessionBean.java | 0 .../service/session/LocationSessionBean.java | 0 .../service/session/LogSessionBean.java | 0 .../service/session/NoticeSessionBean.java | 0 .../service/session/PlaceSessionBean.java | 0 .../service/session/PositionSessionBean.java | 0 .../service/session/PrivilegeSessionBean.java | 0 .../service/session/ShareSessionBean.java | 0 .../service/session/StartupBean.java | 0 .../session/StatisticsSessionBean.java | 0 .../service/session/UserSessionBean.java | 0 .../service/session/VersionSessionBean.java | 0 .../service/session/VisitSessionBean.java | 0 .../service/session/package-info.java | 0 .../service/template/EmailAssignment.java | 0 .../service/template/EmailMessage.java | 0 .../service/template/EmailTemplate.java | 0 .../maptology/service/template/Template.java | 0 .../service/template/package-info.java | 0 .../src/main/resources/META-INF/beans.xml | 0 .../main/resources/META-INF/jboss-ejb3.xml | 0 .../main/resources/META-INF/persistence.xml | 0 .../src/main/resources/emails/new-email.txt | 0 .../src/main/resources/emails/new-user.txt | 0 .../src/main/resources/emails/reset-user.txt | 0 .../maptology/service/test/EjbDeployment.java | 0 .../service/test/login/LoginModule.java | 0 .../service/test/login/package-info.java | 0 .../maptology/service/test/package-info.java | 0 .../test/session/AbstractSessionTest.java | 0 .../test/session/DeviceSessionTest.java | 0 .../test/session/HistorySessionTest.java | 0 .../test/session/LocationSessionTest.java | 0 .../service/test/session/LogSessionTest.java | 0 .../test/session/NoticeSessionTest.java | 0 .../test/session/PrivilegeSessionTest.java | 0 .../test/session/ShareSessionTest.java | 0 .../service/test/session/UserSessionTest.java | 0 .../test/session/VersionSessionTest.java | 0 .../service/test/session/package-info.java | 0 .../service/test/unit/EmailTemplateTest.java | 0 .../service/test/unit/package-info.java | 0 .../src/test/resources/META-INF/beans.xml | 0 .../test/resources/META-INF/persistence.xml | 0 .../src/test/resources/arquillian.xml | 6 +- .../src/test/resources/emails/new-email.txt | 0 .../src/test/resources/emails/new-user.txt | 0 .../src/test/resources/emails/reset-user.txt | 0 .../src/test/resources/wildfly.xml | 0 service-geocode/build.gradle | 14 + {service/geocode => service-geocode}/pom.xml | 10 +- .../service/geocode/GeoLocation.java | 0 .../service/geocode/GeoLocationSubtype.java | 0 .../service/geocode/GeoLocationType.java | 0 .../service/geocode/GeocoderBuilder.java | 0 .../service/geocode/IGeocoderService.java | 0 .../service/geocode/package-info.java | 0 .../service/geocode/GeocoderServiceTest.java | 0 service-thorntail/build.gradle | 16 + {service/swarm => service-thorntail}/pom.xml | 10 +- .../app/MaptologySwarmApplication.java | 0 .../service/rest/MaptologySwaggerListing.java | 0 .../service/swarm/MaptologySwarm.java | 0 .../src/main/resources/beans.xml | 0 .../src/main/resources/jboss-ejb3.xml | 0 .../src/main/resources/jboss-web.xml | 0 .../src/main/resources/persistence.xml | 0 .../src/main/resources/web.xml | 0 .../src/main/webapp/favicon-16x16.png | Bin .../src/main/webapp/favicon-32x32.png | Bin .../src/main/webapp/index.html | 0 .../src/main/webapp/oauth2-redirect.html | 0 .../src/main/webapp/swagger-ui-bundle.js | 0 .../webapp/swagger-ui-standalone-preset.js | 0 .../src/main/webapp/swagger-ui.css | 0 .../src/main/webapp/swagger-ui.css.map | 0 .../src/main/webapp/swagger-ui.js | 0 .../src/main/webapp/swagger-ui.js.map | 0 service-war/build.gradle | 28 + {service/war => service-war}/pom.xml | 16 +- .../service/access/AccessControlFilter.java | 0 .../service/access/package-info.java | 0 .../service/app/MaptologyApplication.java | 0 .../service/app/MaptologyContextListener.java | 0 .../maptology/service/app/MaptologyTime.java | 0 .../service/auth/MaptologyAuthConfig.java | 0 .../service/auth/MaptologyAuthContext.java | 0 .../service/auth/MaptologyAuthModule.java | 0 .../service/auth/MaptologyAuthProvider.java | 0 .../auth/basic/BasicAuthCredential.java | 0 .../auth/bearer/BearerAuthCredential.java | 0 .../http/AbstractHttpServletAuthModule.java | 0 .../auth/http/HttpServletMessageInfo.java | 0 .../maptology/service/auth/package-info.java | 0 .../service/rest/DeviceResource.java | 0 .../service/rest/HistoryResource.java | 0 .../service/rest/LocationResource.java | 0 .../maptology/service/rest/LogResource.java | 0 .../service/rest/NoticeResource.java | 0 .../service/rest/PrivilegeResource.java | 0 .../service/rest/ProcessingTimeFilter.java | 0 .../service/rest/ServerDebugFilter.java | 0 .../maptology/service/rest/ShareResource.java | 0 .../maptology/service/rest/UserResource.java | 0 .../service/rest/VersionResource.java | 0 .../service/servlet/TestServlet.java | 0 .../service/socket/LogMessageEncoder.java | 0 .../service/socket/LogMessageSender.java | 0 .../service/socket/LogStreamSocket.java | 0 .../service/socket/package-info.java | 0 .../src/main/webapp/WEB-INF/jboss-web.xml | 0 .../src/main/webapp/WEB-INF/web.xml | 0 .../src/main/webapp/favicon-16x16.png | Bin .../src/main/webapp/favicon-32x32.png | Bin .../src/main/webapp/index.html | 0 .../src/main/webapp/oauth2-redirect.html | 0 .../src/main/webapp/swagger-ui-bundle.js | 0 .../webapp/swagger-ui-standalone-preset.js | 0 .../src/main/webapp/swagger-ui.css | 0 .../src/main/webapp/swagger-ui.css.map | 0 .../src/main/webapp/swagger-ui.js | 0 .../src/main/webapp/swagger-ui.js.map | 0 .../maptology/service/test/WarDeployment.java | 0 .../maptology/service/test/package-info.java | 0 .../test/rest/AbstractResourceTest.java | 0 .../service/test/rest/AssertResponse.java | 0 .../service/test/rest/DeviceResourceTest.java | 0 .../service/test/rest/LogResourceTest.java | 0 .../service/test/rest/NoticeResourceTest.java | 0 .../service/test/rest/ShareResourceTest.java | 0 .../service/test/rest/UserResourceTest.java | 0 .../test/rest/VersionResourceTest.java | 0 .../service/test/rest/package-info.java | 0 .../test/unit/BasicAuthCredentialTest.java | 0 .../service/test/unit/package-info.java | 0 .../test/resources/META-INF/application.xml | 0 .../src/test/resources/META-INF/beans.xml | 0 .../test/resources/META-INF/jboss-ejb3.xml | 0 .../test/resources/META-INF/persistence.xml | 0 .../src/test/resources/arquillian.xml | 3 +- .../wildfly => service-wildfly}/.gitignore | 2 +- service-wildfly/build.gradle | 24 + {service/wildfly => service-wildfly}/pom.xml | 10 +- service/pom.xml | 66 - settings.gradle | 12 + site-ear/build.gradle | 37 + {ear => site-ear}/pom.xml | 22 +- testing/api-client/.gitignore | 21 - testing/api-client/.swagger-codegen-ignore | 23 - testing/api-client/.swagger-codegen/VERSION | 1 - testing/api-client/.travis.yml | 17 - testing/api-client/README.md | 264 - testing/api-client/build.gradle | 103 - testing/api-client/build.sbt | 20 - testing/api-client/docs/BuildVersion.md | 13 - testing/api-client/docs/Coordinate.md | 11 - testing/api-client/docs/DefaultApi.md | 2845 ------- testing/api-client/docs/Device.md | 26 - testing/api-client/docs/DeviceApi.md | 626 -- testing/api-client/docs/DeviceHandle.md | 27 - testing/api-client/docs/DeviceInfo.md | 21 - testing/api-client/docs/DevicePage.md | 13 - testing/api-client/docs/Email.md | 16 - testing/api-client/docs/EntityStatistic.md | 12 - testing/api-client/docs/LoadStatistic.md | 17 - testing/api-client/docs/Location.md | 22 - testing/api-client/docs/LocationUpdate.md | 10 - testing/api-client/docs/LogMessage.md | 18 - testing/api-client/docs/Message.md | 23 - testing/api-client/docs/Notice.md | 19 - testing/api-client/docs/NoticePage.md | 13 - testing/api-client/docs/Place.md | 16 - testing/api-client/docs/PlaceApi.md | 152 - testing/api-client/docs/PlacePage.md | 13 - testing/api-client/docs/Privilege.md | 15 - testing/api-client/docs/PrivilegeApi.md | 187 - testing/api-client/docs/PrivilegePage.md | 13 - testing/api-client/docs/ReleasedLocation.md | 30 - testing/api-client/docs/ServiceApi.md | 576 -- testing/api-client/docs/Share.md | 19 - testing/api-client/docs/ShareApi.md | 325 - testing/api-client/docs/ShareInfo.md | 12 - testing/api-client/docs/User.md | 18 - testing/api-client/docs/UserApi.md | 1019 --- testing/api-client/docs/UserPage.md | 13 - testing/api-client/docs/UserPassword.md | 10 - testing/api-client/docs/UserRegistration.md | 13 - testing/api-client/docs/Visit.md | 17 - testing/api-client/docs/VisitPage.md | 13 - testing/api-client/git_push.sh | 52 - testing/api-client/gradle.properties | 2 - .../gradle/wrapper/gradle-wrapper.jar | Bin 53639 -> 0 bytes testing/api-client/pom.xml | 117 - testing/api-client/settings.gradle | 1 - .../api-client/src/main/AndroidManifest.xml | 3 - .../java/io/swagger/client/ApiCallback.java | 62 - .../java/io/swagger/client/ApiClient.java | 1361 ---- .../java/io/swagger/client/ApiException.java | 91 - .../java/io/swagger/client/ApiResponse.java | 59 - .../java/io/swagger/client/Configuration.java | 39 - .../client/GzipRequestInterceptor.java | 81 - .../src/main/java/io/swagger/client/JSON.java | 225 - .../src/main/java/io/swagger/client/Pair.java | 52 - .../swagger/client/ProgressRequestBody.java | 77 - .../swagger/client/ProgressResponseBody.java | 76 - .../java/io/swagger/client/StringUtil.java | 55 - .../io/swagger/client/api/DefaultApi.java | 6793 ----------------- .../java/io/swagger/client/api/DeviceApi.java | 1443 ---- .../java/io/swagger/client/api/PlaceApi.java | 457 -- .../io/swagger/client/api/PrivilegeApi.java | 432 -- .../io/swagger/client/api/ServiceApi.java | 1412 ---- .../java/io/swagger/client/api/ShareApi.java | 814 -- .../java/io/swagger/client/api/UserApi.java | 2518 ------ .../io/swagger/client/auth/ApiKeyAuth.java | 75 - .../swagger/client/auth/Authentication.java | 29 - .../io/swagger/client/auth/HttpBasicAuth.java | 54 - .../java/io/swagger/client/auth/OAuth.java | 39 - .../io/swagger/client/auth/OAuthFlow.java | 18 - .../io/swagger/client/model/BuildVersion.java | 163 - .../io/swagger/client/model/Coordinate.java | 121 - .../java/io/swagger/client/model/Device.java | 298 - .../io/swagger/client/model/DeviceHandle.java | 321 - .../io/swagger/client/model/DeviceInfo.java | 210 - .../io/swagger/client/model/DevicePage.java | 171 - .../java/io/swagger/client/model/Email.java | 205 - .../swagger/client/model/EntityStatistic.java | 140 - .../swagger/client/model/LoadStatistic.java | 255 - .../io/swagger/client/model/Location.java | 192 - .../swagger/client/model/LocationUpdate.java | 102 - .../io/swagger/client/model/LogMessage.java | 278 - .../java/io/swagger/client/model/Message.java | 193 - .../java/io/swagger/client/model/Notice.java | 284 - .../io/swagger/client/model/NoticePage.java | 171 - .../java/io/swagger/client/model/Place.java | 206 - .../io/swagger/client/model/PlacePage.java | 171 - .../io/swagger/client/model/Privilege.java | 183 - .../swagger/client/model/PrivilegePage.java | 171 - .../client/model/ReleasedLocation.java | 376 - .../java/io/swagger/client/model/Share.java | 265 - .../io/swagger/client/model/ShareInfo.java | 140 - .../java/io/swagger/client/model/User.java | 264 - .../io/swagger/client/model/UserPage.java | 171 - .../io/swagger/client/model/UserPassword.java | 94 - .../client/model/UserRegistration.java | 163 - .../java/io/swagger/client/model/Visit.java | 228 - .../io/swagger/client/model/VisitPage.java | 171 - .../src/main/resources/api/maptology.json | 3502 --------- .../io/swagger/client/api/DefaultApiTest.java | 924 --- .../io/swagger/client/api/DeviceApiTest.java | 220 - .../io/swagger/client/api/PlaceApiTest.java | 87 - .../swagger/client/api/PrivilegeApiTest.java | 84 - .../io/swagger/client/api/ServiceApiTest.java | 215 - .../io/swagger/client/api/ShareApiTest.java | 134 - .../io/swagger/client/api/UserApiTest.java | 357 - testing/performance/pom.xml | 36 - .../maptology/testing/performance/Main.java | 90 - testing/pom.xml | 21 - {web/angular => web-angular}/.editorconfig | 0 {web/angular => web-angular}/.gitignore | 0 {web/angular => web-angular}/README.md | 0 {web/angular => web-angular}/angular.json | 0 {web/angular => web-angular}/browserslist | 0 web-angular/build.gradle | 47 + .../e2e/app.e2e-spec.ts | 0 {web/angular => web-angular}/e2e/app.po.ts | 0 .../e2e/tsconfig.e2e.json | 0 {web/angular => web-angular}/karma.conf.js | 0 {web/angular => web-angular}/package.json | 0 {web/angular => web-angular}/pom.xml | 10 +- .../protractor.conf.js | 0 {web/angular => web-angular}/proxy.conf.json | 0 .../src/app/app.component.html | 0 .../src/app/app.component.ts | 0 .../src/app/app.module.ts | 0 .../src/app/app.routing.ts | 0 .../directives/use-parent-form.directive.ts | 0 .../src/app/guards/auth.guard.ts | 0 .../src/app/interceptors/auth.interceptor.ts | 0 .../src/app/interceptors/delay.interceptor.ts | 0 .../src/app/layouts/drawer.component.html | 0 .../src/app/layouts/drawer.component.ts | 0 .../src/app/layouts/footer.component.html | 0 .../src/app/layouts/footer.component.ts | 0 .../src/app/layouts/inside.component.html | 0 .../src/app/layouts/inside.component.ts | 0 .../src/app/layouts/outside.component.html | 0 .../src/app/layouts/outside.component.ts | 0 .../src/app/providers/paginator.provider.ts | 0 .../src/app/services/console.service.ts | 0 .../src/app/services/credential.service.ts | 0 .../src/app/services/device-visit.service.ts | 0 .../src/app/services/device.service.ts | 0 .../src/app/services/manage-log.service.ts | 0 .../src/app/services/manage-notice.service.ts | 0 .../src/app/services/manage-user.service.ts | 0 .../src/app/services/notice.service.ts | 0 .../src/app/services/place-visit.service.ts | 0 .../src/app/services/place.service.ts | 0 .../src/app/services/privilege.service.ts | 0 .../src/app/services/resource.service.ts | 0 .../src/app/services/user.service.ts | 0 .../src/app/services/version.service.ts | 0 .../src/app/utils/formcodes.ts | 0 .../src/app/utils/httpcodes.ts | 0 .../src/app/utils/pagination.ts | 0 .../src/app/utils/snackbars.ts | 0 .../src/app/utils/tables.ts | 0 .../src/app/views/activate.component.html | 0 .../src/app/views/activate.component.ts | 0 .../src/app/views/change.component.html | 0 .../src/app/views/change.component.ts | 0 .../app/views/device-location.component.html | 0 .../app/views/device-location.component.ts | 0 .../app/views/device-visits.component.html | 0 .../src/app/views/device-visits.component.ts | 0 .../src/app/views/devices.component.html | 0 .../src/app/views/devices.component.ts | 0 .../src/app/views/edit-notice.component.html | 0 .../src/app/views/edit-notice.component.ts | 0 .../src/app/views/login.component.html | 0 .../src/app/views/login.component.ts | 0 .../src/app/views/manage-log.component.html | 0 .../src/app/views/manage-log.component.ts | 0 .../app/views/manage-notices.component.html | 0 .../src/app/views/manage-notices.component.ts | 0 .../app/views/manage-system.component.html | 0 .../src/app/views/manage-system.component.ts | 0 .../src/app/views/manage-users.component.html | 0 .../src/app/views/manage-users.component.ts | 0 .../src/app/views/notices.component.html | 0 .../src/app/views/notices.component.ts | 0 .../src/app/views/place-visits.component.html | 0 .../src/app/views/place-visits.component.ts | 0 .../src/app/views/places.component.html | 0 .../src/app/views/places.component.ts | 0 .../src/app/views/privileges.component.html | 0 .../src/app/views/privileges.component.ts | 0 .../src/app/views/register.component.html | 0 .../src/app/views/register.component.ts | 0 .../src/app/views/reset.component.html | 0 .../src/app/views/reset.component.ts | 0 .../src/app/views/share.component.html | 0 .../src/app/views/share.component.ts | 0 .../src/app/views/user.component.html | 0 .../src/app/views/user.component.ts | 0 .../confirmation-dialog.component.html | 0 .../widgets/confirmation-dialog.component.ts | 0 .../app/widgets/decision-panel.component.html | 0 .../app/widgets/decision-panel.component.ts | 0 .../app/widgets/email-field.component.html | 0 .../src/app/widgets/email-field.component.ts | 0 .../widgets/language-select.component.html | 0 .../app/widgets/language-select.component.ts | 0 .../src/app/widgets/log-dialog.component.html | 0 .../src/app/widgets/log-dialog.component.ts | 0 .../app/widgets/login-field.component.html | 0 .../src/app/widgets/login-field.component.ts | 0 .../src/app/widgets/marker-map.component.html | 0 .../src/app/widgets/marker-map.component.ts | 0 .../app/widgets/message-dialog.component.html | 0 .../app/widgets/message-dialog.component.ts | 0 .../src/app/widgets/name-field.component.html | 0 .../src/app/widgets/name-field.component.ts | 0 .../widgets/nickname-dialog.component.html | 0 .../app/widgets/nickname-dialog.component.ts | 0 .../app/widgets/notice-card.component.html | 0 .../src/app/widgets/notice-card.component.ts | 0 .../app/widgets/password-field.component.html | 0 .../app/widgets/password-field.component.ts | 0 .../app/widgets/profile-button.component.html | 0 .../app/widgets/profile-button.component.ts | 0 .../app/widgets/share-dialog.component.html | 0 .../src/app/widgets/share-dialog.component.ts | 0 .../src/app/widgets/tile-map.component.html | 0 .../src/app/widgets/tile-map.component.ts | 0 .../app/widgets/toolbar-button.component.html | 0 .../app/widgets/toolbar-button.component.ts | 0 .../src/assets/.gitkeep | 0 .../src/assets/flags/de.svg | 0 .../src/assets/flags/en.svg | 0 .../src/assets/flags/es.svg | 0 .../src/assets/flags/fr.svg | 0 .../src/assets/flags/it.svg | 0 .../assets/fonts/MaterialIcons-Regular.eot | Bin .../assets/fonts/MaterialIcons-Regular.ttf | Bin .../assets/fonts/MaterialIcons-Regular.woff | Bin .../assets/fonts/MaterialIcons-Regular.woff2 | Bin .../src/assets/fonts/RobotoLatin-Regular.eot | Bin .../src/assets/fonts/RobotoLatin-Regular.ttf | Bin .../src/assets/fonts/RobotoLatin-Regular.woff | Bin .../assets/fonts/RobotoLatin-Regular.woff2 | Bin .../assets/fonts/RobotoMonoLatin-Regular.eot | Bin .../assets/fonts/RobotoMonoLatin-Regular.ttf | Bin .../assets/fonts/RobotoMonoLatin-Regular.woff | Bin .../fonts/RobotoMonoLatin-Regular.woff2 | Bin .../src/assets/icons/favicon-114x114.png | Bin .../src/assets/icons/favicon-120x120.png | Bin .../src/assets/icons/favicon-144x144.png | Bin .../src/assets/icons/favicon-152x152.png | Bin .../src/assets/icons/favicon-16x16.png | Bin .../src/assets/icons/favicon-180x180.png | Bin .../src/assets/icons/favicon-192x192.png | Bin .../src/assets/icons/favicon-32x32.png | Bin .../src/assets/icons/favicon-57x57.png | Bin .../src/assets/icons/favicon-60x60.png | Bin .../src/assets/icons/favicon-72x72.png | Bin .../src/assets/icons/favicon-76x76.png | Bin .../src/assets/icons/favicon-96x96.png | Bin .../src/assets/icons/home.svg | 0 .../src/assets/images/frontpage.png | Bin .../src/assets/markers/marker_dark.png | Bin .../src/assets/markers/marker_normal.png | Bin .../src/assets/markers/marker_pin.png | Bin .../src/assets/markers/marker_shadow.png | Bin .../src/environments/environment.prod.ts | 0 .../src/environments/environment.ts | 0 {web/angular => web-angular}/src/favicon.ico | Bin {web/angular => web-angular}/src/fonts.scss | 0 {web/angular => web-angular}/src/index.html | 0 {web/angular => web-angular}/src/main.ts | 0 {web/angular => web-angular}/src/polyfills.ts | 0 {web/angular => web-angular}/src/styles.scss | 0 {web/angular => web-angular}/src/test.ts | 0 {web/angular => web-angular}/src/theme.scss | 0 .../src/tsconfig.app.json | 0 .../src/tsconfig.spec.json | 0 {web/angular => web-angular}/src/typings.d.ts | 0 {web/angular => web-angular}/tsconfig.json | 0 {web/angular => web-angular}/tslint.json | 0 web-war/build.gradle | 26 + {web/webapp => web-war}/pom.xml | 14 +- {web/webapp => web-war}/src/main/java/.keep | 0 .../web/webapp/AngularRouterServlet.java | 0 .../src/main/webapp/WEB-INF/jboss-web.xml | 0 .../src/main/webapp/WEB-INF/web.xml | 0 {web/webapp => web-war}/src/test/java/.keep | 0 .../src/test/resources/.keep | 0 web/pom.xml | 22 - 996 files changed, 912 insertions(+), 42643 deletions(-) create mode 100644 android-app/build.gradle rename {android/app => android-app}/pom.xml (92%) rename {android/app => android-app}/project.properties (100%) rename {android/app => android-app}/src/main/AndroidManifest.xml (93%) rename {android/app => android-app}/src/main/assets/incoming_marker.png (100%) rename {android/app => android-app}/src/main/assets/marker_dark.png (100%) rename {android/app => android-app}/src/main/assets/marker_normal.png (100%) rename {android/app => android-app}/src/main/assets/marker_pin.png (100%) rename {android/app => android-app}/src/main/assets/marker_shadow.png (100%) rename {android/app => android-app}/src/main/assets/terms.html (100%) rename {android/app => android-app}/src/main/icons/logos.cdr (100%) rename {android/app => android-app}/src/main/java/com/maptology/android/app/BootReceiver.java (100%) rename {android/app => android-app}/src/main/java/com/maptology/android/app/LocationService.java (100%) rename {android/app => android-app}/src/main/java/com/maptology/android/app/LoginActivity.java (100%) rename {android/app => android-app}/src/main/java/com/maptology/android/app/MainActivity.java (100%) rename {android/app => android-app}/src/main/java/com/maptology/android/app/MaptologyApp.java (100%) rename {android/app => android-app}/src/main/java/com/maptology/android/app/NoticeReceiver.java (100%) rename {android/app => android-app}/src/main/java/com/maptology/android/app/StartActivity.java (100%) rename {android/app => android-app}/src/main/java/com/maptology/android/app/UploadService.java (100%) rename {android/app => android-app}/src/main/java/com/maptology/android/app/adapter/AlertDialogAdapter.java (100%) rename {android/app => android-app}/src/main/java/com/maptology/android/app/adapter/DetailViewHolder.java (99%) rename {android/app => android-app}/src/main/java/com/maptology/android/app/adapter/GrantAdapter.java (100%) rename {android/app => android-app}/src/main/java/com/maptology/android/app/adapter/NoticeAdapter.java (100%) rename {android/app => android-app}/src/main/java/com/maptology/android/app/adapter/ShareAdapter.java (100%) rename {android/app => android-app}/src/main/java/com/maptology/android/app/fragment/AbstractFragment.java (100%) rename {android/app => android-app}/src/main/java/com/maptology/android/app/fragment/DatePickerFragment.java (100%) rename {android/app => android-app}/src/main/java/com/maptology/android/app/fragment/DetailFragment.java (100%) rename {android/app => android-app}/src/main/java/com/maptology/android/app/fragment/DetailPagerFragment.java (100%) rename {android/app => android-app}/src/main/java/com/maptology/android/app/fragment/GrantListFragment.java (99%) rename {android/app => android-app}/src/main/java/com/maptology/android/app/fragment/LoginFragment.java (100%) rename {android/app => android-app}/src/main/java/com/maptology/android/app/fragment/LogoFragment.java (96%) rename {android/app => android-app}/src/main/java/com/maptology/android/app/fragment/ManageFragment.java (100%) rename {android/app => android-app}/src/main/java/com/maptology/android/app/fragment/MapFragment.java (95%) rename {android/app => android-app}/src/main/java/com/maptology/android/app/fragment/NoticeListFragment.java (100%) rename {android/app => android-app}/src/main/java/com/maptology/android/app/fragment/SettingsFragment.java (100%) rename {android/app => android-app}/src/main/java/com/maptology/android/app/fragment/ShareFragment.java (100%) rename {android/app => android-app}/src/main/java/com/maptology/android/app/fragment/ShareListFragment.java (100%) rename {android/app => android-app}/src/main/java/com/maptology/android/app/fragment/TermsFragment.java (100%) rename {android/app => android-app}/src/main/java/com/maptology/android/app/fragment/TimePickerFragment.java (100%) rename {android/app => android-app}/src/main/java/com/maptology/android/app/location/LocationContract.java (100%) rename {android/app => android-app}/src/main/java/com/maptology/android/app/location/LocationHelper.java (100%) rename {android/app => android-app}/src/main/java/com/maptology/android/app/location/LocationState.java (100%) rename {android/app => android-app}/src/main/java/com/maptology/android/app/location/LocationStore.java (100%) rename {android/app => android-app}/src/main/java/com/maptology/android/app/map/IconManager.java (94%) rename {android/app => android-app}/src/main/java/com/maptology/android/app/map/MapMode.java (100%) rename {android/app => android-app}/src/main/java/com/maptology/android/app/map/MapState.java (94%) rename {android/app => android-app}/src/main/java/com/maptology/android/app/model/Grant.java (100%) rename {android/app => android-app}/src/main/java/com/maptology/android/app/model/LocalMessage.java (100%) rename {android/app => android-app}/src/main/java/com/maptology/android/app/model/LocalNotice.java (100%) rename {android/app => android-app}/src/main/java/com/maptology/android/app/model/LocalShare.java (100%) rename {android/app => android-app}/src/main/java/com/maptology/android/app/model/ModelUtils.java (100%) rename {android/app => android-app}/src/main/java/com/maptology/android/app/model/Network.java (100%) rename {android/app => android-app}/src/main/java/com/maptology/android/app/model/Position.java (100%) rename {android/app => android-app}/src/main/java/com/maptology/android/app/notice/NoticeContract.java (100%) rename {android/app => android-app}/src/main/java/com/maptology/android/app/notice/NoticeHelper.java (100%) rename {android/app => android-app}/src/main/java/com/maptology/android/app/notice/NoticeStore.java (100%) rename {android/app => android-app}/src/main/java/com/maptology/android/app/repository/AsyncError.java (100%) rename {android/app => android-app}/src/main/java/com/maptology/android/app/repository/AsyncInteraction.java (100%) rename {android/app => android-app}/src/main/java/com/maptology/android/app/repository/IValueListener.java (100%) rename {android/app => android-app}/src/main/java/com/maptology/android/app/repository/JacksonSerializer.java (100%) rename {android/app => android-app}/src/main/java/com/maptology/android/app/repository/LocationValue.java (100%) rename {android/app => android-app}/src/main/java/com/maptology/android/app/repository/PersistentValue.java (100%) rename {android/app => android-app}/src/main/java/com/maptology/android/app/repository/Repository.java (100%) rename {android/app => android-app}/src/main/java/com/maptology/android/app/repository/Serializer.java (100%) rename {android/app => android-app}/src/main/java/com/maptology/android/app/repository/Value.java (100%) rename {android/app => android-app}/src/main/java/com/maptology/android/app/share/ShareContract.java (100%) rename {android/app => android-app}/src/main/java/com/maptology/android/app/share/ShareHelper.java (100%) rename {android/app => android-app}/src/main/java/com/maptology/android/app/share/ShareStore.java (100%) rename {android/app => android-app}/src/main/java/com/maptology/android/app/task/AbstractApiTask.java (100%) rename {android/app => android-app}/src/main/java/com/maptology/android/app/task/CreateDeviceTask.java (100%) rename {android/app => android-app}/src/main/java/com/maptology/android/app/task/CreateShareTask.java (100%) rename {android/app => android-app}/src/main/java/com/maptology/android/app/task/DeleteShareTask.java (100%) rename {android/app => android-app}/src/main/java/com/maptology/android/app/task/SaveShareTask.java (100%) rename {android/app => android-app}/src/main/java/com/maptology/android/app/task/SyncNoticeTask.java (100%) rename {android/app => android-app}/src/main/java/com/maptology/android/app/task/UpdateGrantsTask.java (100%) rename {android/app => android-app}/src/main/java/com/maptology/android/app/task/UpdateUserTask.java (100%) rename {android/app => android-app}/src/main/java/com/maptology/android/app/task/UploadLocationTask.java (100%) rename {android/app => android-app}/src/main/java/com/maptology/android/app/util/ActionUtil.java (100%) rename {android/app => android-app}/src/main/java/com/maptology/android/app/util/ColoredSnackbar.java (100%) rename {android/app => android-app}/src/main/java/com/maptology/android/app/util/DateFormatter.java (100%) rename {android/app => android-app}/src/main/java/com/maptology/android/app/util/TabletUtil.java (100%) rename {android/app => android-app}/src/main/key/maptology.jks (100%) rename {android/app => android-app}/src/main/res/drawable-hdpi/ic_add_white_24dp.png (100%) rename {android/app => android-app}/src/main/res/drawable-hdpi/ic_alarm_off_black_48dp.png (100%) rename {android/app => android-app}/src/main/res/drawable-hdpi/ic_all_out_white_24dp.png (100%) rename {android/app => android-app}/src/main/res/drawable-hdpi/ic_call_made_white_24dp.png (100%) rename {android/app => android-app}/src/main/res/drawable-hdpi/ic_call_received_white_24dp.png (100%) rename {android/app => android-app}/src/main/res/drawable-hdpi/ic_card_travel_black_24dp.png (100%) rename {android/app => android-app}/src/main/res/drawable-hdpi/ic_chat_bubble_outline_black_24dp.png (100%) rename {android/app => android-app}/src/main/res/drawable-hdpi/ic_check_black_24dp.png (100%) rename {android/app => android-app}/src/main/res/drawable-hdpi/ic_content_copy_black_24dp.png (100%) rename {android/app => android-app}/src/main/res/drawable-hdpi/ic_delete_black_24dp.png (100%) rename {android/app => android-app}/src/main/res/drawable-hdpi/ic_delete_sweep_white_24dp.png (100%) rename {android/app => android-app}/src/main/res/drawable-hdpi/ic_delete_white_24dp.png (100%) rename {android/app => android-app}/src/main/res/drawable-hdpi/ic_gps_fixed_black_24dp.png (100%) rename {android/app => android-app}/src/main/res/drawable-hdpi/ic_gps_not_fixed_black_24dp.png (100%) rename {android/app => android-app}/src/main/res/drawable-hdpi/ic_gps_not_fixed_black_48dp.png (100%) rename {android/app => android-app}/src/main/res/drawable-hdpi/ic_import_export_black_24dp.png (100%) rename {android/app => android-app}/src/main/res/drawable-hdpi/ic_launch_black_24dp.png (100%) rename {android/app => android-app}/src/main/res/drawable-hdpi/ic_link_black_24dp.png (100%) rename {android/app => android-app}/src/main/res/drawable-hdpi/ic_location_on_black_48dp.png (100%) rename {android/app => android-app}/src/main/res/drawable-hdpi/ic_lock_outline_black_24dp.png (100%) rename {android/app => android-app}/src/main/res/drawable-hdpi/ic_map_black_24dp.png (100%) rename {android/app => android-app}/src/main/res/drawable-hdpi/ic_message_black_24dp.png (100%) rename {android/app => android-app}/src/main/res/drawable-hdpi/ic_my_location_white_24dp.png (100%) rename {android/app => android-app}/src/main/res/drawable-hdpi/ic_open_in_browser_black_24dp.png (100%) rename {android/app => android-app}/src/main/res/drawable-hdpi/ic_pause_black_48dp.png (100%) rename {android/app => android-app}/src/main/res/drawable-hdpi/ic_perm_identity_black_24dp.png (100%) rename {android/app => android-app}/src/main/res/drawable-hdpi/ic_place_white_24dp.png (100%) rename {android/app => android-app}/src/main/res/drawable-hdpi/ic_save_black_24dp.png (100%) rename {android/app => android-app}/src/main/res/drawable-hdpi/ic_settings_black_24dp.png (100%) rename {android/app => android-app}/src/main/res/drawable-hdpi/ic_share_black_24dp.png (100%) rename {android/app => android-app}/src/main/res/drawable-hdpi/ic_share_black_48dp.png (100%) rename {android/app => android-app}/src/main/res/drawable-hdpi/ic_update_black_24dp.png (100%) rename {android/app => android-app}/src/main/res/drawable-hdpi/ic_update_white_24dp.png (100%) rename {android/app => android-app}/src/main/res/drawable-hdpi/ic_visibility_off_black_48dp.png (100%) rename {android/app => android-app}/src/main/res/drawable-hdpi/ic_zoom_in_white_24dp.png (100%) rename {android/app => android-app}/src/main/res/drawable-hdpi/ic_zoom_out_map_white_24dp.png (100%) rename {android/app => android-app}/src/main/res/drawable-hdpi/ic_zoom_out_white_24dp.png (100%) rename {android/app => android-app}/src/main/res/drawable-mdpi/ic_add_white_24dp.png (100%) rename {android/app => android-app}/src/main/res/drawable-mdpi/ic_alarm_off_black_48dp.png (100%) rename {android/app => android-app}/src/main/res/drawable-mdpi/ic_all_out_white_24dp.png (100%) rename {android/app => android-app}/src/main/res/drawable-mdpi/ic_call_made_white_24dp.png (100%) rename {android/app => android-app}/src/main/res/drawable-mdpi/ic_call_received_white_24dp.png (100%) rename {android/app => android-app}/src/main/res/drawable-mdpi/ic_card_travel_black_24dp.png (100%) rename {android/app => android-app}/src/main/res/drawable-mdpi/ic_chat_bubble_outline_black_24dp.png (100%) rename {android/app => android-app}/src/main/res/drawable-mdpi/ic_check_black_24dp.png (100%) rename {android/app => android-app}/src/main/res/drawable-mdpi/ic_content_copy_black_24dp.png (100%) rename {android/app => android-app}/src/main/res/drawable-mdpi/ic_delete_black_24dp.png (100%) rename {android/app => android-app}/src/main/res/drawable-mdpi/ic_delete_sweep_white_24dp.png (100%) rename {android/app => android-app}/src/main/res/drawable-mdpi/ic_delete_white_24dp.png (100%) rename {android/app => android-app}/src/main/res/drawable-mdpi/ic_gps_fixed_black_24dp.png (100%) rename {android/app => android-app}/src/main/res/drawable-mdpi/ic_gps_not_fixed_black_24dp.png (100%) rename {android/app => android-app}/src/main/res/drawable-mdpi/ic_gps_not_fixed_black_48dp.png (100%) rename {android/app => android-app}/src/main/res/drawable-mdpi/ic_import_export_black_24dp.png (100%) rename {android/app => android-app}/src/main/res/drawable-mdpi/ic_launch_black_24dp.png (100%) rename {android/app => android-app}/src/main/res/drawable-mdpi/ic_link_black_24dp.png (100%) rename {android/app => android-app}/src/main/res/drawable-mdpi/ic_location_on_black_48dp.png (100%) rename {android/app => android-app}/src/main/res/drawable-mdpi/ic_lock_outline_black_24dp.png (100%) rename {android/app => android-app}/src/main/res/drawable-mdpi/ic_map_black_24dp.png (100%) rename {android/app => android-app}/src/main/res/drawable-mdpi/ic_message_black_24dp.png (100%) rename {android/app => android-app}/src/main/res/drawable-mdpi/ic_my_location_white_24dp.png (100%) rename {android/app => android-app}/src/main/res/drawable-mdpi/ic_open_in_browser_black_24dp.png (100%) rename {android/app => android-app}/src/main/res/drawable-mdpi/ic_pause_black_48dp.png (100%) rename {android/app => android-app}/src/main/res/drawable-mdpi/ic_perm_identity_black_24dp.png (100%) rename {android/app => android-app}/src/main/res/drawable-mdpi/ic_place_white_24dp.png (100%) rename {android/app => android-app}/src/main/res/drawable-mdpi/ic_save_black_24dp.png (100%) rename {android/app => android-app}/src/main/res/drawable-mdpi/ic_settings_black_24dp.png (100%) rename {android/app => android-app}/src/main/res/drawable-mdpi/ic_share_black_24dp.png (100%) rename {android/app => android-app}/src/main/res/drawable-mdpi/ic_share_black_48dp.png (100%) rename {android/app => android-app}/src/main/res/drawable-mdpi/ic_update_black_24dp.png (100%) rename {android/app => android-app}/src/main/res/drawable-mdpi/ic_update_white_24dp.png (100%) rename {android/app => android-app}/src/main/res/drawable-mdpi/ic_visibility_off_black_48dp.png (100%) rename {android/app => android-app}/src/main/res/drawable-mdpi/ic_zoom_in_white_24dp.png (100%) rename {android/app => android-app}/src/main/res/drawable-mdpi/ic_zoom_out_map_white_24dp.png (100%) rename {android/app => android-app}/src/main/res/drawable-mdpi/ic_zoom_out_white_24dp.png (100%) rename {android/app => android-app}/src/main/res/drawable-xhdpi/ic_add_white_24dp.png (100%) rename {android/app => android-app}/src/main/res/drawable-xhdpi/ic_alarm_off_black_48dp.png (100%) rename {android/app => android-app}/src/main/res/drawable-xhdpi/ic_all_out_white_24dp.png (100%) rename {android/app => android-app}/src/main/res/drawable-xhdpi/ic_call_made_white_24dp.png (100%) rename {android/app => android-app}/src/main/res/drawable-xhdpi/ic_call_received_white_24dp.png (100%) rename {android/app => android-app}/src/main/res/drawable-xhdpi/ic_card_travel_black_24dp.png (100%) rename {android/app => android-app}/src/main/res/drawable-xhdpi/ic_chat_bubble_outline_black_24dp.png (100%) rename {android/app => android-app}/src/main/res/drawable-xhdpi/ic_check_black_24dp.png (100%) rename {android/app => android-app}/src/main/res/drawable-xhdpi/ic_content_copy_black_24dp.png (100%) rename {android/app => android-app}/src/main/res/drawable-xhdpi/ic_delete_black_24dp.png (100%) rename {android/app => android-app}/src/main/res/drawable-xhdpi/ic_delete_sweep_white_24dp.png (100%) rename {android/app => android-app}/src/main/res/drawable-xhdpi/ic_delete_white_24dp.png (100%) rename {android/app => android-app}/src/main/res/drawable-xhdpi/ic_gps_fixed_black_24dp.png (100%) rename {android/app => android-app}/src/main/res/drawable-xhdpi/ic_gps_not_fixed_black_24dp.png (100%) rename {android/app => android-app}/src/main/res/drawable-xhdpi/ic_gps_not_fixed_black_48dp.png (100%) rename {android/app => android-app}/src/main/res/drawable-xhdpi/ic_import_export_black_24dp.png (100%) rename {android/app => android-app}/src/main/res/drawable-xhdpi/ic_launch_black_24dp.png (100%) rename {android/app => android-app}/src/main/res/drawable-xhdpi/ic_link_black_24dp.png (100%) rename {android/app => android-app}/src/main/res/drawable-xhdpi/ic_location_on_black_48dp.png (100%) rename {android/app => android-app}/src/main/res/drawable-xhdpi/ic_lock_outline_black_24dp.png (100%) rename {android/app => android-app}/src/main/res/drawable-xhdpi/ic_map_black_24dp.png (100%) rename {android/app => android-app}/src/main/res/drawable-xhdpi/ic_message_black_24dp.png (100%) rename {android/app => android-app}/src/main/res/drawable-xhdpi/ic_my_location_white_24dp.png (100%) rename {android/app => android-app}/src/main/res/drawable-xhdpi/ic_open_in_browser_black_24dp.png (100%) rename {android/app => android-app}/src/main/res/drawable-xhdpi/ic_pause_black_48dp.png (100%) rename {android/app => android-app}/src/main/res/drawable-xhdpi/ic_perm_identity_black_24dp.png (100%) rename {android/app => android-app}/src/main/res/drawable-xhdpi/ic_place_white_24dp.png (100%) rename {android/app => android-app}/src/main/res/drawable-xhdpi/ic_save_black_24dp.png (100%) rename {android/app => android-app}/src/main/res/drawable-xhdpi/ic_settings_black_24dp.png (100%) rename {android/app => android-app}/src/main/res/drawable-xhdpi/ic_share_black_24dp.png (100%) rename {android/app => android-app}/src/main/res/drawable-xhdpi/ic_share_black_48dp.png (100%) rename {android/app => android-app}/src/main/res/drawable-xhdpi/ic_update_black_24dp.png (100%) rename {android/app => android-app}/src/main/res/drawable-xhdpi/ic_update_white_24dp.png (100%) rename {android/app => android-app}/src/main/res/drawable-xhdpi/ic_visibility_off_black_48dp.png (100%) rename {android/app => android-app}/src/main/res/drawable-xhdpi/ic_zoom_in_white_24dp.png (100%) rename {android/app => android-app}/src/main/res/drawable-xhdpi/ic_zoom_out_map_white_24dp.png (100%) rename {android/app => android-app}/src/main/res/drawable-xhdpi/ic_zoom_out_white_24dp.png (100%) rename {android/app => android-app}/src/main/res/drawable-xxhdpi/ic_add_white_24dp.png (100%) rename {android/app => android-app}/src/main/res/drawable-xxhdpi/ic_alarm_off_black_48dp.png (100%) rename {android/app => android-app}/src/main/res/drawable-xxhdpi/ic_all_out_white_24dp.png (100%) rename {android/app => android-app}/src/main/res/drawable-xxhdpi/ic_call_made_white_24dp.png (100%) rename {android/app => android-app}/src/main/res/drawable-xxhdpi/ic_call_received_white_24dp.png (100%) rename {android/app => android-app}/src/main/res/drawable-xxhdpi/ic_card_travel_black_24dp.png (100%) rename {android/app => android-app}/src/main/res/drawable-xxhdpi/ic_chat_bubble_outline_black_24dp.png (100%) rename {android/app => android-app}/src/main/res/drawable-xxhdpi/ic_check_black_24dp.png (100%) rename {android/app => android-app}/src/main/res/drawable-xxhdpi/ic_content_copy_black_24dp.png (100%) rename {android/app => android-app}/src/main/res/drawable-xxhdpi/ic_delete_black_24dp.png (100%) rename {android/app => android-app}/src/main/res/drawable-xxhdpi/ic_delete_sweep_white_24dp.png (100%) rename {android/app => android-app}/src/main/res/drawable-xxhdpi/ic_delete_white_24dp.png (100%) rename {android/app => android-app}/src/main/res/drawable-xxhdpi/ic_gps_fixed_black_24dp.png (100%) rename {android/app => android-app}/src/main/res/drawable-xxhdpi/ic_gps_not_fixed_black_24dp.png (100%) rename {android/app => android-app}/src/main/res/drawable-xxhdpi/ic_gps_not_fixed_black_48dp.png (100%) rename {android/app => android-app}/src/main/res/drawable-xxhdpi/ic_import_export_black_24dp.png (100%) rename {android/app => android-app}/src/main/res/drawable-xxhdpi/ic_launch_black_24dp.png (100%) rename {android/app => android-app}/src/main/res/drawable-xxhdpi/ic_link_black_24dp.png (100%) rename {android/app => android-app}/src/main/res/drawable-xxhdpi/ic_location_on_black_48dp.png (100%) rename {android/app => android-app}/src/main/res/drawable-xxhdpi/ic_lock_outline_black_24dp.png (100%) rename {android/app => android-app}/src/main/res/drawable-xxhdpi/ic_map_black_24dp.png (100%) rename {android/app => android-app}/src/main/res/drawable-xxhdpi/ic_message_black_24dp.png (100%) rename {android/app => android-app}/src/main/res/drawable-xxhdpi/ic_my_location_white_24dp.png (100%) rename {android/app => android-app}/src/main/res/drawable-xxhdpi/ic_open_in_browser_black_24dp.png (100%) rename {android/app => android-app}/src/main/res/drawable-xxhdpi/ic_pause_black_48dp.png (100%) rename {android/app => android-app}/src/main/res/drawable-xxhdpi/ic_perm_identity_black_24dp.png (100%) rename {android/app => android-app}/src/main/res/drawable-xxhdpi/ic_place_white_24dp.png (100%) rename {android/app => android-app}/src/main/res/drawable-xxhdpi/ic_save_black_24dp.png (100%) rename {android/app => android-app}/src/main/res/drawable-xxhdpi/ic_settings_black_24dp.png (100%) rename {android/app => android-app}/src/main/res/drawable-xxhdpi/ic_share_black_24dp.png (100%) rename {android/app => android-app}/src/main/res/drawable-xxhdpi/ic_share_black_48dp.png (100%) rename {android/app => android-app}/src/main/res/drawable-xxhdpi/ic_update_black_24dp.png (100%) rename {android/app => android-app}/src/main/res/drawable-xxhdpi/ic_update_white_24dp.png (100%) rename {android/app => android-app}/src/main/res/drawable-xxhdpi/ic_visibility_off_black_48dp.png (100%) rename {android/app => android-app}/src/main/res/drawable-xxhdpi/ic_zoom_in_white_24dp.png (100%) rename {android/app => android-app}/src/main/res/drawable-xxhdpi/ic_zoom_out_map_white_24dp.png (100%) rename {android/app => android-app}/src/main/res/drawable-xxhdpi/ic_zoom_out_white_24dp.png (100%) rename {android/app => android-app}/src/main/res/drawable-xxhdpi/icon_header.png (100%) rename {android/app => android-app}/src/main/res/drawable-xxhdpi/icon_launch_map.png (100%) rename {android/app => android-app}/src/main/res/drawable-xxhdpi/icon_launch_person.png (100%) rename {android/app => android-app}/src/main/res/drawable-xxhdpi/icon_launch_text.png (100%) rename {android/app => android-app}/src/main/res/drawable-xxhdpi/icon_launcher.png (100%) rename {android/app => android-app}/src/main/res/drawable-xxhdpi/icon_notification_small.png (100%) rename {android/app => android-app}/src/main/res/drawable-xxxhdpi/ic_access_time_black_24dp.png (100%) rename {android/app => android-app}/src/main/res/drawable-xxxhdpi/ic_accessibility_black_24dp.png (100%) rename {android/app => android-app}/src/main/res/drawable-xxxhdpi/ic_add_white_24dp.png (100%) rename {android/app => android-app}/src/main/res/drawable-xxxhdpi/ic_alarm_off_black_48dp.png (100%) rename {android/app => android-app}/src/main/res/drawable-xxxhdpi/ic_all_out_white_24dp.png (100%) rename {android/app => android-app}/src/main/res/drawable-xxxhdpi/ic_call_made_white_24dp.png (100%) rename {android/app => android-app}/src/main/res/drawable-xxxhdpi/ic_call_received_white_24dp.png (100%) rename {android/app => android-app}/src/main/res/drawable-xxxhdpi/ic_card_travel_black_24dp.png (100%) rename {android/app => android-app}/src/main/res/drawable-xxxhdpi/ic_chat_bubble_outline_black_24dp.png (100%) rename {android/app => android-app}/src/main/res/drawable-xxxhdpi/ic_check_black_24dp.png (100%) rename {android/app => android-app}/src/main/res/drawable-xxxhdpi/ic_content_copy_black_24dp.png (100%) rename {android/app => android-app}/src/main/res/drawable-xxxhdpi/ic_delete_black_24dp.png (100%) rename {android/app => android-app}/src/main/res/drawable-xxxhdpi/ic_delete_sweep_white_24dp.png (100%) rename {android/app => android-app}/src/main/res/drawable-xxxhdpi/ic_delete_white_24dp.png (100%) rename {android/app => android-app}/src/main/res/drawable-xxxhdpi/ic_gps_fixed_black_24dp.png (100%) rename {android/app => android-app}/src/main/res/drawable-xxxhdpi/ic_gps_not_fixed_black_24dp.png (100%) rename {android/app => android-app}/src/main/res/drawable-xxxhdpi/ic_gps_not_fixed_black_48dp.png (100%) rename {android/app => android-app}/src/main/res/drawable-xxxhdpi/ic_import_export_black_24dp.png (100%) rename {android/app => android-app}/src/main/res/drawable-xxxhdpi/ic_launch_black_24dp.png (100%) rename {android/app => android-app}/src/main/res/drawable-xxxhdpi/ic_link_black_24dp.png (100%) rename {android/app => android-app}/src/main/res/drawable-xxxhdpi/ic_location_on_black_48dp.png (100%) rename {android/app => android-app}/src/main/res/drawable-xxxhdpi/ic_lock_outline_black_24dp.png (100%) rename {android/app => android-app}/src/main/res/drawable-xxxhdpi/ic_map_black_24dp.png (100%) rename {android/app => android-app}/src/main/res/drawable-xxxhdpi/ic_message_black_24dp.png (100%) rename {android/app => android-app}/src/main/res/drawable-xxxhdpi/ic_my_location_white_24dp.png (100%) rename {android/app => android-app}/src/main/res/drawable-xxxhdpi/ic_open_in_browser_black_24dp.png (100%) rename {android/app => android-app}/src/main/res/drawable-xxxhdpi/ic_pause_black_48dp.png (100%) rename {android/app => android-app}/src/main/res/drawable-xxxhdpi/ic_perm_identity_black_24dp.png (100%) rename {android/app => android-app}/src/main/res/drawable-xxxhdpi/ic_place_white_24dp.png (100%) rename {android/app => android-app}/src/main/res/drawable-xxxhdpi/ic_save_black_24dp.png (100%) rename {android/app => android-app}/src/main/res/drawable-xxxhdpi/ic_settings_black_24dp.png (100%) rename {android/app => android-app}/src/main/res/drawable-xxxhdpi/ic_share_black_24dp.png (100%) rename {android/app => android-app}/src/main/res/drawable-xxxhdpi/ic_share_black_48dp.png (100%) rename {android/app => android-app}/src/main/res/drawable-xxxhdpi/ic_update_black_24dp.png (100%) rename {android/app => android-app}/src/main/res/drawable-xxxhdpi/ic_update_white_24dp.png (100%) rename {android/app => android-app}/src/main/res/drawable-xxxhdpi/ic_visibility_off_black_48dp.png (100%) rename {android/app => android-app}/src/main/res/drawable-xxxhdpi/ic_zoom_in_white_24dp.png (100%) rename {android/app => android-app}/src/main/res/drawable-xxxhdpi/ic_zoom_out_map_white_24dp.png (100%) rename {android/app => android-app}/src/main/res/drawable-xxxhdpi/ic_zoom_out_white_24dp.png (100%) rename {android/app => android-app}/src/main/res/drawable/bg_launch_gradient.xml (100%) rename {android/app => android-app}/src/main/res/layout/activity_login.xml (100%) rename {android/app => android-app}/src/main/res/layout/activity_main_default.xml (100%) rename {android/app => android-app}/src/main/res/layout/activity_main_tablet.xml (100%) rename {android/app => android-app}/src/main/res/layout/activity_start.xml (96%) rename {android/app => android-app}/src/main/res/layout/fragment_detail.xml (100%) rename {android/app => android-app}/src/main/res/layout/fragment_detail_pager.xml (100%) rename {android/app => android-app}/src/main/res/layout/fragment_list_grant.xml (100%) rename {android/app => android-app}/src/main/res/layout/fragment_list_notice.xml (100%) rename {android/app => android-app}/src/main/res/layout/fragment_list_share.xml (100%) rename {android/app => android-app}/src/main/res/layout/fragment_login.xml (100%) rename {android/app => android-app}/src/main/res/layout/fragment_logo.xml (100%) rename {android/app => android-app}/src/main/res/layout/fragment_manage.xml (100%) rename {android/app => android-app}/src/main/res/layout/fragment_map.xml (100%) rename {android/app => android-app}/src/main/res/layout/fragment_share.xml (100%) rename {android/app => android-app}/src/main/res/layout/fragment_terms.xml (100%) rename {android/app => android-app}/src/main/res/layout/view_alert_dialog.xml (100%) rename {android/app => android-app}/src/main/res/layout/view_detail_card.xml (100%) rename {android/app => android-app}/src/main/res/layout/view_detail_plain.xml (100%) rename {android/app => android-app}/src/main/res/layout/view_drawer_header.xml (100%) rename {android/app => android-app}/src/main/res/layout/view_manage_tab.xml (100%) rename {android/app => android-app}/src/main/res/layout/view_notice.xml (100%) rename {android/app => android-app}/src/main/res/menu/menu_drawer.xml (100%) rename {android/app => android-app}/src/main/res/menu/menu_grant.xml (100%) rename {android/app => android-app}/src/main/res/menu/menu_map.xml (100%) rename {android/app => android-app}/src/main/res/menu/menu_notice.xml (100%) rename {android/app => android-app}/src/main/res/menu/menu_share.xml (100%) rename {android/app => android-app}/src/main/res/values-de/strings.xml (100%) rename {android/app => android-app}/src/main/res/values/colors.xml (100%) rename {android/app => android-app}/src/main/res/values/dimens.xml (100%) rename {android/app => android-app}/src/main/res/values/generic.xml (100%) rename {android/app => android-app}/src/main/res/values/strings.xml (100%) rename {android/app => android-app}/src/main/res/values/styles.xml (100%) rename {android/app => android-app}/src/main/res/values/themes.xml (100%) rename {android/app => android-app}/src/main/res/xml/backup.xml (100%) rename {android/app => android-app}/src/main/res/xml/settings.xml (100%) rename {android/app => android-app}/src/test/java/android/content/pm/ShortcutManager.java (100%) rename {android/app => android-app}/src/test/java/com/maptology/android/app/test/MainActivityTest.java (95%) rename {android/app => android-app}/src/test/java/com/maptology/android/app/test/StartActivityTest.java (96%) rename {android/app => android-app}/src/test/java/com/maptology/android/app/test/location/LocationStoreTest.java (98%) rename {android/app => android-app}/src/test/java/com/maptology/android/app/test/notice/NoticeFragmentTest.java (96%) rename {android/app => android-app}/src/test/java/com/maptology/android/app/test/notice/NoticeStoreTest.java (98%) rename {android/app => android-app}/src/test/java/com/maptology/android/app/test/notice/NoticeSyncTest.java (96%) rename {android/app => android-app}/src/test/java/com/maptology/android/app/test/util/AppConfiguration.java (100%) rename {android/app => android-app}/src/test/java/com/maptology/android/app/test/util/FragmentActivity.java (100%) rename {android/app => android-app}/src/test/java/com/maptology/android/app/test/util/ProxyGenerator.java (100%) rename {android/app => android-app}/src/test/resources/robolectric.properties (100%) create mode 100644 android-feign/build.gradle rename {android/feign => android-feign}/pom.xml (93%) rename {android/feign => android-feign}/src/main/java/com/maptology/android/feign/ApiClient.java (100%) rename {android/feign => android-feign}/src/main/java/com/maptology/android/feign/EncodingUtils.java (100%) rename {android/feign => android-feign}/src/main/java/com/maptology/android/feign/ParamExpander.java (100%) rename {android/feign => android-feign}/src/main/java/com/maptology/android/feign/RFC3339DateFormat.java (100%) rename {android/feign => android-feign}/src/main/java/com/maptology/android/feign/StringUtil.java (100%) rename {android/feign => android-feign}/src/main/java/com/maptology/android/feign/auth/ApiKeyAuth.java (100%) rename {android/feign => android-feign}/src/main/java/com/maptology/android/feign/auth/HttpBasicAuth.java (100%) rename {android/feign => android-feign}/src/main/java/com/maptology/android/feign/auth/OAuth.java (100%) rename {android/feign => android-feign}/src/main/java/com/maptology/android/feign/auth/OAuthFlow.java (100%) delete mode 100644 android/leafless/pom.xml delete mode 100644 android/leafless/src/main/AndroidManifest.xml delete mode 100644 android/leafless/src/main/java/com/locoslab/capi/android/leafless/AbstractElement.java delete mode 100644 android/leafless/src/main/java/com/locoslab/capi/android/leafless/AbstractMovableElement.java delete mode 100644 android/leafless/src/main/java/com/locoslab/capi/android/leafless/AccessibleComparator.java delete mode 100644 android/leafless/src/main/java/com/locoslab/capi/android/leafless/AccessibleMapView.java delete mode 100644 android/leafless/src/main/java/com/locoslab/capi/android/leafless/AccessibleMapViewHelper.java delete mode 100644 android/leafless/src/main/java/com/locoslab/capi/android/leafless/ElementFilter.java delete mode 100644 android/leafless/src/main/java/com/locoslab/capi/android/leafless/ElementOptions.java delete mode 100644 android/leafless/src/main/java/com/locoslab/capi/android/leafless/FixedElementOptions.java delete mode 100644 android/leafless/src/main/java/com/locoslab/capi/android/leafless/IListenerBundle.java delete mode 100644 android/leafless/src/main/java/com/locoslab/capi/android/leafless/ILoadable.java delete mode 100644 android/leafless/src/main/java/com/locoslab/capi/android/leafless/ILoader.java delete mode 100644 android/leafless/src/main/java/com/locoslab/capi/android/leafless/IMapListener.java delete mode 100644 android/leafless/src/main/java/com/locoslab/capi/android/leafless/IMapStateListener.java delete mode 100644 android/leafless/src/main/java/com/locoslab/capi/android/leafless/IMoveListener.java delete mode 100644 android/leafless/src/main/java/com/locoslab/capi/android/leafless/ITouchListener.java delete mode 100644 android/leafless/src/main/java/com/locoslab/capi/android/leafless/IdentifierGenerator.java delete mode 100644 android/leafless/src/main/java/com/locoslab/capi/android/leafless/InterimRotation.java delete mode 100644 android/leafless/src/main/java/com/locoslab/capi/android/leafless/ListenerBundle.java delete mode 100644 android/leafless/src/main/java/com/locoslab/capi/android/leafless/MapEvent.java delete mode 100644 android/leafless/src/main/java/com/locoslab/capi/android/leafless/MapOptions.java delete mode 100644 android/leafless/src/main/java/com/locoslab/capi/android/leafless/MapPoint.java delete mode 100644 android/leafless/src/main/java/com/locoslab/capi/android/leafless/MapProjection.java delete mode 100644 android/leafless/src/main/java/com/locoslab/capi/android/leafless/MapStateEvent.java delete mode 100644 android/leafless/src/main/java/com/locoslab/capi/android/leafless/MapView.java delete mode 100644 android/leafless/src/main/java/com/locoslab/capi/android/leafless/MapViewState.java delete mode 100644 android/leafless/src/main/java/com/locoslab/capi/android/leafless/MoveEvent.java delete mode 100644 android/leafless/src/main/java/com/locoslab/capi/android/leafless/TouchEvent.java delete mode 100644 android/leafless/src/main/java/com/locoslab/capi/android/leafless/cache/AbstractCreator.java delete mode 100644 android/leafless/src/main/java/com/locoslab/capi/android/leafless/cache/Cache.java delete mode 100644 android/leafless/src/main/java/com/locoslab/capi/android/leafless/cache/CacheConfiguration.java delete mode 100644 android/leafless/src/main/java/com/locoslab/capi/android/leafless/cache/CacheContract.java delete mode 100644 android/leafless/src/main/java/com/locoslab/capi/android/leafless/cache/CacheHelper.java delete mode 100644 android/leafless/src/main/java/com/locoslab/capi/android/leafless/cache/CacheObjectLoader.java delete mode 100644 android/leafless/src/main/java/com/locoslab/capi/android/leafless/cache/CacheRequest.java delete mode 100644 android/leafless/src/main/java/com/locoslab/capi/android/leafless/cache/IObjectFactory.java delete mode 100644 android/leafless/src/main/java/com/locoslab/capi/android/leafless/cache/IObjectRequest.java delete mode 100644 android/leafless/src/main/java/com/locoslab/capi/android/leafless/circle/Circle.java delete mode 100644 android/leafless/src/main/java/com/locoslab/capi/android/leafless/circle/CircleOptions.java delete mode 100644 android/leafless/src/main/java/com/locoslab/capi/android/leafless/circle/CircleUnit.java delete mode 100644 android/leafless/src/main/java/com/locoslab/capi/android/leafless/control/AbstractControl.java delete mode 100644 android/leafless/src/main/java/com/locoslab/capi/android/leafless/control/CompassControl.java delete mode 100644 android/leafless/src/main/java/com/locoslab/capi/android/leafless/control/CompassControlOptions.java delete mode 100644 android/leafless/src/main/java/com/locoslab/capi/android/leafless/control/ControlOptions.java delete mode 100644 android/leafless/src/main/java/com/locoslab/capi/android/leafless/geojson/GeojsonLoader.java delete mode 100644 android/leafless/src/main/java/com/locoslab/capi/android/leafless/geojson/IGeojson.java delete mode 100644 android/leafless/src/main/java/com/locoslab/capi/android/leafless/geojson/IGeojsonLoader.java delete mode 100644 android/leafless/src/main/java/com/locoslab/capi/android/leafless/icon/Icon.java delete mode 100644 android/leafless/src/main/java/com/locoslab/capi/android/leafless/icon/IconImage.java delete mode 100644 android/leafless/src/main/java/com/locoslab/capi/android/leafless/icon/IconOptions.java delete mode 100644 android/leafless/src/main/java/com/locoslab/capi/android/leafless/image/IImage.java delete mode 100644 android/leafless/src/main/java/com/locoslab/capi/android/leafless/image/IImageLoader.java delete mode 100644 android/leafless/src/main/java/com/locoslab/capi/android/leafless/image/ImageLoader.java delete mode 100644 android/leafless/src/main/java/com/locoslab/capi/android/leafless/layer/AbstractLayer.java delete mode 100644 android/leafless/src/main/java/com/locoslab/capi/android/leafless/layer/LayerOptions.java delete mode 100644 android/leafless/src/main/java/com/locoslab/capi/android/leafless/marker/Marker.java delete mode 100644 android/leafless/src/main/java/com/locoslab/capi/android/leafless/marker/MarkerOptions.java delete mode 100644 android/leafless/src/main/java/com/locoslab/capi/android/leafless/marker/RotatedMarker.java delete mode 100644 android/leafless/src/main/java/com/locoslab/capi/android/leafless/marker/RotatedMarkerOptions.java delete mode 100644 android/leafless/src/main/java/com/locoslab/capi/android/leafless/polyline/Polyline.java delete mode 100644 android/leafless/src/main/java/com/locoslab/capi/android/leafless/polyline/PolylineClipper.java delete mode 100644 android/leafless/src/main/java/com/locoslab/capi/android/leafless/polyline/PolylineOptions.java delete mode 100644 android/leafless/src/main/java/com/locoslab/capi/android/leafless/tile/TileImage.java delete mode 100644 android/leafless/src/main/java/com/locoslab/capi/android/leafless/tile/TileLayer.java delete mode 100644 android/leafless/src/main/java/com/locoslab/capi/android/leafless/tile/TileLayerOptions.java delete mode 100644 android/leafless/src/main/java/com/locoslab/capi/android/leafless/touch/BasicRecognizer.java delete mode 100644 android/leafless/src/main/java/com/locoslab/capi/android/leafless/touch/DoubleTapRecognizer.java delete mode 100644 android/leafless/src/main/java/com/locoslab/capi/android/leafless/touch/IBasicView.java delete mode 100644 android/leafless/src/main/java/com/locoslab/capi/android/leafless/touch/IDoubleTapView.java delete mode 100644 android/leafless/src/main/java/com/locoslab/capi/android/leafless/touch/IMovableTarget.java delete mode 100644 android/leafless/src/main/java/com/locoslab/capi/android/leafless/touch/IRecognizer.java delete mode 100644 android/leafless/src/main/java/com/locoslab/capi/android/leafless/touch/Pointer.java delete mode 100644 android/leafless/src/main/java/com/locoslab/capi/android/leafless/vector/VectorLayer.java delete mode 100644 android/leafless/src/main/java/com/locoslab/capi/android/leafless/vector/VectorLayerOptions.java delete mode 100644 android/leafless/src/main/java/com/locoslab/capi/android/leafless/vector/VectorTile.java delete mode 100644 android/pom.xml create mode 100644 build.gradle create mode 100644 common-api/build.gradle rename {api => common-api}/pom.xml (95%) rename {api => common-api}/src/main/java/com/maptology/api/Entity.java (100%) rename {api => common-api}/src/main/java/com/maptology/api/Page.java (100%) rename {api => common-api}/src/main/java/com/maptology/api/PageConfig.java (100%) rename {api => common-api}/src/main/java/com/maptology/api/Tags.java (100%) rename {api => common-api}/src/main/java/com/maptology/api/access/Authorizations.java (100%) rename {api => common-api}/src/main/java/com/maptology/api/access/Roles.java (100%) rename {api => common-api}/src/main/java/com/maptology/api/access/package-info.java (100%) rename {api => common-api}/src/main/java/com/maptology/api/device/Device.java (100%) rename {api => common-api}/src/main/java/com/maptology/api/device/DeviceHandle.java (100%) rename {api => common-api}/src/main/java/com/maptology/api/device/DeviceInfo.java (100%) rename {api => common-api}/src/main/java/com/maptology/api/device/DevicePage.java (100%) rename {api => common-api}/src/main/java/com/maptology/api/device/IDeviceService.java (100%) rename {api => common-api}/src/main/java/com/maptology/api/device/OperatingSystem.java (100%) rename {api => common-api}/src/main/java/com/maptology/api/device/package-info.java (100%) rename {api => common-api}/src/main/java/com/maptology/api/history/IHistoryService.java (100%) rename {api => common-api}/src/main/java/com/maptology/api/history/Place.java (100%) rename {api => common-api}/src/main/java/com/maptology/api/history/PlacePage.java (100%) rename {api => common-api}/src/main/java/com/maptology/api/history/Visit.java (100%) rename {api => common-api}/src/main/java/com/maptology/api/history/VisitPage.java (100%) rename {api => common-api}/src/main/java/com/maptology/api/history/package-info.java (100%) rename {api => common-api}/src/main/java/com/maptology/api/location/Availability.java (100%) rename {api => common-api}/src/main/java/com/maptology/api/location/Coordinate.java (100%) rename {api => common-api}/src/main/java/com/maptology/api/location/DetailedLocation.java (100%) rename {api => common-api}/src/main/java/com/maptology/api/location/ILocationService.java (100%) rename {api => common-api}/src/main/java/com/maptology/api/location/Location.java (100%) rename {api => common-api}/src/main/java/com/maptology/api/location/LocationUpdate.java (100%) rename {api => common-api}/src/main/java/com/maptology/api/location/Position.java (100%) rename {api => common-api}/src/main/java/com/maptology/api/location/PositionPage.java (100%) rename {api => common-api}/src/main/java/com/maptology/api/location/ReleasedLocation.java (100%) rename {api => common-api}/src/main/java/com/maptology/api/location/package-info.java (100%) rename {api => common-api}/src/main/java/com/maptology/api/log/EntityStatistic.java (100%) rename {api => common-api}/src/main/java/com/maptology/api/log/ILogService.java (100%) rename {api => common-api}/src/main/java/com/maptology/api/log/LoadStatistic.java (100%) rename {api => common-api}/src/main/java/com/maptology/api/log/LogMessage.java (100%) rename {api => common-api}/src/main/java/com/maptology/api/log/SystemStatistic.java (100%) rename {api => common-api}/src/main/java/com/maptology/api/log/package-info.java (100%) rename {api => common-api}/src/main/java/com/maptology/api/notice/INoticeService.java (100%) rename {api => common-api}/src/main/java/com/maptology/api/notice/Language.java (100%) rename {api => common-api}/src/main/java/com/maptology/api/notice/Message.java (100%) rename {api => common-api}/src/main/java/com/maptology/api/notice/Notice.java (100%) rename {api => common-api}/src/main/java/com/maptology/api/notice/NoticePage.java (100%) rename {api => common-api}/src/main/java/com/maptology/api/notice/package-info.java (100%) rename {api => common-api}/src/main/java/com/maptology/api/package-info.java (100%) rename {api => common-api}/src/main/java/com/maptology/api/privilege/IPrivilegeService.java (100%) rename {api => common-api}/src/main/java/com/maptology/api/privilege/Privilege.java (100%) rename {api => common-api}/src/main/java/com/maptology/api/privilege/PrivilegePage.java (100%) rename {api => common-api}/src/main/java/com/maptology/api/privilege/package-info.java (100%) rename {api => common-api}/src/main/java/com/maptology/api/share/IShareService.java (100%) rename {api => common-api}/src/main/java/com/maptology/api/share/Share.java (100%) rename {api => common-api}/src/main/java/com/maptology/api/share/ShareInfo.java (100%) rename {api => common-api}/src/main/java/com/maptology/api/share/SharePage.java (100%) rename {api => common-api}/src/main/java/com/maptology/api/share/package-info.java (100%) rename {api => common-api}/src/main/java/com/maptology/api/user/Email.java (100%) rename {api => common-api}/src/main/java/com/maptology/api/user/IUserService.java (100%) rename {api => common-api}/src/main/java/com/maptology/api/user/User.java (100%) rename {api => common-api}/src/main/java/com/maptology/api/user/UserPage.java (100%) rename {api => common-api}/src/main/java/com/maptology/api/user/UserPassword.java (100%) rename {api => common-api}/src/main/java/com/maptology/api/user/UserRegistration.java (100%) rename {api => common-api}/src/main/java/com/maptology/api/user/package-info.java (100%) rename {api => common-api}/src/main/java/com/maptology/api/validation/EmailGroup.java (100%) rename {api => common-api}/src/main/java/com/maptology/api/validation/EmailGroupValidator.java (100%) rename {api => common-api}/src/main/java/com/maptology/api/validation/package-info.java (100%) rename {api => common-api}/src/main/java/com/maptology/api/version/BuildVersion.java (100%) rename {api => common-api}/src/main/java/com/maptology/api/version/IVersionService.java (100%) rename {api => common-api}/src/main/java/com/maptology/api/version/package-info.java (100%) rename {api => common-api}/src/main/resources/security-admin.json (100%) rename {api => common-api}/src/main/resources/security-device.json (100%) rename {api => common-api}/src/main/resources/security-user.json (100%) rename {api => common-api}/src/test/java/com/maptology/api/test/unit/NoticeTest.java (100%) rename {api => common-api}/src/test/java/com/maptology/api/test/unit/package-info.java (100%) rename {testing/api-client/gradle => gradle}/wrapper/gradle-wrapper.properties (79%) rename testing/api-client/gradlew => gradlew (75%) rename testing/api-client/gradlew.bat => gradlew.bat (75%) create mode 100644 local.properties create mode 100644 service-ejb/build.gradle rename {service/ejb => service-ejb}/pom.xml (89%) rename {service/ejb => service-ejb}/src/main/java/com/maptology/service/conversion/AbstractConverter.java (100%) rename {service/ejb => service-ejb}/src/main/java/com/maptology/service/conversion/AbstractDeviceConverter.java (100%) rename {service/ejb => service-ejb}/src/main/java/com/maptology/service/conversion/AbstractEntityConverter.java (100%) rename {service/ejb => service-ejb}/src/main/java/com/maptology/service/conversion/DeviceConverter.java (100%) rename {service/ejb => service-ejb}/src/main/java/com/maptology/service/conversion/DeviceHandleConverter.java (100%) rename {service/ejb => service-ejb}/src/main/java/com/maptology/service/conversion/EmailConverter.java (100%) rename {service/ejb => service-ejb}/src/main/java/com/maptology/service/conversion/IConverter.java (100%) rename {service/ejb => service-ejb}/src/main/java/com/maptology/service/conversion/LocationConverter.java (100%) rename {service/ejb => service-ejb}/src/main/java/com/maptology/service/conversion/MessageConverter.java (100%) rename {service/ejb => service-ejb}/src/main/java/com/maptology/service/conversion/NoticeConverter.java (100%) rename {service/ejb => service-ejb}/src/main/java/com/maptology/service/conversion/PlaceConverter.java (100%) rename {service/ejb => service-ejb}/src/main/java/com/maptology/service/conversion/PositionConverter.java (100%) rename {service/ejb => service-ejb}/src/main/java/com/maptology/service/conversion/PrivilegeConverter.java (100%) rename {service/ejb => service-ejb}/src/main/java/com/maptology/service/conversion/ShareConverter.java (100%) rename {service/ejb => service-ejb}/src/main/java/com/maptology/service/conversion/ShareInfoConverter.java (100%) rename {service/ejb => service-ejb}/src/main/java/com/maptology/service/conversion/UserConverter.java (100%) rename {service/ejb => service-ejb}/src/main/java/com/maptology/service/conversion/VisitConverter.java (100%) rename {service/ejb => service-ejb}/src/main/java/com/maptology/service/conversion/package-info.java (100%) rename {service/ejb => service-ejb}/src/main/java/com/maptology/service/crypto/SecureException.java (100%) rename {service/ejb => service-ejb}/src/main/java/com/maptology/service/crypto/SecureHash.java (100%) rename {service/ejb => service-ejb}/src/main/java/com/maptology/service/crypto/SecureToken.java (100%) rename {service/ejb => service-ejb}/src/main/java/com/maptology/service/crypto/TokenType.java (100%) rename {service/ejb => service-ejb}/src/main/java/com/maptology/service/crypto/package-info.java (100%) rename {service/ejb => service-ejb}/src/main/java/com/maptology/service/entity/AbstractEntity.java (100%) rename {service/ejb => service-ejb}/src/main/java/com/maptology/service/entity/AbstractUserSpecificEntity.java (100%) rename {service/ejb => service-ejb}/src/main/java/com/maptology/service/entity/CodeEntity.java (100%) rename {service/ejb => service-ejb}/src/main/java/com/maptology/service/entity/CodeType.java (100%) rename {service/ejb => service-ejb}/src/main/java/com/maptology/service/entity/DeviceEntity.java (100%) rename {service/ejb => service-ejb}/src/main/java/com/maptology/service/entity/EmailEntity.java (100%) rename {service/ejb => service-ejb}/src/main/java/com/maptology/service/entity/EmbeddedCoordinate.java (100%) rename {service/ejb => service-ejb}/src/main/java/com/maptology/service/entity/EmbeddedMessage.java (100%) rename {service/ejb => service-ejb}/src/main/java/com/maptology/service/entity/EntityConflictException.java (100%) rename {service/ejb => service-ejb}/src/main/java/com/maptology/service/entity/EntityException.java (100%) rename {service/ejb => service-ejb}/src/main/java/com/maptology/service/entity/EntityForbiddenException.java (100%) rename {service/ejb => service-ejb}/src/main/java/com/maptology/service/entity/EntityNotFoundException.java (100%) rename {service/ejb => service-ejb}/src/main/java/com/maptology/service/entity/LocationEntity.java (100%) rename {service/ejb => service-ejb}/src/main/java/com/maptology/service/entity/NoticeEntity.java (100%) rename {service/ejb => service-ejb}/src/main/java/com/maptology/service/entity/OrderCriterion.java (100%) rename {service/ejb => service-ejb}/src/main/java/com/maptology/service/entity/PlaceEntity.java (100%) rename {service/ejb => service-ejb}/src/main/java/com/maptology/service/entity/PositionEntity.java (100%) rename {service/ejb => service-ejb}/src/main/java/com/maptology/service/entity/PrivilegeEntity.java (100%) rename {service/ejb => service-ejb}/src/main/java/com/maptology/service/entity/RoleEntity.java (100%) rename {service/ejb => service-ejb}/src/main/java/com/maptology/service/entity/ShareEntity.java (100%) rename {service/ejb => service-ejb}/src/main/java/com/maptology/service/entity/UserEntity.java (100%) rename {service/ejb => service-ejb}/src/main/java/com/maptology/service/entity/VisitEntity.java (100%) rename {service/ejb => service-ejb}/src/main/java/com/maptology/service/entity/package-info.java (100%) rename {service/ejb => service-ejb}/src/main/java/com/maptology/service/injection/Datasources.java (100%) rename {service/ejb => service-ejb}/src/main/java/com/maptology/service/injection/Loggers.java (100%) rename {service/ejb => service-ejb}/src/main/java/com/maptology/service/injection/Public.java (100%) rename {service/ejb => service-ejb}/src/main/java/com/maptology/service/injection/Sessions.java (100%) rename {service/ejb => service-ejb}/src/main/java/com/maptology/service/injection/package-info.java (100%) rename {service/ejb => service-ejb}/src/main/java/com/maptology/service/principal/LoginManager.java (100%) rename {service/ejb => service-ejb}/src/main/java/com/maptology/service/principal/MaptologyPrincipal.java (100%) rename {service/ejb => service-ejb}/src/main/java/com/maptology/service/session/AbstractPrincipalSessionBean.java (100%) rename {service/ejb => service-ejb}/src/main/java/com/maptology/service/session/AbstractSessionBean.java (100%) rename {service/ejb => service-ejb}/src/main/java/com/maptology/service/session/AbstractUserSpecificSessionBean.java (100%) rename {service/ejb => service-ejb}/src/main/java/com/maptology/service/session/DataSessionBean.java (100%) rename {service/ejb => service-ejb}/src/main/java/com/maptology/service/session/DebugDataSessionBean.java (100%) rename {service/ejb => service-ejb}/src/main/java/com/maptology/service/session/DebugEmailSessionBean.java (100%) rename {service/ejb => service-ejb}/src/main/java/com/maptology/service/session/DebugPositionSessionBean.java (100%) rename {service/ejb => service-ejb}/src/main/java/com/maptology/service/session/DeviceSessionBean.java (100%) rename {service/ejb => service-ejb}/src/main/java/com/maptology/service/session/EmailSessionBean.java (100%) rename {service/ejb => service-ejb}/src/main/java/com/maptology/service/session/GeocoderSessionBean.java (100%) rename {service/ejb => service-ejb}/src/main/java/com/maptology/service/session/IDataSessionBean.java (100%) rename {service/ejb => service-ejb}/src/main/java/com/maptology/service/session/IDebugEmailSessionBean.java (100%) rename {service/ejb => service-ejb}/src/main/java/com/maptology/service/session/IEmailSessionBean.java (100%) rename {service/ejb => service-ejb}/src/main/java/com/maptology/service/session/IPositionSessionBean.java (100%) rename {service/ejb => service-ejb}/src/main/java/com/maptology/service/session/LocationSessionBean.java (100%) rename {service/ejb => service-ejb}/src/main/java/com/maptology/service/session/LogSessionBean.java (100%) rename {service/ejb => service-ejb}/src/main/java/com/maptology/service/session/NoticeSessionBean.java (100%) rename {service/ejb => service-ejb}/src/main/java/com/maptology/service/session/PlaceSessionBean.java (100%) rename {service/ejb => service-ejb}/src/main/java/com/maptology/service/session/PositionSessionBean.java (100%) rename {service/ejb => service-ejb}/src/main/java/com/maptology/service/session/PrivilegeSessionBean.java (100%) rename {service/ejb => service-ejb}/src/main/java/com/maptology/service/session/ShareSessionBean.java (100%) rename {service/ejb => service-ejb}/src/main/java/com/maptology/service/session/StartupBean.java (100%) rename {service/ejb => service-ejb}/src/main/java/com/maptology/service/session/StatisticsSessionBean.java (100%) rename {service/ejb => service-ejb}/src/main/java/com/maptology/service/session/UserSessionBean.java (100%) rename {service/ejb => service-ejb}/src/main/java/com/maptology/service/session/VersionSessionBean.java (100%) rename {service/ejb => service-ejb}/src/main/java/com/maptology/service/session/VisitSessionBean.java (100%) rename {service/ejb => service-ejb}/src/main/java/com/maptology/service/session/package-info.java (100%) rename {service/ejb => service-ejb}/src/main/java/com/maptology/service/template/EmailAssignment.java (100%) rename {service/ejb => service-ejb}/src/main/java/com/maptology/service/template/EmailMessage.java (100%) rename {service/ejb => service-ejb}/src/main/java/com/maptology/service/template/EmailTemplate.java (100%) rename {service/ejb => service-ejb}/src/main/java/com/maptology/service/template/Template.java (100%) rename {service/ejb => service-ejb}/src/main/java/com/maptology/service/template/package-info.java (100%) rename {service/ejb => service-ejb}/src/main/resources/META-INF/beans.xml (100%) rename {service/ejb => service-ejb}/src/main/resources/META-INF/jboss-ejb3.xml (100%) rename {service/ejb => service-ejb}/src/main/resources/META-INF/persistence.xml (100%) rename {service/ejb => service-ejb}/src/main/resources/emails/new-email.txt (100%) rename {service/ejb => service-ejb}/src/main/resources/emails/new-user.txt (100%) rename {service/ejb => service-ejb}/src/main/resources/emails/reset-user.txt (100%) rename {service/ejb => service-ejb}/src/test/java/com/maptology/service/test/EjbDeployment.java (100%) rename {service/ejb => service-ejb}/src/test/java/com/maptology/service/test/login/LoginModule.java (100%) rename {service/ejb => service-ejb}/src/test/java/com/maptology/service/test/login/package-info.java (100%) rename {service/ejb => service-ejb}/src/test/java/com/maptology/service/test/package-info.java (100%) rename {service/ejb => service-ejb}/src/test/java/com/maptology/service/test/session/AbstractSessionTest.java (100%) rename {service/ejb => service-ejb}/src/test/java/com/maptology/service/test/session/DeviceSessionTest.java (100%) rename {service/ejb => service-ejb}/src/test/java/com/maptology/service/test/session/HistorySessionTest.java (100%) rename {service/ejb => service-ejb}/src/test/java/com/maptology/service/test/session/LocationSessionTest.java (100%) rename {service/ejb => service-ejb}/src/test/java/com/maptology/service/test/session/LogSessionTest.java (100%) rename {service/ejb => service-ejb}/src/test/java/com/maptology/service/test/session/NoticeSessionTest.java (100%) rename {service/ejb => service-ejb}/src/test/java/com/maptology/service/test/session/PrivilegeSessionTest.java (100%) rename {service/ejb => service-ejb}/src/test/java/com/maptology/service/test/session/ShareSessionTest.java (100%) rename {service/ejb => service-ejb}/src/test/java/com/maptology/service/test/session/UserSessionTest.java (100%) rename {service/ejb => service-ejb}/src/test/java/com/maptology/service/test/session/VersionSessionTest.java (100%) rename {service/ejb => service-ejb}/src/test/java/com/maptology/service/test/session/package-info.java (100%) rename {service/ejb => service-ejb}/src/test/java/com/maptology/service/test/unit/EmailTemplateTest.java (100%) rename {service/ejb => service-ejb}/src/test/java/com/maptology/service/test/unit/package-info.java (100%) rename {service/ejb => service-ejb}/src/test/resources/META-INF/beans.xml (100%) rename {service/ejb => service-ejb}/src/test/resources/META-INF/persistence.xml (100%) rename {service/ejb => service-ejb}/src/test/resources/arquillian.xml (76%) rename {service/ejb => service-ejb}/src/test/resources/emails/new-email.txt (100%) rename {service/ejb => service-ejb}/src/test/resources/emails/new-user.txt (100%) rename {service/ejb => service-ejb}/src/test/resources/emails/reset-user.txt (100%) rename {service/ejb => service-ejb}/src/test/resources/wildfly.xml (100%) create mode 100644 service-geocode/build.gradle rename {service/geocode => service-geocode}/pom.xml (85%) rename {service/geocode => service-geocode}/src/main/java/com/maptology/service/geocode/GeoLocation.java (100%) rename {service/geocode => service-geocode}/src/main/java/com/maptology/service/geocode/GeoLocationSubtype.java (100%) rename {service/geocode => service-geocode}/src/main/java/com/maptology/service/geocode/GeoLocationType.java (100%) rename {service/geocode => service-geocode}/src/main/java/com/maptology/service/geocode/GeocoderBuilder.java (100%) rename {service/geocode => service-geocode}/src/main/java/com/maptology/service/geocode/IGeocoderService.java (100%) rename {service/geocode => service-geocode}/src/main/java/com/maptology/service/geocode/package-info.java (100%) rename {service/geocode => service-geocode}/src/test/java/com/maptology/service/geocode/GeocoderServiceTest.java (100%) create mode 100644 service-thorntail/build.gradle rename {service/swarm => service-thorntail}/pom.xml (93%) rename {service/swarm => service-thorntail}/src/main/java/com/maptology/service/app/MaptologySwarmApplication.java (100%) rename {service/swarm => service-thorntail}/src/main/java/com/maptology/service/rest/MaptologySwaggerListing.java (100%) rename {service/swarm => service-thorntail}/src/main/java/com/maptology/service/swarm/MaptologySwarm.java (100%) rename {service/swarm => service-thorntail}/src/main/resources/beans.xml (100%) rename {service/swarm => service-thorntail}/src/main/resources/jboss-ejb3.xml (100%) rename {service/swarm => service-thorntail}/src/main/resources/jboss-web.xml (100%) rename {service/swarm => service-thorntail}/src/main/resources/persistence.xml (100%) rename {service/swarm => service-thorntail}/src/main/resources/web.xml (100%) rename {service/swarm => service-thorntail}/src/main/webapp/favicon-16x16.png (100%) rename {service/swarm => service-thorntail}/src/main/webapp/favicon-32x32.png (100%) rename {service/swarm => service-thorntail}/src/main/webapp/index.html (100%) rename {service/swarm => service-thorntail}/src/main/webapp/oauth2-redirect.html (100%) rename {service/swarm => service-thorntail}/src/main/webapp/swagger-ui-bundle.js (100%) rename {service/swarm => service-thorntail}/src/main/webapp/swagger-ui-standalone-preset.js (100%) rename {service/swarm => service-thorntail}/src/main/webapp/swagger-ui.css (100%) rename {service/swarm => service-thorntail}/src/main/webapp/swagger-ui.css.map (100%) rename {service/swarm => service-thorntail}/src/main/webapp/swagger-ui.js (100%) rename {service/swarm => service-thorntail}/src/main/webapp/swagger-ui.js.map (100%) create mode 100644 service-war/build.gradle rename {service/war => service-war}/pom.xml (92%) rename {service/war => service-war}/src/main/java/com/maptology/service/access/AccessControlFilter.java (100%) rename {service/war => service-war}/src/main/java/com/maptology/service/access/package-info.java (100%) rename {service/war => service-war}/src/main/java/com/maptology/service/app/MaptologyApplication.java (100%) rename {service/war => service-war}/src/main/java/com/maptology/service/app/MaptologyContextListener.java (100%) rename {service/war => service-war}/src/main/java/com/maptology/service/app/MaptologyTime.java (100%) rename {service/war => service-war}/src/main/java/com/maptology/service/auth/MaptologyAuthConfig.java (100%) rename {service/war => service-war}/src/main/java/com/maptology/service/auth/MaptologyAuthContext.java (100%) rename {service/war => service-war}/src/main/java/com/maptology/service/auth/MaptologyAuthModule.java (100%) rename {service/war => service-war}/src/main/java/com/maptology/service/auth/MaptologyAuthProvider.java (100%) rename {service/war => service-war}/src/main/java/com/maptology/service/auth/basic/BasicAuthCredential.java (100%) rename {service/war => service-war}/src/main/java/com/maptology/service/auth/bearer/BearerAuthCredential.java (100%) rename {service/war => service-war}/src/main/java/com/maptology/service/auth/http/AbstractHttpServletAuthModule.java (100%) rename {service/war => service-war}/src/main/java/com/maptology/service/auth/http/HttpServletMessageInfo.java (100%) rename {service/war => service-war}/src/main/java/com/maptology/service/auth/package-info.java (100%) rename {service/war => service-war}/src/main/java/com/maptology/service/rest/DeviceResource.java (100%) rename {service/war => service-war}/src/main/java/com/maptology/service/rest/HistoryResource.java (100%) rename {service/war => service-war}/src/main/java/com/maptology/service/rest/LocationResource.java (100%) rename {service/war => service-war}/src/main/java/com/maptology/service/rest/LogResource.java (100%) rename {service/war => service-war}/src/main/java/com/maptology/service/rest/NoticeResource.java (100%) rename {service/war => service-war}/src/main/java/com/maptology/service/rest/PrivilegeResource.java (100%) rename {service/war => service-war}/src/main/java/com/maptology/service/rest/ProcessingTimeFilter.java (100%) rename {service/war => service-war}/src/main/java/com/maptology/service/rest/ServerDebugFilter.java (100%) rename {service/war => service-war}/src/main/java/com/maptology/service/rest/ShareResource.java (100%) rename {service/war => service-war}/src/main/java/com/maptology/service/rest/UserResource.java (100%) rename {service/war => service-war}/src/main/java/com/maptology/service/rest/VersionResource.java (100%) rename {service/war => service-war}/src/main/java/com/maptology/service/servlet/TestServlet.java (100%) rename {service/war => service-war}/src/main/java/com/maptology/service/socket/LogMessageEncoder.java (100%) rename {service/war => service-war}/src/main/java/com/maptology/service/socket/LogMessageSender.java (100%) rename {service/war => service-war}/src/main/java/com/maptology/service/socket/LogStreamSocket.java (100%) rename {service/war => service-war}/src/main/java/com/maptology/service/socket/package-info.java (100%) rename {service/war => service-war}/src/main/webapp/WEB-INF/jboss-web.xml (100%) rename {service/war => service-war}/src/main/webapp/WEB-INF/web.xml (100%) rename {service/war => service-war}/src/main/webapp/favicon-16x16.png (100%) rename {service/war => service-war}/src/main/webapp/favicon-32x32.png (100%) rename {service/war => service-war}/src/main/webapp/index.html (100%) rename {service/war => service-war}/src/main/webapp/oauth2-redirect.html (100%) rename {service/war => service-war}/src/main/webapp/swagger-ui-bundle.js (100%) rename {service/war => service-war}/src/main/webapp/swagger-ui-standalone-preset.js (100%) rename {service/war => service-war}/src/main/webapp/swagger-ui.css (100%) rename {service/war => service-war}/src/main/webapp/swagger-ui.css.map (100%) rename {service/war => service-war}/src/main/webapp/swagger-ui.js (100%) rename {service/war => service-war}/src/main/webapp/swagger-ui.js.map (100%) rename {service/war => service-war}/src/test/java/com/maptology/service/test/WarDeployment.java (100%) rename {service/war => service-war}/src/test/java/com/maptology/service/test/package-info.java (100%) rename {service/war => service-war}/src/test/java/com/maptology/service/test/rest/AbstractResourceTest.java (100%) rename {service/war => service-war}/src/test/java/com/maptology/service/test/rest/AssertResponse.java (100%) rename {service/war => service-war}/src/test/java/com/maptology/service/test/rest/DeviceResourceTest.java (100%) rename {service/war => service-war}/src/test/java/com/maptology/service/test/rest/LogResourceTest.java (100%) rename {service/war => service-war}/src/test/java/com/maptology/service/test/rest/NoticeResourceTest.java (100%) rename {service/war => service-war}/src/test/java/com/maptology/service/test/rest/ShareResourceTest.java (100%) rename {service/war => service-war}/src/test/java/com/maptology/service/test/rest/UserResourceTest.java (100%) rename {service/war => service-war}/src/test/java/com/maptology/service/test/rest/VersionResourceTest.java (100%) rename {service/war => service-war}/src/test/java/com/maptology/service/test/rest/package-info.java (100%) rename {service/war => service-war}/src/test/java/com/maptology/service/test/unit/BasicAuthCredentialTest.java (100%) rename {service/war => service-war}/src/test/java/com/maptology/service/test/unit/package-info.java (100%) rename {service/war => service-war}/src/test/resources/META-INF/application.xml (100%) rename {service/war => service-war}/src/test/resources/META-INF/beans.xml (100%) rename {service/war => service-war}/src/test/resources/META-INF/jboss-ejb3.xml (100%) rename {service/war => service-war}/src/test/resources/META-INF/persistence.xml (100%) rename {service/war => service-war}/src/test/resources/arquillian.xml (84%) rename {service/wildfly => service-wildfly}/.gitignore (53%) create mode 100644 service-wildfly/build.gradle rename {service/wildfly => service-wildfly}/pom.xml (94%) delete mode 100644 service/pom.xml create mode 100644 settings.gradle create mode 100644 site-ear/build.gradle rename {ear => site-ear}/pom.xml (78%) delete mode 100644 testing/api-client/.gitignore delete mode 100644 testing/api-client/.swagger-codegen-ignore delete mode 100644 testing/api-client/.swagger-codegen/VERSION delete mode 100644 testing/api-client/.travis.yml delete mode 100644 testing/api-client/README.md delete mode 100644 testing/api-client/build.gradle delete mode 100644 testing/api-client/build.sbt delete mode 100644 testing/api-client/docs/BuildVersion.md delete mode 100644 testing/api-client/docs/Coordinate.md delete mode 100644 testing/api-client/docs/DefaultApi.md delete mode 100644 testing/api-client/docs/Device.md delete mode 100644 testing/api-client/docs/DeviceApi.md delete mode 100644 testing/api-client/docs/DeviceHandle.md delete mode 100644 testing/api-client/docs/DeviceInfo.md delete mode 100644 testing/api-client/docs/DevicePage.md delete mode 100644 testing/api-client/docs/Email.md delete mode 100644 testing/api-client/docs/EntityStatistic.md delete mode 100644 testing/api-client/docs/LoadStatistic.md delete mode 100644 testing/api-client/docs/Location.md delete mode 100644 testing/api-client/docs/LocationUpdate.md delete mode 100644 testing/api-client/docs/LogMessage.md delete mode 100644 testing/api-client/docs/Message.md delete mode 100644 testing/api-client/docs/Notice.md delete mode 100644 testing/api-client/docs/NoticePage.md delete mode 100644 testing/api-client/docs/Place.md delete mode 100644 testing/api-client/docs/PlaceApi.md delete mode 100644 testing/api-client/docs/PlacePage.md delete mode 100644 testing/api-client/docs/Privilege.md delete mode 100644 testing/api-client/docs/PrivilegeApi.md delete mode 100644 testing/api-client/docs/PrivilegePage.md delete mode 100644 testing/api-client/docs/ReleasedLocation.md delete mode 100644 testing/api-client/docs/ServiceApi.md delete mode 100644 testing/api-client/docs/Share.md delete mode 100644 testing/api-client/docs/ShareApi.md delete mode 100644 testing/api-client/docs/ShareInfo.md delete mode 100644 testing/api-client/docs/User.md delete mode 100644 testing/api-client/docs/UserApi.md delete mode 100644 testing/api-client/docs/UserPage.md delete mode 100644 testing/api-client/docs/UserPassword.md delete mode 100644 testing/api-client/docs/UserRegistration.md delete mode 100644 testing/api-client/docs/Visit.md delete mode 100644 testing/api-client/docs/VisitPage.md delete mode 100644 testing/api-client/git_push.sh delete mode 100644 testing/api-client/gradle.properties delete mode 100644 testing/api-client/gradle/wrapper/gradle-wrapper.jar delete mode 100644 testing/api-client/pom.xml delete mode 100644 testing/api-client/settings.gradle delete mode 100644 testing/api-client/src/main/AndroidManifest.xml delete mode 100644 testing/api-client/src/main/java/io/swagger/client/ApiCallback.java delete mode 100644 testing/api-client/src/main/java/io/swagger/client/ApiClient.java delete mode 100644 testing/api-client/src/main/java/io/swagger/client/ApiException.java delete mode 100644 testing/api-client/src/main/java/io/swagger/client/ApiResponse.java delete mode 100644 testing/api-client/src/main/java/io/swagger/client/Configuration.java delete mode 100644 testing/api-client/src/main/java/io/swagger/client/GzipRequestInterceptor.java delete mode 100644 testing/api-client/src/main/java/io/swagger/client/JSON.java delete mode 100644 testing/api-client/src/main/java/io/swagger/client/Pair.java delete mode 100644 testing/api-client/src/main/java/io/swagger/client/ProgressRequestBody.java delete mode 100644 testing/api-client/src/main/java/io/swagger/client/ProgressResponseBody.java delete mode 100644 testing/api-client/src/main/java/io/swagger/client/StringUtil.java delete mode 100644 testing/api-client/src/main/java/io/swagger/client/api/DefaultApi.java delete mode 100644 testing/api-client/src/main/java/io/swagger/client/api/DeviceApi.java delete mode 100644 testing/api-client/src/main/java/io/swagger/client/api/PlaceApi.java delete mode 100644 testing/api-client/src/main/java/io/swagger/client/api/PrivilegeApi.java delete mode 100644 testing/api-client/src/main/java/io/swagger/client/api/ServiceApi.java delete mode 100644 testing/api-client/src/main/java/io/swagger/client/api/ShareApi.java delete mode 100644 testing/api-client/src/main/java/io/swagger/client/api/UserApi.java delete mode 100644 testing/api-client/src/main/java/io/swagger/client/auth/ApiKeyAuth.java delete mode 100644 testing/api-client/src/main/java/io/swagger/client/auth/Authentication.java delete mode 100644 testing/api-client/src/main/java/io/swagger/client/auth/HttpBasicAuth.java delete mode 100644 testing/api-client/src/main/java/io/swagger/client/auth/OAuth.java delete mode 100644 testing/api-client/src/main/java/io/swagger/client/auth/OAuthFlow.java delete mode 100644 testing/api-client/src/main/java/io/swagger/client/model/BuildVersion.java delete mode 100644 testing/api-client/src/main/java/io/swagger/client/model/Coordinate.java delete mode 100644 testing/api-client/src/main/java/io/swagger/client/model/Device.java delete mode 100644 testing/api-client/src/main/java/io/swagger/client/model/DeviceHandle.java delete mode 100644 testing/api-client/src/main/java/io/swagger/client/model/DeviceInfo.java delete mode 100644 testing/api-client/src/main/java/io/swagger/client/model/DevicePage.java delete mode 100644 testing/api-client/src/main/java/io/swagger/client/model/Email.java delete mode 100644 testing/api-client/src/main/java/io/swagger/client/model/EntityStatistic.java delete mode 100644 testing/api-client/src/main/java/io/swagger/client/model/LoadStatistic.java delete mode 100644 testing/api-client/src/main/java/io/swagger/client/model/Location.java delete mode 100644 testing/api-client/src/main/java/io/swagger/client/model/LocationUpdate.java delete mode 100644 testing/api-client/src/main/java/io/swagger/client/model/LogMessage.java delete mode 100644 testing/api-client/src/main/java/io/swagger/client/model/Message.java delete mode 100644 testing/api-client/src/main/java/io/swagger/client/model/Notice.java delete mode 100644 testing/api-client/src/main/java/io/swagger/client/model/NoticePage.java delete mode 100644 testing/api-client/src/main/java/io/swagger/client/model/Place.java delete mode 100644 testing/api-client/src/main/java/io/swagger/client/model/PlacePage.java delete mode 100644 testing/api-client/src/main/java/io/swagger/client/model/Privilege.java delete mode 100644 testing/api-client/src/main/java/io/swagger/client/model/PrivilegePage.java delete mode 100644 testing/api-client/src/main/java/io/swagger/client/model/ReleasedLocation.java delete mode 100644 testing/api-client/src/main/java/io/swagger/client/model/Share.java delete mode 100644 testing/api-client/src/main/java/io/swagger/client/model/ShareInfo.java delete mode 100644 testing/api-client/src/main/java/io/swagger/client/model/User.java delete mode 100644 testing/api-client/src/main/java/io/swagger/client/model/UserPage.java delete mode 100644 testing/api-client/src/main/java/io/swagger/client/model/UserPassword.java delete mode 100644 testing/api-client/src/main/java/io/swagger/client/model/UserRegistration.java delete mode 100644 testing/api-client/src/main/java/io/swagger/client/model/Visit.java delete mode 100644 testing/api-client/src/main/java/io/swagger/client/model/VisitPage.java delete mode 100644 testing/api-client/src/main/resources/api/maptology.json delete mode 100644 testing/api-client/src/test/java/io/swagger/client/api/DefaultApiTest.java delete mode 100644 testing/api-client/src/test/java/io/swagger/client/api/DeviceApiTest.java delete mode 100644 testing/api-client/src/test/java/io/swagger/client/api/PlaceApiTest.java delete mode 100644 testing/api-client/src/test/java/io/swagger/client/api/PrivilegeApiTest.java delete mode 100644 testing/api-client/src/test/java/io/swagger/client/api/ServiceApiTest.java delete mode 100644 testing/api-client/src/test/java/io/swagger/client/api/ShareApiTest.java delete mode 100644 testing/api-client/src/test/java/io/swagger/client/api/UserApiTest.java delete mode 100644 testing/performance/pom.xml delete mode 100644 testing/performance/src/main/java/com/maptology/testing/performance/Main.java delete mode 100644 testing/pom.xml rename {web/angular => web-angular}/.editorconfig (100%) rename {web/angular => web-angular}/.gitignore (100%) rename {web/angular => web-angular}/README.md (100%) rename {web/angular => web-angular}/angular.json (100%) rename {web/angular => web-angular}/browserslist (100%) create mode 100644 web-angular/build.gradle rename {web/angular => web-angular}/e2e/app.e2e-spec.ts (100%) rename {web/angular => web-angular}/e2e/app.po.ts (100%) rename {web/angular => web-angular}/e2e/tsconfig.e2e.json (100%) rename {web/angular => web-angular}/karma.conf.js (100%) rename {web/angular => web-angular}/package.json (100%) rename {web/angular => web-angular}/pom.xml (94%) rename {web/angular => web-angular}/protractor.conf.js (100%) rename {web/angular => web-angular}/proxy.conf.json (100%) rename {web/angular => web-angular}/src/app/app.component.html (100%) mode change 100755 => 100644 rename {web/angular => web-angular}/src/app/app.component.ts (100%) mode change 100755 => 100644 rename {web/angular => web-angular}/src/app/app.module.ts (100%) mode change 100755 => 100644 rename {web/angular => web-angular}/src/app/app.routing.ts (100%) mode change 100755 => 100644 rename {web/angular => web-angular}/src/app/directives/use-parent-form.directive.ts (100%) rename {web/angular => web-angular}/src/app/guards/auth.guard.ts (100%) rename {web/angular => web-angular}/src/app/interceptors/auth.interceptor.ts (100%) rename {web/angular => web-angular}/src/app/interceptors/delay.interceptor.ts (100%) rename {web/angular => web-angular}/src/app/layouts/drawer.component.html (100%) rename {web/angular => web-angular}/src/app/layouts/drawer.component.ts (100%) rename {web/angular => web-angular}/src/app/layouts/footer.component.html (100%) rename {web/angular => web-angular}/src/app/layouts/footer.component.ts (100%) rename {web/angular => web-angular}/src/app/layouts/inside.component.html (100%) rename {web/angular => web-angular}/src/app/layouts/inside.component.ts (100%) rename {web/angular => web-angular}/src/app/layouts/outside.component.html (100%) rename {web/angular => web-angular}/src/app/layouts/outside.component.ts (100%) rename {web/angular => web-angular}/src/app/providers/paginator.provider.ts (100%) rename {web/angular => web-angular}/src/app/services/console.service.ts (100%) rename {web/angular => web-angular}/src/app/services/credential.service.ts (100%) rename {web/angular => web-angular}/src/app/services/device-visit.service.ts (100%) rename {web/angular => web-angular}/src/app/services/device.service.ts (100%) rename {web/angular => web-angular}/src/app/services/manage-log.service.ts (100%) rename {web/angular => web-angular}/src/app/services/manage-notice.service.ts (100%) rename {web/angular => web-angular}/src/app/services/manage-user.service.ts (100%) rename {web/angular => web-angular}/src/app/services/notice.service.ts (100%) rename {web/angular => web-angular}/src/app/services/place-visit.service.ts (100%) rename {web/angular => web-angular}/src/app/services/place.service.ts (100%) rename {web/angular => web-angular}/src/app/services/privilege.service.ts (100%) rename {web/angular => web-angular}/src/app/services/resource.service.ts (100%) rename {web/angular => web-angular}/src/app/services/user.service.ts (100%) rename {web/angular => web-angular}/src/app/services/version.service.ts (100%) rename {web/angular => web-angular}/src/app/utils/formcodes.ts (100%) rename {web/angular => web-angular}/src/app/utils/httpcodes.ts (100%) rename {web/angular => web-angular}/src/app/utils/pagination.ts (100%) rename {web/angular => web-angular}/src/app/utils/snackbars.ts (100%) rename {web/angular => web-angular}/src/app/utils/tables.ts (100%) rename {web/angular => web-angular}/src/app/views/activate.component.html (100%) rename {web/angular => web-angular}/src/app/views/activate.component.ts (100%) rename {web/angular => web-angular}/src/app/views/change.component.html (100%) rename {web/angular => web-angular}/src/app/views/change.component.ts (100%) rename {web/angular => web-angular}/src/app/views/device-location.component.html (100%) rename {web/angular => web-angular}/src/app/views/device-location.component.ts (100%) rename {web/angular => web-angular}/src/app/views/device-visits.component.html (100%) rename {web/angular => web-angular}/src/app/views/device-visits.component.ts (100%) rename {web/angular => web-angular}/src/app/views/devices.component.html (100%) rename {web/angular => web-angular}/src/app/views/devices.component.ts (100%) rename {web/angular => web-angular}/src/app/views/edit-notice.component.html (100%) rename {web/angular => web-angular}/src/app/views/edit-notice.component.ts (100%) rename {web/angular => web-angular}/src/app/views/login.component.html (100%) rename {web/angular => web-angular}/src/app/views/login.component.ts (100%) rename {web/angular => web-angular}/src/app/views/manage-log.component.html (100%) rename {web/angular => web-angular}/src/app/views/manage-log.component.ts (100%) rename {web/angular => web-angular}/src/app/views/manage-notices.component.html (100%) rename {web/angular => web-angular}/src/app/views/manage-notices.component.ts (100%) rename {web/angular => web-angular}/src/app/views/manage-system.component.html (100%) rename {web/angular => web-angular}/src/app/views/manage-system.component.ts (100%) rename {web/angular => web-angular}/src/app/views/manage-users.component.html (100%) rename {web/angular => web-angular}/src/app/views/manage-users.component.ts (100%) rename {web/angular => web-angular}/src/app/views/notices.component.html (100%) rename {web/angular => web-angular}/src/app/views/notices.component.ts (100%) rename {web/angular => web-angular}/src/app/views/place-visits.component.html (100%) rename {web/angular => web-angular}/src/app/views/place-visits.component.ts (100%) rename {web/angular => web-angular}/src/app/views/places.component.html (100%) rename {web/angular => web-angular}/src/app/views/places.component.ts (100%) rename {web/angular => web-angular}/src/app/views/privileges.component.html (100%) rename {web/angular => web-angular}/src/app/views/privileges.component.ts (100%) rename {web/angular => web-angular}/src/app/views/register.component.html (100%) rename {web/angular => web-angular}/src/app/views/register.component.ts (100%) rename {web/angular => web-angular}/src/app/views/reset.component.html (100%) rename {web/angular => web-angular}/src/app/views/reset.component.ts (100%) rename {web/angular => web-angular}/src/app/views/share.component.html (100%) rename {web/angular => web-angular}/src/app/views/share.component.ts (100%) rename {web/angular => web-angular}/src/app/views/user.component.html (100%) rename {web/angular => web-angular}/src/app/views/user.component.ts (100%) rename {web/angular => web-angular}/src/app/widgets/confirmation-dialog.component.html (100%) rename {web/angular => web-angular}/src/app/widgets/confirmation-dialog.component.ts (100%) rename {web/angular => web-angular}/src/app/widgets/decision-panel.component.html (100%) rename {web/angular => web-angular}/src/app/widgets/decision-panel.component.ts (100%) rename {web/angular => web-angular}/src/app/widgets/email-field.component.html (100%) rename {web/angular => web-angular}/src/app/widgets/email-field.component.ts (100%) rename {web/angular => web-angular}/src/app/widgets/language-select.component.html (100%) rename {web/angular => web-angular}/src/app/widgets/language-select.component.ts (100%) rename {web/angular => web-angular}/src/app/widgets/log-dialog.component.html (100%) rename {web/angular => web-angular}/src/app/widgets/log-dialog.component.ts (100%) rename {web/angular => web-angular}/src/app/widgets/login-field.component.html (100%) rename {web/angular => web-angular}/src/app/widgets/login-field.component.ts (100%) rename {web/angular => web-angular}/src/app/widgets/marker-map.component.html (100%) rename {web/angular => web-angular}/src/app/widgets/marker-map.component.ts (100%) rename {web/angular => web-angular}/src/app/widgets/message-dialog.component.html (100%) rename {web/angular => web-angular}/src/app/widgets/message-dialog.component.ts (100%) rename {web/angular => web-angular}/src/app/widgets/name-field.component.html (100%) rename {web/angular => web-angular}/src/app/widgets/name-field.component.ts (100%) rename {web/angular => web-angular}/src/app/widgets/nickname-dialog.component.html (100%) rename {web/angular => web-angular}/src/app/widgets/nickname-dialog.component.ts (100%) rename {web/angular => web-angular}/src/app/widgets/notice-card.component.html (100%) rename {web/angular => web-angular}/src/app/widgets/notice-card.component.ts (100%) rename {web/angular => web-angular}/src/app/widgets/password-field.component.html (100%) rename {web/angular => web-angular}/src/app/widgets/password-field.component.ts (100%) rename {web/angular => web-angular}/src/app/widgets/profile-button.component.html (100%) rename {web/angular => web-angular}/src/app/widgets/profile-button.component.ts (100%) rename {web/angular => web-angular}/src/app/widgets/share-dialog.component.html (100%) rename {web/angular => web-angular}/src/app/widgets/share-dialog.component.ts (100%) rename {web/angular => web-angular}/src/app/widgets/tile-map.component.html (100%) rename {web/angular => web-angular}/src/app/widgets/tile-map.component.ts (100%) rename {web/angular => web-angular}/src/app/widgets/toolbar-button.component.html (100%) rename {web/angular => web-angular}/src/app/widgets/toolbar-button.component.ts (100%) rename {web/angular => web-angular}/src/assets/.gitkeep (100%) mode change 100755 => 100644 rename {web/angular => web-angular}/src/assets/flags/de.svg (100%) rename {web/angular => web-angular}/src/assets/flags/en.svg (100%) rename {web/angular => web-angular}/src/assets/flags/es.svg (100%) rename {web/angular => web-angular}/src/assets/flags/fr.svg (100%) rename {web/angular => web-angular}/src/assets/flags/it.svg (100%) rename {web/angular => web-angular}/src/assets/fonts/MaterialIcons-Regular.eot (100%) rename {web/angular => web-angular}/src/assets/fonts/MaterialIcons-Regular.ttf (100%) rename {web/angular => web-angular}/src/assets/fonts/MaterialIcons-Regular.woff (100%) rename {web/angular => web-angular}/src/assets/fonts/MaterialIcons-Regular.woff2 (100%) rename {web/angular => web-angular}/src/assets/fonts/RobotoLatin-Regular.eot (100%) rename {web/angular => web-angular}/src/assets/fonts/RobotoLatin-Regular.ttf (100%) rename {web/angular => web-angular}/src/assets/fonts/RobotoLatin-Regular.woff (100%) rename {web/angular => web-angular}/src/assets/fonts/RobotoLatin-Regular.woff2 (100%) rename {web/angular => web-angular}/src/assets/fonts/RobotoMonoLatin-Regular.eot (100%) rename {web/angular => web-angular}/src/assets/fonts/RobotoMonoLatin-Regular.ttf (100%) rename {web/angular => web-angular}/src/assets/fonts/RobotoMonoLatin-Regular.woff (100%) rename {web/angular => web-angular}/src/assets/fonts/RobotoMonoLatin-Regular.woff2 (100%) rename {web/angular => web-angular}/src/assets/icons/favicon-114x114.png (100%) rename {web/angular => web-angular}/src/assets/icons/favicon-120x120.png (100%) rename {web/angular => web-angular}/src/assets/icons/favicon-144x144.png (100%) rename {web/angular => web-angular}/src/assets/icons/favicon-152x152.png (100%) rename {web/angular => web-angular}/src/assets/icons/favicon-16x16.png (100%) rename {web/angular => web-angular}/src/assets/icons/favicon-180x180.png (100%) rename {web/angular => web-angular}/src/assets/icons/favicon-192x192.png (100%) rename {web/angular => web-angular}/src/assets/icons/favicon-32x32.png (100%) rename {web/angular => web-angular}/src/assets/icons/favicon-57x57.png (100%) rename {web/angular => web-angular}/src/assets/icons/favicon-60x60.png (100%) rename {web/angular => web-angular}/src/assets/icons/favicon-72x72.png (100%) rename {web/angular => web-angular}/src/assets/icons/favicon-76x76.png (100%) rename {web/angular => web-angular}/src/assets/icons/favicon-96x96.png (100%) rename {web/angular => web-angular}/src/assets/icons/home.svg (100%) rename {web/angular => web-angular}/src/assets/images/frontpage.png (100%) rename {web/angular => web-angular}/src/assets/markers/marker_dark.png (100%) rename {web/angular => web-angular}/src/assets/markers/marker_normal.png (100%) rename {web/angular => web-angular}/src/assets/markers/marker_pin.png (100%) rename {web/angular => web-angular}/src/assets/markers/marker_shadow.png (100%) rename {web/angular => web-angular}/src/environments/environment.prod.ts (100%) mode change 100755 => 100644 rename {web/angular => web-angular}/src/environments/environment.ts (100%) mode change 100755 => 100644 rename {web/angular => web-angular}/src/favicon.ico (100%) rename {web/angular => web-angular}/src/fonts.scss (100%) rename {web/angular => web-angular}/src/index.html (100%) mode change 100755 => 100644 rename {web/angular => web-angular}/src/main.ts (100%) rename {web/angular => web-angular}/src/polyfills.ts (100%) rename {web/angular => web-angular}/src/styles.scss (100%) rename {web/angular => web-angular}/src/test.ts (100%) rename {web/angular => web-angular}/src/theme.scss (100%) rename {web/angular => web-angular}/src/tsconfig.app.json (100%) rename {web/angular => web-angular}/src/tsconfig.spec.json (100%) rename {web/angular => web-angular}/src/typings.d.ts (100%) rename {web/angular => web-angular}/tsconfig.json (100%) rename {web/angular => web-angular}/tslint.json (100%) create mode 100644 web-war/build.gradle rename {web/webapp => web-war}/pom.xml (88%) rename {web/webapp => web-war}/src/main/java/.keep (100%) rename {web/webapp => web-war}/src/main/java/com/maptology/web/webapp/AngularRouterServlet.java (100%) rename {web/webapp => web-war}/src/main/webapp/WEB-INF/jboss-web.xml (100%) rename {web/webapp => web-war}/src/main/webapp/WEB-INF/web.xml (100%) rename {web/webapp => web-war}/src/test/java/.keep (100%) rename {web/webapp => web-war}/src/test/resources/.keep (100%) delete mode 100644 web/pom.xml diff --git a/.gitignore b/.gitignore index e515d72..8fccaee 100644 --- a/.gitignore +++ b/.gitignore @@ -39,4 +39,8 @@ lint.xml #nodejs node/ -node_modules/ \ No newline at end of file +node_modules/ + +#gradle +build/ +.gradle/ diff --git a/Jenkinsfile b/Jenkinsfile index 2641bfb..1252f56 100644 --- a/Jenkinsfile +++ b/Jenkinsfile @@ -3,6 +3,46 @@ // this groovy script is executed by jenkins node { + + def gradleInfo + def server = Artifactory.server 'project.nes.uni-due.de' + def gradleBuild = Artifactory.newGradleBuild() + gradleBuild.tool = 'gradle-5.5.1' + gradleBuild.usesPlugin = true + + // checkout code from scm + stage('Checkout') { + checkout scm + } + + // configure the deployer based on the version + stage('Configure') { + def version = sh (script: "./gradlew properties -q | grep \"version:\" | awk '{print \$2}'", returnStdout: true).trim() + if (version.endsWith("-SNAPSHOT")) { + gradleBuild.deployer server: server, repo: 'internal-snapshots' + } else { + gradleBuild.deployer server: server, repo: 'internal-releases' + } + } + + // build the source code with gradle + stage('Build') { + gradleInfo = gradleBuild.run buildFile: 'build.gradle', tasks: 'clean publish', switches ="-Djenkins.build.number=${env.BUILD_NUMBER}" + } + + // deploy the final ear + stage ('Publish') { + if (env.BRANCH_NAME == "master") { + gradleInfo = gradleBuild.run buildFile: 'build.gradle', tasks: 'artifactoryPublish' + } else { + echo "Skipping deployment for non-master branch." + } + } + + + +/* + // configure maven path for 3.3.9 def mvnHome = tool 'maven-3.3.9' @@ -34,5 +74,6 @@ node { echo "Skipping deployment for non-master branch." } } +*/ } diff --git a/android-app/build.gradle b/android-app/build.gradle new file mode 100644 index 0000000..cc63186 --- /dev/null +++ b/android-app/build.gradle @@ -0,0 +1,42 @@ +description = "Maptology Android App" + +dependencies { + implementation fileTree(dir: "libs", include: ["*.jar"]) + implementation project(":android-feign") + implementation "com.android.support:appcompat-v7:${versionSupport}" + implementation "com.android.support:design:${versionSupport}" + implementation "com.android.support:preference-v7:${versionSupport}" + implementation "com.android.support:cardview-v7:${versionSupport}" + implementation "com.android.support:recyclerview-v7:${versionSupport}" + testImplementation "junit:junit:${versionJunit}" + testImplementation "org.robolectric:robolectric:${versionRobolectric}" + testImplementation "org.robolectric:shadows-supportv4:${versionRobolectric}" +} + +android { + compileSdkVersion 28 + defaultConfig { + applicationId "com.maptology.android.app" + minSdkVersion 14 + targetSdkVersion 28 + versionCode 2 + versionName "1.0" + testInstrumentationRunner "android.support.test.runner.AndroidJUnitRunner" + } + buildTypes { + release { + minifyEnabled false + proguardFiles getDefaultProguardFile("proguard-android.txt"), "proguard-rules.pro" + } + } + testOptions { + unitTests { + includeAndroidResources = true + } + } + + lintOptions { + abortOnError false +// disable "InvalidPackage" + } +} diff --git a/android/app/pom.xml b/android-app/pom.xml similarity index 92% rename from android/app/pom.xml rename to android-app/pom.xml index 31446be..4e51330 100644 --- a/android/app/pom.xml +++ b/android-app/pom.xml @@ -3,13 +3,13 @@ xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd"> - android + project com.maptology 0.0.1-SNAPSHOT 4.0.0 - com.maptology.android - app + com.maptology + android-app Maptology Android App Source code of the maptology app. apk @@ -115,8 +115,8 @@ - com.maptology.android - feign + com.maptology + android-feign ${project.version} @@ -168,11 +168,5 @@ recyclerview-v7 aar - - com.maptology.android - leafless - ${project.version} - aar - diff --git a/android/app/project.properties b/android-app/project.properties similarity index 100% rename from android/app/project.properties rename to android-app/project.properties diff --git a/android/app/src/main/AndroidManifest.xml b/android-app/src/main/AndroidManifest.xml similarity index 93% rename from android/app/src/main/AndroidManifest.xml rename to android-app/src/main/AndroidManifest.xml index cbd25c6..96c30fb 100644 --- a/android/app/src/main/AndroidManifest.xml +++ b/android-app/src/main/AndroidManifest.xml @@ -1,12 +1,7 @@ + package="com.maptology.android.app"> - diff --git a/android/app/src/main/assets/incoming_marker.png b/android-app/src/main/assets/incoming_marker.png similarity index 100% rename from android/app/src/main/assets/incoming_marker.png rename to android-app/src/main/assets/incoming_marker.png diff --git a/android/app/src/main/assets/marker_dark.png b/android-app/src/main/assets/marker_dark.png similarity index 100% rename from android/app/src/main/assets/marker_dark.png rename to android-app/src/main/assets/marker_dark.png diff --git a/android/app/src/main/assets/marker_normal.png b/android-app/src/main/assets/marker_normal.png similarity index 100% rename from android/app/src/main/assets/marker_normal.png rename to android-app/src/main/assets/marker_normal.png diff --git a/android/app/src/main/assets/marker_pin.png b/android-app/src/main/assets/marker_pin.png similarity index 100% rename from android/app/src/main/assets/marker_pin.png rename to android-app/src/main/assets/marker_pin.png diff --git a/android/app/src/main/assets/marker_shadow.png b/android-app/src/main/assets/marker_shadow.png similarity index 100% rename from android/app/src/main/assets/marker_shadow.png rename to android-app/src/main/assets/marker_shadow.png diff --git a/android/app/src/main/assets/terms.html b/android-app/src/main/assets/terms.html similarity index 100% rename from android/app/src/main/assets/terms.html rename to android-app/src/main/assets/terms.html diff --git a/android/app/src/main/icons/logos.cdr b/android-app/src/main/icons/logos.cdr similarity index 100% rename from android/app/src/main/icons/logos.cdr rename to android-app/src/main/icons/logos.cdr diff --git a/android/app/src/main/java/com/maptology/android/app/BootReceiver.java b/android-app/src/main/java/com/maptology/android/app/BootReceiver.java similarity index 100% rename from android/app/src/main/java/com/maptology/android/app/BootReceiver.java rename to android-app/src/main/java/com/maptology/android/app/BootReceiver.java diff --git a/android/app/src/main/java/com/maptology/android/app/LocationService.java b/android-app/src/main/java/com/maptology/android/app/LocationService.java similarity index 100% rename from android/app/src/main/java/com/maptology/android/app/LocationService.java rename to android-app/src/main/java/com/maptology/android/app/LocationService.java diff --git a/android/app/src/main/java/com/maptology/android/app/LoginActivity.java b/android-app/src/main/java/com/maptology/android/app/LoginActivity.java similarity index 100% rename from android/app/src/main/java/com/maptology/android/app/LoginActivity.java rename to android-app/src/main/java/com/maptology/android/app/LoginActivity.java diff --git a/android/app/src/main/java/com/maptology/android/app/MainActivity.java b/android-app/src/main/java/com/maptology/android/app/MainActivity.java similarity index 100% rename from android/app/src/main/java/com/maptology/android/app/MainActivity.java rename to android-app/src/main/java/com/maptology/android/app/MainActivity.java diff --git a/android/app/src/main/java/com/maptology/android/app/MaptologyApp.java b/android-app/src/main/java/com/maptology/android/app/MaptologyApp.java similarity index 100% rename from android/app/src/main/java/com/maptology/android/app/MaptologyApp.java rename to android-app/src/main/java/com/maptology/android/app/MaptologyApp.java diff --git a/android/app/src/main/java/com/maptology/android/app/NoticeReceiver.java b/android-app/src/main/java/com/maptology/android/app/NoticeReceiver.java similarity index 100% rename from android/app/src/main/java/com/maptology/android/app/NoticeReceiver.java rename to android-app/src/main/java/com/maptology/android/app/NoticeReceiver.java diff --git a/android/app/src/main/java/com/maptology/android/app/StartActivity.java b/android-app/src/main/java/com/maptology/android/app/StartActivity.java similarity index 100% rename from android/app/src/main/java/com/maptology/android/app/StartActivity.java rename to android-app/src/main/java/com/maptology/android/app/StartActivity.java diff --git a/android/app/src/main/java/com/maptology/android/app/UploadService.java b/android-app/src/main/java/com/maptology/android/app/UploadService.java similarity index 100% rename from android/app/src/main/java/com/maptology/android/app/UploadService.java rename to android-app/src/main/java/com/maptology/android/app/UploadService.java diff --git a/android/app/src/main/java/com/maptology/android/app/adapter/AlertDialogAdapter.java b/android-app/src/main/java/com/maptology/android/app/adapter/AlertDialogAdapter.java similarity index 100% rename from android/app/src/main/java/com/maptology/android/app/adapter/AlertDialogAdapter.java rename to android-app/src/main/java/com/maptology/android/app/adapter/AlertDialogAdapter.java diff --git a/android/app/src/main/java/com/maptology/android/app/adapter/DetailViewHolder.java b/android-app/src/main/java/com/maptology/android/app/adapter/DetailViewHolder.java similarity index 99% rename from android/app/src/main/java/com/maptology/android/app/adapter/DetailViewHolder.java rename to android-app/src/main/java/com/maptology/android/app/adapter/DetailViewHolder.java index cd4326b..eea357c 100644 --- a/android/app/src/main/java/com/maptology/android/app/adapter/DetailViewHolder.java +++ b/android-app/src/main/java/com/maptology/android/app/adapter/DetailViewHolder.java @@ -11,7 +11,6 @@ import com.maptology.android.app.util.DateFormatter; import com.maptology.android.feign.model.Location; import com.maptology.android.feign.model.ShareInfo; -import javax.xml.soap.Text; /** diff --git a/android/app/src/main/java/com/maptology/android/app/adapter/GrantAdapter.java b/android-app/src/main/java/com/maptology/android/app/adapter/GrantAdapter.java similarity index 100% rename from android/app/src/main/java/com/maptology/android/app/adapter/GrantAdapter.java rename to android-app/src/main/java/com/maptology/android/app/adapter/GrantAdapter.java diff --git a/android/app/src/main/java/com/maptology/android/app/adapter/NoticeAdapter.java b/android-app/src/main/java/com/maptology/android/app/adapter/NoticeAdapter.java similarity index 100% rename from android/app/src/main/java/com/maptology/android/app/adapter/NoticeAdapter.java rename to android-app/src/main/java/com/maptology/android/app/adapter/NoticeAdapter.java diff --git a/android/app/src/main/java/com/maptology/android/app/adapter/ShareAdapter.java b/android-app/src/main/java/com/maptology/android/app/adapter/ShareAdapter.java similarity index 100% rename from android/app/src/main/java/com/maptology/android/app/adapter/ShareAdapter.java rename to android-app/src/main/java/com/maptology/android/app/adapter/ShareAdapter.java diff --git a/android/app/src/main/java/com/maptology/android/app/fragment/AbstractFragment.java b/android-app/src/main/java/com/maptology/android/app/fragment/AbstractFragment.java similarity index 100% rename from android/app/src/main/java/com/maptology/android/app/fragment/AbstractFragment.java rename to android-app/src/main/java/com/maptology/android/app/fragment/AbstractFragment.java diff --git a/android/app/src/main/java/com/maptology/android/app/fragment/DatePickerFragment.java b/android-app/src/main/java/com/maptology/android/app/fragment/DatePickerFragment.java similarity index 100% rename from android/app/src/main/java/com/maptology/android/app/fragment/DatePickerFragment.java rename to android-app/src/main/java/com/maptology/android/app/fragment/DatePickerFragment.java diff --git a/android/app/src/main/java/com/maptology/android/app/fragment/DetailFragment.java b/android-app/src/main/java/com/maptology/android/app/fragment/DetailFragment.java similarity index 100% rename from android/app/src/main/java/com/maptology/android/app/fragment/DetailFragment.java rename to android-app/src/main/java/com/maptology/android/app/fragment/DetailFragment.java diff --git a/android/app/src/main/java/com/maptology/android/app/fragment/DetailPagerFragment.java b/android-app/src/main/java/com/maptology/android/app/fragment/DetailPagerFragment.java similarity index 100% rename from android/app/src/main/java/com/maptology/android/app/fragment/DetailPagerFragment.java rename to android-app/src/main/java/com/maptology/android/app/fragment/DetailPagerFragment.java diff --git a/android/app/src/main/java/com/maptology/android/app/fragment/GrantListFragment.java b/android-app/src/main/java/com/maptology/android/app/fragment/GrantListFragment.java similarity index 99% rename from android/app/src/main/java/com/maptology/android/app/fragment/GrantListFragment.java rename to android-app/src/main/java/com/maptology/android/app/fragment/GrantListFragment.java index 3c0e885..2c44262 100644 --- a/android/app/src/main/java/com/maptology/android/app/fragment/GrantListFragment.java +++ b/android-app/src/main/java/com/maptology/android/app/fragment/GrantListFragment.java @@ -27,8 +27,6 @@ import com.maptology.android.app.task.UpdateGrantsTask; import com.maptology.android.app.util.ActionUtil; import com.maptology.android.app.util.TabletUtil; -import javax.xml.soap.Text; - /** * Displays the grants. * diff --git a/android/app/src/main/java/com/maptology/android/app/fragment/LoginFragment.java b/android-app/src/main/java/com/maptology/android/app/fragment/LoginFragment.java similarity index 100% rename from android/app/src/main/java/com/maptology/android/app/fragment/LoginFragment.java rename to android-app/src/main/java/com/maptology/android/app/fragment/LoginFragment.java diff --git a/android/app/src/main/java/com/maptology/android/app/fragment/LogoFragment.java b/android-app/src/main/java/com/maptology/android/app/fragment/LogoFragment.java similarity index 96% rename from android/app/src/main/java/com/maptology/android/app/fragment/LogoFragment.java rename to android-app/src/main/java/com/maptology/android/app/fragment/LogoFragment.java index 7246898..feb94ad 100644 --- a/android/app/src/main/java/com/maptology/android/app/fragment/LogoFragment.java +++ b/android-app/src/main/java/com/maptology/android/app/fragment/LogoFragment.java @@ -1,25 +1,25 @@ -package com.maptology.android.app.fragment; - -import android.os.Bundle; -import android.support.annotation.Nullable; -import android.view.LayoutInflater; -import android.view.View; -import android.view.ViewGroup; -import com.maptology.android.app.R; - -/** - * Fragment to display maptology logo. - * - * @author sarah - */ -public class LogoFragment extends AbstractFragment { - @Override - public void onCreate(@Nullable Bundle savedInstanceState) { - super.onCreate(savedInstanceState); - } - - @Override - public View onCreateView(LayoutInflater inflater, ViewGroup container, Bundle savedInstanceState) { - return inflater.inflate(R.layout.fragment_logo, container, false); - } -} +package com.maptology.android.app.fragment; + +import android.os.Bundle; +import android.support.annotation.Nullable; +import android.view.LayoutInflater; +import android.view.View; +import android.view.ViewGroup; +import com.maptology.android.app.R; + +/** + * Fragment to display maptology logo. + * + * @author sarah + */ +public class LogoFragment extends AbstractFragment { + @Override + public void onCreate(@Nullable Bundle savedInstanceState) { + super.onCreate(savedInstanceState); + } + + @Override + public View onCreateView(LayoutInflater inflater, ViewGroup container, Bundle savedInstanceState) { + return inflater.inflate(R.layout.fragment_logo, container, false); + } +} diff --git a/android/app/src/main/java/com/maptology/android/app/fragment/ManageFragment.java b/android-app/src/main/java/com/maptology/android/app/fragment/ManageFragment.java similarity index 100% rename from android/app/src/main/java/com/maptology/android/app/fragment/ManageFragment.java rename to android-app/src/main/java/com/maptology/android/app/fragment/ManageFragment.java diff --git a/android/app/src/main/java/com/maptology/android/app/fragment/MapFragment.java b/android-app/src/main/java/com/maptology/android/app/fragment/MapFragment.java similarity index 95% rename from android/app/src/main/java/com/maptology/android/app/fragment/MapFragment.java rename to android-app/src/main/java/com/maptology/android/app/fragment/MapFragment.java index 14b263e..8c4a39a 100644 --- a/android/app/src/main/java/com/maptology/android/app/fragment/MapFragment.java +++ b/android-app/src/main/java/com/maptology/android/app/fragment/MapFragment.java @@ -14,18 +14,18 @@ import android.view.MenuInflater; import android.view.MenuItem; import android.view.View; import android.view.ViewGroup; -import com.locoslab.api.data.maps.model.Box; -import com.locoslab.capi.android.leafless.IMapStateListener; -import com.locoslab.capi.android.leafless.ITouchListener; -import com.locoslab.capi.android.leafless.MapOptions; -import com.locoslab.capi.android.leafless.MapPoint; -import com.locoslab.capi.android.leafless.MapStateEvent; -import com.locoslab.capi.android.leafless.MapView; -import com.locoslab.capi.android.leafless.TouchEvent; -import com.locoslab.capi.android.leafless.marker.Marker; -import com.locoslab.capi.android.leafless.marker.MarkerOptions; -import com.locoslab.capi.android.leafless.tile.TileLayer; -import com.locoslab.capi.android.leafless.tile.TileLayerOptions; +import com.locoslab.android.leafless.IMapStateListener; +import com.locoslab.android.leafless.ITouchListener; +import com.locoslab.android.leafless.MapOptions; +import com.locoslab.android.leafless.MapPoint; +import com.locoslab.android.leafless.MapStateEvent; +import com.locoslab.android.leafless.MapView; +import com.locoslab.android.leafless.TouchEvent; +import com.locoslab.android.leafless.marker.Marker; +import com.locoslab.android.leafless.marker.MarkerOptions; +import com.locoslab.android.leafless.tile.TileLayer; +import com.locoslab.android.leafless.tile.TileLayerOptions; +import com.locoslab.library.geometry.wgs.Box; import com.maptology.android.app.R; import com.maptology.android.app.map.IconManager; import com.maptology.android.app.model.Grant; diff --git a/android/app/src/main/java/com/maptology/android/app/fragment/NoticeListFragment.java b/android-app/src/main/java/com/maptology/android/app/fragment/NoticeListFragment.java similarity index 100% rename from android/app/src/main/java/com/maptology/android/app/fragment/NoticeListFragment.java rename to android-app/src/main/java/com/maptology/android/app/fragment/NoticeListFragment.java diff --git a/android/app/src/main/java/com/maptology/android/app/fragment/SettingsFragment.java b/android-app/src/main/java/com/maptology/android/app/fragment/SettingsFragment.java similarity index 100% rename from android/app/src/main/java/com/maptology/android/app/fragment/SettingsFragment.java rename to android-app/src/main/java/com/maptology/android/app/fragment/SettingsFragment.java diff --git a/android/app/src/main/java/com/maptology/android/app/fragment/ShareFragment.java b/android-app/src/main/java/com/maptology/android/app/fragment/ShareFragment.java similarity index 100% rename from android/app/src/main/java/com/maptology/android/app/fragment/ShareFragment.java rename to android-app/src/main/java/com/maptology/android/app/fragment/ShareFragment.java diff --git a/android/app/src/main/java/com/maptology/android/app/fragment/ShareListFragment.java b/android-app/src/main/java/com/maptology/android/app/fragment/ShareListFragment.java similarity index 100% rename from android/app/src/main/java/com/maptology/android/app/fragment/ShareListFragment.java rename to android-app/src/main/java/com/maptology/android/app/fragment/ShareListFragment.java diff --git a/android/app/src/main/java/com/maptology/android/app/fragment/TermsFragment.java b/android-app/src/main/java/com/maptology/android/app/fragment/TermsFragment.java similarity index 100% rename from android/app/src/main/java/com/maptology/android/app/fragment/TermsFragment.java rename to android-app/src/main/java/com/maptology/android/app/fragment/TermsFragment.java diff --git a/android/app/src/main/java/com/maptology/android/app/fragment/TimePickerFragment.java b/android-app/src/main/java/com/maptology/android/app/fragment/TimePickerFragment.java similarity index 100% rename from android/app/src/main/java/com/maptology/android/app/fragment/TimePickerFragment.java rename to android-app/src/main/java/com/maptology/android/app/fragment/TimePickerFragment.java diff --git a/android/app/src/main/java/com/maptology/android/app/location/LocationContract.java b/android-app/src/main/java/com/maptology/android/app/location/LocationContract.java similarity index 100% rename from android/app/src/main/java/com/maptology/android/app/location/LocationContract.java rename to android-app/src/main/java/com/maptology/android/app/location/LocationContract.java diff --git a/android/app/src/main/java/com/maptology/android/app/location/LocationHelper.java b/android-app/src/main/java/com/maptology/android/app/location/LocationHelper.java similarity index 100% rename from android/app/src/main/java/com/maptology/android/app/location/LocationHelper.java rename to android-app/src/main/java/com/maptology/android/app/location/LocationHelper.java diff --git a/android/app/src/main/java/com/maptology/android/app/location/LocationState.java b/android-app/src/main/java/com/maptology/android/app/location/LocationState.java similarity index 100% rename from android/app/src/main/java/com/maptology/android/app/location/LocationState.java rename to android-app/src/main/java/com/maptology/android/app/location/LocationState.java diff --git a/android/app/src/main/java/com/maptology/android/app/location/LocationStore.java b/android-app/src/main/java/com/maptology/android/app/location/LocationStore.java similarity index 100% rename from android/app/src/main/java/com/maptology/android/app/location/LocationStore.java rename to android-app/src/main/java/com/maptology/android/app/location/LocationStore.java diff --git a/android/app/src/main/java/com/maptology/android/app/map/IconManager.java b/android-app/src/main/java/com/maptology/android/app/map/IconManager.java similarity index 94% rename from android/app/src/main/java/com/maptology/android/app/map/IconManager.java rename to android-app/src/main/java/com/maptology/android/app/map/IconManager.java index aa0be05..e76e2e3 100644 --- a/android/app/src/main/java/com/maptology/android/app/map/IconManager.java +++ b/android-app/src/main/java/com/maptology/android/app/map/IconManager.java @@ -1,8 +1,8 @@ package com.maptology.android.app.map; -import com.locoslab.capi.android.leafless.MapPoint; -import com.locoslab.capi.android.leafless.icon.Icon; -import com.locoslab.capi.android.leafless.icon.IconOptions; +import com.locoslab.android.leafless.MapPoint; +import com.locoslab.android.leafless.icon.Icon; +import com.locoslab.android.leafless.icon.IconOptions; /** * A helper class to manage icons. diff --git a/android/app/src/main/java/com/maptology/android/app/map/MapMode.java b/android-app/src/main/java/com/maptology/android/app/map/MapMode.java similarity index 100% rename from android/app/src/main/java/com/maptology/android/app/map/MapMode.java rename to android-app/src/main/java/com/maptology/android/app/map/MapMode.java diff --git a/android/app/src/main/java/com/maptology/android/app/map/MapState.java b/android-app/src/main/java/com/maptology/android/app/map/MapState.java similarity index 94% rename from android/app/src/main/java/com/maptology/android/app/map/MapState.java rename to android-app/src/main/java/com/maptology/android/app/map/MapState.java index a19803f..5238634 100644 --- a/android/app/src/main/java/com/maptology/android/app/map/MapState.java +++ b/android-app/src/main/java/com/maptology/android/app/map/MapState.java @@ -1,7 +1,7 @@ package com.maptology.android.app.map; -import com.locoslab.capi.android.leafless.MapView; -import com.locoslab.capi.android.leafless.MapViewState; +import com.locoslab.android.leafless.MapView; +import com.locoslab.android.leafless.MapViewState; /** * The class that stores the state of the map diff --git a/android/app/src/main/java/com/maptology/android/app/model/Grant.java b/android-app/src/main/java/com/maptology/android/app/model/Grant.java similarity index 100% rename from android/app/src/main/java/com/maptology/android/app/model/Grant.java rename to android-app/src/main/java/com/maptology/android/app/model/Grant.java diff --git a/android/app/src/main/java/com/maptology/android/app/model/LocalMessage.java b/android-app/src/main/java/com/maptology/android/app/model/LocalMessage.java similarity index 100% rename from android/app/src/main/java/com/maptology/android/app/model/LocalMessage.java rename to android-app/src/main/java/com/maptology/android/app/model/LocalMessage.java diff --git a/android/app/src/main/java/com/maptology/android/app/model/LocalNotice.java b/android-app/src/main/java/com/maptology/android/app/model/LocalNotice.java similarity index 100% rename from android/app/src/main/java/com/maptology/android/app/model/LocalNotice.java rename to android-app/src/main/java/com/maptology/android/app/model/LocalNotice.java diff --git a/android/app/src/main/java/com/maptology/android/app/model/LocalShare.java b/android-app/src/main/java/com/maptology/android/app/model/LocalShare.java similarity index 100% rename from android/app/src/main/java/com/maptology/android/app/model/LocalShare.java rename to android-app/src/main/java/com/maptology/android/app/model/LocalShare.java diff --git a/android/app/src/main/java/com/maptology/android/app/model/ModelUtils.java b/android-app/src/main/java/com/maptology/android/app/model/ModelUtils.java similarity index 100% rename from android/app/src/main/java/com/maptology/android/app/model/ModelUtils.java rename to android-app/src/main/java/com/maptology/android/app/model/ModelUtils.java diff --git a/android/app/src/main/java/com/maptology/android/app/model/Network.java b/android-app/src/main/java/com/maptology/android/app/model/Network.java similarity index 100% rename from android/app/src/main/java/com/maptology/android/app/model/Network.java rename to android-app/src/main/java/com/maptology/android/app/model/Network.java diff --git a/android/app/src/main/java/com/maptology/android/app/model/Position.java b/android-app/src/main/java/com/maptology/android/app/model/Position.java similarity index 100% rename from android/app/src/main/java/com/maptology/android/app/model/Position.java rename to android-app/src/main/java/com/maptology/android/app/model/Position.java diff --git a/android/app/src/main/java/com/maptology/android/app/notice/NoticeContract.java b/android-app/src/main/java/com/maptology/android/app/notice/NoticeContract.java similarity index 100% rename from android/app/src/main/java/com/maptology/android/app/notice/NoticeContract.java rename to android-app/src/main/java/com/maptology/android/app/notice/NoticeContract.java diff --git a/android/app/src/main/java/com/maptology/android/app/notice/NoticeHelper.java b/android-app/src/main/java/com/maptology/android/app/notice/NoticeHelper.java similarity index 100% rename from android/app/src/main/java/com/maptology/android/app/notice/NoticeHelper.java rename to android-app/src/main/java/com/maptology/android/app/notice/NoticeHelper.java diff --git a/android/app/src/main/java/com/maptology/android/app/notice/NoticeStore.java b/android-app/src/main/java/com/maptology/android/app/notice/NoticeStore.java similarity index 100% rename from android/app/src/main/java/com/maptology/android/app/notice/NoticeStore.java rename to android-app/src/main/java/com/maptology/android/app/notice/NoticeStore.java diff --git a/android/app/src/main/java/com/maptology/android/app/repository/AsyncError.java b/android-app/src/main/java/com/maptology/android/app/repository/AsyncError.java similarity index 100% rename from android/app/src/main/java/com/maptology/android/app/repository/AsyncError.java rename to android-app/src/main/java/com/maptology/android/app/repository/AsyncError.java diff --git a/android/app/src/main/java/com/maptology/android/app/repository/AsyncInteraction.java b/android-app/src/main/java/com/maptology/android/app/repository/AsyncInteraction.java similarity index 100% rename from android/app/src/main/java/com/maptology/android/app/repository/AsyncInteraction.java rename to android-app/src/main/java/com/maptology/android/app/repository/AsyncInteraction.java diff --git a/android/app/src/main/java/com/maptology/android/app/repository/IValueListener.java b/android-app/src/main/java/com/maptology/android/app/repository/IValueListener.java similarity index 100% rename from android/app/src/main/java/com/maptology/android/app/repository/IValueListener.java rename to android-app/src/main/java/com/maptology/android/app/repository/IValueListener.java diff --git a/android/app/src/main/java/com/maptology/android/app/repository/JacksonSerializer.java b/android-app/src/main/java/com/maptology/android/app/repository/JacksonSerializer.java similarity index 100% rename from android/app/src/main/java/com/maptology/android/app/repository/JacksonSerializer.java rename to android-app/src/main/java/com/maptology/android/app/repository/JacksonSerializer.java diff --git a/android/app/src/main/java/com/maptology/android/app/repository/LocationValue.java b/android-app/src/main/java/com/maptology/android/app/repository/LocationValue.java similarity index 100% rename from android/app/src/main/java/com/maptology/android/app/repository/LocationValue.java rename to android-app/src/main/java/com/maptology/android/app/repository/LocationValue.java diff --git a/android/app/src/main/java/com/maptology/android/app/repository/PersistentValue.java b/android-app/src/main/java/com/maptology/android/app/repository/PersistentValue.java similarity index 100% rename from android/app/src/main/java/com/maptology/android/app/repository/PersistentValue.java rename to android-app/src/main/java/com/maptology/android/app/repository/PersistentValue.java diff --git a/android/app/src/main/java/com/maptology/android/app/repository/Repository.java b/android-app/src/main/java/com/maptology/android/app/repository/Repository.java similarity index 100% rename from android/app/src/main/java/com/maptology/android/app/repository/Repository.java rename to android-app/src/main/java/com/maptology/android/app/repository/Repository.java diff --git a/android/app/src/main/java/com/maptology/android/app/repository/Serializer.java b/android-app/src/main/java/com/maptology/android/app/repository/Serializer.java similarity index 100% rename from android/app/src/main/java/com/maptology/android/app/repository/Serializer.java rename to android-app/src/main/java/com/maptology/android/app/repository/Serializer.java diff --git a/android/app/src/main/java/com/maptology/android/app/repository/Value.java b/android-app/src/main/java/com/maptology/android/app/repository/Value.java similarity index 100% rename from android/app/src/main/java/com/maptology/android/app/repository/Value.java rename to android-app/src/main/java/com/maptology/android/app/repository/Value.java diff --git a/android/app/src/main/java/com/maptology/android/app/share/ShareContract.java b/android-app/src/main/java/com/maptology/android/app/share/ShareContract.java similarity index 100% rename from android/app/src/main/java/com/maptology/android/app/share/ShareContract.java rename to android-app/src/main/java/com/maptology/android/app/share/ShareContract.java diff --git a/android/app/src/main/java/com/maptology/android/app/share/ShareHelper.java b/android-app/src/main/java/com/maptology/android/app/share/ShareHelper.java similarity index 100% rename from android/app/src/main/java/com/maptology/android/app/share/ShareHelper.java rename to android-app/src/main/java/com/maptology/android/app/share/ShareHelper.java diff --git a/android/app/src/main/java/com/maptology/android/app/share/ShareStore.java b/android-app/src/main/java/com/maptology/android/app/share/ShareStore.java similarity index 100% rename from android/app/src/main/java/com/maptology/android/app/share/ShareStore.java rename to android-app/src/main/java/com/maptology/android/app/share/ShareStore.java diff --git a/android/app/src/main/java/com/maptology/android/app/task/AbstractApiTask.java b/android-app/src/main/java/com/maptology/android/app/task/AbstractApiTask.java similarity index 100% rename from android/app/src/main/java/com/maptology/android/app/task/AbstractApiTask.java rename to android-app/src/main/java/com/maptology/android/app/task/AbstractApiTask.java diff --git a/android/app/src/main/java/com/maptology/android/app/task/CreateDeviceTask.java b/android-app/src/main/java/com/maptology/android/app/task/CreateDeviceTask.java similarity index 100% rename from android/app/src/main/java/com/maptology/android/app/task/CreateDeviceTask.java rename to android-app/src/main/java/com/maptology/android/app/task/CreateDeviceTask.java diff --git a/android/app/src/main/java/com/maptology/android/app/task/CreateShareTask.java b/android-app/src/main/java/com/maptology/android/app/task/CreateShareTask.java similarity index 100% rename from android/app/src/main/java/com/maptology/android/app/task/CreateShareTask.java rename to android-app/src/main/java/com/maptology/android/app/task/CreateShareTask.java diff --git a/android/app/src/main/java/com/maptology/android/app/task/DeleteShareTask.java b/android-app/src/main/java/com/maptology/android/app/task/DeleteShareTask.java similarity index 100% rename from android/app/src/main/java/com/maptology/android/app/task/DeleteShareTask.java rename to android-app/src/main/java/com/maptology/android/app/task/DeleteShareTask.java diff --git a/android/app/src/main/java/com/maptology/android/app/task/SaveShareTask.java b/android-app/src/main/java/com/maptology/android/app/task/SaveShareTask.java similarity index 100% rename from android/app/src/main/java/com/maptology/android/app/task/SaveShareTask.java rename to android-app/src/main/java/com/maptology/android/app/task/SaveShareTask.java diff --git a/android/app/src/main/java/com/maptology/android/app/task/SyncNoticeTask.java b/android-app/src/main/java/com/maptology/android/app/task/SyncNoticeTask.java similarity index 100% rename from android/app/src/main/java/com/maptology/android/app/task/SyncNoticeTask.java rename to android-app/src/main/java/com/maptology/android/app/task/SyncNoticeTask.java diff --git a/android/app/src/main/java/com/maptology/android/app/task/UpdateGrantsTask.java b/android-app/src/main/java/com/maptology/android/app/task/UpdateGrantsTask.java similarity index 100% rename from android/app/src/main/java/com/maptology/android/app/task/UpdateGrantsTask.java rename to android-app/src/main/java/com/maptology/android/app/task/UpdateGrantsTask.java diff --git a/android/app/src/main/java/com/maptology/android/app/task/UpdateUserTask.java b/android-app/src/main/java/com/maptology/android/app/task/UpdateUserTask.java similarity index 100% rename from android/app/src/main/java/com/maptology/android/app/task/UpdateUserTask.java rename to android-app/src/main/java/com/maptology/android/app/task/UpdateUserTask.java diff --git a/android/app/src/main/java/com/maptology/android/app/task/UploadLocationTask.java b/android-app/src/main/java/com/maptology/android/app/task/UploadLocationTask.java similarity index 100% rename from android/app/src/main/java/com/maptology/android/app/task/UploadLocationTask.java rename to android-app/src/main/java/com/maptology/android/app/task/UploadLocationTask.java diff --git a/android/app/src/main/java/com/maptology/android/app/util/ActionUtil.java b/android-app/src/main/java/com/maptology/android/app/util/ActionUtil.java similarity index 100% rename from android/app/src/main/java/com/maptology/android/app/util/ActionUtil.java rename to android-app/src/main/java/com/maptology/android/app/util/ActionUtil.java diff --git a/android/app/src/main/java/com/maptology/android/app/util/ColoredSnackbar.java b/android-app/src/main/java/com/maptology/android/app/util/ColoredSnackbar.java similarity index 100% rename from android/app/src/main/java/com/maptology/android/app/util/ColoredSnackbar.java rename to android-app/src/main/java/com/maptology/android/app/util/ColoredSnackbar.java diff --git a/android/app/src/main/java/com/maptology/android/app/util/DateFormatter.java b/android-app/src/main/java/com/maptology/android/app/util/DateFormatter.java similarity index 100% rename from android/app/src/main/java/com/maptology/android/app/util/DateFormatter.java rename to android-app/src/main/java/com/maptology/android/app/util/DateFormatter.java diff --git a/android/app/src/main/java/com/maptology/android/app/util/TabletUtil.java b/android-app/src/main/java/com/maptology/android/app/util/TabletUtil.java similarity index 100% rename from android/app/src/main/java/com/maptology/android/app/util/TabletUtil.java rename to android-app/src/main/java/com/maptology/android/app/util/TabletUtil.java diff --git a/android/app/src/main/key/maptology.jks b/android-app/src/main/key/maptology.jks similarity index 100% rename from android/app/src/main/key/maptology.jks rename to android-app/src/main/key/maptology.jks diff --git a/android/app/src/main/res/drawable-hdpi/ic_add_white_24dp.png b/android-app/src/main/res/drawable-hdpi/ic_add_white_24dp.png similarity index 100% rename from android/app/src/main/res/drawable-hdpi/ic_add_white_24dp.png rename to android-app/src/main/res/drawable-hdpi/ic_add_white_24dp.png diff --git a/android/app/src/main/res/drawable-hdpi/ic_alarm_off_black_48dp.png b/android-app/src/main/res/drawable-hdpi/ic_alarm_off_black_48dp.png similarity index 100% rename from android/app/src/main/res/drawable-hdpi/ic_alarm_off_black_48dp.png rename to android-app/src/main/res/drawable-hdpi/ic_alarm_off_black_48dp.png diff --git a/android/app/src/main/res/drawable-hdpi/ic_all_out_white_24dp.png b/android-app/src/main/res/drawable-hdpi/ic_all_out_white_24dp.png similarity index 100% rename from android/app/src/main/res/drawable-hdpi/ic_all_out_white_24dp.png rename to android-app/src/main/res/drawable-hdpi/ic_all_out_white_24dp.png diff --git a/android/app/src/main/res/drawable-hdpi/ic_call_made_white_24dp.png b/android-app/src/main/res/drawable-hdpi/ic_call_made_white_24dp.png similarity index 100% rename from android/app/src/main/res/drawable-hdpi/ic_call_made_white_24dp.png rename to android-app/src/main/res/drawable-hdpi/ic_call_made_white_24dp.png diff --git a/android/app/src/main/res/drawable-hdpi/ic_call_received_white_24dp.png b/android-app/src/main/res/drawable-hdpi/ic_call_received_white_24dp.png similarity index 100% rename from android/app/src/main/res/drawable-hdpi/ic_call_received_white_24dp.png rename to android-app/src/main/res/drawable-hdpi/ic_call_received_white_24dp.png diff --git a/android/app/src/main/res/drawable-hdpi/ic_card_travel_black_24dp.png b/android-app/src/main/res/drawable-hdpi/ic_card_travel_black_24dp.png similarity index 100% rename from android/app/src/main/res/drawable-hdpi/ic_card_travel_black_24dp.png rename to android-app/src/main/res/drawable-hdpi/ic_card_travel_black_24dp.png diff --git a/android/app/src/main/res/drawable-hdpi/ic_chat_bubble_outline_black_24dp.png b/android-app/src/main/res/drawable-hdpi/ic_chat_bubble_outline_black_24dp.png similarity index 100% rename from android/app/src/main/res/drawable-hdpi/ic_chat_bubble_outline_black_24dp.png rename to android-app/src/main/res/drawable-hdpi/ic_chat_bubble_outline_black_24dp.png diff --git a/android/app/src/main/res/drawable-hdpi/ic_check_black_24dp.png b/android-app/src/main/res/drawable-hdpi/ic_check_black_24dp.png similarity index 100% rename from android/app/src/main/res/drawable-hdpi/ic_check_black_24dp.png rename to android-app/src/main/res/drawable-hdpi/ic_check_black_24dp.png diff --git a/android/app/src/main/res/drawable-hdpi/ic_content_copy_black_24dp.png b/android-app/src/main/res/drawable-hdpi/ic_content_copy_black_24dp.png similarity index 100% rename from android/app/src/main/res/drawable-hdpi/ic_content_copy_black_24dp.png rename to android-app/src/main/res/drawable-hdpi/ic_content_copy_black_24dp.png diff --git a/android/app/src/main/res/drawable-hdpi/ic_delete_black_24dp.png b/android-app/src/main/res/drawable-hdpi/ic_delete_black_24dp.png similarity index 100% rename from android/app/src/main/res/drawable-hdpi/ic_delete_black_24dp.png rename to android-app/src/main/res/drawable-hdpi/ic_delete_black_24dp.png diff --git a/android/app/src/main/res/drawable-hdpi/ic_delete_sweep_white_24dp.png b/android-app/src/main/res/drawable-hdpi/ic_delete_sweep_white_24dp.png similarity index 100% rename from android/app/src/main/res/drawable-hdpi/ic_delete_sweep_white_24dp.png rename to android-app/src/main/res/drawable-hdpi/ic_delete_sweep_white_24dp.png diff --git a/android/app/src/main/res/drawable-hdpi/ic_delete_white_24dp.png b/android-app/src/main/res/drawable-hdpi/ic_delete_white_24dp.png similarity index 100% rename from android/app/src/main/res/drawable-hdpi/ic_delete_white_24dp.png rename to android-app/src/main/res/drawable-hdpi/ic_delete_white_24dp.png diff --git a/android/app/src/main/res/drawable-hdpi/ic_gps_fixed_black_24dp.png b/android-app/src/main/res/drawable-hdpi/ic_gps_fixed_black_24dp.png similarity index 100% rename from android/app/src/main/res/drawable-hdpi/ic_gps_fixed_black_24dp.png rename to android-app/src/main/res/drawable-hdpi/ic_gps_fixed_black_24dp.png diff --git a/android/app/src/main/res/drawable-hdpi/ic_gps_not_fixed_black_24dp.png b/android-app/src/main/res/drawable-hdpi/ic_gps_not_fixed_black_24dp.png similarity index 100% rename from android/app/src/main/res/drawable-hdpi/ic_gps_not_fixed_black_24dp.png rename to android-app/src/main/res/drawable-hdpi/ic_gps_not_fixed_black_24dp.png diff --git a/android/app/src/main/res/drawable-hdpi/ic_gps_not_fixed_black_48dp.png b/android-app/src/main/res/drawable-hdpi/ic_gps_not_fixed_black_48dp.png similarity index 100% rename from android/app/src/main/res/drawable-hdpi/ic_gps_not_fixed_black_48dp.png rename to android-app/src/main/res/drawable-hdpi/ic_gps_not_fixed_black_48dp.png diff --git a/android/app/src/main/res/drawable-hdpi/ic_import_export_black_24dp.png b/android-app/src/main/res/drawable-hdpi/ic_import_export_black_24dp.png similarity index 100% rename from android/app/src/main/res/drawable-hdpi/ic_import_export_black_24dp.png rename to android-app/src/main/res/drawable-hdpi/ic_import_export_black_24dp.png diff --git a/android/app/src/main/res/drawable-hdpi/ic_launch_black_24dp.png b/android-app/src/main/res/drawable-hdpi/ic_launch_black_24dp.png similarity index 100% rename from android/app/src/main/res/drawable-hdpi/ic_launch_black_24dp.png rename to android-app/src/main/res/drawable-hdpi/ic_launch_black_24dp.png diff --git a/android/app/src/main/res/drawable-hdpi/ic_link_black_24dp.png b/android-app/src/main/res/drawable-hdpi/ic_link_black_24dp.png similarity index 100% rename from android/app/src/main/res/drawable-hdpi/ic_link_black_24dp.png rename to android-app/src/main/res/drawable-hdpi/ic_link_black_24dp.png diff --git a/android/app/src/main/res/drawable-hdpi/ic_location_on_black_48dp.png b/android-app/src/main/res/drawable-hdpi/ic_location_on_black_48dp.png similarity index 100% rename from android/app/src/main/res/drawable-hdpi/ic_location_on_black_48dp.png rename to android-app/src/main/res/drawable-hdpi/ic_location_on_black_48dp.png diff --git a/android/app/src/main/res/drawable-hdpi/ic_lock_outline_black_24dp.png b/android-app/src/main/res/drawable-hdpi/ic_lock_outline_black_24dp.png similarity index 100% rename from android/app/src/main/res/drawable-hdpi/ic_lock_outline_black_24dp.png rename to android-app/src/main/res/drawable-hdpi/ic_lock_outline_black_24dp.png diff --git a/android/app/src/main/res/drawable-hdpi/ic_map_black_24dp.png b/android-app/src/main/res/drawable-hdpi/ic_map_black_24dp.png similarity index 100% rename from android/app/src/main/res/drawable-hdpi/ic_map_black_24dp.png rename to android-app/src/main/res/drawable-hdpi/ic_map_black_24dp.png diff --git a/android/app/src/main/res/drawable-hdpi/ic_message_black_24dp.png b/android-app/src/main/res/drawable-hdpi/ic_message_black_24dp.png similarity index 100% rename from android/app/src/main/res/drawable-hdpi/ic_message_black_24dp.png rename to android-app/src/main/res/drawable-hdpi/ic_message_black_24dp.png diff --git a/android/app/src/main/res/drawable-hdpi/ic_my_location_white_24dp.png b/android-app/src/main/res/drawable-hdpi/ic_my_location_white_24dp.png similarity index 100% rename from android/app/src/main/res/drawable-hdpi/ic_my_location_white_24dp.png rename to android-app/src/main/res/drawable-hdpi/ic_my_location_white_24dp.png diff --git a/android/app/src/main/res/drawable-hdpi/ic_open_in_browser_black_24dp.png b/android-app/src/main/res/drawable-hdpi/ic_open_in_browser_black_24dp.png similarity index 100% rename from android/app/src/main/res/drawable-hdpi/ic_open_in_browser_black_24dp.png rename to android-app/src/main/res/drawable-hdpi/ic_open_in_browser_black_24dp.png diff --git a/android/app/src/main/res/drawable-hdpi/ic_pause_black_48dp.png b/android-app/src/main/res/drawable-hdpi/ic_pause_black_48dp.png similarity index 100% rename from android/app/src/main/res/drawable-hdpi/ic_pause_black_48dp.png rename to android-app/src/main/res/drawable-hdpi/ic_pause_black_48dp.png diff --git a/android/app/src/main/res/drawable-hdpi/ic_perm_identity_black_24dp.png b/android-app/src/main/res/drawable-hdpi/ic_perm_identity_black_24dp.png similarity index 100% rename from android/app/src/main/res/drawable-hdpi/ic_perm_identity_black_24dp.png rename to android-app/src/main/res/drawable-hdpi/ic_perm_identity_black_24dp.png diff --git a/android/app/src/main/res/drawable-hdpi/ic_place_white_24dp.png b/android-app/src/main/res/drawable-hdpi/ic_place_white_24dp.png similarity index 100% rename from android/app/src/main/res/drawable-hdpi/ic_place_white_24dp.png rename to android-app/src/main/res/drawable-hdpi/ic_place_white_24dp.png diff --git a/android/app/src/main/res/drawable-hdpi/ic_save_black_24dp.png b/android-app/src/main/res/drawable-hdpi/ic_save_black_24dp.png similarity index 100% rename from android/app/src/main/res/drawable-hdpi/ic_save_black_24dp.png rename to android-app/src/main/res/drawable-hdpi/ic_save_black_24dp.png diff --git a/android/app/src/main/res/drawable-hdpi/ic_settings_black_24dp.png b/android-app/src/main/res/drawable-hdpi/ic_settings_black_24dp.png similarity index 100% rename from android/app/src/main/res/drawable-hdpi/ic_settings_black_24dp.png rename to android-app/src/main/res/drawable-hdpi/ic_settings_black_24dp.png diff --git a/android/app/src/main/res/drawable-hdpi/ic_share_black_24dp.png b/android-app/src/main/res/drawable-hdpi/ic_share_black_24dp.png similarity index 100% rename from android/app/src/main/res/drawable-hdpi/ic_share_black_24dp.png rename to android-app/src/main/res/drawable-hdpi/ic_share_black_24dp.png diff --git a/android/app/src/main/res/drawable-hdpi/ic_share_black_48dp.png b/android-app/src/main/res/drawable-hdpi/ic_share_black_48dp.png similarity index 100% rename from android/app/src/main/res/drawable-hdpi/ic_share_black_48dp.png rename to android-app/src/main/res/drawable-hdpi/ic_share_black_48dp.png diff --git a/android/app/src/main/res/drawable-hdpi/ic_update_black_24dp.png b/android-app/src/main/res/drawable-hdpi/ic_update_black_24dp.png similarity index 100% rename from android/app/src/main/res/drawable-hdpi/ic_update_black_24dp.png rename to android-app/src/main/res/drawable-hdpi/ic_update_black_24dp.png diff --git a/android/app/src/main/res/drawable-hdpi/ic_update_white_24dp.png b/android-app/src/main/res/drawable-hdpi/ic_update_white_24dp.png similarity index 100% rename from android/app/src/main/res/drawable-hdpi/ic_update_white_24dp.png rename to android-app/src/main/res/drawable-hdpi/ic_update_white_24dp.png diff --git a/android/app/src/main/res/drawable-hdpi/ic_visibility_off_black_48dp.png b/android-app/src/main/res/drawable-hdpi/ic_visibility_off_black_48dp.png similarity index 100% rename from android/app/src/main/res/drawable-hdpi/ic_visibility_off_black_48dp.png rename to android-app/src/main/res/drawable-hdpi/ic_visibility_off_black_48dp.png diff --git a/android/app/src/main/res/drawable-hdpi/ic_zoom_in_white_24dp.png b/android-app/src/main/res/drawable-hdpi/ic_zoom_in_white_24dp.png similarity index 100% rename from android/app/src/main/res/drawable-hdpi/ic_zoom_in_white_24dp.png rename to android-app/src/main/res/drawable-hdpi/ic_zoom_in_white_24dp.png diff --git a/android/app/src/main/res/drawable-hdpi/ic_zoom_out_map_white_24dp.png b/android-app/src/main/res/drawable-hdpi/ic_zoom_out_map_white_24dp.png similarity index 100% rename from android/app/src/main/res/drawable-hdpi/ic_zoom_out_map_white_24dp.png rename to android-app/src/main/res/drawable-hdpi/ic_zoom_out_map_white_24dp.png diff --git a/android/app/src/main/res/drawable-hdpi/ic_zoom_out_white_24dp.png b/android-app/src/main/res/drawable-hdpi/ic_zoom_out_white_24dp.png similarity index 100% rename from android/app/src/main/res/drawable-hdpi/ic_zoom_out_white_24dp.png rename to android-app/src/main/res/drawable-hdpi/ic_zoom_out_white_24dp.png diff --git a/android/app/src/main/res/drawable-mdpi/ic_add_white_24dp.png b/android-app/src/main/res/drawable-mdpi/ic_add_white_24dp.png similarity index 100% rename from android/app/src/main/res/drawable-mdpi/ic_add_white_24dp.png rename to android-app/src/main/res/drawable-mdpi/ic_add_white_24dp.png diff --git a/android/app/src/main/res/drawable-mdpi/ic_alarm_off_black_48dp.png b/android-app/src/main/res/drawable-mdpi/ic_alarm_off_black_48dp.png similarity index 100% rename from android/app/src/main/res/drawable-mdpi/ic_alarm_off_black_48dp.png rename to android-app/src/main/res/drawable-mdpi/ic_alarm_off_black_48dp.png diff --git a/android/app/src/main/res/drawable-mdpi/ic_all_out_white_24dp.png b/android-app/src/main/res/drawable-mdpi/ic_all_out_white_24dp.png similarity index 100% rename from android/app/src/main/res/drawable-mdpi/ic_all_out_white_24dp.png rename to android-app/src/main/res/drawable-mdpi/ic_all_out_white_24dp.png diff --git a/android/app/src/main/res/drawable-mdpi/ic_call_made_white_24dp.png b/android-app/src/main/res/drawable-mdpi/ic_call_made_white_24dp.png similarity index 100% rename from android/app/src/main/res/drawable-mdpi/ic_call_made_white_24dp.png rename to android-app/src/main/res/drawable-mdpi/ic_call_made_white_24dp.png diff --git a/android/app/src/main/res/drawable-mdpi/ic_call_received_white_24dp.png b/android-app/src/main/res/drawable-mdpi/ic_call_received_white_24dp.png similarity index 100% rename from android/app/src/main/res/drawable-mdpi/ic_call_received_white_24dp.png rename to android-app/src/main/res/drawable-mdpi/ic_call_received_white_24dp.png diff --git a/android/app/src/main/res/drawable-mdpi/ic_card_travel_black_24dp.png b/android-app/src/main/res/drawable-mdpi/ic_card_travel_black_24dp.png similarity index 100% rename from android/app/src/main/res/drawable-mdpi/ic_card_travel_black_24dp.png rename to android-app/src/main/res/drawable-mdpi/ic_card_travel_black_24dp.png diff --git a/android/app/src/main/res/drawable-mdpi/ic_chat_bubble_outline_black_24dp.png b/android-app/src/main/res/drawable-mdpi/ic_chat_bubble_outline_black_24dp.png similarity index 100% rename from android/app/src/main/res/drawable-mdpi/ic_chat_bubble_outline_black_24dp.png rename to android-app/src/main/res/drawable-mdpi/ic_chat_bubble_outline_black_24dp.png diff --git a/android/app/src/main/res/drawable-mdpi/ic_check_black_24dp.png b/android-app/src/main/res/drawable-mdpi/ic_check_black_24dp.png similarity index 100% rename from android/app/src/main/res/drawable-mdpi/ic_check_black_24dp.png rename to android-app/src/main/res/drawable-mdpi/ic_check_black_24dp.png diff --git a/android/app/src/main/res/drawable-mdpi/ic_content_copy_black_24dp.png b/android-app/src/main/res/drawable-mdpi/ic_content_copy_black_24dp.png similarity index 100% rename from android/app/src/main/res/drawable-mdpi/ic_content_copy_black_24dp.png rename to android-app/src/main/res/drawable-mdpi/ic_content_copy_black_24dp.png diff --git a/android/app/src/main/res/drawable-mdpi/ic_delete_black_24dp.png b/android-app/src/main/res/drawable-mdpi/ic_delete_black_24dp.png similarity index 100% rename from android/app/src/main/res/drawable-mdpi/ic_delete_black_24dp.png rename to android-app/src/main/res/drawable-mdpi/ic_delete_black_24dp.png diff --git a/android/app/src/main/res/drawable-mdpi/ic_delete_sweep_white_24dp.png b/android-app/src/main/res/drawable-mdpi/ic_delete_sweep_white_24dp.png similarity index 100% rename from android/app/src/main/res/drawable-mdpi/ic_delete_sweep_white_24dp.png rename to android-app/src/main/res/drawable-mdpi/ic_delete_sweep_white_24dp.png diff --git a/android/app/src/main/res/drawable-mdpi/ic_delete_white_24dp.png b/android-app/src/main/res/drawable-mdpi/ic_delete_white_24dp.png similarity index 100% rename from android/app/src/main/res/drawable-mdpi/ic_delete_white_24dp.png rename to android-app/src/main/res/drawable-mdpi/ic_delete_white_24dp.png diff --git a/android/app/src/main/res/drawable-mdpi/ic_gps_fixed_black_24dp.png b/android-app/src/main/res/drawable-mdpi/ic_gps_fixed_black_24dp.png similarity index 100% rename from android/app/src/main/res/drawable-mdpi/ic_gps_fixed_black_24dp.png rename to android-app/src/main/res/drawable-mdpi/ic_gps_fixed_black_24dp.png diff --git a/android/app/src/main/res/drawable-mdpi/ic_gps_not_fixed_black_24dp.png b/android-app/src/main/res/drawable-mdpi/ic_gps_not_fixed_black_24dp.png similarity index 100% rename from android/app/src/main/res/drawable-mdpi/ic_gps_not_fixed_black_24dp.png rename to android-app/src/main/res/drawable-mdpi/ic_gps_not_fixed_black_24dp.png diff --git a/android/app/src/main/res/drawable-mdpi/ic_gps_not_fixed_black_48dp.png b/android-app/src/main/res/drawable-mdpi/ic_gps_not_fixed_black_48dp.png similarity index 100% rename from android/app/src/main/res/drawable-mdpi/ic_gps_not_fixed_black_48dp.png rename to android-app/src/main/res/drawable-mdpi/ic_gps_not_fixed_black_48dp.png diff --git a/android/app/src/main/res/drawable-mdpi/ic_import_export_black_24dp.png b/android-app/src/main/res/drawable-mdpi/ic_import_export_black_24dp.png similarity index 100% rename from android/app/src/main/res/drawable-mdpi/ic_import_export_black_24dp.png rename to android-app/src/main/res/drawable-mdpi/ic_import_export_black_24dp.png diff --git a/android/app/src/main/res/drawable-mdpi/ic_launch_black_24dp.png b/android-app/src/main/res/drawable-mdpi/ic_launch_black_24dp.png similarity index 100% rename from android/app/src/main/res/drawable-mdpi/ic_launch_black_24dp.png rename to android-app/src/main/res/drawable-mdpi/ic_launch_black_24dp.png diff --git a/android/app/src/main/res/drawable-mdpi/ic_link_black_24dp.png b/android-app/src/main/res/drawable-mdpi/ic_link_black_24dp.png similarity index 100% rename from android/app/src/main/res/drawable-mdpi/ic_link_black_24dp.png rename to android-app/src/main/res/drawable-mdpi/ic_link_black_24dp.png diff --git a/android/app/src/main/res/drawable-mdpi/ic_location_on_black_48dp.png b/android-app/src/main/res/drawable-mdpi/ic_location_on_black_48dp.png similarity index 100% rename from android/app/src/main/res/drawable-mdpi/ic_location_on_black_48dp.png rename to android-app/src/main/res/drawable-mdpi/ic_location_on_black_48dp.png diff --git a/android/app/src/main/res/drawable-mdpi/ic_lock_outline_black_24dp.png b/android-app/src/main/res/drawable-mdpi/ic_lock_outline_black_24dp.png similarity index 100% rename from android/app/src/main/res/drawable-mdpi/ic_lock_outline_black_24dp.png rename to android-app/src/main/res/drawable-mdpi/ic_lock_outline_black_24dp.png diff --git a/android/app/src/main/res/drawable-mdpi/ic_map_black_24dp.png b/android-app/src/main/res/drawable-mdpi/ic_map_black_24dp.png similarity index 100% rename from android/app/src/main/res/drawable-mdpi/ic_map_black_24dp.png rename to android-app/src/main/res/drawable-mdpi/ic_map_black_24dp.png diff --git a/android/app/src/main/res/drawable-mdpi/ic_message_black_24dp.png b/android-app/src/main/res/drawable-mdpi/ic_message_black_24dp.png similarity index 100% rename from android/app/src/main/res/drawable-mdpi/ic_message_black_24dp.png rename to android-app/src/main/res/drawable-mdpi/ic_message_black_24dp.png diff --git a/android/app/src/main/res/drawable-mdpi/ic_my_location_white_24dp.png b/android-app/src/main/res/drawable-mdpi/ic_my_location_white_24dp.png similarity index 100% rename from android/app/src/main/res/drawable-mdpi/ic_my_location_white_24dp.png rename to android-app/src/main/res/drawable-mdpi/ic_my_location_white_24dp.png diff --git a/android/app/src/main/res/drawable-mdpi/ic_open_in_browser_black_24dp.png b/android-app/src/main/res/drawable-mdpi/ic_open_in_browser_black_24dp.png similarity index 100% rename from android/app/src/main/res/drawable-mdpi/ic_open_in_browser_black_24dp.png rename to android-app/src/main/res/drawable-mdpi/ic_open_in_browser_black_24dp.png diff --git a/android/app/src/main/res/drawable-mdpi/ic_pause_black_48dp.png b/android-app/src/main/res/drawable-mdpi/ic_pause_black_48dp.png similarity index 100% rename from android/app/src/main/res/drawable-mdpi/ic_pause_black_48dp.png rename to android-app/src/main/res/drawable-mdpi/ic_pause_black_48dp.png diff --git a/android/app/src/main/res/drawable-mdpi/ic_perm_identity_black_24dp.png b/android-app/src/main/res/drawable-mdpi/ic_perm_identity_black_24dp.png similarity index 100% rename from android/app/src/main/res/drawable-mdpi/ic_perm_identity_black_24dp.png rename to android-app/src/main/res/drawable-mdpi/ic_perm_identity_black_24dp.png diff --git a/android/app/src/main/res/drawable-mdpi/ic_place_white_24dp.png b/android-app/src/main/res/drawable-mdpi/ic_place_white_24dp.png similarity index 100% rename from android/app/src/main/res/drawable-mdpi/ic_place_white_24dp.png rename to android-app/src/main/res/drawable-mdpi/ic_place_white_24dp.png diff --git a/android/app/src/main/res/drawable-mdpi/ic_save_black_24dp.png b/android-app/src/main/res/drawable-mdpi/ic_save_black_24dp.png similarity index 100% rename from android/app/src/main/res/drawable-mdpi/ic_save_black_24dp.png rename to android-app/src/main/res/drawable-mdpi/ic_save_black_24dp.png diff --git a/android/app/src/main/res/drawable-mdpi/ic_settings_black_24dp.png b/android-app/src/main/res/drawable-mdpi/ic_settings_black_24dp.png similarity index 100% rename from android/app/src/main/res/drawable-mdpi/ic_settings_black_24dp.png rename to android-app/src/main/res/drawable-mdpi/ic_settings_black_24dp.png diff --git a/android/app/src/main/res/drawable-mdpi/ic_share_black_24dp.png b/android-app/src/main/res/drawable-mdpi/ic_share_black_24dp.png similarity index 100% rename from android/app/src/main/res/drawable-mdpi/ic_share_black_24dp.png rename to android-app/src/main/res/drawable-mdpi/ic_share_black_24dp.png diff --git a/android/app/src/main/res/drawable-mdpi/ic_share_black_48dp.png b/android-app/src/main/res/drawable-mdpi/ic_share_black_48dp.png similarity index 100% rename from android/app/src/main/res/drawable-mdpi/ic_share_black_48dp.png rename to android-app/src/main/res/drawable-mdpi/ic_share_black_48dp.png diff --git a/android/app/src/main/res/drawable-mdpi/ic_update_black_24dp.png b/android-app/src/main/res/drawable-mdpi/ic_update_black_24dp.png similarity index 100% rename from android/app/src/main/res/drawable-mdpi/ic_update_black_24dp.png rename to android-app/src/main/res/drawable-mdpi/ic_update_black_24dp.png diff --git a/android/app/src/main/res/drawable-mdpi/ic_update_white_24dp.png b/android-app/src/main/res/drawable-mdpi/ic_update_white_24dp.png similarity index 100% rename from android/app/src/main/res/drawable-mdpi/ic_update_white_24dp.png rename to android-app/src/main/res/drawable-mdpi/ic_update_white_24dp.png diff --git a/android/app/src/main/res/drawable-mdpi/ic_visibility_off_black_48dp.png b/android-app/src/main/res/drawable-mdpi/ic_visibility_off_black_48dp.png similarity index 100% rename from android/app/src/main/res/drawable-mdpi/ic_visibility_off_black_48dp.png rename to android-app/src/main/res/drawable-mdpi/ic_visibility_off_black_48dp.png diff --git a/android/app/src/main/res/drawable-mdpi/ic_zoom_in_white_24dp.png b/android-app/src/main/res/drawable-mdpi/ic_zoom_in_white_24dp.png similarity index 100% rename from android/app/src/main/res/drawable-mdpi/ic_zoom_in_white_24dp.png rename to android-app/src/main/res/drawable-mdpi/ic_zoom_in_white_24dp.png diff --git a/android/app/src/main/res/drawable-mdpi/ic_zoom_out_map_white_24dp.png b/android-app/src/main/res/drawable-mdpi/ic_zoom_out_map_white_24dp.png similarity index 100% rename from android/app/src/main/res/drawable-mdpi/ic_zoom_out_map_white_24dp.png rename to android-app/src/main/res/drawable-mdpi/ic_zoom_out_map_white_24dp.png diff --git a/android/app/src/main/res/drawable-mdpi/ic_zoom_out_white_24dp.png b/android-app/src/main/res/drawable-mdpi/ic_zoom_out_white_24dp.png similarity index 100% rename from android/app/src/main/res/drawable-mdpi/ic_zoom_out_white_24dp.png rename to android-app/src/main/res/drawable-mdpi/ic_zoom_out_white_24dp.png diff --git a/android/app/src/main/res/drawable-xhdpi/ic_add_white_24dp.png b/android-app/src/main/res/drawable-xhdpi/ic_add_white_24dp.png similarity index 100% rename from android/app/src/main/res/drawable-xhdpi/ic_add_white_24dp.png rename to android-app/src/main/res/drawable-xhdpi/ic_add_white_24dp.png diff --git a/android/app/src/main/res/drawable-xhdpi/ic_alarm_off_black_48dp.png b/android-app/src/main/res/drawable-xhdpi/ic_alarm_off_black_48dp.png similarity index 100% rename from android/app/src/main/res/drawable-xhdpi/ic_alarm_off_black_48dp.png rename to android-app/src/main/res/drawable-xhdpi/ic_alarm_off_black_48dp.png diff --git a/android/app/src/main/res/drawable-xhdpi/ic_all_out_white_24dp.png b/android-app/src/main/res/drawable-xhdpi/ic_all_out_white_24dp.png similarity index 100% rename from android/app/src/main/res/drawable-xhdpi/ic_all_out_white_24dp.png rename to android-app/src/main/res/drawable-xhdpi/ic_all_out_white_24dp.png diff --git a/android/app/src/main/res/drawable-xhdpi/ic_call_made_white_24dp.png b/android-app/src/main/res/drawable-xhdpi/ic_call_made_white_24dp.png similarity index 100% rename from android/app/src/main/res/drawable-xhdpi/ic_call_made_white_24dp.png rename to android-app/src/main/res/drawable-xhdpi/ic_call_made_white_24dp.png diff --git a/android/app/src/main/res/drawable-xhdpi/ic_call_received_white_24dp.png b/android-app/src/main/res/drawable-xhdpi/ic_call_received_white_24dp.png similarity index 100% rename from android/app/src/main/res/drawable-xhdpi/ic_call_received_white_24dp.png rename to android-app/src/main/res/drawable-xhdpi/ic_call_received_white_24dp.png diff --git a/android/app/src/main/res/drawable-xhdpi/ic_card_travel_black_24dp.png b/android-app/src/main/res/drawable-xhdpi/ic_card_travel_black_24dp.png similarity index 100% rename from android/app/src/main/res/drawable-xhdpi/ic_card_travel_black_24dp.png rename to android-app/src/main/res/drawable-xhdpi/ic_card_travel_black_24dp.png diff --git a/android/app/src/main/res/drawable-xhdpi/ic_chat_bubble_outline_black_24dp.png b/android-app/src/main/res/drawable-xhdpi/ic_chat_bubble_outline_black_24dp.png similarity index 100% rename from android/app/src/main/res/drawable-xhdpi/ic_chat_bubble_outline_black_24dp.png rename to android-app/src/main/res/drawable-xhdpi/ic_chat_bubble_outline_black_24dp.png diff --git a/android/app/src/main/res/drawable-xhdpi/ic_check_black_24dp.png b/android-app/src/main/res/drawable-xhdpi/ic_check_black_24dp.png similarity index 100% rename from android/app/src/main/res/drawable-xhdpi/ic_check_black_24dp.png rename to android-app/src/main/res/drawable-xhdpi/ic_check_black_24dp.png diff --git a/android/app/src/main/res/drawable-xhdpi/ic_content_copy_black_24dp.png b/android-app/src/main/res/drawable-xhdpi/ic_content_copy_black_24dp.png similarity index 100% rename from android/app/src/main/res/drawable-xhdpi/ic_content_copy_black_24dp.png rename to android-app/src/main/res/drawable-xhdpi/ic_content_copy_black_24dp.png diff --git a/android/app/src/main/res/drawable-xhdpi/ic_delete_black_24dp.png b/android-app/src/main/res/drawable-xhdpi/ic_delete_black_24dp.png similarity index 100% rename from android/app/src/main/res/drawable-xhdpi/ic_delete_black_24dp.png rename to android-app/src/main/res/drawable-xhdpi/ic_delete_black_24dp.png diff --git a/android/app/src/main/res/drawable-xhdpi/ic_delete_sweep_white_24dp.png b/android-app/src/main/res/drawable-xhdpi/ic_delete_sweep_white_24dp.png similarity index 100% rename from android/app/src/main/res/drawable-xhdpi/ic_delete_sweep_white_24dp.png rename to android-app/src/main/res/drawable-xhdpi/ic_delete_sweep_white_24dp.png diff --git a/android/app/src/main/res/drawable-xhdpi/ic_delete_white_24dp.png b/android-app/src/main/res/drawable-xhdpi/ic_delete_white_24dp.png similarity index 100% rename from android/app/src/main/res/drawable-xhdpi/ic_delete_white_24dp.png rename to android-app/src/main/res/drawable-xhdpi/ic_delete_white_24dp.png diff --git a/android/app/src/main/res/drawable-xhdpi/ic_gps_fixed_black_24dp.png b/android-app/src/main/res/drawable-xhdpi/ic_gps_fixed_black_24dp.png similarity index 100% rename from android/app/src/main/res/drawable-xhdpi/ic_gps_fixed_black_24dp.png rename to android-app/src/main/res/drawable-xhdpi/ic_gps_fixed_black_24dp.png diff --git a/android/app/src/main/res/drawable-xhdpi/ic_gps_not_fixed_black_24dp.png b/android-app/src/main/res/drawable-xhdpi/ic_gps_not_fixed_black_24dp.png similarity index 100% rename from android/app/src/main/res/drawable-xhdpi/ic_gps_not_fixed_black_24dp.png rename to android-app/src/main/res/drawable-xhdpi/ic_gps_not_fixed_black_24dp.png diff --git a/android/app/src/main/res/drawable-xhdpi/ic_gps_not_fixed_black_48dp.png b/android-app/src/main/res/drawable-xhdpi/ic_gps_not_fixed_black_48dp.png similarity index 100% rename from android/app/src/main/res/drawable-xhdpi/ic_gps_not_fixed_black_48dp.png rename to android-app/src/main/res/drawable-xhdpi/ic_gps_not_fixed_black_48dp.png diff --git a/android/app/src/main/res/drawable-xhdpi/ic_import_export_black_24dp.png b/android-app/src/main/res/drawable-xhdpi/ic_import_export_black_24dp.png similarity index 100% rename from android/app/src/main/res/drawable-xhdpi/ic_import_export_black_24dp.png rename to android-app/src/main/res/drawable-xhdpi/ic_import_export_black_24dp.png diff --git a/android/app/src/main/res/drawable-xhdpi/ic_launch_black_24dp.png b/android-app/src/main/res/drawable-xhdpi/ic_launch_black_24dp.png similarity index 100% rename from android/app/src/main/res/drawable-xhdpi/ic_launch_black_24dp.png rename to android-app/src/main/res/drawable-xhdpi/ic_launch_black_24dp.png diff --git a/android/app/src/main/res/drawable-xhdpi/ic_link_black_24dp.png b/android-app/src/main/res/drawable-xhdpi/ic_link_black_24dp.png similarity index 100% rename from android/app/src/main/res/drawable-xhdpi/ic_link_black_24dp.png rename to android-app/src/main/res/drawable-xhdpi/ic_link_black_24dp.png diff --git a/android/app/src/main/res/drawable-xhdpi/ic_location_on_black_48dp.png b/android-app/src/main/res/drawable-xhdpi/ic_location_on_black_48dp.png similarity index 100% rename from android/app/src/main/res/drawable-xhdpi/ic_location_on_black_48dp.png rename to android-app/src/main/res/drawable-xhdpi/ic_location_on_black_48dp.png diff --git a/android/app/src/main/res/drawable-xhdpi/ic_lock_outline_black_24dp.png b/android-app/src/main/res/drawable-xhdpi/ic_lock_outline_black_24dp.png similarity index 100% rename from android/app/src/main/res/drawable-xhdpi/ic_lock_outline_black_24dp.png rename to android-app/src/main/res/drawable-xhdpi/ic_lock_outline_black_24dp.png diff --git a/android/app/src/main/res/drawable-xhdpi/ic_map_black_24dp.png b/android-app/src/main/res/drawable-xhdpi/ic_map_black_24dp.png similarity index 100% rename from android/app/src/main/res/drawable-xhdpi/ic_map_black_24dp.png rename to android-app/src/main/res/drawable-xhdpi/ic_map_black_24dp.png diff --git a/android/app/src/main/res/drawable-xhdpi/ic_message_black_24dp.png b/android-app/src/main/res/drawable-xhdpi/ic_message_black_24dp.png similarity index 100% rename from android/app/src/main/res/drawable-xhdpi/ic_message_black_24dp.png rename to android-app/src/main/res/drawable-xhdpi/ic_message_black_24dp.png diff --git a/android/app/src/main/res/drawable-xhdpi/ic_my_location_white_24dp.png b/android-app/src/main/res/drawable-xhdpi/ic_my_location_white_24dp.png similarity index 100% rename from android/app/src/main/res/drawable-xhdpi/ic_my_location_white_24dp.png rename to android-app/src/main/res/drawable-xhdpi/ic_my_location_white_24dp.png diff --git a/android/app/src/main/res/drawable-xhdpi/ic_open_in_browser_black_24dp.png b/android-app/src/main/res/drawable-xhdpi/ic_open_in_browser_black_24dp.png similarity index 100% rename from android/app/src/main/res/drawable-xhdpi/ic_open_in_browser_black_24dp.png rename to android-app/src/main/res/drawable-xhdpi/ic_open_in_browser_black_24dp.png diff --git a/android/app/src/main/res/drawable-xhdpi/ic_pause_black_48dp.png b/android-app/src/main/res/drawable-xhdpi/ic_pause_black_48dp.png similarity index 100% rename from android/app/src/main/res/drawable-xhdpi/ic_pause_black_48dp.png rename to android-app/src/main/res/drawable-xhdpi/ic_pause_black_48dp.png diff --git a/android/app/src/main/res/drawable-xhdpi/ic_perm_identity_black_24dp.png b/android-app/src/main/res/drawable-xhdpi/ic_perm_identity_black_24dp.png similarity index 100% rename from android/app/src/main/res/drawable-xhdpi/ic_perm_identity_black_24dp.png rename to android-app/src/main/res/drawable-xhdpi/ic_perm_identity_black_24dp.png diff --git a/android/app/src/main/res/drawable-xhdpi/ic_place_white_24dp.png b/android-app/src/main/res/drawable-xhdpi/ic_place_white_24dp.png similarity index 100% rename from android/app/src/main/res/drawable-xhdpi/ic_place_white_24dp.png rename to android-app/src/main/res/drawable-xhdpi/ic_place_white_24dp.png diff --git a/android/app/src/main/res/drawable-xhdpi/ic_save_black_24dp.png b/android-app/src/main/res/drawable-xhdpi/ic_save_black_24dp.png similarity index 100% rename from android/app/src/main/res/drawable-xhdpi/ic_save_black_24dp.png rename to android-app/src/main/res/drawable-xhdpi/ic_save_black_24dp.png diff --git a/android/app/src/main/res/drawable-xhdpi/ic_settings_black_24dp.png b/android-app/src/main/res/drawable-xhdpi/ic_settings_black_24dp.png similarity index 100% rename from android/app/src/main/res/drawable-xhdpi/ic_settings_black_24dp.png rename to android-app/src/main/res/drawable-xhdpi/ic_settings_black_24dp.png diff --git a/android/app/src/main/res/drawable-xhdpi/ic_share_black_24dp.png b/android-app/src/main/res/drawable-xhdpi/ic_share_black_24dp.png similarity index 100% rename from android/app/src/main/res/drawable-xhdpi/ic_share_black_24dp.png rename to android-app/src/main/res/drawable-xhdpi/ic_share_black_24dp.png diff --git a/android/app/src/main/res/drawable-xhdpi/ic_share_black_48dp.png b/android-app/src/main/res/drawable-xhdpi/ic_share_black_48dp.png similarity index 100% rename from android/app/src/main/res/drawable-xhdpi/ic_share_black_48dp.png rename to android-app/src/main/res/drawable-xhdpi/ic_share_black_48dp.png diff --git a/android/app/src/main/res/drawable-xhdpi/ic_update_black_24dp.png b/android-app/src/main/res/drawable-xhdpi/ic_update_black_24dp.png similarity index 100% rename from android/app/src/main/res/drawable-xhdpi/ic_update_black_24dp.png rename to android-app/src/main/res/drawable-xhdpi/ic_update_black_24dp.png diff --git a/android/app/src/main/res/drawable-xhdpi/ic_update_white_24dp.png b/android-app/src/main/res/drawable-xhdpi/ic_update_white_24dp.png similarity index 100% rename from android/app/src/main/res/drawable-xhdpi/ic_update_white_24dp.png rename to android-app/src/main/res/drawable-xhdpi/ic_update_white_24dp.png diff --git a/android/app/src/main/res/drawable-xhdpi/ic_visibility_off_black_48dp.png b/android-app/src/main/res/drawable-xhdpi/ic_visibility_off_black_48dp.png similarity index 100% rename from android/app/src/main/res/drawable-xhdpi/ic_visibility_off_black_48dp.png rename to android-app/src/main/res/drawable-xhdpi/ic_visibility_off_black_48dp.png diff --git a/android/app/src/main/res/drawable-xhdpi/ic_zoom_in_white_24dp.png b/android-app/src/main/res/drawable-xhdpi/ic_zoom_in_white_24dp.png similarity index 100% rename from android/app/src/main/res/drawable-xhdpi/ic_zoom_in_white_24dp.png rename to android-app/src/main/res/drawable-xhdpi/ic_zoom_in_white_24dp.png diff --git a/android/app/src/main/res/drawable-xhdpi/ic_zoom_out_map_white_24dp.png b/android-app/src/main/res/drawable-xhdpi/ic_zoom_out_map_white_24dp.png similarity index 100% rename from android/app/src/main/res/drawable-xhdpi/ic_zoom_out_map_white_24dp.png rename to android-app/src/main/res/drawable-xhdpi/ic_zoom_out_map_white_24dp.png diff --git a/android/app/src/main/res/drawable-xhdpi/ic_zoom_out_white_24dp.png b/android-app/src/main/res/drawable-xhdpi/ic_zoom_out_white_24dp.png similarity index 100% rename from android/app/src/main/res/drawable-xhdpi/ic_zoom_out_white_24dp.png rename to android-app/src/main/res/drawable-xhdpi/ic_zoom_out_white_24dp.png diff --git a/android/app/src/main/res/drawable-xxhdpi/ic_add_white_24dp.png b/android-app/src/main/res/drawable-xxhdpi/ic_add_white_24dp.png similarity index 100% rename from android/app/src/main/res/drawable-xxhdpi/ic_add_white_24dp.png rename to android-app/src/main/res/drawable-xxhdpi/ic_add_white_24dp.png diff --git a/android/app/src/main/res/drawable-xxhdpi/ic_alarm_off_black_48dp.png b/android-app/src/main/res/drawable-xxhdpi/ic_alarm_off_black_48dp.png similarity index 100% rename from android/app/src/main/res/drawable-xxhdpi/ic_alarm_off_black_48dp.png rename to android-app/src/main/res/drawable-xxhdpi/ic_alarm_off_black_48dp.png diff --git a/android/app/src/main/res/drawable-xxhdpi/ic_all_out_white_24dp.png b/android-app/src/main/res/drawable-xxhdpi/ic_all_out_white_24dp.png similarity index 100% rename from android/app/src/main/res/drawable-xxhdpi/ic_all_out_white_24dp.png rename to android-app/src/main/res/drawable-xxhdpi/ic_all_out_white_24dp.png diff --git a/android/app/src/main/res/drawable-xxhdpi/ic_call_made_white_24dp.png b/android-app/src/main/res/drawable-xxhdpi/ic_call_made_white_24dp.png similarity index 100% rename from android/app/src/main/res/drawable-xxhdpi/ic_call_made_white_24dp.png rename to android-app/src/main/res/drawable-xxhdpi/ic_call_made_white_24dp.png diff --git a/android/app/src/main/res/drawable-xxhdpi/ic_call_received_white_24dp.png b/android-app/src/main/res/drawable-xxhdpi/ic_call_received_white_24dp.png similarity index 100% rename from android/app/src/main/res/drawable-xxhdpi/ic_call_received_white_24dp.png rename to android-app/src/main/res/drawable-xxhdpi/ic_call_received_white_24dp.png diff --git a/android/app/src/main/res/drawable-xxhdpi/ic_card_travel_black_24dp.png b/android-app/src/main/res/drawable-xxhdpi/ic_card_travel_black_24dp.png similarity index 100% rename from android/app/src/main/res/drawable-xxhdpi/ic_card_travel_black_24dp.png rename to android-app/src/main/res/drawable-xxhdpi/ic_card_travel_black_24dp.png diff --git a/android/app/src/main/res/drawable-xxhdpi/ic_chat_bubble_outline_black_24dp.png b/android-app/src/main/res/drawable-xxhdpi/ic_chat_bubble_outline_black_24dp.png similarity index 100% rename from android/app/src/main/res/drawable-xxhdpi/ic_chat_bubble_outline_black_24dp.png rename to android-app/src/main/res/drawable-xxhdpi/ic_chat_bubble_outline_black_24dp.png diff --git a/android/app/src/main/res/drawable-xxhdpi/ic_check_black_24dp.png b/android-app/src/main/res/drawable-xxhdpi/ic_check_black_24dp.png similarity index 100% rename from android/app/src/main/res/drawable-xxhdpi/ic_check_black_24dp.png rename to android-app/src/main/res/drawable-xxhdpi/ic_check_black_24dp.png diff --git a/android/app/src/main/res/drawable-xxhdpi/ic_content_copy_black_24dp.png b/android-app/src/main/res/drawable-xxhdpi/ic_content_copy_black_24dp.png similarity index 100% rename from android/app/src/main/res/drawable-xxhdpi/ic_content_copy_black_24dp.png rename to android-app/src/main/res/drawable-xxhdpi/ic_content_copy_black_24dp.png diff --git a/android/app/src/main/res/drawable-xxhdpi/ic_delete_black_24dp.png b/android-app/src/main/res/drawable-xxhdpi/ic_delete_black_24dp.png similarity index 100% rename from android/app/src/main/res/drawable-xxhdpi/ic_delete_black_24dp.png rename to android-app/src/main/res/drawable-xxhdpi/ic_delete_black_24dp.png diff --git a/android/app/src/main/res/drawable-xxhdpi/ic_delete_sweep_white_24dp.png b/android-app/src/main/res/drawable-xxhdpi/ic_delete_sweep_white_24dp.png similarity index 100% rename from android/app/src/main/res/drawable-xxhdpi/ic_delete_sweep_white_24dp.png rename to android-app/src/main/res/drawable-xxhdpi/ic_delete_sweep_white_24dp.png diff --git a/android/app/src/main/res/drawable-xxhdpi/ic_delete_white_24dp.png b/android-app/src/main/res/drawable-xxhdpi/ic_delete_white_24dp.png similarity index 100% rename from android/app/src/main/res/drawable-xxhdpi/ic_delete_white_24dp.png rename to android-app/src/main/res/drawable-xxhdpi/ic_delete_white_24dp.png diff --git a/android/app/src/main/res/drawable-xxhdpi/ic_gps_fixed_black_24dp.png b/android-app/src/main/res/drawable-xxhdpi/ic_gps_fixed_black_24dp.png similarity index 100% rename from android/app/src/main/res/drawable-xxhdpi/ic_gps_fixed_black_24dp.png rename to android-app/src/main/res/drawable-xxhdpi/ic_gps_fixed_black_24dp.png diff --git a/android/app/src/main/res/drawable-xxhdpi/ic_gps_not_fixed_black_24dp.png b/android-app/src/main/res/drawable-xxhdpi/ic_gps_not_fixed_black_24dp.png similarity index 100% rename from android/app/src/main/res/drawable-xxhdpi/ic_gps_not_fixed_black_24dp.png rename to android-app/src/main/res/drawable-xxhdpi/ic_gps_not_fixed_black_24dp.png diff --git a/android/app/src/main/res/drawable-xxhdpi/ic_gps_not_fixed_black_48dp.png b/android-app/src/main/res/drawable-xxhdpi/ic_gps_not_fixed_black_48dp.png similarity index 100% rename from android/app/src/main/res/drawable-xxhdpi/ic_gps_not_fixed_black_48dp.png rename to android-app/src/main/res/drawable-xxhdpi/ic_gps_not_fixed_black_48dp.png diff --git a/android/app/src/main/res/drawable-xxhdpi/ic_import_export_black_24dp.png b/android-app/src/main/res/drawable-xxhdpi/ic_import_export_black_24dp.png similarity index 100% rename from android/app/src/main/res/drawable-xxhdpi/ic_import_export_black_24dp.png rename to android-app/src/main/res/drawable-xxhdpi/ic_import_export_black_24dp.png diff --git a/android/app/src/main/res/drawable-xxhdpi/ic_launch_black_24dp.png b/android-app/src/main/res/drawable-xxhdpi/ic_launch_black_24dp.png similarity index 100% rename from android/app/src/main/res/drawable-xxhdpi/ic_launch_black_24dp.png rename to android-app/src/main/res/drawable-xxhdpi/ic_launch_black_24dp.png diff --git a/android/app/src/main/res/drawable-xxhdpi/ic_link_black_24dp.png b/android-app/src/main/res/drawable-xxhdpi/ic_link_black_24dp.png similarity index 100% rename from android/app/src/main/res/drawable-xxhdpi/ic_link_black_24dp.png rename to android-app/src/main/res/drawable-xxhdpi/ic_link_black_24dp.png diff --git a/android/app/src/main/res/drawable-xxhdpi/ic_location_on_black_48dp.png b/android-app/src/main/res/drawable-xxhdpi/ic_location_on_black_48dp.png similarity index 100% rename from android/app/src/main/res/drawable-xxhdpi/ic_location_on_black_48dp.png rename to android-app/src/main/res/drawable-xxhdpi/ic_location_on_black_48dp.png diff --git a/android/app/src/main/res/drawable-xxhdpi/ic_lock_outline_black_24dp.png b/android-app/src/main/res/drawable-xxhdpi/ic_lock_outline_black_24dp.png similarity index 100% rename from android/app/src/main/res/drawable-xxhdpi/ic_lock_outline_black_24dp.png rename to android-app/src/main/res/drawable-xxhdpi/ic_lock_outline_black_24dp.png diff --git a/android/app/src/main/res/drawable-xxhdpi/ic_map_black_24dp.png b/android-app/src/main/res/drawable-xxhdpi/ic_map_black_24dp.png similarity index 100% rename from android/app/src/main/res/drawable-xxhdpi/ic_map_black_24dp.png rename to android-app/src/main/res/drawable-xxhdpi/ic_map_black_24dp.png diff --git a/android/app/src/main/res/drawable-xxhdpi/ic_message_black_24dp.png b/android-app/src/main/res/drawable-xxhdpi/ic_message_black_24dp.png similarity index 100% rename from android/app/src/main/res/drawable-xxhdpi/ic_message_black_24dp.png rename to android-app/src/main/res/drawable-xxhdpi/ic_message_black_24dp.png diff --git a/android/app/src/main/res/drawable-xxhdpi/ic_my_location_white_24dp.png b/android-app/src/main/res/drawable-xxhdpi/ic_my_location_white_24dp.png similarity index 100% rename from android/app/src/main/res/drawable-xxhdpi/ic_my_location_white_24dp.png rename to android-app/src/main/res/drawable-xxhdpi/ic_my_location_white_24dp.png diff --git a/android/app/src/main/res/drawable-xxhdpi/ic_open_in_browser_black_24dp.png b/android-app/src/main/res/drawable-xxhdpi/ic_open_in_browser_black_24dp.png similarity index 100% rename from android/app/src/main/res/drawable-xxhdpi/ic_open_in_browser_black_24dp.png rename to android-app/src/main/res/drawable-xxhdpi/ic_open_in_browser_black_24dp.png diff --git a/android/app/src/main/res/drawable-xxhdpi/ic_pause_black_48dp.png b/android-app/src/main/res/drawable-xxhdpi/ic_pause_black_48dp.png similarity index 100% rename from android/app/src/main/res/drawable-xxhdpi/ic_pause_black_48dp.png rename to android-app/src/main/res/drawable-xxhdpi/ic_pause_black_48dp.png diff --git a/android/app/src/main/res/drawable-xxhdpi/ic_perm_identity_black_24dp.png b/android-app/src/main/res/drawable-xxhdpi/ic_perm_identity_black_24dp.png similarity index 100% rename from android/app/src/main/res/drawable-xxhdpi/ic_perm_identity_black_24dp.png rename to android-app/src/main/res/drawable-xxhdpi/ic_perm_identity_black_24dp.png diff --git a/android/app/src/main/res/drawable-xxhdpi/ic_place_white_24dp.png b/android-app/src/main/res/drawable-xxhdpi/ic_place_white_24dp.png similarity index 100% rename from android/app/src/main/res/drawable-xxhdpi/ic_place_white_24dp.png rename to android-app/src/main/res/drawable-xxhdpi/ic_place_white_24dp.png diff --git a/android/app/src/main/res/drawable-xxhdpi/ic_save_black_24dp.png b/android-app/src/main/res/drawable-xxhdpi/ic_save_black_24dp.png similarity index 100% rename from android/app/src/main/res/drawable-xxhdpi/ic_save_black_24dp.png rename to android-app/src/main/res/drawable-xxhdpi/ic_save_black_24dp.png diff --git a/android/app/src/main/res/drawable-xxhdpi/ic_settings_black_24dp.png b/android-app/src/main/res/drawable-xxhdpi/ic_settings_black_24dp.png similarity index 100% rename from android/app/src/main/res/drawable-xxhdpi/ic_settings_black_24dp.png rename to android-app/src/main/res/drawable-xxhdpi/ic_settings_black_24dp.png diff --git a/android/app/src/main/res/drawable-xxhdpi/ic_share_black_24dp.png b/android-app/src/main/res/drawable-xxhdpi/ic_share_black_24dp.png similarity index 100% rename from android/app/src/main/res/drawable-xxhdpi/ic_share_black_24dp.png rename to android-app/src/main/res/drawable-xxhdpi/ic_share_black_24dp.png diff --git a/android/app/src/main/res/drawable-xxhdpi/ic_share_black_48dp.png b/android-app/src/main/res/drawable-xxhdpi/ic_share_black_48dp.png similarity index 100% rename from android/app/src/main/res/drawable-xxhdpi/ic_share_black_48dp.png rename to android-app/src/main/res/drawable-xxhdpi/ic_share_black_48dp.png diff --git a/android/app/src/main/res/drawable-xxhdpi/ic_update_black_24dp.png b/android-app/src/main/res/drawable-xxhdpi/ic_update_black_24dp.png similarity index 100% rename from android/app/src/main/res/drawable-xxhdpi/ic_update_black_24dp.png rename to android-app/src/main/res/drawable-xxhdpi/ic_update_black_24dp.png diff --git a/android/app/src/main/res/drawable-xxhdpi/ic_update_white_24dp.png b/android-app/src/main/res/drawable-xxhdpi/ic_update_white_24dp.png similarity index 100% rename from android/app/src/main/res/drawable-xxhdpi/ic_update_white_24dp.png rename to android-app/src/main/res/drawable-xxhdpi/ic_update_white_24dp.png diff --git a/android/app/src/main/res/drawable-xxhdpi/ic_visibility_off_black_48dp.png b/android-app/src/main/res/drawable-xxhdpi/ic_visibility_off_black_48dp.png similarity index 100% rename from android/app/src/main/res/drawable-xxhdpi/ic_visibility_off_black_48dp.png rename to android-app/src/main/res/drawable-xxhdpi/ic_visibility_off_black_48dp.png diff --git a/android/app/src/main/res/drawable-xxhdpi/ic_zoom_in_white_24dp.png b/android-app/src/main/res/drawable-xxhdpi/ic_zoom_in_white_24dp.png similarity index 100% rename from android/app/src/main/res/drawable-xxhdpi/ic_zoom_in_white_24dp.png rename to android-app/src/main/res/drawable-xxhdpi/ic_zoom_in_white_24dp.png diff --git a/android/app/src/main/res/drawable-xxhdpi/ic_zoom_out_map_white_24dp.png b/android-app/src/main/res/drawable-xxhdpi/ic_zoom_out_map_white_24dp.png similarity index 100% rename from android/app/src/main/res/drawable-xxhdpi/ic_zoom_out_map_white_24dp.png rename to android-app/src/main/res/drawable-xxhdpi/ic_zoom_out_map_white_24dp.png diff --git a/android/app/src/main/res/drawable-xxhdpi/ic_zoom_out_white_24dp.png b/android-app/src/main/res/drawable-xxhdpi/ic_zoom_out_white_24dp.png similarity index 100% rename from android/app/src/main/res/drawable-xxhdpi/ic_zoom_out_white_24dp.png rename to android-app/src/main/res/drawable-xxhdpi/ic_zoom_out_white_24dp.png diff --git a/android/app/src/main/res/drawable-xxhdpi/icon_header.png b/android-app/src/main/res/drawable-xxhdpi/icon_header.png similarity index 100% rename from android/app/src/main/res/drawable-xxhdpi/icon_header.png rename to android-app/src/main/res/drawable-xxhdpi/icon_header.png diff --git a/android/app/src/main/res/drawable-xxhdpi/icon_launch_map.png b/android-app/src/main/res/drawable-xxhdpi/icon_launch_map.png similarity index 100% rename from android/app/src/main/res/drawable-xxhdpi/icon_launch_map.png rename to android-app/src/main/res/drawable-xxhdpi/icon_launch_map.png diff --git a/android/app/src/main/res/drawable-xxhdpi/icon_launch_person.png b/android-app/src/main/res/drawable-xxhdpi/icon_launch_person.png similarity index 100% rename from android/app/src/main/res/drawable-xxhdpi/icon_launch_person.png rename to android-app/src/main/res/drawable-xxhdpi/icon_launch_person.png diff --git a/android/app/src/main/res/drawable-xxhdpi/icon_launch_text.png b/android-app/src/main/res/drawable-xxhdpi/icon_launch_text.png similarity index 100% rename from android/app/src/main/res/drawable-xxhdpi/icon_launch_text.png rename to android-app/src/main/res/drawable-xxhdpi/icon_launch_text.png diff --git a/android/app/src/main/res/drawable-xxhdpi/icon_launcher.png b/android-app/src/main/res/drawable-xxhdpi/icon_launcher.png similarity index 100% rename from android/app/src/main/res/drawable-xxhdpi/icon_launcher.png rename to android-app/src/main/res/drawable-xxhdpi/icon_launcher.png diff --git a/android/app/src/main/res/drawable-xxhdpi/icon_notification_small.png b/android-app/src/main/res/drawable-xxhdpi/icon_notification_small.png similarity index 100% rename from android/app/src/main/res/drawable-xxhdpi/icon_notification_small.png rename to android-app/src/main/res/drawable-xxhdpi/icon_notification_small.png diff --git a/android/app/src/main/res/drawable-xxxhdpi/ic_access_time_black_24dp.png b/android-app/src/main/res/drawable-xxxhdpi/ic_access_time_black_24dp.png similarity index 100% rename from android/app/src/main/res/drawable-xxxhdpi/ic_access_time_black_24dp.png rename to android-app/src/main/res/drawable-xxxhdpi/ic_access_time_black_24dp.png diff --git a/android/app/src/main/res/drawable-xxxhdpi/ic_accessibility_black_24dp.png b/android-app/src/main/res/drawable-xxxhdpi/ic_accessibility_black_24dp.png similarity index 100% rename from android/app/src/main/res/drawable-xxxhdpi/ic_accessibility_black_24dp.png rename to android-app/src/main/res/drawable-xxxhdpi/ic_accessibility_black_24dp.png diff --git a/android/app/src/main/res/drawable-xxxhdpi/ic_add_white_24dp.png b/android-app/src/main/res/drawable-xxxhdpi/ic_add_white_24dp.png similarity index 100% rename from android/app/src/main/res/drawable-xxxhdpi/ic_add_white_24dp.png rename to android-app/src/main/res/drawable-xxxhdpi/ic_add_white_24dp.png diff --git a/android/app/src/main/res/drawable-xxxhdpi/ic_alarm_off_black_48dp.png b/android-app/src/main/res/drawable-xxxhdpi/ic_alarm_off_black_48dp.png similarity index 100% rename from android/app/src/main/res/drawable-xxxhdpi/ic_alarm_off_black_48dp.png rename to android-app/src/main/res/drawable-xxxhdpi/ic_alarm_off_black_48dp.png diff --git a/android/app/src/main/res/drawable-xxxhdpi/ic_all_out_white_24dp.png b/android-app/src/main/res/drawable-xxxhdpi/ic_all_out_white_24dp.png similarity index 100% rename from android/app/src/main/res/drawable-xxxhdpi/ic_all_out_white_24dp.png rename to android-app/src/main/res/drawable-xxxhdpi/ic_all_out_white_24dp.png diff --git a/android/app/src/main/res/drawable-xxxhdpi/ic_call_made_white_24dp.png b/android-app/src/main/res/drawable-xxxhdpi/ic_call_made_white_24dp.png similarity index 100% rename from android/app/src/main/res/drawable-xxxhdpi/ic_call_made_white_24dp.png rename to android-app/src/main/res/drawable-xxxhdpi/ic_call_made_white_24dp.png diff --git a/android/app/src/main/res/drawable-xxxhdpi/ic_call_received_white_24dp.png b/android-app/src/main/res/drawable-xxxhdpi/ic_call_received_white_24dp.png similarity index 100% rename from android/app/src/main/res/drawable-xxxhdpi/ic_call_received_white_24dp.png rename to android-app/src/main/res/drawable-xxxhdpi/ic_call_received_white_24dp.png diff --git a/android/app/src/main/res/drawable-xxxhdpi/ic_card_travel_black_24dp.png b/android-app/src/main/res/drawable-xxxhdpi/ic_card_travel_black_24dp.png similarity index 100% rename from android/app/src/main/res/drawable-xxxhdpi/ic_card_travel_black_24dp.png rename to android-app/src/main/res/drawable-xxxhdpi/ic_card_travel_black_24dp.png diff --git a/android/app/src/main/res/drawable-xxxhdpi/ic_chat_bubble_outline_black_24dp.png b/android-app/src/main/res/drawable-xxxhdpi/ic_chat_bubble_outline_black_24dp.png similarity index 100% rename from android/app/src/main/res/drawable-xxxhdpi/ic_chat_bubble_outline_black_24dp.png rename to android-app/src/main/res/drawable-xxxhdpi/ic_chat_bubble_outline_black_24dp.png diff --git a/android/app/src/main/res/drawable-xxxhdpi/ic_check_black_24dp.png b/android-app/src/main/res/drawable-xxxhdpi/ic_check_black_24dp.png similarity index 100% rename from android/app/src/main/res/drawable-xxxhdpi/ic_check_black_24dp.png rename to android-app/src/main/res/drawable-xxxhdpi/ic_check_black_24dp.png diff --git a/android/app/src/main/res/drawable-xxxhdpi/ic_content_copy_black_24dp.png b/android-app/src/main/res/drawable-xxxhdpi/ic_content_copy_black_24dp.png similarity index 100% rename from android/app/src/main/res/drawable-xxxhdpi/ic_content_copy_black_24dp.png rename to android-app/src/main/res/drawable-xxxhdpi/ic_content_copy_black_24dp.png diff --git a/android/app/src/main/res/drawable-xxxhdpi/ic_delete_black_24dp.png b/android-app/src/main/res/drawable-xxxhdpi/ic_delete_black_24dp.png similarity index 100% rename from android/app/src/main/res/drawable-xxxhdpi/ic_delete_black_24dp.png rename to android-app/src/main/res/drawable-xxxhdpi/ic_delete_black_24dp.png diff --git a/android/app/src/main/res/drawable-xxxhdpi/ic_delete_sweep_white_24dp.png b/android-app/src/main/res/drawable-xxxhdpi/ic_delete_sweep_white_24dp.png similarity index 100% rename from android/app/src/main/res/drawable-xxxhdpi/ic_delete_sweep_white_24dp.png rename to android-app/src/main/res/drawable-xxxhdpi/ic_delete_sweep_white_24dp.png diff --git a/android/app/src/main/res/drawable-xxxhdpi/ic_delete_white_24dp.png b/android-app/src/main/res/drawable-xxxhdpi/ic_delete_white_24dp.png similarity index 100% rename from android/app/src/main/res/drawable-xxxhdpi/ic_delete_white_24dp.png rename to android-app/src/main/res/drawable-xxxhdpi/ic_delete_white_24dp.png diff --git a/android/app/src/main/res/drawable-xxxhdpi/ic_gps_fixed_black_24dp.png b/android-app/src/main/res/drawable-xxxhdpi/ic_gps_fixed_black_24dp.png similarity index 100% rename from android/app/src/main/res/drawable-xxxhdpi/ic_gps_fixed_black_24dp.png rename to android-app/src/main/res/drawable-xxxhdpi/ic_gps_fixed_black_24dp.png diff --git a/android/app/src/main/res/drawable-xxxhdpi/ic_gps_not_fixed_black_24dp.png b/android-app/src/main/res/drawable-xxxhdpi/ic_gps_not_fixed_black_24dp.png similarity index 100% rename from android/app/src/main/res/drawable-xxxhdpi/ic_gps_not_fixed_black_24dp.png rename to android-app/src/main/res/drawable-xxxhdpi/ic_gps_not_fixed_black_24dp.png diff --git a/android/app/src/main/res/drawable-xxxhdpi/ic_gps_not_fixed_black_48dp.png b/android-app/src/main/res/drawable-xxxhdpi/ic_gps_not_fixed_black_48dp.png similarity index 100% rename from android/app/src/main/res/drawable-xxxhdpi/ic_gps_not_fixed_black_48dp.png rename to android-app/src/main/res/drawable-xxxhdpi/ic_gps_not_fixed_black_48dp.png diff --git a/android/app/src/main/res/drawable-xxxhdpi/ic_import_export_black_24dp.png b/android-app/src/main/res/drawable-xxxhdpi/ic_import_export_black_24dp.png similarity index 100% rename from android/app/src/main/res/drawable-xxxhdpi/ic_import_export_black_24dp.png rename to android-app/src/main/res/drawable-xxxhdpi/ic_import_export_black_24dp.png diff --git a/android/app/src/main/res/drawable-xxxhdpi/ic_launch_black_24dp.png b/android-app/src/main/res/drawable-xxxhdpi/ic_launch_black_24dp.png similarity index 100% rename from android/app/src/main/res/drawable-xxxhdpi/ic_launch_black_24dp.png rename to android-app/src/main/res/drawable-xxxhdpi/ic_launch_black_24dp.png diff --git a/android/app/src/main/res/drawable-xxxhdpi/ic_link_black_24dp.png b/android-app/src/main/res/drawable-xxxhdpi/ic_link_black_24dp.png similarity index 100% rename from android/app/src/main/res/drawable-xxxhdpi/ic_link_black_24dp.png rename to android-app/src/main/res/drawable-xxxhdpi/ic_link_black_24dp.png diff --git a/android/app/src/main/res/drawable-xxxhdpi/ic_location_on_black_48dp.png b/android-app/src/main/res/drawable-xxxhdpi/ic_location_on_black_48dp.png similarity index 100% rename from android/app/src/main/res/drawable-xxxhdpi/ic_location_on_black_48dp.png rename to android-app/src/main/res/drawable-xxxhdpi/ic_location_on_black_48dp.png diff --git a/android/app/src/main/res/drawable-xxxhdpi/ic_lock_outline_black_24dp.png b/android-app/src/main/res/drawable-xxxhdpi/ic_lock_outline_black_24dp.png similarity index 100% rename from android/app/src/main/res/drawable-xxxhdpi/ic_lock_outline_black_24dp.png rename to android-app/src/main/res/drawable-xxxhdpi/ic_lock_outline_black_24dp.png diff --git a/android/app/src/main/res/drawable-xxxhdpi/ic_map_black_24dp.png b/android-app/src/main/res/drawable-xxxhdpi/ic_map_black_24dp.png similarity index 100% rename from android/app/src/main/res/drawable-xxxhdpi/ic_map_black_24dp.png rename to android-app/src/main/res/drawable-xxxhdpi/ic_map_black_24dp.png diff --git a/android/app/src/main/res/drawable-xxxhdpi/ic_message_black_24dp.png b/android-app/src/main/res/drawable-xxxhdpi/ic_message_black_24dp.png similarity index 100% rename from android/app/src/main/res/drawable-xxxhdpi/ic_message_black_24dp.png rename to android-app/src/main/res/drawable-xxxhdpi/ic_message_black_24dp.png diff --git a/android/app/src/main/res/drawable-xxxhdpi/ic_my_location_white_24dp.png b/android-app/src/main/res/drawable-xxxhdpi/ic_my_location_white_24dp.png similarity index 100% rename from android/app/src/main/res/drawable-xxxhdpi/ic_my_location_white_24dp.png rename to android-app/src/main/res/drawable-xxxhdpi/ic_my_location_white_24dp.png diff --git a/android/app/src/main/res/drawable-xxxhdpi/ic_open_in_browser_black_24dp.png b/android-app/src/main/res/drawable-xxxhdpi/ic_open_in_browser_black_24dp.png similarity index 100% rename from android/app/src/main/res/drawable-xxxhdpi/ic_open_in_browser_black_24dp.png rename to android-app/src/main/res/drawable-xxxhdpi/ic_open_in_browser_black_24dp.png diff --git a/android/app/src/main/res/drawable-xxxhdpi/ic_pause_black_48dp.png b/android-app/src/main/res/drawable-xxxhdpi/ic_pause_black_48dp.png similarity index 100% rename from android/app/src/main/res/drawable-xxxhdpi/ic_pause_black_48dp.png rename to android-app/src/main/res/drawable-xxxhdpi/ic_pause_black_48dp.png diff --git a/android/app/src/main/res/drawable-xxxhdpi/ic_perm_identity_black_24dp.png b/android-app/src/main/res/drawable-xxxhdpi/ic_perm_identity_black_24dp.png similarity index 100% rename from android/app/src/main/res/drawable-xxxhdpi/ic_perm_identity_black_24dp.png rename to android-app/src/main/res/drawable-xxxhdpi/ic_perm_identity_black_24dp.png diff --git a/android/app/src/main/res/drawable-xxxhdpi/ic_place_white_24dp.png b/android-app/src/main/res/drawable-xxxhdpi/ic_place_white_24dp.png similarity index 100% rename from android/app/src/main/res/drawable-xxxhdpi/ic_place_white_24dp.png rename to android-app/src/main/res/drawable-xxxhdpi/ic_place_white_24dp.png diff --git a/android/app/src/main/res/drawable-xxxhdpi/ic_save_black_24dp.png b/android-app/src/main/res/drawable-xxxhdpi/ic_save_black_24dp.png similarity index 100% rename from android/app/src/main/res/drawable-xxxhdpi/ic_save_black_24dp.png rename to android-app/src/main/res/drawable-xxxhdpi/ic_save_black_24dp.png diff --git a/android/app/src/main/res/drawable-xxxhdpi/ic_settings_black_24dp.png b/android-app/src/main/res/drawable-xxxhdpi/ic_settings_black_24dp.png similarity index 100% rename from android/app/src/main/res/drawable-xxxhdpi/ic_settings_black_24dp.png rename to android-app/src/main/res/drawable-xxxhdpi/ic_settings_black_24dp.png diff --git a/android/app/src/main/res/drawable-xxxhdpi/ic_share_black_24dp.png b/android-app/src/main/res/drawable-xxxhdpi/ic_share_black_24dp.png similarity index 100% rename from android/app/src/main/res/drawable-xxxhdpi/ic_share_black_24dp.png rename to android-app/src/main/res/drawable-xxxhdpi/ic_share_black_24dp.png diff --git a/android/app/src/main/res/drawable-xxxhdpi/ic_share_black_48dp.png b/android-app/src/main/res/drawable-xxxhdpi/ic_share_black_48dp.png similarity index 100% rename from android/app/src/main/res/drawable-xxxhdpi/ic_share_black_48dp.png rename to android-app/src/main/res/drawable-xxxhdpi/ic_share_black_48dp.png diff --git a/android/app/src/main/res/drawable-xxxhdpi/ic_update_black_24dp.png b/android-app/src/main/res/drawable-xxxhdpi/ic_update_black_24dp.png similarity index 100% rename from android/app/src/main/res/drawable-xxxhdpi/ic_update_black_24dp.png rename to android-app/src/main/res/drawable-xxxhdpi/ic_update_black_24dp.png diff --git a/android/app/src/main/res/drawable-xxxhdpi/ic_update_white_24dp.png b/android-app/src/main/res/drawable-xxxhdpi/ic_update_white_24dp.png similarity index 100% rename from android/app/src/main/res/drawable-xxxhdpi/ic_update_white_24dp.png rename to android-app/src/main/res/drawable-xxxhdpi/ic_update_white_24dp.png diff --git a/android/app/src/main/res/drawable-xxxhdpi/ic_visibility_off_black_48dp.png b/android-app/src/main/res/drawable-xxxhdpi/ic_visibility_off_black_48dp.png similarity index 100% rename from android/app/src/main/res/drawable-xxxhdpi/ic_visibility_off_black_48dp.png rename to android-app/src/main/res/drawable-xxxhdpi/ic_visibility_off_black_48dp.png diff --git a/android/app/src/main/res/drawable-xxxhdpi/ic_zoom_in_white_24dp.png b/android-app/src/main/res/drawable-xxxhdpi/ic_zoom_in_white_24dp.png similarity index 100% rename from android/app/src/main/res/drawable-xxxhdpi/ic_zoom_in_white_24dp.png rename to android-app/src/main/res/drawable-xxxhdpi/ic_zoom_in_white_24dp.png diff --git a/android/app/src/main/res/drawable-xxxhdpi/ic_zoom_out_map_white_24dp.png b/android-app/src/main/res/drawable-xxxhdpi/ic_zoom_out_map_white_24dp.png similarity index 100% rename from android/app/src/main/res/drawable-xxxhdpi/ic_zoom_out_map_white_24dp.png rename to android-app/src/main/res/drawable-xxxhdpi/ic_zoom_out_map_white_24dp.png diff --git a/android/app/src/main/res/drawable-xxxhdpi/ic_zoom_out_white_24dp.png b/android-app/src/main/res/drawable-xxxhdpi/ic_zoom_out_white_24dp.png similarity index 100% rename from android/app/src/main/res/drawable-xxxhdpi/ic_zoom_out_white_24dp.png rename to android-app/src/main/res/drawable-xxxhdpi/ic_zoom_out_white_24dp.png diff --git a/android/app/src/main/res/drawable/bg_launch_gradient.xml b/android-app/src/main/res/drawable/bg_launch_gradient.xml similarity index 100% rename from android/app/src/main/res/drawable/bg_launch_gradient.xml rename to android-app/src/main/res/drawable/bg_launch_gradient.xml diff --git a/android/app/src/main/res/layout/activity_login.xml b/android-app/src/main/res/layout/activity_login.xml similarity index 100% rename from android/app/src/main/res/layout/activity_login.xml rename to android-app/src/main/res/layout/activity_login.xml diff --git a/android/app/src/main/res/layout/activity_main_default.xml b/android-app/src/main/res/layout/activity_main_default.xml similarity index 100% rename from android/app/src/main/res/layout/activity_main_default.xml rename to android-app/src/main/res/layout/activity_main_default.xml diff --git a/android/app/src/main/res/layout/activity_main_tablet.xml b/android-app/src/main/res/layout/activity_main_tablet.xml similarity index 100% rename from android/app/src/main/res/layout/activity_main_tablet.xml rename to android-app/src/main/res/layout/activity_main_tablet.xml diff --git a/android/app/src/main/res/layout/activity_start.xml b/android-app/src/main/res/layout/activity_start.xml similarity index 96% rename from android/app/src/main/res/layout/activity_start.xml rename to android-app/src/main/res/layout/activity_start.xml index 4dcf2c7..03d265e 100644 --- a/android/app/src/main/res/layout/activity_start.xml +++ b/android-app/src/main/res/layout/activity_start.xml @@ -1,13 +1,13 @@ - - - - - - - + + + + + + + diff --git a/android/app/src/main/res/layout/fragment_detail.xml b/android-app/src/main/res/layout/fragment_detail.xml similarity index 100% rename from android/app/src/main/res/layout/fragment_detail.xml rename to android-app/src/main/res/layout/fragment_detail.xml diff --git a/android/app/src/main/res/layout/fragment_detail_pager.xml b/android-app/src/main/res/layout/fragment_detail_pager.xml similarity index 100% rename from android/app/src/main/res/layout/fragment_detail_pager.xml rename to android-app/src/main/res/layout/fragment_detail_pager.xml diff --git a/android/app/src/main/res/layout/fragment_list_grant.xml b/android-app/src/main/res/layout/fragment_list_grant.xml similarity index 100% rename from android/app/src/main/res/layout/fragment_list_grant.xml rename to android-app/src/main/res/layout/fragment_list_grant.xml diff --git a/android/app/src/main/res/layout/fragment_list_notice.xml b/android-app/src/main/res/layout/fragment_list_notice.xml similarity index 100% rename from android/app/src/main/res/layout/fragment_list_notice.xml rename to android-app/src/main/res/layout/fragment_list_notice.xml diff --git a/android/app/src/main/res/layout/fragment_list_share.xml b/android-app/src/main/res/layout/fragment_list_share.xml similarity index 100% rename from android/app/src/main/res/layout/fragment_list_share.xml rename to android-app/src/main/res/layout/fragment_list_share.xml diff --git a/android/app/src/main/res/layout/fragment_login.xml b/android-app/src/main/res/layout/fragment_login.xml similarity index 100% rename from android/app/src/main/res/layout/fragment_login.xml rename to android-app/src/main/res/layout/fragment_login.xml diff --git a/android/app/src/main/res/layout/fragment_logo.xml b/android-app/src/main/res/layout/fragment_logo.xml similarity index 100% rename from android/app/src/main/res/layout/fragment_logo.xml rename to android-app/src/main/res/layout/fragment_logo.xml diff --git a/android/app/src/main/res/layout/fragment_manage.xml b/android-app/src/main/res/layout/fragment_manage.xml similarity index 100% rename from android/app/src/main/res/layout/fragment_manage.xml rename to android-app/src/main/res/layout/fragment_manage.xml diff --git a/android/app/src/main/res/layout/fragment_map.xml b/android-app/src/main/res/layout/fragment_map.xml similarity index 100% rename from android/app/src/main/res/layout/fragment_map.xml rename to android-app/src/main/res/layout/fragment_map.xml diff --git a/android/app/src/main/res/layout/fragment_share.xml b/android-app/src/main/res/layout/fragment_share.xml similarity index 100% rename from android/app/src/main/res/layout/fragment_share.xml rename to android-app/src/main/res/layout/fragment_share.xml diff --git a/android/app/src/main/res/layout/fragment_terms.xml b/android-app/src/main/res/layout/fragment_terms.xml similarity index 100% rename from android/app/src/main/res/layout/fragment_terms.xml rename to android-app/src/main/res/layout/fragment_terms.xml diff --git a/android/app/src/main/res/layout/view_alert_dialog.xml b/android-app/src/main/res/layout/view_alert_dialog.xml similarity index 100% rename from android/app/src/main/res/layout/view_alert_dialog.xml rename to android-app/src/main/res/layout/view_alert_dialog.xml diff --git a/android/app/src/main/res/layout/view_detail_card.xml b/android-app/src/main/res/layout/view_detail_card.xml similarity index 100% rename from android/app/src/main/res/layout/view_detail_card.xml rename to android-app/src/main/res/layout/view_detail_card.xml diff --git a/android/app/src/main/res/layout/view_detail_plain.xml b/android-app/src/main/res/layout/view_detail_plain.xml similarity index 100% rename from android/app/src/main/res/layout/view_detail_plain.xml rename to android-app/src/main/res/layout/view_detail_plain.xml diff --git a/android/app/src/main/res/layout/view_drawer_header.xml b/android-app/src/main/res/layout/view_drawer_header.xml similarity index 100% rename from android/app/src/main/res/layout/view_drawer_header.xml rename to android-app/src/main/res/layout/view_drawer_header.xml diff --git a/android/app/src/main/res/layout/view_manage_tab.xml b/android-app/src/main/res/layout/view_manage_tab.xml similarity index 100% rename from android/app/src/main/res/layout/view_manage_tab.xml rename to android-app/src/main/res/layout/view_manage_tab.xml diff --git a/android/app/src/main/res/layout/view_notice.xml b/android-app/src/main/res/layout/view_notice.xml similarity index 100% rename from android/app/src/main/res/layout/view_notice.xml rename to android-app/src/main/res/layout/view_notice.xml diff --git a/android/app/src/main/res/menu/menu_drawer.xml b/android-app/src/main/res/menu/menu_drawer.xml similarity index 100% rename from android/app/src/main/res/menu/menu_drawer.xml rename to android-app/src/main/res/menu/menu_drawer.xml diff --git a/android/app/src/main/res/menu/menu_grant.xml b/android-app/src/main/res/menu/menu_grant.xml similarity index 100% rename from android/app/src/main/res/menu/menu_grant.xml rename to android-app/src/main/res/menu/menu_grant.xml diff --git a/android/app/src/main/res/menu/menu_map.xml b/android-app/src/main/res/menu/menu_map.xml similarity index 100% rename from android/app/src/main/res/menu/menu_map.xml rename to android-app/src/main/res/menu/menu_map.xml diff --git a/android/app/src/main/res/menu/menu_notice.xml b/android-app/src/main/res/menu/menu_notice.xml similarity index 100% rename from android/app/src/main/res/menu/menu_notice.xml rename to android-app/src/main/res/menu/menu_notice.xml diff --git a/android/app/src/main/res/menu/menu_share.xml b/android-app/src/main/res/menu/menu_share.xml similarity index 100% rename from android/app/src/main/res/menu/menu_share.xml rename to android-app/src/main/res/menu/menu_share.xml diff --git a/android/app/src/main/res/values-de/strings.xml b/android-app/src/main/res/values-de/strings.xml similarity index 100% rename from android/app/src/main/res/values-de/strings.xml rename to android-app/src/main/res/values-de/strings.xml diff --git a/android/app/src/main/res/values/colors.xml b/android-app/src/main/res/values/colors.xml similarity index 100% rename from android/app/src/main/res/values/colors.xml rename to android-app/src/main/res/values/colors.xml diff --git a/android/app/src/main/res/values/dimens.xml b/android-app/src/main/res/values/dimens.xml similarity index 100% rename from android/app/src/main/res/values/dimens.xml rename to android-app/src/main/res/values/dimens.xml diff --git a/android/app/src/main/res/values/generic.xml b/android-app/src/main/res/values/generic.xml similarity index 100% rename from android/app/src/main/res/values/generic.xml rename to android-app/src/main/res/values/generic.xml diff --git a/android/app/src/main/res/values/strings.xml b/android-app/src/main/res/values/strings.xml similarity index 100% rename from android/app/src/main/res/values/strings.xml rename to android-app/src/main/res/values/strings.xml diff --git a/android/app/src/main/res/values/styles.xml b/android-app/src/main/res/values/styles.xml similarity index 100% rename from android/app/src/main/res/values/styles.xml rename to android-app/src/main/res/values/styles.xml diff --git a/android/app/src/main/res/values/themes.xml b/android-app/src/main/res/values/themes.xml similarity index 100% rename from android/app/src/main/res/values/themes.xml rename to android-app/src/main/res/values/themes.xml diff --git a/android/app/src/main/res/xml/backup.xml b/android-app/src/main/res/xml/backup.xml similarity index 100% rename from android/app/src/main/res/xml/backup.xml rename to android-app/src/main/res/xml/backup.xml diff --git a/android/app/src/main/res/xml/settings.xml b/android-app/src/main/res/xml/settings.xml similarity index 100% rename from android/app/src/main/res/xml/settings.xml rename to android-app/src/main/res/xml/settings.xml diff --git a/android/app/src/test/java/android/content/pm/ShortcutManager.java b/android-app/src/test/java/android/content/pm/ShortcutManager.java similarity index 100% rename from android/app/src/test/java/android/content/pm/ShortcutManager.java rename to android-app/src/test/java/android/content/pm/ShortcutManager.java diff --git a/android/app/src/test/java/com/maptology/android/app/test/MainActivityTest.java b/android-app/src/test/java/com/maptology/android/app/test/MainActivityTest.java similarity index 95% rename from android/app/src/test/java/com/maptology/android/app/test/MainActivityTest.java rename to android-app/src/test/java/com/maptology/android/app/test/MainActivityTest.java index 8ecaca8..55931cb 100644 --- a/android/app/src/test/java/com/maptology/android/app/test/MainActivityTest.java +++ b/android-app/src/test/java/com/maptology/android/app/test/MainActivityTest.java @@ -9,6 +9,7 @@ import org.junit.runner.RunWith; import org.robolectric.Robolectric; import org.robolectric.RobolectricTestRunner; import org.robolectric.RuntimeEnvironment; +import org.robolectric.annotation.Config; /** * Runs a simple roboelectric test. @@ -21,6 +22,7 @@ import org.robolectric.RuntimeEnvironment; // the resource type to be loaded (e.g. "en-port" for // english resources in portrait mode, etc. // @Config(qualifiers = "en-port", sdk = 18) +@Config(manifest = "AndroidManifest.xml") public class MainActivityTest { @Test diff --git a/android/app/src/test/java/com/maptology/android/app/test/StartActivityTest.java b/android-app/src/test/java/com/maptology/android/app/test/StartActivityTest.java similarity index 96% rename from android/app/src/test/java/com/maptology/android/app/test/StartActivityTest.java rename to android-app/src/test/java/com/maptology/android/app/test/StartActivityTest.java index 525fde1..ac5199c 100644 --- a/android/app/src/test/java/com/maptology/android/app/test/StartActivityTest.java +++ b/android-app/src/test/java/com/maptology/android/app/test/StartActivityTest.java @@ -14,6 +14,7 @@ import org.junit.runner.RunWith; import org.robolectric.Robolectric; import org.robolectric.RobolectricTestRunner; import org.robolectric.android.controller.ActivityController; +import org.robolectric.annotation.Config; import org.robolectric.shadows.ShadowIntent; import static org.robolectric.Shadows.shadowOf; @@ -29,6 +30,7 @@ import static org.robolectric.Shadows.shadowOf; // the resource type to be loaded (e.g. "en-port" for // english resources in portrait mode, etc. // @Config(qualifiers = "en-port", sdk = 18) +@Config(manifest = "AndroidManifest.xml") public class StartActivityTest { @Test diff --git a/android/app/src/test/java/com/maptology/android/app/test/location/LocationStoreTest.java b/android-app/src/test/java/com/maptology/android/app/test/location/LocationStoreTest.java similarity index 98% rename from android/app/src/test/java/com/maptology/android/app/test/location/LocationStoreTest.java rename to android-app/src/test/java/com/maptology/android/app/test/location/LocationStoreTest.java index 0f6adac..982b7f6 100644 --- a/android/app/src/test/java/com/maptology/android/app/test/location/LocationStoreTest.java +++ b/android-app/src/test/java/com/maptology/android/app/test/location/LocationStoreTest.java @@ -12,6 +12,7 @@ import org.junit.Test; import org.junit.runner.RunWith; import org.robolectric.RobolectricTestRunner; import org.robolectric.RuntimeEnvironment; +import org.robolectric.annotation.Config; import org.robolectric.shadows.ShadowLog; import java.util.ArrayList; @@ -23,6 +24,7 @@ import java.util.List; * @author Marcus */ @RunWith(RobolectricTestRunner.class) +@Config(manifest = "AndroidManifest.xml") public class LocationStoreTest { @Before diff --git a/android/app/src/test/java/com/maptology/android/app/test/notice/NoticeFragmentTest.java b/android-app/src/test/java/com/maptology/android/app/test/notice/NoticeFragmentTest.java similarity index 96% rename from android/app/src/test/java/com/maptology/android/app/test/notice/NoticeFragmentTest.java rename to android-app/src/test/java/com/maptology/android/app/test/notice/NoticeFragmentTest.java index d999612..0c898ed 100644 --- a/android/app/src/test/java/com/maptology/android/app/test/notice/NoticeFragmentTest.java +++ b/android-app/src/test/java/com/maptology/android/app/test/notice/NoticeFragmentTest.java @@ -11,6 +11,7 @@ import org.robolectric.Robolectric; import org.robolectric.RobolectricTestRunner; import org.robolectric.Shadows; import org.robolectric.android.controller.ActivityController; +import org.robolectric.annotation.Config; import org.robolectric.shadows.ShadowActivity; /** @@ -20,6 +21,7 @@ import org.robolectric.shadows.ShadowActivity; * @author Marcus */ @RunWith(RobolectricTestRunner.class) +@Config(manifest = "AndroidManifest.xml") public class NoticeFragmentTest { @Test diff --git a/android/app/src/test/java/com/maptology/android/app/test/notice/NoticeStoreTest.java b/android-app/src/test/java/com/maptology/android/app/test/notice/NoticeStoreTest.java similarity index 98% rename from android/app/src/test/java/com/maptology/android/app/test/notice/NoticeStoreTest.java rename to android-app/src/test/java/com/maptology/android/app/test/notice/NoticeStoreTest.java index c9a52a1..aefd02b 100644 --- a/android/app/src/test/java/com/maptology/android/app/test/notice/NoticeStoreTest.java +++ b/android-app/src/test/java/com/maptology/android/app/test/notice/NoticeStoreTest.java @@ -13,6 +13,7 @@ import org.junit.Test; import org.junit.runner.RunWith; import org.robolectric.RobolectricTestRunner; import org.robolectric.RuntimeEnvironment; +import org.robolectric.annotation.Config; import java.util.ArrayList; @@ -22,6 +23,7 @@ import java.util.ArrayList; * @author Marcus */ @RunWith(RobolectricTestRunner.class) +@Config(manifest = "AndroidManifest.xml") public class NoticeStoreTest { @Before diff --git a/android/app/src/test/java/com/maptology/android/app/test/notice/NoticeSyncTest.java b/android-app/src/test/java/com/maptology/android/app/test/notice/NoticeSyncTest.java similarity index 96% rename from android/app/src/test/java/com/maptology/android/app/test/notice/NoticeSyncTest.java rename to android-app/src/test/java/com/maptology/android/app/test/notice/NoticeSyncTest.java index 729383c..0ba6404 100644 --- a/android/app/src/test/java/com/maptology/android/app/test/notice/NoticeSyncTest.java +++ b/android-app/src/test/java/com/maptology/android/app/test/notice/NoticeSyncTest.java @@ -32,6 +32,7 @@ import java.util.List; * @author Marcus */ @RunWith(RobolectricTestRunner.class) +@Config(manifest = "AndroidManifest.xml") public class NoticeSyncTest { @Before @@ -91,8 +92,8 @@ public class NoticeSyncTest { ShadowNotification shadowNotification = Shadows.shadowOf(notification); Assert.assertEquals("Should have english title.", "The title 1", shadowNotification.getContentTitle()); - // get rid of the notificaiton - notificationManager.cancel(SyncNoticeTask.NOTIFICATION_ID); + // get rid of the notification + ((NotificationManager)app.getSystemService(Context.NOTIFICATION_SERVICE)).cancel(SyncNoticeTask.NOTIFICATION_ID); Assert.assertEquals("Notification should be empty.", notificationManager.getAllNotifications().size(), 0); // synchronize again against the same messages diff --git a/android/app/src/test/java/com/maptology/android/app/test/util/AppConfiguration.java b/android-app/src/test/java/com/maptology/android/app/test/util/AppConfiguration.java similarity index 100% rename from android/app/src/test/java/com/maptology/android/app/test/util/AppConfiguration.java rename to android-app/src/test/java/com/maptology/android/app/test/util/AppConfiguration.java diff --git a/android/app/src/test/java/com/maptology/android/app/test/util/FragmentActivity.java b/android-app/src/test/java/com/maptology/android/app/test/util/FragmentActivity.java similarity index 100% rename from android/app/src/test/java/com/maptology/android/app/test/util/FragmentActivity.java rename to android-app/src/test/java/com/maptology/android/app/test/util/FragmentActivity.java diff --git a/android/app/src/test/java/com/maptology/android/app/test/util/ProxyGenerator.java b/android-app/src/test/java/com/maptology/android/app/test/util/ProxyGenerator.java similarity index 100% rename from android/app/src/test/java/com/maptology/android/app/test/util/ProxyGenerator.java rename to android-app/src/test/java/com/maptology/android/app/test/util/ProxyGenerator.java diff --git a/android/app/src/test/resources/robolectric.properties b/android-app/src/test/resources/robolectric.properties similarity index 100% rename from android/app/src/test/resources/robolectric.properties rename to android-app/src/test/resources/robolectric.properties diff --git a/android-feign/build.gradle b/android-feign/build.gradle new file mode 100644 index 0000000..4792c6c --- /dev/null +++ b/android-feign/build.gradle @@ -0,0 +1,50 @@ +plugins { + id 'org.detoeuf.swagger-codegen' version '1.7.4' +} + +description = "Maptology Android Feign" + +dependencies { + compile "io.swagger:swagger-annotations:${versionSwagger}" + compile "com.fasterxml.jackson.core:jackson-core:${versionJackson}" + compile "com.fasterxml.jackson.core:jackson-annotations:${versionJackson}" + compile "com.fasterxml.jackson.core:jackson-databind:${versionJackson}" + compile "com.fasterxml.jackson.datatype:jackson-datatype-joda:${versionJackson}" + compile "javax.annotation:javax.annotation-api:${versionAnnotation}" + compile "io.github.openfeign:feign-core:9.4.0" + compile "io.github.openfeign:feign-jackson:9.4.0" + compileOnly "org.apache.oltu.oauth2:org.apache.oltu.oauth2.client:1.0.1" +} + +sourceSets.main.java.srcDirs = ['src/main/java', 'build/swagger/src/main/java'] + +swagger { + inputSpec = file(project(':common-api:').buildDir.path + '/swagger/maptology.json') + outputDir = file("${project.buildDir}/swagger") + lang = 'java' + library = 'feign' + additionalProperties = [ + 'invokerPackage' : 'com.maptology.android.feign', + 'modelPackage' : 'com.maptology.android.feign.model', + 'apiPackage' : 'com.maptology.android.feign.api', + 'dateLibrary' : 'java8' + ] + systemProperties = [ + 'apis' : '', + 'models' : '', + 'supportingFiles' : 'false', + 'modelDocs' : 'false', + 'apiTests' : 'false', + 'modelTests' : 'false' + ] +} + +// require api build to access swagger definition +tasks['swagger'].dependsOn(project(':common-api').tasks['build']) +// require swagger code gen before compilation +compileJava.dependsOn('swagger') + + + + + diff --git a/android/feign/pom.xml b/android-feign/pom.xml similarity index 93% rename from android/feign/pom.xml rename to android-feign/pom.xml index 057f83a..e1fbbac 100644 --- a/android/feign/pom.xml +++ b/android-feign/pom.xml @@ -2,13 +2,13 @@ - android + project com.maptology 0.0.1-SNAPSHOT 4.0.0 - com.maptology.android - feign + com.maptology + android-feign Maptology Android Feign Source code of the generated client. jar @@ -33,7 +33,7 @@ com.maptology - api + common-api ${project.version} swagger maptology.json @@ -78,7 +78,7 @@ com.maptology - api + common-api ${project.version} swagger provided @@ -123,7 +123,10 @@ jackson-datatype-joda ${version.jackson} - + + javax.annotation + javax.annotation-api + org.apache.oltu.oauth2 diff --git a/android/feign/src/main/java/com/maptology/android/feign/ApiClient.java b/android-feign/src/main/java/com/maptology/android/feign/ApiClient.java similarity index 100% rename from android/feign/src/main/java/com/maptology/android/feign/ApiClient.java rename to android-feign/src/main/java/com/maptology/android/feign/ApiClient.java diff --git a/android/feign/src/main/java/com/maptology/android/feign/EncodingUtils.java b/android-feign/src/main/java/com/maptology/android/feign/EncodingUtils.java similarity index 100% rename from android/feign/src/main/java/com/maptology/android/feign/EncodingUtils.java rename to android-feign/src/main/java/com/maptology/android/feign/EncodingUtils.java diff --git a/android/feign/src/main/java/com/maptology/android/feign/ParamExpander.java b/android-feign/src/main/java/com/maptology/android/feign/ParamExpander.java similarity index 100% rename from android/feign/src/main/java/com/maptology/android/feign/ParamExpander.java rename to android-feign/src/main/java/com/maptology/android/feign/ParamExpander.java diff --git a/android/feign/src/main/java/com/maptology/android/feign/RFC3339DateFormat.java b/android-feign/src/main/java/com/maptology/android/feign/RFC3339DateFormat.java similarity index 100% rename from android/feign/src/main/java/com/maptology/android/feign/RFC3339DateFormat.java rename to android-feign/src/main/java/com/maptology/android/feign/RFC3339DateFormat.java diff --git a/android/feign/src/main/java/com/maptology/android/feign/StringUtil.java b/android-feign/src/main/java/com/maptology/android/feign/StringUtil.java similarity index 100% rename from android/feign/src/main/java/com/maptology/android/feign/StringUtil.java rename to android-feign/src/main/java/com/maptology/android/feign/StringUtil.java diff --git a/android/feign/src/main/java/com/maptology/android/feign/auth/ApiKeyAuth.java b/android-feign/src/main/java/com/maptology/android/feign/auth/ApiKeyAuth.java similarity index 100% rename from android/feign/src/main/java/com/maptology/android/feign/auth/ApiKeyAuth.java rename to android-feign/src/main/java/com/maptology/android/feign/auth/ApiKeyAuth.java diff --git a/android/feign/src/main/java/com/maptology/android/feign/auth/HttpBasicAuth.java b/android-feign/src/main/java/com/maptology/android/feign/auth/HttpBasicAuth.java similarity index 100% rename from android/feign/src/main/java/com/maptology/android/feign/auth/HttpBasicAuth.java rename to android-feign/src/main/java/com/maptology/android/feign/auth/HttpBasicAuth.java diff --git a/android/feign/src/main/java/com/maptology/android/feign/auth/OAuth.java b/android-feign/src/main/java/com/maptology/android/feign/auth/OAuth.java similarity index 100% rename from android/feign/src/main/java/com/maptology/android/feign/auth/OAuth.java rename to android-feign/src/main/java/com/maptology/android/feign/auth/OAuth.java diff --git a/android/feign/src/main/java/com/maptology/android/feign/auth/OAuthFlow.java b/android-feign/src/main/java/com/maptology/android/feign/auth/OAuthFlow.java similarity index 100% rename from android/feign/src/main/java/com/maptology/android/feign/auth/OAuthFlow.java rename to android-feign/src/main/java/com/maptology/android/feign/auth/OAuthFlow.java diff --git a/android/leafless/pom.xml b/android/leafless/pom.xml deleted file mode 100644 index 288c69c..0000000 --- a/android/leafless/pom.xml +++ /dev/null @@ -1,61 +0,0 @@ - - 4.0.0 - - android - com.maptology - 0.0.1-SNAPSHOT - - com.maptology.android - leafless - Maptology Android Leafless - A native leaflet like map view from Locoslab. - aar - - - - maven-compiler-plugin - - - com.simpligility.maven.plugins - android-maven-plugin - - - - - - junit - junit - - - android - android - provided - - - com.locoslab.api.data - carta - 1.3.0 - - - com.locoslab.api.data - maps - 1.3.0 - - - com.android.support - appcompat-v7 - aar - - - de.grundid.opendatalab - geojson-jackson - 1.8 - - - com.fasterxml.jackson.core - jackson-databind - 2.8.5 - - - diff --git a/android/leafless/src/main/AndroidManifest.xml b/android/leafless/src/main/AndroidManifest.xml deleted file mode 100644 index 528400f..0000000 --- a/android/leafless/src/main/AndroidManifest.xml +++ /dev/null @@ -1,6 +0,0 @@ - - - - - \ No newline at end of file diff --git a/android/leafless/src/main/java/com/locoslab/capi/android/leafless/AbstractElement.java b/android/leafless/src/main/java/com/locoslab/capi/android/leafless/AbstractElement.java deleted file mode 100644 index a82744c..0000000 --- a/android/leafless/src/main/java/com/locoslab/capi/android/leafless/AbstractElement.java +++ /dev/null @@ -1,306 +0,0 @@ -package com.locoslab.capi.android.leafless; - -import com.locoslab.api.data.maps.model.Box; -import com.locoslab.api.data.maps.model.Coordinate; -import com.locoslab.capi.android.leafless.touch.IMovableTarget; - -import android.graphics.Canvas; -import android.graphics.Rect; - -/** - * An element that is supposed to be drawn on the map. - * It contains bounds to determine whether we should - * be drawing it for the current view port, a drawing - * method and a back reference to the active map to - * signal changes that will require redrawing. - * - * @author Marcus - */ -public abstract class AbstractElement implements IMovableTarget { - - /** - * The short tap listeners. - */ - protected ListenerBundle shortTapListeners = new ListenerBundle<>(); - - /** - * The long tap listeners. - */ - protected ListenerBundle longTapListeners = new ListenerBundle<>(); - - /** - * The currently active map. - */ - protected MapView map; - - /** - * The map element options. - */ - protected O options; - - /** - * A unique element id that is assigned when - * the element is added. - */ - protected int id; - - /** - * Creates a new map element with the specified options. - * - * @param options The options. - */ - public AbstractElement(O options) { - this.options = options; - } - - - /** - * Returns the internal id of the view. - * - * @return The internal id. - */ - public int getId() { - return id; - } - - /** - * Sets the internal id of the view. - * - * @param id The id to set. - */ - protected void setId(int id) { - this.id = id; - } - - - /** - * Draws the object onto the canvas. During this call, - * the map view state will be accessible. - * - * @param canvas The canvas. - */ - public abstract void drawObject(Canvas canvas); - - /** - * Returns the bounds of the object. - * - * @return The bounds of the object. - */ - public abstract Box getBounds(); - - /** - * Sets or unsets the active map. - * - * @param map The map. - */ - public void setMap(MapView map) { - this.map = map; - } - - /** - * Returns the short tap listener bundle. - * - * @return The short tap listener bundle. - */ - protected IListenerBundle getShortTapListeners() { - return shortTapListeners; - } - - /** - * Returns the long tap listener bundle. - * - * @return The long tap listener bundle. - */ - protected IListenerBundle getLongTapListeners() { - return longTapListeners; - } - - /** - * Adds a touch listener for short tap events. - * - * @param listener The listener to add. - */ - public void addShortTapListener(ITouchListener listener) { - getShortTapListeners().addListener(listener); - } - - /** - * Removes a previously added short tap listener. - * - * @param listener The listener to remove. - */ - public void removeShortTapListener(ITouchListener listener) { - getShortTapListeners().removeListener(listener); - } - - /** - * Adds a touch listener for long tap events. - * - * @param listener The listener to add. - */ - public void addLongTapListener(ITouchListener listener) { - getLongTapListeners().addListener(listener); - } - - /** - * Removes a listener for long tap events. - * - * @param listener The listener to remove. - */ - public void removeLongTapListener(ITouchListener listener) { - getLongTapListeners().removeListener(listener); - } - - /** - * Returns the current map view or null. - * - * @return The map view or null. - */ - protected MapView getMapView() { - return map; - } - - /** - * Returns the current map view state or null. - * - * @return The current map view state or null. - */ - protected MapViewState getMapViewState() { - MapView map = getMapView(); - if (map != null) { - return map.getState(); - } else { - return null; - } - } - - /** - * Determines whether the element contains the point. Subclasses - * can overwrite this to provide a more specific match. - * - * @param x The x coordinate. - * @param y The y coordinate. - * @return True if the point is contained, false otherwise. - */ - public boolean contains(int x, int y) { - MapViewState state = getMapViewState(); - if (state != null) { - double[] lonLat = state.pixelToCoordinate(x, y); - Coordinate c = new Coordinate(); - c.setLatitude(lonLat[1]); - c.setLongitude(lonLat[0]); - return getBounds().contains(c); - } else { - return false; - } - } - - /** - * Returns the rectangle around the region where the element - * will be drawn. Subclasses can override this to provide - * a more specific rectangle. - * - * @return The drawing region or null, if the map state is not available. - */ - public Rect getRegion() { - MapViewState state = getMapViewState(); - Box bounds = getBounds(); - if (state != null) { - float[] a = state.coordinateToPixel(bounds.getMinimumLongitude(), bounds.getMinimumLatitude()); - float[] b = state.coordinateToPixel(bounds.getMaximumLongitude(), bounds.getMinimumLatitude()); - float[] c = state.coordinateToPixel(bounds.getMinimumLongitude(), bounds.getMaximumLatitude()); - float[] d = state.coordinateToPixel(bounds.getMaximumLongitude(), bounds.getMaximumLatitude()); - float minX = Math.min(a[0], Math.min(b[0], Math.min(c[0], d[0]))); - float minY = Math.min(a[1], Math.min(b[1], Math.min(c[1], d[1]))); - float maxX = Math.max(a[0], Math.max(b[0], Math.max(c[0], d[0]))); - float maxY = Math.max(a[1], Math.max(b[1], Math.max(c[1], d[1]))); - return new Rect((int)minX, (int)minY, (int)maxX, (int)maxY); - } - return null; - } - - /** - * Does nothing by default. - */ - public void moveBy(int x, int y) { - // do nothing, let sub classes overwrite. - } - - /** - * Fires a short tap event. - * - * @param x The x. - * @param y The y. - */ - public void shortTap(int x, int y) { - TouchEvent event = createTouch(x, y); - if (event != null) { - shortTapListeners.fireEvent(event); - } - } - - /** - * Fires a long tap event. - * - * @param x The x. - * @param y The y. - */ - public void longTap(int x, int y) { - TouchEvent event = createTouch(x, y); - if (event != null) { - longTapListeners.fireEvent(event); - } - } - - /** - * Creates a touch event for the view. - * - * @param x The x coordinate. - * @param y The y coordinate. - * @return The touch event or null. - */ - protected TouchEvent createTouch(int x, int y) { - MapView map = getMapView(); - MapViewState state = getMapViewState(); - if (map != null) { - MapPoint p = new MapPoint(x, y); - Coordinate c = new Coordinate(); - double[] lnglat = state.pixelToCoordinate(x, y); - c.setLatitude(lnglat[1]); - c.setLongitude(lnglat[0]); - return new TouchEvent(map, p, c); - } - return null; - } - - /** - * Returns the current content description or null, if none is set. - * - * @return The content description or null, if none set. - */ - public String getContentDescription() { - return options.contentDescription; - } - - /** - * Sets the content description to a text or unsets it (by setting it to null) - * - * @param description The content description or null to unset. - */ - public void setContentDescription(String description) { - options.contentDescription = description; - invalidate(); - } - - - /** - * Invalidates the map view if set. - */ - protected void invalidate() { - if (map != null) { - map.onChangeElement(this); - } - } - - -} diff --git a/android/leafless/src/main/java/com/locoslab/capi/android/leafless/AbstractMovableElement.java b/android/leafless/src/main/java/com/locoslab/capi/android/leafless/AbstractMovableElement.java deleted file mode 100644 index bde93df..0000000 --- a/android/leafless/src/main/java/com/locoslab/capi/android/leafless/AbstractMovableElement.java +++ /dev/null @@ -1,53 +0,0 @@ -package com.locoslab.capi.android.leafless; - -/** - * This class extends the abstract element with a method to draw - * shadows of the object. - * - * @author Marcus - */ -public abstract class AbstractMovableElement extends AbstractElement { - - - /** - * The move listeners. - */ - protected ListenerBundle moveListeners = new ListenerBundle<>(); - - /** - * Creates a new element with the specified options. - * - * @param options The options. - */ - public AbstractMovableElement(O options) { - super(options); - } - - /** - * Returns the move listener bundle. - * - * @return The move listener bundle. - */ - protected IListenerBundle getMoveListeners() { - return moveListeners; - } - - /** - * Adds a listener for movement events. - * - * @param listener The listener to add. - */ - public void addMoveListener(IMoveListener listener) { - getMoveListeners().addListener(listener); - } - - /** - * Removes a listener for movement events. - * - * @param listener The listener to remove. - */ - public void removeMoveListener(IMoveListener listener) { - getMoveListeners().removeListener(listener); - } - -} diff --git a/android/leafless/src/main/java/com/locoslab/capi/android/leafless/AccessibleComparator.java b/android/leafless/src/main/java/com/locoslab/capi/android/leafless/AccessibleComparator.java deleted file mode 100644 index bc7f690..0000000 --- a/android/leafless/src/main/java/com/locoslab/capi/android/leafless/AccessibleComparator.java +++ /dev/null @@ -1,73 +0,0 @@ -package com.locoslab.capi.android.leafless; - -import java.util.Comparator; - -import com.locoslab.api.data.maps.model.Box; -import com.locoslab.capi.android.leafless.control.AbstractControl; -import com.locoslab.capi.android.leafless.marker.Marker; -import com.locoslab.capi.android.leafless.polyline.Polyline; -import com.locoslab.capi.android.leafless.tile.TileLayer; - -/** - * A comparator that compares elements to compute their accessibility order. - * - * @author Marcus - */ -public class AccessibleComparator implements Comparator> { - - @Override - public int compare(AbstractElement o1, AbstractElement o2) { - int to1 = getTypeOrder(o1); - int to2 = getTypeOrder(o2); - if (to1 == to2) { - return compare(o1.getBounds(), o2.getBounds()); - } else { - return to1 < to2?1:-1; - } - } - - /** - * Returns an order values based on the type. - * - * @param o1 The object. - * @return An int. Elements that should go first will have a higher value. - */ - protected int getTypeOrder(AbstractElement o1) { - if (o1 instanceof TileLayer) { - return 0; - } else if (o1 instanceof Polyline) { - return 1; - } else if (o1 instanceof Marker) { - return 3; - } else if (o1 instanceof AbstractControl) { - return 4; - } else { - return 2; // between marker and polyline - } - } - - /** - * Compares two boxes such that boxes with higher latitudes will - * be first and if this does not resolve all cases, we will also - * consider the longitude such that higher longitudes will go later. - * - * @param b1 The first box. - * @param b2 The second box - * @return -1 if b1 should go first, 1 if b2 should go first, 0 if - * there is no order between the boxes. - */ - protected int compare(Box b1, Box b2) { - if (b1.getMaximumLatitude() > b2.getMaximumLatitude()) { - return -1; - } else if (b1.getMaximumLatitude() < b2.getMaximumLatitude()) { - return 1; - } else if (b1.getMinimumLongitude() > b2.getMinimumLongitude()){ - return 1; - } else if (b1.getMinimumLatitude() < b2.getMinimumLatitude()) { - return -1; - } else { - return 0; - } - } - -} diff --git a/android/leafless/src/main/java/com/locoslab/capi/android/leafless/AccessibleMapView.java b/android/leafless/src/main/java/com/locoslab/capi/android/leafless/AccessibleMapView.java deleted file mode 100644 index 9d73e90..0000000 --- a/android/leafless/src/main/java/com/locoslab/capi/android/leafless/AccessibleMapView.java +++ /dev/null @@ -1,212 +0,0 @@ -package com.locoslab.capi.android.leafless; - -import java.util.ArrayList; -import java.util.List; - -import android.content.Context; -import android.graphics.Rect; -import android.support.v4.view.ViewCompat; -import android.util.AttributeSet; -import android.view.KeyEvent; -import android.view.MotionEvent; - -/** - * The accessible map view is a specialized map view that - * supports accessibility. However to use this class, it - * is necessary to include the app compat library as part - * of the app. - * - * @author Marcus - */ -public class AccessibleMapView extends MapView { - - /** - * The accessibility helper to handle accessibility events - * without loosing compatibility with older versions of Android. - */ - private AccessibleMapViewHelper accessibilityHelper; - - /** - * A list of individual view updates that are scheduled. - */ - private List scheduledInvalidators = new ArrayList<>(); - - /** - * Helper class to invalidate individual views. - * - * @author Marcus - */ - private class ViewInvalidator implements Runnable { - - /** - * The view id to invalidate. - */ - private int id; - - /** - * Creates a view invalidator. - * - * @param id The id of the view. - */ - private ViewInvalidator(int id) { - this.id = id; - } - - @Override - public void run() { - List ids = new ArrayList<>(); - accessibilityHelper.getVisibleVirtualViews(ids); - if (ids.contains(id)) { - accessibilityHelper.invalidateVirtualView(id); - } - scheduledInvalidators.remove(this); - } - - @Override - public boolean equals(Object obj) { - if (obj.getClass() == getClass()) { - return id == ((ViewInvalidator)obj).id; - } - return false; - } - - @Override - public int hashCode() { - return id; - } - } - - /** - * A runnable to schedule to invalidate the virtual hierarchy. - */ - private Runnable invalidator = new Runnable() { - @Override - public void run() { - accessibilityHelper.invalidateRoot(); - } - }; - - /** - * Creates a new map view. - * - * @param context The context. - */ - public AccessibleMapView(Context context) { - super(context); - init(context); - } - - /** - * Creates a new map view. - * - * @param context The context. - * @param attrs The attributes. - */ - public AccessibleMapView(Context context, AttributeSet attrs) { - super(context, attrs); - init(context); - } - - /** - * Initializes the map view. - * - * @param context the context. - */ - private void init(Context context) { - accessibilityHelper = new AccessibleMapViewHelper(this); - ViewCompat.setAccessibilityDelegate(this, accessibilityHelper); - } - - @Override - public boolean dispatchHoverEvent(MotionEvent event) { - return accessibilityHelper.dispatchHoverEvent(event) || super.dispatchHoverEvent(event); - } - - @Override - public boolean dispatchKeyEvent(KeyEvent event) { - return accessibilityHelper.dispatchKeyEvent(event) || super.dispatchKeyEvent(event); - } - - @Override - public void onFocusChanged(boolean gainFocus, int direction, Rect previouslyFocusedRect) { - super.onFocusChanged(gainFocus, direction, previouslyFocusedRect); - accessibilityHelper.onFocusChanged(gainFocus, direction, previouslyFocusedRect); - } - - @Override - protected void onAddElement(AbstractElement element) { - super.onAddElement(element); - scheduleInvalidate(); - } - - @Override - protected void onRemoveElement(AbstractElement element) { - super.onRemoveElement(element); - scheduleInvalidate(); - } - - @Override - protected void onChangeElement(AbstractElement element) { - super.onChangeElement(element); - scheduleInvalidate(element.getId()); - } - - @Override - public void scaleBy(double scale) { - super.scaleBy(scale); - scheduleInvalidate(); - } - - @Override - public void rotateBy(double angle) { - super.rotateBy(angle); - scheduleInvalidate(); - } - - @Override - public void moveBy(int x, int y) { - super.moveBy(x, y); - scheduleInvalidate(); - } - - @Override - public void setScale(double scale) { - super.setScale(scale); - scheduleInvalidate(); - } - - @Override - public void setAngle(double angle) { - super.setAngle(angle); - scheduleInvalidate(); - } - - @Override - public void setCenter(double longitude, double latitude) { - super.setCenter(longitude, latitude); - scheduleInvalidate(); - } - - /** - * Schedules the invalidation of a the complete view. - */ - private void scheduleInvalidate() { - requests.removeAll(scheduledInvalidators); - scheduledInvalidators.clear(); - requests.remove(invalidator); - requests.add(invalidator); - } - - /** - * Schedules the invalidation of a particular view. - * - * @param view The view id. - */ - private void scheduleInvalidate(int view) { - ViewInvalidator inv = new ViewInvalidator(view); - if (!requests.contains(invalidator) && !scheduledInvalidators.contains(inv)) { - scheduledInvalidators.add(inv); - requests.add(inv); - } - } -} diff --git a/android/leafless/src/main/java/com/locoslab/capi/android/leafless/AccessibleMapViewHelper.java b/android/leafless/src/main/java/com/locoslab/capi/android/leafless/AccessibleMapViewHelper.java deleted file mode 100644 index 0a1ef24..0000000 --- a/android/leafless/src/main/java/com/locoslab/capi/android/leafless/AccessibleMapViewHelper.java +++ /dev/null @@ -1,157 +0,0 @@ -package com.locoslab.capi.android.leafless; - -import java.util.Collections; -import java.util.List; - -import com.locoslab.api.data.maps.model.Coordinate; - -import android.graphics.Rect; -import android.os.Bundle; -import android.support.v4.view.accessibility.AccessibilityNodeInfoCompat; -import android.support.v4.widget.ExploreByTouchHelper; -import android.view.accessibility.AccessibilityEvent; - -/** - * Implements an explore by touch helper that integrates with the map - * view elements. The map view helper uses the Android application - * compatibility library to add accessibility handling by composition - * which enables support for old and new Android versions with a - * single piece of code. - * - * @author Marcus - * - */ -public class AccessibleMapViewHelper extends ExploreByTouchHelper { - - /** - * Enables or disables debug output to standard out. - */ - private static final boolean HEAVY_DEBUG = false; - - /** - * The map view that is handled by this helper. - */ - private MapView view; - - /** - * A single instance for the class, to reduce the gc overhead. - */ - private AccessibleComparator comparator = new AccessibleComparator(); - - /** - * Creates a new helper for the view. - * - * @param view The map view. - */ - public AccessibleMapViewHelper(MapView view) { - super(view); - this.view = view; - } - - @Override - protected int getVirtualViewAt(float x, float y) { - if (HEAVY_DEBUG) System.out.println("Get view at: " + x + ", " + y); - AbstractElement element = view.findElement((int)x, (int)y, ElementFilter.ACCESSIBLE); - if (element != null) { - if (HEAVY_DEBUG) System.out.println("Returning element with id " + element.getId()); - return element.getId(); - } else { - if (HEAVY_DEBUG) System.out.println("No element found."); - return HOST_ID; - } - } - - @Override - protected void getVisibleVirtualViews(List virtualViewIds) { - List> elements = view.findElements(view.getState().getViewport(), ElementFilter.ACCESSIBLE); - Collections.sort(elements, comparator); - for (AbstractElement element: elements) { - virtualViewIds.add(element.getId()); - } - if (HEAVY_DEBUG) System.out.println("Returning " + virtualViewIds.size() + " visible views."); - } - - @Override - protected void onPopulateEventForVirtualView(int virtualViewId, AccessibilityEvent event) { - if (HEAVY_DEBUG) System.out.println("On populate view for id " + virtualViewId); - // set the content description in case we cannot get it - event.setContentDescription(""); - AbstractElement element = view.findElement(virtualViewId); - if (element != null) { - String contentDescription = element.getContentDescription(); - if (contentDescription != null) { - if (HEAVY_DEBUG) System.out.println("On populate for id " + virtualViewId + " setting content description to " + contentDescription); - event.setContentDescription(contentDescription); - } - } - } - - @Override - protected void onPopulateNodeForVirtualView(int virtualViewId, AccessibilityNodeInfoCompat node) { - if (HEAVY_DEBUG) System.out.println("On populate node for id " + virtualViewId); - // set the content description and the bounds to offscreen values, in case we cannot get them - node.setContentDescription(""); - node.setBoundsInParent(new Rect(view.getState().getPixelWidth() + 1, view.getState().getPixelHeight() + 1, view.getState().getPixelWidth() + 1, view.getState().getPixelHeight() + 1)); - AbstractElement element = view.findElement(virtualViewId); - if (element != null) { - String contentDescription = element.getContentDescription(); - if (contentDescription != null) { - if (HEAVY_DEBUG) System.out.println("Setting content description: " + contentDescription); - node.setContentDescription(contentDescription); - } - Rect region = element.getRegion(); - if (region != null) { - if (HEAVY_DEBUG) System.out.println("Setting region to " + region.left + "," + region.top + "," + region.right + "," + region.bottom); - node.setBoundsInParent(region); - } - } - } - - @Override - protected boolean onPerformActionForVirtualView(int virtualViewId, int action, Bundle arguments) { - if (HEAVY_DEBUG) System.out.println("Perform touch for view " + virtualViewId + " action " + action); - AbstractElement element = view.findElement(virtualViewId); - switch (action) { - case AccessibilityNodeInfoCompat.ACTION_CLICK: - if (element.shortTapListeners.hasListeners()) { - TouchEvent event = createTouchEvent(element); - if (event != null) element.shortTapListeners.fireEvent(event); - return true; - } else { - return false; - } - case AccessibilityNodeInfoCompat.ACTION_LONG_CLICK: - if (element.longTapListeners.hasListeners()) { - TouchEvent event = createTouchEvent(element); - if (event != null) element.longTapListeners.fireEvent(event); - return true; - } else { - return false; - } - default: - return false; - } - } - - /** - * Creates a touch event that will hopefully reach the view. - * - * @param element The element. - * @return The touch element or null. - */ - protected TouchEvent createTouchEvent(AbstractElement element) { - Rect region = element.getRegion(); - if (region != null) { - int x = region.left + (region.right - region.left) / 2; - int y = region.top + (region.bottom - region.top) / 2; - double[] lnglat = view.getState().pixelToCoordinate(x, y); - Coordinate c = new Coordinate(); - c.setLongitude(lnglat[0]); - c.setLatitude(lnglat[1]); - return new TouchEvent(view, new MapPoint(x, y), c); - } else { - return null; - } - } - -} diff --git a/android/leafless/src/main/java/com/locoslab/capi/android/leafless/ElementFilter.java b/android/leafless/src/main/java/com/locoslab/capi/android/leafless/ElementFilter.java deleted file mode 100644 index 4825ad5..0000000 --- a/android/leafless/src/main/java/com/locoslab/capi/android/leafless/ElementFilter.java +++ /dev/null @@ -1,57 +0,0 @@ -package com.locoslab.capi.android.leafless; - -/** - * A filter to filter abstract elements for their touch. - * - * @author Marcus - */ -enum ElementFilter { - - /** - * Accepts only elements that have a content - * description set. - */ - ACCESSIBLE, - - /** - * Accepts only movable elements. - */ - MOVEABLE, - - /** - * Accepts only long tapable elements. - */ - LONG_TAPABLE, - - /** - * Accepts only short tapable elements. - */ - SHORT_TAPABLE; - - /** - * Filters the elements to ensure that they are either - * short or long tapable or movable. - * - * @param element The element. - * @return The filter. - */ - public boolean acceptElement(AbstractElement element) { - switch (this) { - case ACCESSIBLE: - return element.options.contentDescription != null; - case MOVEABLE: - if (element instanceof AbstractMovableElement) { - return ((AbstractMovableElement)element).moveListeners.hasListeners(); - } else { - return false; - } - case LONG_TAPABLE: - return element.longTapListeners.hasListeners(); - case SHORT_TAPABLE: - return element.shortTapListeners.hasListeners(); - } - return false; - } - - -} diff --git a/android/leafless/src/main/java/com/locoslab/capi/android/leafless/ElementOptions.java b/android/leafless/src/main/java/com/locoslab/capi/android/leafless/ElementOptions.java deleted file mode 100644 index a27d76c..0000000 --- a/android/leafless/src/main/java/com/locoslab/capi/android/leafless/ElementOptions.java +++ /dev/null @@ -1,35 +0,0 @@ -package com.locoslab.capi.android.leafless; - -/** - * An options object for map objects. - * - * @author Marcus - */ -public class ElementOptions { - - /** - * The accessibility text of the element. If set to null, - * the element will not be accessible and not be explorable - * by touch. - */ - public String contentDescription = null; - - /** - * Creates a new options object. - */ - public ElementOptions() { - super(); - } - - /** - * Creates a new options object with the field - * values copied from the specified map options. - * - * @param options The options to copy. - */ - public ElementOptions(ElementOptions options) { - this.contentDescription = options.contentDescription; - } - - -} diff --git a/android/leafless/src/main/java/com/locoslab/capi/android/leafless/FixedElementOptions.java b/android/leafless/src/main/java/com/locoslab/capi/android/leafless/FixedElementOptions.java deleted file mode 100644 index 70a4e2c..0000000 --- a/android/leafless/src/main/java/com/locoslab/capi/android/leafless/FixedElementOptions.java +++ /dev/null @@ -1,37 +0,0 @@ -package com.locoslab.capi.android.leafless; - -/** - * Base options for map elements with fixed sizes. - * - * @author Marcus - * - */ -public class FixedElementOptions extends ElementOptions { - - /** - * Determines whether the size of this element is - * density independent. In this case, pixel sizes - * will be taken as is and not scaled by the display - * density. - */ - public boolean densityIndependent = false; - - /** - * Creates a new options object. - */ - public FixedElementOptions() { - super(); - } - - /** - * Creates a new options object with the field - * values copied from the specified map options. - * - * @param options The options to copy. - */ - public FixedElementOptions(FixedElementOptions options) { - super(options); - this.densityIndependent = options.densityIndependent; - } - -} diff --git a/android/leafless/src/main/java/com/locoslab/capi/android/leafless/IListenerBundle.java b/android/leafless/src/main/java/com/locoslab/capi/android/leafless/IListenerBundle.java deleted file mode 100644 index ca149ea..0000000 --- a/android/leafless/src/main/java/com/locoslab/capi/android/leafless/IListenerBundle.java +++ /dev/null @@ -1,28 +0,0 @@ -package com.locoslab.capi.android.leafless; - -/** - * An interface for listener bundles. - * - * @author Marcus - * - * @param The listener type. - */ -public interface IListenerBundle> { - - /** - * Adds a listener. - * - * @param listener The listener. - */ - public void addListener(L listener); - - /** - * Removes a listener. - * - * @param listener The listener. - * @return True if the listener was removed, - * false if its was not registered. - */ - public boolean removeListener(L listener); - -} diff --git a/android/leafless/src/main/java/com/locoslab/capi/android/leafless/ILoadable.java b/android/leafless/src/main/java/com/locoslab/capi/android/leafless/ILoadable.java deleted file mode 100644 index ea1881a..0000000 --- a/android/leafless/src/main/java/com/locoslab/capi/android/leafless/ILoadable.java +++ /dev/null @@ -1,16 +0,0 @@ -package com.locoslab.capi.android.leafless; - -/** - * A base interface for loadable elements. - * - * @author Marcus - */ -public interface ILoadable { - - /** - * Returns the url from where to load the object. - * - * @return The url to load the object. - */ - String getUrl(); -} diff --git a/android/leafless/src/main/java/com/locoslab/capi/android/leafless/ILoader.java b/android/leafless/src/main/java/com/locoslab/capi/android/leafless/ILoader.java deleted file mode 100644 index 685fe2a..0000000 --- a/android/leafless/src/main/java/com/locoslab/capi/android/leafless/ILoader.java +++ /dev/null @@ -1,32 +0,0 @@ -package com.locoslab.capi.android.leafless; - -import com.locoslab.capi.android.leafless.cache.CacheObjectLoader; - -/** - * A base interface for typed loaders. - * - * @author Marcus - */ -public interface ILoader { - - /** - * Requests an object to be loaded. - * - * @param loadable The loadable. - */ - void requestObject(O loadable); - - /** - * Signals that an object is no longer needed. - * - * @param loadable The loadable. - */ - void releaseObject(O loadable); - - /** - * Sets the base loader to use. - * - * @param loader The loader. - */ - void setLoader(CacheObjectLoader loader); -} diff --git a/android/leafless/src/main/java/com/locoslab/capi/android/leafless/IMapListener.java b/android/leafless/src/main/java/com/locoslab/capi/android/leafless/IMapListener.java deleted file mode 100644 index 525f275..0000000 --- a/android/leafless/src/main/java/com/locoslab/capi/android/leafless/IMapListener.java +++ /dev/null @@ -1,19 +0,0 @@ -package com.locoslab.capi.android.leafless; - -/** - * A base interface for event listeners. - * - * @author Marcus - * - * @param The type of event. - */ -public interface IMapListener { - - /** - * Signals an event. - * - * @param event The event. - */ - public void onEvent(E event); - -} diff --git a/android/leafless/src/main/java/com/locoslab/capi/android/leafless/IMapStateListener.java b/android/leafless/src/main/java/com/locoslab/capi/android/leafless/IMapStateListener.java deleted file mode 100644 index c4bd6fa..0000000 --- a/android/leafless/src/main/java/com/locoslab/capi/android/leafless/IMapStateListener.java +++ /dev/null @@ -1,11 +0,0 @@ -package com.locoslab.capi.android.leafless; - -/** - * An event listener interface for map events - * that signal changes to the map state. - * - * @author Marcus - */ -public interface IMapStateListener extends IMapListener { - -} diff --git a/android/leafless/src/main/java/com/locoslab/capi/android/leafless/IMoveListener.java b/android/leafless/src/main/java/com/locoslab/capi/android/leafless/IMoveListener.java deleted file mode 100644 index c73c8e4..0000000 --- a/android/leafless/src/main/java/com/locoslab/capi/android/leafless/IMoveListener.java +++ /dev/null @@ -1,10 +0,0 @@ -package com.locoslab.capi.android.leafless; - -/** - * A listener for move events. - * - * @author Marcus - */ -public interface IMoveListener extends IMapListener { - -} diff --git a/android/leafless/src/main/java/com/locoslab/capi/android/leafless/ITouchListener.java b/android/leafless/src/main/java/com/locoslab/capi/android/leafless/ITouchListener.java deleted file mode 100644 index 9c54595..0000000 --- a/android/leafless/src/main/java/com/locoslab/capi/android/leafless/ITouchListener.java +++ /dev/null @@ -1,11 +0,0 @@ -package com.locoslab.capi.android.leafless; - -/** - * A listener for touch events that signal - * short or long single finter taps. - * - * @author Marcus - */ -public interface ITouchListener extends IMapListener { - -} diff --git a/android/leafless/src/main/java/com/locoslab/capi/android/leafless/IdentifierGenerator.java b/android/leafless/src/main/java/com/locoslab/capi/android/leafless/IdentifierGenerator.java deleted file mode 100644 index b8d9514..0000000 --- a/android/leafless/src/main/java/com/locoslab/capi/android/leafless/IdentifierGenerator.java +++ /dev/null @@ -1,63 +0,0 @@ -package com.locoslab.capi.android.leafless; - -import java.util.ArrayList; -import java.util.List; - -/** - * A helper class to assign unique ids to elements. - * - * @author Marcus - */ -class IdentifierGenerator { - - /** - * The current id. - */ - private int next = 1; - - /** - * The set of used ids. - */ - private List used = new ArrayList<>(); - - /** - * The set of unused ids. - */ - private List unused = new ArrayList<>(); - - /** - * Creates a new identifier. - */ - public IdentifierGenerator() { - super(); - } - - /** - * Creates the next id. - * - * @return The next id. - */ - public int next() { - int result; - if (unused.size() > 0) { - result = unused.remove(0); - } else { - result = next; - next += 1; - } - used.add(result); - return result; - } - - /** - * Releases the specified id. - * - * @param id The id. - */ - public void release(int id) { - if (used.remove(new Integer(id))) { - unused.add(id); - } - } - -} diff --git a/android/leafless/src/main/java/com/locoslab/capi/android/leafless/InterimRotation.java b/android/leafless/src/main/java/com/locoslab/capi/android/leafless/InterimRotation.java deleted file mode 100644 index 0e9c22b..0000000 --- a/android/leafless/src/main/java/com/locoslab/capi/android/leafless/InterimRotation.java +++ /dev/null @@ -1,71 +0,0 @@ -package com.locoslab.capi.android.leafless; -/** - * A helper class to avoid repeated computations of - * sine and cosine values. - * - * @author Marcus - */ -public class InterimRotation { - - /** - * The angle in radians. - */ - public final double radians; - /** - * Sin(angle) for forward transforms. - */ - public final double sineForward; - /** - * Cos(angle) for forward transforms. - */ - public final double cosineForward; - /** - * Sin(angle) for backward transforms. - */ - public final double sineBackward; - /** - * Cos(angle) for backward transforms. - */ - public final double cosineBackward; - - /** - * Initializes the rotation for a particular - * degree. - * - * @param degree The degree of the rotation. - */ - public InterimRotation(double degree) { - this.radians = (float)Math.toRadians(degree); - this.sineForward = Math.sin(radians); - this.cosineForward = Math.cos(radians); - this.sineBackward = Math.sin(-radians); - this.cosineBackward = Math.cos(-radians); - } - - /** - * Rotates the point around the pivot point in the forward direction. - * - * @param point The point. - * @param pivot The pivot point (unchanged) - * @return The forward rotated point. - */ - public float[] rotateForward(float[] point, float[] pivot) { - double nx = pivot[0] + (point[0]-pivot[0])*cosineForward - (point[1]-pivot[1])*sineForward; - double ny = pivot[1] + (point[0]-pivot[0])*sineForward + (point[1]-pivot[1])*cosineForward; - return new float[] { (float) nx, (float)ny }; - } - - /** - * Rotates the point around the pivot point in the backward direction. - * - * @param point The point. - * @param pivot The pivot point (unchanged) - * @return The backward rotated point. - */ - public float[] rotateBackward(float[] point, float[] pivot) { - double nx = pivot[0] + (point[0]-pivot[0])*cosineBackward - (point[1]-pivot[1])*sineBackward; - double ny = pivot[1] + (point[0]-pivot[0])*sineBackward + (point[1]-pivot[1])*cosineBackward; - return new float[] { (float) nx, (float)ny }; - } - -} \ No newline at end of file diff --git a/android/leafless/src/main/java/com/locoslab/capi/android/leafless/ListenerBundle.java b/android/leafless/src/main/java/com/locoslab/capi/android/leafless/ListenerBundle.java deleted file mode 100644 index a590989..0000000 --- a/android/leafless/src/main/java/com/locoslab/capi/android/leafless/ListenerBundle.java +++ /dev/null @@ -1,55 +0,0 @@ -package com.locoslab.capi.android.leafless; - -import java.util.ArrayList; -import java.util.List; - -/** - * Implements a listener bundle for the event listener type L that - * takes events of type E. - * - * @author Marcus - * - * @param The event type. - * @param The listener type. - */ -public class ListenerBundle> implements IListenerBundle { - - /** - * The registered listeners. - */ - private List listeners = new ArrayList<>(); - - - @Override - public void addListener(L listener) { - listeners = new ArrayList<>(listeners); - listeners.add(listener); - } - - @Override - public boolean removeListener(L listener) { - listeners = new ArrayList<>(listeners); - return listeners.remove(listener); - } - - /** - * Determines whether this bundle has registered listeners. - * - * @return True if the bundle has a listener, false otherwise. - */ - public boolean hasListeners() { - return listeners.size() > 0; - } - - /** - * Sends a map event to all registered listeners. - * - * @param event The map event. - */ - public void fireEvent(E event) { - for (L listener: listeners) { - listener.onEvent(event); - } - } - -} diff --git a/android/leafless/src/main/java/com/locoslab/capi/android/leafless/MapEvent.java b/android/leafless/src/main/java/com/locoslab/capi/android/leafless/MapEvent.java deleted file mode 100644 index 398f011..0000000 --- a/android/leafless/src/main/java/com/locoslab/capi/android/leafless/MapEvent.java +++ /dev/null @@ -1,36 +0,0 @@ -package com.locoslab.capi.android.leafless; - -/** - * An event that ocurred on a map view. - * - * @author Marcus - * - */ -public class MapEvent { - - /** - * The view. - */ - protected MapView view; - - /** - * Creates a new event. - * - * @param view The view. - */ - public MapEvent(MapView view) { - this.view = view; - } - - /** - * Returns the map view that created - * the event. - * - * @return The map view. - */ - public MapView getView() { - return view; - } - - -} diff --git a/android/leafless/src/main/java/com/locoslab/capi/android/leafless/MapOptions.java b/android/leafless/src/main/java/com/locoslab/capi/android/leafless/MapOptions.java deleted file mode 100644 index 65d50bc..0000000 --- a/android/leafless/src/main/java/com/locoslab/capi/android/leafless/MapOptions.java +++ /dev/null @@ -1,96 +0,0 @@ -package com.locoslab.capi.android.leafless; - -import com.locoslab.api.data.maps.model.Box; - -import android.view.ViewConfiguration; - -/** - * The options to configure the behavior of the map. - * - * @author Marcus - */ -public class MapOptions { - - /** - * The minimum zoom level. - */ - public int minZoom = 1; - - /** - * The maximum zoom level. - */ - public int maxZoom = 20; - - /** - * The minimum scale (should be max scale / 2). - * It is possible to adapt this to zoom more in - * or out. Make sure to also adapt the max scale. - */ - public double minScale = 0.5; - - /** - * The maximum scale (should be min scale * 2). - * It is possible to adapt this to zoom more in - * or out. Make sure to also adapt the min scale. - */ - public double maxScale = 1.5; - - /** - * The bounds of the map which will be used to - * avoid scrolling the map off the screen. - */ - public Box bounds = new Box(-180, -90, 180, 90); - - /** - * The timeout for the double tap detection. - */ - public int doubleTapTimeout = ViewConfiguration.getDoubleTapTimeout(); - - /** - * Enables double tap zoom and two finger double tap zoom out. - */ - public boolean doubleTapZoom = true; - - /** - * Enables one finger drag to move. - */ - public boolean dragToMove = true; - - /** - * Enables pinch to rotate. - */ - public boolean pinchToRotate = true; - - /** - * Enables pinch to zoom. - */ - public boolean pinchToZoom = true; - - /** - * Creates the default map options. - */ - public MapOptions() { - super(); - } - - /** - * Creates options copied from the copy. - * - * @param copy The copy. - */ - public MapOptions(MapOptions copy) { - minZoom = copy.minZoom; - maxZoom = copy.maxZoom; - minScale = copy.minScale; - maxScale = copy.maxScale; - doubleTapTimeout = copy.doubleTapTimeout; - doubleTapZoom = copy.doubleTapZoom; - dragToMove = copy.dragToMove; - pinchToRotate = copy.pinchToRotate; - pinchToZoom = copy.pinchToZoom; - bounds = new Box - (copy.bounds.getMinimumLongitude(), copy.bounds.getMinimumLatitude(), - copy.bounds.getMaximumLongitude(), copy.bounds.getMaximumLatitude()); - } - -} diff --git a/android/leafless/src/main/java/com/locoslab/capi/android/leafless/MapPoint.java b/android/leafless/src/main/java/com/locoslab/capi/android/leafless/MapPoint.java deleted file mode 100644 index 2b3e482..0000000 --- a/android/leafless/src/main/java/com/locoslab/capi/android/leafless/MapPoint.java +++ /dev/null @@ -1,98 +0,0 @@ -package com.locoslab.capi.android.leafless; - -/** - * A two-dimensional point with integers that is used to represent - * a particular point on the screen as well as dimensions. - * - * @author Marcus - */ -public class MapPoint { - - /** - * The x coordinate. - */ - private int x; - - /** - * The y coordinate. - */ - private int y; - - /** - * Creates a new point with x and y - * set to 0. - */ - public MapPoint() { - super(); - } - - /** - * Creates a new point with a given - * x and y coordinate. - * - * @param x The x coordinate. - * @param y The y coordinate. - */ - public MapPoint(int x, int y) { - this.x = x; - this.y = y; - } - - /** - * Returns the x coordinate or the - * width, if used as dimension. - * - * @return The x coordinate. - */ - public int getX() { - return x; - } - - /** - * Returns the y coordinate or the - * height, if used as dimension. - * - * @return The y coordinate. - */ - public int getY() { - return y; - } - - /** - * Sets the x coordinate. - * - * @param x The x coordinate. - */ - public void setX(int x) { - this.x = x; - } - - /** - * Sets the y coordiante. - * - * @param y The y coordinate. - */ - public void setY(int y) { - this.y = y; - } - - @Override - public String toString() { - return "x: " + x + " y: " + y; - } - - @Override - public int hashCode() { - return x * 13 + y; - } - - @Override - public boolean equals(Object obj) { - if (obj.getClass() == getClass()) { - MapPoint p = (MapPoint)obj; - return p.x == x && p.y == y; - } - return false; - } - -} diff --git a/android/leafless/src/main/java/com/locoslab/capi/android/leafless/MapProjection.java b/android/leafless/src/main/java/com/locoslab/capi/android/leafless/MapProjection.java deleted file mode 100644 index 923f762..0000000 --- a/android/leafless/src/main/java/com/locoslab/capi/android/leafless/MapProjection.java +++ /dev/null @@ -1,82 +0,0 @@ -package com.locoslab.capi.android.leafless; - -/** - * An implementation of the spherical mercator projection. - * - * @author Marcus - */ -public class MapProjection { - - /** - * The radius of the earth. - */ - public static int RADIUS = 6378137; - /** - * The maximum latitude. - */ - public static double MAX_LAT = 85.0511287798; - - /** - * Converts the latitude and logitude to a value between -/+ PI * RADIUS - * - * @param longitude The longitude. - * @param latitude The latitude. - * @return The point value. - */ - private double[] projectRaw(double longitude, double latitude) { - double d = Math.PI / 180; - double lat = Math.max(Math.min(MAX_LAT, latitude), -MAX_LAT); - double sin = Math.sin(lat * d); - double[] res = new double[] { - RADIUS * longitude * d, - RADIUS * Math.log((1 + sin) / (1 - sin)) / 2 - }; - return res; - } - - /** - * Converts a point value between -/+ PI * RADIUS to longitude and latitude. - * - * @param x The x value. - * @param y The y value. - * @return The longitude, latitude pair. - */ - private double[] unprojectRaw(double x, double y) { - double d = 180 / Math.PI; - double[] res = new double[] { - x * d / RADIUS, - (2 * Math.atan(Math.exp(y / RADIUS)) - (Math.PI / 2)) * d - - }; - return res; - } - - /** - * Converts a coordinate to a point value between 0 and 1. - * - * @param longitude The longitude. - * @param latitude The latitude. - * @return The point value. - */ - public double[] project(double longitude, double latitude) { - double[] v = projectRaw(longitude, latitude); - double f = 0.5 / (Math.PI * RADIUS); - v[0] = v[0] * f + 0.5; - v[1] = 1 - (v[1] * f + 0.5); - return v; - } - - /** - * Converts a point value between 0 and 1 to longitude and latitude. - * - * @param x The x point value. - * @param y The y point value. - * @return The longitude, latitude pair. - */ - public double[] unproject(double x, double y) { - double f = 0.5 / (Math.PI * RADIUS); - double[] v = unprojectRaw((x - 0.5) / f, -(y - 0.5) / f); - return v; - } - -} \ No newline at end of file diff --git a/android/leafless/src/main/java/com/locoslab/capi/android/leafless/MapStateEvent.java b/android/leafless/src/main/java/com/locoslab/capi/android/leafless/MapStateEvent.java deleted file mode 100644 index 6fb2b6d..0000000 --- a/android/leafless/src/main/java/com/locoslab/capi/android/leafless/MapStateEvent.java +++ /dev/null @@ -1,95 +0,0 @@ -package com.locoslab.capi.android.leafless; - -/** - * An event to signal changes to the map view. - * - * @author Marcus - */ -public class MapStateEvent extends MapEvent { - - /** - * The type of change that occured. - * - * @author Marcus - */ - public static enum Type { - /** - * The scale has changed. - */ - SCALE, - /** - * The zoom level has changed. - */ - ZOOM, - /** - * The center has changed. - */ - CENTER, - /** - * The rotation angle has changed. - */ - ANGLE, - /** - * The width or height has changed. - */ - SIZE - } - - /** - * The type. - */ - private Type type; - - /** - * The previous state. - */ - private MapViewState previous; - - /** - * The current state. - */ - private MapViewState current; - - /** - * Creates a new event. - * - * @param view The view. - * @param type The type. - * @param previous The previous state. - * @param current The current state. - */ - public MapStateEvent(MapView view, Type type, MapViewState previous, MapViewState current) { - super(view); - this.type = type; - this.current = current; - this.previous = previous; - } - - /** - * Returns the type of change. - * - * @return The type of change. - */ - public Type getType() { - return type; - } - - /** - * Gets the current state (after the change). - * - * @return The current state. - */ - public MapViewState getCurrent() { - return current; - } - - /** - * Gets the previous state (before the change) - * - * @return The previous state. - */ - public MapViewState getPrevious() { - return previous; - } - -} diff --git a/android/leafless/src/main/java/com/locoslab/capi/android/leafless/MapView.java b/android/leafless/src/main/java/com/locoslab/capi/android/leafless/MapView.java deleted file mode 100644 index 915aa58..0000000 --- a/android/leafless/src/main/java/com/locoslab/capi/android/leafless/MapView.java +++ /dev/null @@ -1,944 +0,0 @@ -package com.locoslab.capi.android.leafless; - -import java.util.ArrayList; -import java.util.Collections; -import java.util.Comparator; -import java.util.List; - -import android.annotation.TargetApi; -import com.locoslab.api.data.maps.model.Box; -import com.locoslab.api.data.maps.model.Coordinate; -import com.locoslab.capi.android.leafless.MapStateEvent.Type; -import com.locoslab.capi.android.leafless.cache.CacheObjectLoader; -import com.locoslab.capi.android.leafless.circle.Circle; -import com.locoslab.capi.android.leafless.circle.CircleOptions; -import com.locoslab.capi.android.leafless.control.AbstractControl; -import com.locoslab.capi.android.leafless.control.CompassControl; -import com.locoslab.capi.android.leafless.control.CompassControlOptions; -import com.locoslab.capi.android.leafless.geojson.GeojsonLoader; -import com.locoslab.capi.android.leafless.icon.Icon; -import com.locoslab.capi.android.leafless.icon.IconImage; -import com.locoslab.capi.android.leafless.icon.IconOptions; -import com.locoslab.capi.android.leafless.image.ImageLoader; -import com.locoslab.capi.android.leafless.layer.AbstractLayer; -import com.locoslab.capi.android.leafless.marker.Marker; -import com.locoslab.capi.android.leafless.marker.MarkerOptions; -import com.locoslab.capi.android.leafless.marker.RotatedMarker; -import com.locoslab.capi.android.leafless.marker.RotatedMarkerOptions; -import com.locoslab.capi.android.leafless.polyline.Polyline; -import com.locoslab.capi.android.leafless.polyline.PolylineOptions; -import com.locoslab.capi.android.leafless.tile.TileLayer; -import com.locoslab.capi.android.leafless.tile.TileLayerOptions; -import com.locoslab.capi.android.leafless.touch.DoubleTapRecognizer; -import com.locoslab.capi.android.leafless.touch.IDoubleTapView; -import com.locoslab.capi.android.leafless.touch.IMovableTarget; -import com.locoslab.capi.android.leafless.vector.VectorLayer; -import com.locoslab.capi.android.leafless.vector.VectorLayerOptions; - -import android.content.Context; -import android.graphics.Canvas; -import android.util.AttributeSet; -import android.view.HapticFeedbackConstants; -import android.view.MotionEvent; -import android.view.SoundEffectConstants; -import android.view.View; -import android.view.accessibility.AccessibilityEvent; - -/** - * A view that displays a map. This map view only relies on the standard Android - * SDK. However, it does not support accessibility. If this is required, use the - * AccessibleMapView instead but note that the accessible map view has a dependency - * on the support library. - * - * @author Marcus - */ -@TargetApi(4) -public class MapView extends View implements IDoubleTapView, IMovableTarget { - - /** - * The short tap listeners. - */ - protected ListenerBundle shortTapListeners = new ListenerBundle<>(); - - /** - * The long tap listeners. - */ - protected ListenerBundle longTapListeners = new ListenerBundle<>(); - - /** - * The map listeners. - */ - protected ListenerBundle mapStateListeners = new ListenerBundle<>(); - - /** - * The state of the map view. - */ - protected MapViewState state = new MapViewState(); - - /** - * The map image loader that is used to load - * everything. - */ - protected CacheObjectLoader objectLoader; - - /** - * The image loader that we use to load icons. - */ - protected ImageLoader imageLoader = new ImageLoader(); - - /** - * The tile layers on the map. - */ - protected List> layers = new ArrayList<>(); - - /** - * The markers on the map. - */ - protected List markers = new ArrayList<>(); - - /** - * The shapes to draw onto the map. - */ - protected List> shapes = new ArrayList<>(); - - /** - * The list of controls that we render. - */ - protected List> controls = new ArrayList<>(); - - /** - * The touch recognizer that is used to emit events. - */ - protected DoubleTapRecognizer recognizer = new DoubleTapRecognizer(this); - - /** - * The map options. - */ - protected MapOptions options = new MapOptions(); - - /** - * Deferred operations that can only be executed when the view - * is visible and knows its size. - */ - protected List requests = new ArrayList<>(); - - /** - * The identifier generator used to assign unique ids to elements. - */ - protected IdentifierGenerator generator = new IdentifierGenerator(); - - /** - * Creates a new view with the context. - * - * @param context The context. - */ - public MapView(Context context) { - super(context); - init(context); - } - - /** - * Creates a new view with the context and attributes. - * - * @param context The context. - * @param attrs The attributes. - */ - public MapView(Context context, AttributeSet attrs) { - super(context, attrs); - init(context); - } - - /** - * Initializes the internal data structures. - * - * @param context The context. - */ - private void init(Context context) { - state.setDensity(context.getResources().getDisplayMetrics().density); - } - - - /** - * Returns the map listener bundle. - * - * @return The map listener bundle. - */ - protected IListenerBundle getMapStateListeners() { - return mapStateListeners; - } - - /** - * Returns the short tap listener bundle. - * - * @return The short tap listener bundle. - */ - protected IListenerBundle getShortTapListeners() { - return shortTapListeners; - } - - /** - * Returns the long tap listener bundle. - * - * @return The long tap listener bundle. - */ - protected IListenerBundle getLongTapListeners() { - return longTapListeners; - } - - /** - * Adds a listener to receive map state events. - * - * @param listener The listener to add. - */ - public void addMapStateListener(IMapStateListener listener) { - getMapStateListeners().addListener(listener); - } - - /** - * Removes a previously registered listener for map state events. - * - * @param listener The listener to remove. - */ - public void removeMapStateListener(IMapStateListener listener) { - getMapStateListeners().removeListener(listener); - } - - /** - * Adds a touch listener for short tap events. - * - * @param listener The listener to add. - */ - public void addShortTapListener(ITouchListener listener) { - getShortTapListeners().addListener(listener); - } - - /** - * Removes a previously added short tap listener. - * - * @param listener The listener to remove. - */ - public void removeShortTapListener(ITouchListener listener) { - getShortTapListeners().removeListener(listener); - } - - /** - * Adds a touch listener for long tap events. - * - * @param listener The listener to add. - */ - public void addLongTapListener(ITouchListener listener) { - getLongTapListeners().addListener(listener); - } - - /** - * Removes a listener for long tap events. - * - * @param listener The listener to remove. - */ - public void removeLongTapListener(ITouchListener listener) { - getLongTapListeners().removeListener(listener); - } - - /** - * Returns the view state. - * - * @return The view state. - */ - MapViewState getState() { - return state; - } - - /** - * Sets the map options. - * - * @param options The options. - */ - public void setMapOptions(MapOptions options) { - this.options = new MapOptions(options); - // ensure that we are in the limits - setScale(state.getScale()); - setZoom(state.getZoom()); - Coordinate c = state.getCenter(); - setCenter(c.getLongitude(), c.getLatitude()); - // configure gesture recognition - if (options.doubleTapZoom) { - // configure the gesture recognizer based on the options - recognizer.setTimeout(options.doubleTapTimeout); - } else { - // disable detection of double taps to ensure fast response - recognizer.setTimeout(0); - } - - } - - /** - * Returns a copy of the current map options. - * - * @return The map options. - */ - public MapOptions getMapOptions() { - return new MapOptions(this.options); - } - - /** - * Adds the layer on top of the map. - * - * @param layer The layer. - */ - public void addLayer(AbstractLayer layer) { - if (! layers.contains(layer)) { - layer.setLoader(objectLoader); - onAddElement(layer); - layers.add(layer); - invalidate(); - } - } - - /** - * Removes the layer. - * - * @param layer layer. - */ - public void removeLayer(AbstractLayer layer) { - if (layers.remove(layer)) { - onRemoveElement(layer); - layer.setLoader(null); - } - invalidate(); - } - - /** - * Adds a marker. - * - * @param marker The marker to add. - */ - public void addMarker(Marker marker) { - if (!markers.contains(marker)) { - markers.add(marker); - onAddElement(marker); - invalidate(); - } - } - - /** - * Removes a marker. - * - * @param marker The marker to remove. - */ - public void removeMarker(Marker marker) { - if (markers.remove(marker)) { - onRemoveElement(marker); - invalidate(); - } - } - - /** - * Adds a control. - * - * @param control The control. - */ - public void addControl(AbstractControl control) { - if (! controls.contains(control)) { - controls.add(control); - onAddElement(control); - invalidate(); - } - } - - /** - * Removes a control. - * - * @param control The control. - */ - public void removeControl(AbstractControl control) { - if (controls.remove(control)) { - onRemoveElement(control); - invalidate(); - } - } - - - - - /** - * Adds a simple shape such as a polyline or - * a circle. - * - * @param shape The shape to add. - */ - public void addShape(AbstractElement shape) { - if (! shapes.contains(shape)) { - onAddElement(shape); - shapes.add(shape); - } - invalidate(); - } - - /** - * Removes a simple shape such as a polyline - * or a circle. - * - * @param shape The shape to remove. - */ - public void removeShape(AbstractElement shape) { - if (shapes.remove(shape)) { - onRemoveElement(shape); - } - invalidate(); - } - - /** - * Centers the map on the latitude and longitude. - * - * @param longitude The longitude. - * @param latitude The latitude. - */ - public void setCenter(double longitude, double latitude) { - setCenter(longitude, latitude, false); - } - - /** - * Returns the center of the map. - * - * @return The center of the map. - */ - public Coordinate getCenter() { - return state.getCenter(); - } - - /** - * Sets the zoom level. - * - * @param zoom The zoom level. - */ - public void setZoom(int zoom) { - state.setZoom(Math.min(options.maxZoom, Math.max(options.minZoom, zoom))); - invalidate(); - } - - /** - * Returns the current zoom level. - * - * @return The zoom level. - */ - public int getZoom() { - return state.getZoom(); - } - - /** - * Sets the scale factor. - * - * @param scale The scale factor. - */ - public void setScale(double scale) { - state.setScale(Math.min(options.maxScale, Math.max(options.minScale, scale))); - invalidate(); - } - - /** - * Returns the current scale factor. - * - * @return The current scale factor. - */ - public double getScale() { - return state.getScale(); - } - - /** - * Sets the current rotation angle. - * - * @param angle The angle. - */ - public void setAngle(double angle) { - state.setAngle(angle); - invalidate(); - } - - /** - * Returns the current angle. - * - * @return The rotation angle. - */ - public double getAngle() { - return state.getAngle(); - } - - /** - * Computes the zoom level such that the box is in the view port, if this is possible - * with the current map settings. Note that this method will adjust the angle to 0 - * and scale to (minScale + maxScale) / 2. Also note that this method might be executed - * deferred, if the view is not visible or has not been drawn yet. - * - * @param bounds The bounds. - * @param paddingTopLeft The padding top left. - * @param paddingBottomRight The padding bottom right. - */ - public void setViewport(final Box bounds, final MapPoint paddingTopLeft, final MapPoint paddingBottomRight) { - if (getVisibility() != View.VISIBLE ||state.getPixelWidth() == 0 || state.getPixelHeight() == 0) { - requests.add(new Runnable() { - @Override - public void run() { - updateViewport(bounds, paddingTopLeft, paddingBottomRight, true); - } - }); - } else { - updateViewport(bounds, paddingTopLeft, paddingBottomRight, false); - } - } - - /** - * Unconditionally updates the viewport without deferring it. This should only be called, - * if the view has been drawn already and is currently visible. - * - * @param bounds The bounds. - * @param paddingTopLeft The top left padding. - * @param paddingBottomRight The bottom right padding. - */ - public void updateViewport(Box bounds, MapPoint paddingTopLeft, MapPoint paddingBottomRight) { - updateViewport(bounds, paddingTopLeft, paddingBottomRight, false); - } - - /** - * Unconditionally updates the viewport without deferring it. - * - * @param bounds The bounds. - * @param paddingTopLeft The top left padding. - * @param paddingBottomRight The bottom right padding. - * @param fireEvent Fires the change events. - */ - private void updateViewport(Box bounds, MapPoint paddingTopLeft, MapPoint paddingBottomRight, boolean fireEvent) { - MapViewState prev = new MapViewState(state); - if (getAngle() != 0) { - setAngle(0); - if (fireEvent) mapStateListeners.fireEvent(new MapStateEvent(this, Type.ANGLE, prev, state)); - prev = new MapViewState(); - } - setScale((options.minScale + options.maxScale) / 2); - if (fireEvent) mapStateListeners.fireEvent(new MapStateEvent(this, Type.SCALE, prev, state)); - setCenter(bounds.getMinimumLongitude() + (bounds.getMaximumLongitude() - bounds.getMinimumLongitude()) / 2, - bounds.getMinimumLatitude() + (bounds.getMaximumLatitude() - bounds.getMinimumLatitude()) / 2, fireEvent); - state.setPixelDimension(getWidth(), getHeight()); - int x1 = 0 + paddingTopLeft.getX(); - int y1 = 0 + paddingTopLeft.getY(); - int x2 = getWidth() - paddingBottomRight.getX(); - int y2 = getHeight() - paddingBottomRight.getY(); - prev = new MapViewState(); - for (int i = options.maxZoom; i >= options.minZoom; i--) { - setZoom(i); - double[] mins = state.pixelToCoordinate(x1, y2); // bottom left - double[] maxs = state.pixelToCoordinate(x2, y1); // top right - Box vp = new Box(mins[0], mins[1], maxs[0], maxs[1]); - if (vp.contains(bounds)) { - break; - } - } - if (fireEvent) mapStateListeners.fireEvent(new MapStateEvent(this, Type.ZOOM, prev, state)); - prev = new MapViewState(); - } - - /** - * Computes the zoom level such that the box is in the viewport, if this is possible - * with the current map settings. Note that this method will adjust the angle to 0 - * and scale to (minScale + maxScale) / 2. Also note that this method might be executed - * deferred, if the view is not visible or has not been drawn yet. - * - * @param bounds The bounds. - * @param padding The padding. - */ - public void setViewport(Box bounds, MapPoint padding) { - setViewport(bounds, padding, padding); - } - - - /** - * Sets the center and optionally fires an event. - * - * @param longitude The longitude. - * @param latitude The latitude. - * @param fireEvent True to fire and event, false otherwise. - */ - private void setCenter(double longitude, double latitude, boolean fireEvent) { - MapViewState prev = fireEvent?new MapViewState(state):null; - Coordinate c = new Coordinate(); - c.setLongitude(Math.min(options.bounds.getMaximumLongitude(), Math.max(options.bounds.getMinimumLongitude(), longitude))); - c.setLatitude(Math.min(options.bounds.getMaximumLatitude(), Math.max(options.bounds.getMinimumLatitude(), latitude))); - state.setCenter(c); - if (prev != null) { - mapStateListeners.fireEvent(new MapStateEvent(this, Type.CENTER, prev, state)); - } - invalidate(); - } - - - /** - * Handles the addition of a new element to the map. - * - * @param element The element that will be added. - */ - protected void onAddElement(AbstractElement element) { - element.setMap(this); - element.setId(generator.next()); - } - - /** - * Handles the removal of a previously added element - * from the map. - * - * @param element The element that has been removed. - */ - protected void onRemoveElement(AbstractElement element) { - element.setMap(null); - generator.release(element.getId()); - element.setId(0); - } - - /** - * Called when an element changes. - * - * @param element The element that has changed. - */ - protected void onChangeElement(AbstractElement element) { - invalidate(); - } - - /** - * Finds a particular element that declares to contain the point and - * that matches the filter. - * - * @param x The x. - * @param y The y. - * @param filter The filter. - * @return The element that matches or null. - */ - protected AbstractElement findElement(int x, int y, ElementFilter filter) { - List>> elements = new ArrayList<>(); - elements.add(layers); - elements.add(shapes); - elements.add(markers); - elements.add(controls); - for (List> next: elements) { - for (int i = next.size() - 1; i >= 0; i--) { - AbstractElement element = next.get(i); - if (filter.acceptElement(element) && element.contains(x, y)) { - return element; - } - } - } - return null; - } - - /** - * Finds all elements that intersect a particular box. - * - * @param box The box defining the bounds. - * @param filter The filter. - * @return The list of matching elements within the bounds. - */ - protected List> findElements(Box box, ElementFilter filter) { - List> result = new ArrayList<>(); - List>> elements = new ArrayList<>(); - elements.add(layers); - elements.add(shapes); - elements.add(markers); - elements.add(controls); - for (List> next: elements) { - for (int i = next.size() - 1; i >= 0; i--) { - AbstractElement element = next.get(i); - if (filter.acceptElement(element) && box.intersects(element.getBounds())) { - result.add(element); - } - } - } - return result; - } - - /** - * Returns the element with the specified id or null, if the element is not contained. - * - * @param id The id of the element. - * @return The element or null. - */ - protected AbstractElement findElement(int id) { - List>> elements = new ArrayList<>(); - elements.add(layers); - elements.add(shapes); - elements.add(markers); - elements.add(controls); - for (List> next: elements) { - for (int i = next.size() - 1; i >= 0; i--) { - AbstractElement element = next.get(i); - if (element.getId() == id) { - return element; - } - } - } - return null; - } - - - /** - * Computes the drawing order of the markers based on their - * zindex and latitude. - */ - protected void sortMarkers() { - Collections.sort(markers, new Comparator() { - @Override - public int compare(Marker o1, Marker o2) { - if (o1.getZIndexOffset() < o2.getZIndexOffset()) { - return -1; - } else if (o1.getZIndexOffset() > o2.getZIndexOffset()) { - return 1; - } else { - // inverse: make top markers (higher latitude) appear first (drawn earlier) - return Double.compare(o2.getCoordinate().getLatitude(), o1.getCoordinate().getLatitude()); - } - } - }); - } - - @Override - protected void onDraw(Canvas canvas) { - int w = getWidth(); - int h = getHeight(); - if (state.getPixelWidth() != w || state.getPixelHeight() != h) { - MapViewState prev = new MapViewState(state); - state.setPixelDimension(getWidth(), getHeight()); - mapStateListeners.fireEvent(new MapStateEvent(this, Type.SIZE, prev, state)); - } - while (requests.size() > 0) { - Runnable r = requests.remove(0); - r.run(); - } - super.onDraw(canvas); - Box viewport = state.getViewport(); - for (AbstractLayer layer: layers) { - if (viewport.intersects(layer.getBounds())) { - layer.drawObject(canvas); - } - } - sortMarkers(); - for (Marker marker: markers) { - if (viewport.intersects(marker.getBounds())) { - IconImage image = marker.getIcon().getShadowImage(); - if (image != null && image.getBitmap() == null) { - imageLoader.requestObject(image); - } - marker.drawShadow(canvas); - } - } - for (AbstractControl control: controls) { - for (Icon icon: control.getIcons()) { - IconImage image = icon.getShadowImage(); - if (image != null && image.getBitmap() == null) { - imageLoader.requestObject(image); - } - } - control.drawShadow(canvas); - } - for (AbstractElement shape: shapes) { - if (viewport.intersects(shape.getBounds())) { - shape.drawObject(canvas); - } - } - for (Marker marker: markers) { - if (viewport.intersects(marker.getBounds())) { - IconImage image = marker.getIcon().getIconImage(); - if (image != null && image.getBitmap() == null) { - imageLoader.requestObject(image); - } - marker.drawObject(canvas); - } - } - for (AbstractControl control: controls) { - for (Icon icon: control.getIcons()) { - IconImage image = icon.getIconImage(); - if (image != null && image.getBitmap() == null) { - imageLoader.requestObject(image); - } - } - control.drawObject(canvas); - } - } - - @Override - public boolean onTouchEvent(MotionEvent event) { - return recognizer.onEvent(event); - } - - @Override - public void moveBy(int x, int y) { - if (!options.dragToMove) return; - double[] c = state.pixelToCoordinate(state.getPixelCenterX() - x,state.getPixelCenterY() - y); - c[0] = Math.max(options.bounds.getMinimumLongitude(), Math.min(options.bounds.getMaximumLongitude(), c[0])); - c[1] = Math.max(options.bounds.getMinimumLatitude(), Math.min(options.bounds.getMaximumLatitude(), c[1])); - MapViewState prev = new MapViewState(state); - Coordinate nc = new Coordinate(); - nc.setLatitude(c[1]); - nc.setLongitude(c[0]); - state.setCenter(nc); - mapStateListeners.fireEvent(new MapStateEvent(this, Type.CENTER, prev, state)); - invalidate(); - } - - @Override - public void rotateBy(double angle) { - if (!options.pinchToRotate) return; - MapViewState prev = new MapViewState(state); - state.setAngle(state.getAngle() + angle); - mapStateListeners.fireEvent(new MapStateEvent(this, Type.ANGLE, prev, state)); - invalidate(); - } - - - @Override - public IMovableTarget getMovable(int x, int y) { - AbstractElement element = findElement(x, y, ElementFilter.MOVEABLE); - if (element != null) { - return element; - } else { - if (options.dragToMove) { - return this; - } else { - return null; - } - } - } - - @Override - public void scaleBy(double scale) { - if (!options.pinchToZoom) return; - MapViewState prev = new MapViewState(state); - boolean zoomChanged = false; - double newScale = state.getScale() + scale; - if (scale >= 0) { - newScale = state.getScale() + scale; - while (newScale > options.maxScale && state.getZoom() < options.maxZoom) { - state.setZoom(state.getZoom() + 1); - zoomChanged = true; - newScale = newScale / 2; - } - } else { - double factor = state.getScale(); - while (newScale < options.minScale && state.getZoom() > options.minZoom) { - state.setZoom(state.getZoom() - 1); - zoomChanged = true; - factor = factor * 2; - newScale = factor + scale; - } - } - if (zoomChanged) { - mapStateListeners.fireEvent(new MapStateEvent(this, Type.ZOOM, prev, state)); - prev = new MapViewState(state); - } - newScale = Math.min(options.maxScale, Math.max(options.minScale, newScale)); - state.setScale(newScale); - mapStateListeners.fireEvent(new MapStateEvent(this, Type.SCALE, prev, state)); - invalidate(); - } - - @Override - public void longTap(int x, int y) { - AbstractElement element = findElement(x, y, ElementFilter.LONG_TAPABLE); - boolean responded = false; - if (element != null) { - element.longTap(x, y); - responded = true; - } else if (longTapListeners.hasListeners()) { - longTapListeners.fireEvent(createTouchEvent(x, y)); - responded = true; - } - if (responded) { - performHapticFeedback(HapticFeedbackConstants.LONG_PRESS); - sendAccessibilityEvent(AccessibilityEvent.TYPE_VIEW_LONG_CLICKED); - } - } - - @Override - public void shortTap(int x, int y) { - AbstractElement element = findElement(x, y, ElementFilter.SHORT_TAPABLE); - boolean responded = false; - if (element != null) { - element.shortTap(x, y); - responded = true; - } else if (shortTapListeners.hasListeners()) { - shortTapListeners.fireEvent(createTouchEvent(x, y)); - responded = true; - } - if (responded) { - playSoundEffect(SoundEffectConstants.CLICK); - sendAccessibilityEvent(AccessibilityEvent.TYPE_VIEW_CLICKED); - } - } - - @Override - public void shortTwoTap(int x1, int y1, int x2, int y2) { - // not needed - } - - @Override - public void longTwoTap(int x1, int y1, int x2, int y2) { - // not needed - } - - @Override - public void doubleTap(int x, int y) { - if (options.doubleTapZoom && options.maxZoom > state.getZoom()) { - double[] lnglat = state.pixelToCoordinate(x, y); - MapViewState prev = new MapViewState(state); - state.setZoom(state.getZoom() + 1); - mapStateListeners.fireEvent(new MapStateEvent(this, Type.ZOOM, prev, state)); - setCenter(lnglat[0], lnglat[1], true); - } - } - - @Override - public void doubleTwoTap(int x1, int y1, int x2, int y2) { - if (options.doubleTapZoom && options.minZoom < state.getZoom()) { - MapViewState prev = new MapViewState(state); - state.setZoom(state.getZoom() - 1); - invalidate(); - mapStateListeners.fireEvent(new MapStateEvent(this, Type.ZOOM, prev, state)); - } - } - - /** - * Creates a touch event. - * - * @param x The x coordinate. - * @param y The y coordinate. - * @return The touch event. - */ - protected TouchEvent createTouchEvent(int x, int y) { - MapPoint p = new MapPoint(x, y); - Coordinate c = new Coordinate(); - double[] lnglat = state.pixelToCoordinate(x, y); - c.setLatitude(lnglat[1]); - c.setLongitude(lnglat[0]); - return new TouchEvent(this, p, c); - } - - - @Override - protected void onAttachedToWindow() { - super.onAttachedToWindow(); - objectLoader = new CacheObjectLoader(this, 5); - imageLoader.setLoader(objectLoader); - for (AbstractLayer layer: layers) { - layer.setLoader(objectLoader); - } - } - - @Override - protected void onDetachedFromWindow() { - super.onDetachedFromWindow(); - imageLoader.setLoader(null); - for (AbstractLayer layer: layers) { - layer.setLoader(null); - } - if (objectLoader != null) { - objectLoader.shutdown(); - objectLoader = null; - } - } - -} diff --git a/android/leafless/src/main/java/com/locoslab/capi/android/leafless/MapViewState.java b/android/leafless/src/main/java/com/locoslab/capi/android/leafless/MapViewState.java deleted file mode 100644 index 4d431e9..0000000 --- a/android/leafless/src/main/java/com/locoslab/capi/android/leafless/MapViewState.java +++ /dev/null @@ -1,433 +0,0 @@ -package com.locoslab.capi.android.leafless; - -import com.locoslab.api.data.maps.model.Box; -import com.locoslab.api.data.maps.model.Coordinate; - -/** - * The state of the map view that is required to draw it. - * - * @author Marcus - */ -public class MapViewState { - - /** - * The projection for the map. - */ - private MapProjection projection = new MapProjection(); - - /** - * The current zoom level of the map. - */ - private int zoom = 0; - - /** - * The rotation angle of the map in degrees. - */ - private double angle = 0; - - /** - * The cached rotation value for the angle. - */ - private InterimRotation rotation; - - /** - * The current scale of the map. - */ - private double scale = 1; - - /** - * The current center of the map. - */ - private Coordinate center = new Coordinate(); - - /** - * The width of the map view in pixels. - */ - private int pixelWidth; - - /** - * The computed center in x. - */ - private int pixelCenterX; - - /** - * The height of the map view in pixels. - */ - private int pixelHeight; - - /** - * The computed center in y. - */ - private int pixelCenterY; - - /** - * The relative center point of the map. This enables - * shifting the rotational pivot point and the point - * at which the center coordinate is located. Setting - * 0.5 will set the center coordinate at the center - * pixel of the view. Setting 0 will set the center - * coordinate to the left border. - */ - private float centerX = 0.5f; - - /** - * The relative center point of the map. This enables - * shifting the rotational pivot point and the point - * at which the center coordinate is located. Setting - * 0.5 will set the center coordinate at the center - * pixel of the view. Setting 0 will set the center - * coordinate to the top border. - */ - private float centerY = 0.5f; - - /** - * A bounding box for the current viewport. - */ - private Box viewport; - - /** - * The display density. This is used to draw layers - * and to correct elements such as markers and tiles. - * The range and meaning is defined in DisplayMetrics - * in Android. - */ - private float density = 1; - - /** - * Creates a new map view state. - */ - public MapViewState() { - center.setLatitude(49); - center.setLongitude(6); - zoom = 7; - } - - /** - * Creates a copy of the state. - * - * @param state The state. - */ - public MapViewState(MapViewState state) { - this.angle = state.angle; - this.center.setLatitude(state.center.getLatitude()); - this.center.setLongitude(state.center.getLongitude()); - this.pixelHeight = state.pixelHeight; - this.pixelWidth = state.pixelWidth; - this.projection = state.projection; - this.rotation = state.rotation; - this.scale = state.scale; - this.viewport = state.viewport; - this.zoom = state.zoom; - this.centerX = state.centerX; - this.centerY = state.centerY; - } - - /** - * Returns the current zoom level. - * - * @return the zoom The zoom level. - */ - public int getZoom() { - return zoom; - } - - /** - * Sets the zoom to a particular level. - * - * @param zoom The zoom to set. - */ - protected void setZoom(int zoom) { - this.zoom = zoom; - this.viewport = null; - } - - /** - * Returns the rotation angle in degrees. - * - * @return The angle - */ - public double getAngle() { - return angle; - } - - /** - * Sets the rotation angle in degrees. - * - * @param angle The angle to set. - */ - protected void setAngle(double angle) { - while (angle < 0) { - angle += 360; - } - while (angle > 360) { - angle -= 360; - } - this.angle = angle; - this.rotation = null; - this.viewport = null; - } - - /** - * Returns the scale. - * - * @return The scale - */ - public double getScale() { - return scale; - } - - /** - * Sets the scale. - * - * @param scale the scale to set. - */ - protected void setScale(double scale) { - this.scale = scale; - this.viewport = null; - } - - /** - * Returns the center of the map. - * - * @return The center. - */ - public Coordinate getCenter() { - Coordinate c = new Coordinate(); - c.setLatitude(center.getLatitude()); - c.setLongitude(center.getLongitude()); - return c; - } - - /** - * Sets the center of the map. - * - * @param center the center to set. - */ - protected void setCenter(Coordinate center) { - this.center = center; - this.viewport = null; - } - - /** - * Returns the pixel width of the view. - * - * @return The pixelWidth of the view. - */ - public int getPixelWidth() { - return pixelWidth; - } - - /** - * Returns the pixel to which the center coordinate - * will be mapped. - * - * @return The x coordinate of the center. - */ - public int getPixelCenterX() { - return pixelCenterX; - } - - /** - * Returns the pixel to which the ccenter coordinate - * will be mapped. - * - * @return The y coordinate of the center. - */ - public int getPixelCenterY() { - return pixelCenterY; - } - - /** - * Sets the relative location of the center point with - * respect to x. This value is interpreted relative. - * Setting 0.5 will center the view. Setting 0 will - * move the center to the left. - * - * @param centerX The relative x center. - */ - public void setCenterX(float centerX) { - this.centerX = centerX; - this.pixelCenterX = (int)(centerX * pixelWidth); - } - - /** - * Returns the relative location of the center point - * with respect to x. - * - * @return The relative x center. - */ - public float getCenterX() { - return centerX; - } - - /** - * Sets the relative location of the center point with - * respect to y. This value is interpreted relative. - * Setting 0.5 will center the view. Setting 0 will - * move the center to the top. - * - * @param centerY The relative y center. - */ - public void setCenterY(float centerY) { - this.centerY = centerY; - this.pixelCenterY = (int)(centerY * pixelHeight); - } - - /** - * Returns the relative location of the center point - * with respect to y. - * - * @return The relative y center. - */ - public float getCenterY() { - return centerY; - } - - /** - * Returns the pixel height of the view. - * - * @return The pixel height of the view. - */ - public int getPixelHeight() { - return pixelHeight; - } - - /** - * Sets the view dimension in pixels. - * - * @param width The width in pixels. - * @param height The height in pixels. - */ - protected void setPixelDimension(int width, int height) { - this.pixelHeight = height; - this.pixelWidth = width; - this.pixelCenterX = (int)(width* centerX); - this.pixelCenterY = (int)(height * centerY); - this.viewport = null; - } - - /** - * Returns the rotation values or computes them. - * - * @return The precomputated rotation values. - */ - public InterimRotation getRotation() { - if (rotation == null) { - rotation = new InterimRotation(angle); - } - return rotation; - } - - /** - * Returns the map projection. - * - * @return The map projection. - */ - public MapProjection getProjection() { - return projection; - } - - /** - * Sets the display density. - * - * @param density The display density. - */ - public void setDensity(float density) { - this.density = density; - } - - /** - * Returns the display density. - * - * @return The display density. - */ - public float getDensity() { - return density; - } - - /** - * Converts a pixel to a wgs84 coordinate. - * - * @param x The x of the pixel. - * @param y The y of the pixel. - * @return The longitude, latitude of the coordinate. - */ - public double[] pixelToCoordinate(float x, float y) { - double cx = pixelCenterX; - double cy = pixelCenterY; - // scale the pixel - double sx = cx + ((x - cx) / scale); - double sy = cy + ((y - cy) / scale); - InterimRotation r = getRotation(); - double nx = cx + (sx-cx)*r.cosineBackward - (sy-cy)*r.sineBackward; - double ny = cy + (sx-cx)*r.sineBackward + (sy-cy)*r.cosineBackward; - double dx = nx - cx; // delta x - double dy = ny - cy; // delta y - // get the latitude - double numberOfPixels = 256 * density * (1 << zoom); - double[] center = projection.project(this.center.getLongitude(), this.center.getLatitude()); - double px = (center[0] * numberOfPixels + dx) / numberOfPixels; - double py = (center[1] * numberOfPixels + dy) / numberOfPixels; - return projection.unproject(px, py); - } - - /** - * Converts a wgs cooridnate to a pixel. - * - * @param longitude The longitude. - * @param latitude The latitude. - * @return The x and y of the pixel. - */ - public float[] coordinateToPixel(double longitude, double latitude) { - float[] xy = new float[2]; - coordinateToPixel(longitude, latitude, xy, 0); - return xy; - } - - /** - * Converts the coordinate to a pixel and puts the x and y values - * into the destination array starting at the offset. - * - * @param longitude The longitude. - * @param latitude The latitude. - * @param dest The destination. - * @param offset The offset. - */ - public void coordinateToPixel(double longitude, double latitude, float[] dest, int offset) { - double[] center = projection.project(this.center.getLongitude(), this.center.getLatitude()); - double[] point = projection.project(longitude, latitude); - double numberOfPixels = 256 * density * (1 << zoom); - double cx = center[0] * numberOfPixels; - double cy = center[1] * numberOfPixels; - double px = point[0] * numberOfPixels; - double py = point[1] * numberOfPixels; - InterimRotation r = getRotation(); - double nx = (px-cx)*r.cosineForward - (py-cy)*r.sineForward; - double ny = (px-cx)*r.sineForward + (py-cy)*r.cosineForward; - dest[offset] = (float)(pixelCenterX + nx * scale); - dest[offset + 1] = (float)(pixelCenterY + ny * scale); - } - - /** - * Returns the current bounds of the view. This is an overestimated bounding - * box which can be used to avoid rendering of elements that are not displayed - * on the map. - * - * @return The bounding box of the view port. - */ - public Box getViewport() { - if (viewport == null) { - double[] a = pixelToCoordinate(0, 0); - double[] b = pixelToCoordinate(pixelWidth, pixelHeight); - double[] c = pixelToCoordinate(pixelWidth, 0); - double[] d = pixelToCoordinate(0, pixelHeight); - double minX = Math.min(a[0], Math.min(b[0], Math.min(c[0], d[0]))); - double maxX = Math.max(a[0], Math.max(b[0], Math.max(c[0], d[0]))); - double minY = Math.min(a[1], Math.min(b[1], Math.min(c[1], d[1]))); - double maxY = Math.max(a[1], Math.max(b[1], Math.max(c[1], d[1]))); - viewport = new Box(minX, minY, maxX, maxY); - } - return viewport; - } - -} diff --git a/android/leafless/src/main/java/com/locoslab/capi/android/leafless/MoveEvent.java b/android/leafless/src/main/java/com/locoslab/capi/android/leafless/MoveEvent.java deleted file mode 100644 index 6c16d07..0000000 --- a/android/leafless/src/main/java/com/locoslab/capi/android/leafless/MoveEvent.java +++ /dev/null @@ -1,85 +0,0 @@ -package com.locoslab.capi.android.leafless; - -import com.locoslab.api.data.maps.model.Coordinate; - -/** - * A move event. - * - * @author Marcus - */ -public class MoveEvent extends MapEvent { - - /** - * The point. - */ - private MapPoint sourcePoint; - - /** - * The coordinate. - */ - private Coordinate sourceCoordinate; - - /** - * The point. - */ - private MapPoint targetPoint; - - /** - * The coordinate. - */ - private Coordinate targetCoordinate; - - /** - * Creates a new event. - * - * @param view The view. - * @param sourcePoint The source point. - * @param sourceCoordinate The source coordinate. - * @param targetPoint The target point. - * @param targetCoordinate The target coordinate. - */ - public MoveEvent(MapView view, MapPoint sourcePoint, Coordinate sourceCoordinate, MapPoint targetPoint, Coordinate targetCoordinate) { - super(view); - this.sourcePoint = sourcePoint; - this.sourceCoordinate = sourceCoordinate; - this.targetPoint = targetPoint; - this.targetCoordinate = targetCoordinate; - } - - /** - * Returns the source point. - * - * @return the sourcePoint. - */ - public MapPoint getSourcePoint() { - return sourcePoint; - } - - /** - * Returns the source coordinate. - * - * @return the sourceCoordinate - */ - public Coordinate getSourceCoordinate() { - return sourceCoordinate; - } - - /** - * Returns the target point. - * - * @return the targetPoint - */ - public MapPoint getTargetPoint() { - return targetPoint; - } - - /** - * Returns the target coordinate. - * - * @return the targetCoordinate - */ - public Coordinate getTargetCoordinate() { - return targetCoordinate; - } - -} diff --git a/android/leafless/src/main/java/com/locoslab/capi/android/leafless/TouchEvent.java b/android/leafless/src/main/java/com/locoslab/capi/android/leafless/TouchEvent.java deleted file mode 100644 index 72eec33..0000000 --- a/android/leafless/src/main/java/com/locoslab/capi/android/leafless/TouchEvent.java +++ /dev/null @@ -1,54 +0,0 @@ -package com.locoslab.capi.android.leafless; - -import com.locoslab.api.data.maps.model.Coordinate; - -/** - * A touch event that is issued at a particular position on a view. - * - * @author Marcus - */ -public class TouchEvent extends MapEvent { - - /** - * The point. - */ - private MapPoint point; - - /** - * The coordinate. - */ - private Coordinate coordinate; - - /** - * Creates a new touch event for a view, point and coordinate. - * - * @param view The view. - * @param point The point. - * @param c The coordinate. - */ - public TouchEvent(MapView view, MapPoint point, Coordinate c) { - super(view); - this.point = point; - this.coordinate = c; - } - - /** - * Returns the coordinate. - * - * @return The coordinate. - */ - public Coordinate getCoordinate() { - return coordinate; - } - - /** - * Returns the point. - * - * @return The point. - */ - public MapPoint getPoint() { - return point; - } - - -} diff --git a/android/leafless/src/main/java/com/locoslab/capi/android/leafless/cache/AbstractCreator.java b/android/leafless/src/main/java/com/locoslab/capi/android/leafless/cache/AbstractCreator.java deleted file mode 100644 index 75d4894..0000000 --- a/android/leafless/src/main/java/com/locoslab/capi/android/leafless/cache/AbstractCreator.java +++ /dev/null @@ -1,32 +0,0 @@ -package com.locoslab.capi.android.leafless.cache; - -import java.io.ByteArrayOutputStream; -import java.io.IOException; -import java.io.InputStream; - -/** - * An abstract base class for creator implementations. - * - * @author Marcus - */ -public abstract class AbstractCreator implements IObjectFactory { - - @Override - public O createObject(String mimeType, InputStream in) { - try { - ByteArrayOutputStream bos = new ByteArrayOutputStream(); - byte[] buffer = new byte[8192]; - int read = in.read(buffer); - while (read != -1) { - bos.write(buffer, 0, read); - read = in.read(buffer); - } - in.close(); - byte[] bytes = bos.toByteArray(); - return createObject(mimeType, bytes); - } catch (IOException e) { - return null; - } - } - -} diff --git a/android/leafless/src/main/java/com/locoslab/capi/android/leafless/cache/Cache.java b/android/leafless/src/main/java/com/locoslab/capi/android/leafless/cache/Cache.java deleted file mode 100644 index 74b1485..0000000 --- a/android/leafless/src/main/java/com/locoslab/capi/android/leafless/cache/Cache.java +++ /dev/null @@ -1,174 +0,0 @@ -package com.locoslab.capi.android.leafless.cache; - -import com.locoslab.capi.android.leafless.cache.CacheContract.Request; - -import android.content.ContentValues; -import android.content.Context; -import android.database.Cursor; -import android.database.sqlite.SQLiteDatabase; -import android.database.sqlite.SQLiteException; -import android.util.Log; - - -/** - * This class implements a facade for the database cache. - * - * @author Marcus - */ -public class Cache { - - /** - * The log tag. - */ - private static final String TAG = Cache.class.getSimpleName(); - - /** - * The static instance of the logger. - */ - private static Cache cache; - - /** - * Returns the logger using the context. - * - * @param c - * The context. - * @return The logger. - */ - public static synchronized Cache getCache(Context c) { - if (cache == null) { - cache = new Cache(c.getApplicationContext()); - } - return cache; - } - - /** - * Resets the logger. - */ - public static synchronized void resetCache() { - if (cache != null) { - cache.close(); - cache = null; - } - } - - /** - * The columns to select. - */ - private static String[] COLUMNS = new String[] { - Request.COLUMN_NAME_ID, Request.COLUMN_NAME_URL, - Request.COLUMN_NAME_TYPE, Request.COLUMN_NAME_MODIFIED, - Request.COLUMN_NAME_ETAG, Request.COLUMN_NAME_EXPIRES, - Request.COLUMN_NAME_DATA - }; - - - /** - * Reference to the SQLiteOpenHelper class for creation and deletion of - * database - */ - private CacheHelper helper; - - /** - * Creates a new logger in the application context. - * - * @param context - * The context. - */ - private Cache(Context context) { - helper = new CacheHelper(context); - } - - /** - * Returns a writable reference to the database. - * - * @return The database reference or null, if it cannot be created or the - * cache has been disposed. - */ - private SQLiteDatabase getDatabase() { - if (helper != null) { - try { - return helper.getWritableDatabase(); - } catch (SQLiteException e) { - Log.d(TAG, "Failed to open database.", e); - resetCache(); - } - } else { - Log.d(TAG, "Call closed cache."); - resetCache(); - } - return null; - } - - /** - * Saves the request. - * - * @param r The request to save. - * @return True if the request was saved. - */ - public synchronized boolean save(CacheRequest r) { - SQLiteDatabase db = getDatabase(); - if (db == null) return false; - ContentValues values = new ContentValues(); - values.put(Request.COLUMN_NAME_URL, r.url); - values.put(Request.COLUMN_NAME_TYPE, r.type); - values.put(Request.COLUMN_NAME_MODIFIED, r.modified); - values.put(Request.COLUMN_NAME_DATA, r.data); - values.put(Request.COLUMN_NAME_ETAG, r.etag); - values.put(Request.COLUMN_NAME_EXPIRES, r.expires); - boolean success = false; - if (r.identifier == null) { - long id = db.insert(Request.TABLE_NAME, null, values); - if (id != -1) { - r.identifier = id; - success = true; - } - } else { - int count = db.update(Request.TABLE_NAME, values, Request.COLUMN_NAME_ID + "= ?", new String[] { r.identifier.toString() }); - if (count == 1) { - success = true; - } - } - db.close(); - return success; - } - - /** - * Loads a cache entry from the db. If the db - * does not contain the entry, a new one will - * be returned. - * - * @param url The url. - * @return The cache entry. - */ - public synchronized CacheRequest load(String url) { - CacheRequest r = new CacheRequest(); - r.url = url; - SQLiteDatabase db = getDatabase(); - if (db == null) return r; - Cursor c = db.query(Request.TABLE_NAME, COLUMNS, Request.COLUMN_NAME_URL + "= ?", new String[] { url }, null, null, null); - if (c.moveToNext()) { - r.identifier = c.getLong(0); - if (! c.isNull(1)) r.url = c.getString(1); - if (! c.isNull(2)) r.type = c.getString(2); - if (! c.isNull(3)) r.modified = c.getLong(3); - if (! c.isNull(4)) r.etag = c.getString(4); - if (! c.isNull(5)) r.expires = c.getLong(5); - if (! c.isNull(6)) r.data = c.getBlob(6); - } - c.close(); - db.close(); - return r; - } - - - /** - * Called to close the cache. - */ - private synchronized void close() { - if (helper != null) { - helper.close(); - helper = null; - } - } - -} diff --git a/android/leafless/src/main/java/com/locoslab/capi/android/leafless/cache/CacheConfiguration.java b/android/leafless/src/main/java/com/locoslab/capi/android/leafless/cache/CacheConfiguration.java deleted file mode 100644 index c8e190e..0000000 --- a/android/leafless/src/main/java/com/locoslab/capi/android/leafless/cache/CacheConfiguration.java +++ /dev/null @@ -1,56 +0,0 @@ -package com.locoslab.capi.android.leafless.cache; - -/** - * Contains all constants to configure the caching database. - * - * @author Marcus - */ -public class CacheConfiguration { - - /** - * The name of the database file that is used to store the - * data. - */ - private static String databaseName = "tile-cache.db"; - /** - * The version of the database file that is used to store - * the data. - */ - private static int databaseVersion = 2; - /** - * Returns the databaseName. - * - * @return The databaseName. - */ - public static String getDatabaseName() { - return databaseName; - } - - /** - * Sets the databaseName. - * - * @param databaseName The databaseName to set. - */ - public static void setDatabaseName(String databaseName) { - CacheConfiguration.databaseName = databaseName; - } - - /** - * Returns the databaseVersion. - * - * @return The databaseVersion. - */ - public static int getDatabaseVersion() { - return databaseVersion; - } - - /** - * Sets the databaseVersion. - * - * @param databaseVersion The databaseVersion to set. - */ - public static void setDatabaseVersion(int databaseVersion) { - CacheConfiguration.databaseVersion = databaseVersion; - } - -} diff --git a/android/leafless/src/main/java/com/locoslab/capi/android/leafless/cache/CacheContract.java b/android/leafless/src/main/java/com/locoslab/capi/android/leafless/cache/CacheContract.java deleted file mode 100644 index 5ac4b30..0000000 --- a/android/leafless/src/main/java/com/locoslab/capi/android/leafless/cache/CacheContract.java +++ /dev/null @@ -1,90 +0,0 @@ -package com.locoslab.capi.android.leafless.cache; - -import android.provider.BaseColumns; - -/** - * Contract class for defining the constants used in the database - * - * @author Marcus - * - */ -public final class CacheContract { - - /** - * Disable constructor. - */ - private CacheContract() { }; - - /** - * For data type for numbers. - */ - static final String TYPE_NUMBER = " INTEGER"; - - /** - * For data type for short var chars. - */ - static final String TYPE_TEXT = " VARCHAR"; - - /** - * For data type character large object - */ - static final String TYPE_BLOB = " BLOB"; - - /** - * Comma character for creation of tables and queries - */ - static final String SEPARATOR = ","; - - /** - * Inner class for defining the table contents - */ - public static final class Request implements BaseColumns { - - /** - * Disable constructor. - */ - private Request() { }; - - /** - * Name of the table - */ - public static final String TABLE_NAME = "request"; - - /** - * The sequence id (auto generated) - */ - public static final String COLUMN_NAME_ID = "_id"; - - /** - * The request url including parameters. - */ - public static final String COLUMN_NAME_URL = "url"; - - /** - * The content type of the response. - */ - public static final String COLUMN_NAME_TYPE = "type"; - - /** - * The etag of the request. - */ - public static final String COLUMN_NAME_ETAG = "etag"; - - /** - * The time when the request result has been last modified. - */ - public static final String COLUMN_NAME_MODIFIED = "modified"; - - /** - * The time when the request expires. - */ - public static final String COLUMN_NAME_EXPIRES = "expires"; - - /** - * The result of the request. - */ - public static final String COLUMN_NAME_DATA = "data"; - - } - -} diff --git a/android/leafless/src/main/java/com/locoslab/capi/android/leafless/cache/CacheHelper.java b/android/leafless/src/main/java/com/locoslab/capi/android/leafless/cache/CacheHelper.java deleted file mode 100644 index 7ec802a..0000000 --- a/android/leafless/src/main/java/com/locoslab/capi/android/leafless/cache/CacheHelper.java +++ /dev/null @@ -1,73 +0,0 @@ -package com.locoslab.capi.android.leafless.cache; - -import java.io.File; - -import com.locoslab.capi.android.leafless.cache.CacheContract.Request; - -import android.content.Context; -import android.database.sqlite.SQLiteDatabase; -import android.database.sqlite.SQLiteOpenHelper; - -/** - * - * A helper class for editing database entries for the database. - * - * @author Marcus - */ -public class CacheHelper extends SQLiteOpenHelper { - - /** - * String for the creation of the table. - */ - private static final String SQL_CREATE_TABLE = "CREATE TABLE " - + Request.TABLE_NAME + " (" - + Request.COLUMN_NAME_ID + CacheContract.TYPE_NUMBER + " PRIMARY KEY AUTOINCREMENT" + CacheContract.SEPARATOR - + Request.COLUMN_NAME_URL + CacheContract.TYPE_TEXT + CacheContract.SEPARATOR - + Request.COLUMN_NAME_ETAG + CacheContract.TYPE_TEXT + CacheContract.SEPARATOR - + Request.COLUMN_NAME_MODIFIED + CacheContract.TYPE_NUMBER + CacheContract.SEPARATOR - + Request.COLUMN_NAME_TYPE + CacheContract.TYPE_NUMBER + CacheContract.SEPARATOR - + Request.COLUMN_NAME_EXPIRES + CacheContract.TYPE_NUMBER + CacheContract.SEPARATOR - + Request.COLUMN_NAME_DATA + CacheContract.TYPE_BLOB - + ")"; - - /** - * String for the creation of the index. - */ - private static final String SQL_CREATE_INDEX = "CREATE UNIQUE INDEX URLINDEX ON " - + Request.TABLE_NAME + " (" + Request.COLUMN_NAME_URL + ")"; - - /** - * String for the deletion of the table. - */ - private static final String SQL_DELETE_TABLE = "DROP TABLE IF EXISTS " - + CacheContract.Request.TABLE_NAME; - - /** - * String for the deletion of the index. - */ - private static final String SQL_DELETE_INDEX = "DROP INDEX IF EXISTS URLINDEX"; - - /** - * Creates a new helper using the context. - * - * @param context - * The context. - */ - public CacheHelper(Context context) { - super(context, new File(context.getCacheDir(), CacheConfiguration.getDatabaseName()).getAbsolutePath(), null, CacheConfiguration.getDatabaseVersion()); - } - - @Override - public void onCreate(SQLiteDatabase db) { - db.execSQL(SQL_CREATE_TABLE); - db.execSQL(SQL_CREATE_INDEX); - } - - @Override - public void onUpgrade(SQLiteDatabase db, int oldVersion, int newVersion) { - db.execSQL(SQL_DELETE_INDEX); - db.execSQL(SQL_DELETE_TABLE); - onCreate(db); - } - -} diff --git a/android/leafless/src/main/java/com/locoslab/capi/android/leafless/cache/CacheObjectLoader.java b/android/leafless/src/main/java/com/locoslab/capi/android/leafless/cache/CacheObjectLoader.java deleted file mode 100644 index 7698f38..0000000 --- a/android/leafless/src/main/java/com/locoslab/capi/android/leafless/cache/CacheObjectLoader.java +++ /dev/null @@ -1,314 +0,0 @@ -package com.locoslab.capi.android.leafless.cache; - -import java.io.ByteArrayOutputStream; -import java.io.IOException; -import java.io.InputStream; -import java.net.HttpURLConnection; -import java.net.URL; -import java.net.URLConnection; -import java.util.HashMap; -import java.util.Map; -import java.util.concurrent.ExecutorService; -import java.util.concurrent.Executors; -import java.util.concurrent.Future; - -import android.content.res.AssetManager; -import android.os.Handler; -import android.view.View; -import android.webkit.MimeTypeMap; - -/** - * A class that loads images via http, https or from assets and caches the - * results. - * - * @author Marcus - */ -public class CacheObjectLoader { - - /** - * A runnable that loads the bitmap for a map image. - * - * @author Marcus - */ - private class LoadHandler implements Runnable { - - /** - * The image. - */ - private IObjectRequest request; - - /** - * Creates a new handler. - * - * @param request - * The image to load. - */ - public LoadHandler(IObjectRequest request) { - this.request = request; - } - - @Override - public void run() { - if (shutdown) - return; - try { - completeRequest(request, fetchRequest(request, new URL(request.getUrl()))); - } catch (IOException e) { - // invalid urls should fail permanently - completeRequest(request, request.getCreator().createObject(404)); - } - synchronized (CacheObjectLoader.this) { - futures.remove(request); - } - } - - } - - /** - * The minimum expiration time for a tile, if none is specified by the - * server (6 hours in milliseconds). - */ - private static final int MINIMUM_EXPIRATION = 1000 * 60 * 60 * 6; - - /** - * The cache database to persistently cache results. - */ - private Cache cache; - - /** - * The asset manager to load assets. - */ - private AssetManager manager; - - /** - * The handler to post ui events. - */ - private Handler handler = new Handler(); - - /** - * The future objects for images that have been requested. - */ - private Map, Future> futures = new HashMap<>(); - - /** - * The executor service to load images. - */ - private ExecutorService executor; - - /** - * The map view. - */ - private View view; - - /** - * A flag to indicate that we have been shut down. - */ - private boolean shutdown = false; - - /** - * Creates a new image loader. - * - * @param view - * The view. - * @param threads - * The number of threads. - */ - public CacheObjectLoader(View view, int threads) { - this.view = view; - this.manager = view.getContext().getAssets(); - cache = Cache.getCache(view.getContext()); - executor = Executors.newFixedThreadPool(threads); - } - - public synchronized void shutdown() { - shutdown = true; - executor.shutdown(); - } - - public synchronized void requestObject(IObjectRequest request) { - if (!shutdown && !futures.containsKey(request)) { - LoadHandler h = new LoadHandler(request); - Future task = executor.submit(h); - futures.put(request, task); - } - } - - public synchronized void releaseObject(IObjectRequest request) { - Future task = futures.remove(request); - if (task != null) { - task.cancel(false); - } - } - - /** - * Guesses the mime type from the file extension in the url. - * - * @param request The request. - * @return The guessed mime type or null. - */ - protected String getUrlType(IObjectRequest request) { - String extension = MimeTypeMap.getFileExtensionFromUrl(request.getUrl()); - String type = null; - if (extension != null) { - type = MimeTypeMap.getSingleton().getMimeTypeFromExtension(extension); - } - return type; - } - - /** - * Fetches the object for the request either from cache or - * via a download. - * - * @param request The request. - * @param url The url. - * @return The object. - */ - private O fetchRequest(IObjectRequest request, URL url) { - if (url.getProtocol().equals("file") && url.getPath().startsWith("/android_asset/")) { - try { - InputStream s = manager.open(url.getPath().substring(15)); - O result = request.getCreator().createObject(getUrlType(request), s); - s.close(); - return result; - } catch (IOException e) { - // asset load errors should fail permanently - return request.getCreator().createObject(404); - } - } - CacheRequest r = cache.load(url.toString()); - O b = null; - if (r.data != null) { - b = request.getCreator().createObject(r.type, r.data); - if (b != null) { - if (r.expires >= System.currentTimeMillis()) { - return b; - } - } else { - // broken image, make sure we are full reloading it - r.etag = null; - r.modified = null; - r.data = null; - } - } - try { - URLConnection c = url.openConnection(); - if (c instanceof HttpURLConnection) { - HttpURLConnection h = (HttpURLConnection) c; - h.setRequestMethod("GET"); - h.setDoInput(true); - h.setDoOutput(false); - prepareHeaders(r, request.getCreator().getMimeType(), h); - if (h.getResponseCode() == 200) { - ByteArrayOutputStream bos = new ByteArrayOutputStream(); - InputStream in = h.getInputStream(); - byte[] buffer = new byte[8192]; - int read = in.read(buffer); - while (read != -1) { - bos.write(buffer, 0, read); - read = in.read(buffer); - } - in.close(); - byte[] bytes = bos.toByteArray(); - extractHeaders(r, h); - b = request.getCreator().createObject(r.type, bytes); - if (b != null) { - r.data = bytes; - cache.save(r); - } - return b; - } else if (h.getResponseCode() == 304) { - extractHeaders(r, h); - cache.save(r); - return b; - } else if (h.getResponseCode() >= 400 && h.getResponseCode() < 600) { - // client or server errors should fail permanently - return request.getCreator().createObject(h.getResponseCode()); - } else { - return null; - } - } else { - InputStream s = c.getInputStream(); - O result = request.getCreator().createObject(getUrlType(request), s); - s.close(); - return result; - } - } catch (IOException e) { - // this could be a transient failure - return null; - } - - } - - /** - * Signals the completion of the request. - * - * @param request The request. - * @param object The object. - */ - protected void completeRequest(final IObjectRequest request, final O object) { - handler.post(new Runnable() { - @Override - public void run() { - request.onCompletion(object); - if (view.isShown()) { - view.invalidate(); - } - } - }); - } - - /** - * Prepares the headers for the request. - * - * @param request The request. - * @param mimeType The acceptable mime types or null. - * @param c The connection. - */ - protected void prepareHeaders(CacheRequest request, String mimeType, HttpURLConnection c) { - if (mimeType != null) { - c.setRequestProperty("Accept", mimeType); - } - if (request.data != null) { - if (request.etag != null) { - c.setRequestProperty("If-None-Match", request.etag); - } - if (request.modified != null) { - c.setIfModifiedSince(request.modified); - } - } - } - - /** - * Extracts the headers and puts them into the request. - * - * @param request The request. - * @param c The connection. - */ - protected void extractHeaders(CacheRequest request, HttpURLConnection c) { - long now = System.currentTimeMillis(); - long expire = c.getExpiration(); - long modified = c.getExpiration(); - String etag = c.getHeaderField("ETag"); - String type = c.getHeaderField("Content-Type"); - String cache = c.getHeaderField("Cache-Control"); - long maxAge = 0; - if (cache != null) { - String[] cts = cache.split(","); - for (String ct : cts) { - ct = ct.trim(); - if (ct.startsWith("max-age=")) { - try { - maxAge = Integer.parseInt(ct.substring(8)); - } catch (Exception e) { - e.printStackTrace(); - } - } - } - } - request.modified = (modified == 0) ? null : modified; - request.expires = Math.max(expire, now + Math.max(MINIMUM_EXPIRATION, maxAge * 1000)); - request.etag = etag; - request.type = type; - } - -} diff --git a/android/leafless/src/main/java/com/locoslab/capi/android/leafless/cache/CacheRequest.java b/android/leafless/src/main/java/com/locoslab/capi/android/leafless/cache/CacheRequest.java deleted file mode 100644 index 9070216..0000000 --- a/android/leafless/src/main/java/com/locoslab/capi/android/leafless/cache/CacheRequest.java +++ /dev/null @@ -1,43 +0,0 @@ -package com.locoslab.capi.android.leafless.cache; - -/** - * A cache request that can be loaded and stored. - * - * @author Marcus - */ -public class CacheRequest { - - /** - * The data base identifier or - * null for new entries. - */ - public Long identifier; - /** - * The url of the request. - */ - public String url; - /** - * The etag of the response which may be null. - */ - public String etag; - /** - * The time in system current time millis when - * the cache result expires and must be at least - * revalidated. - */ - public long expires; - /** - * The last modified timestamp in system time millis. - */ - public Long modified; - /** - * The mime type of the response which may be null - * for new requests. - */ - public String type; - /** - * The actual data which may be null. - */ - public byte[] data; - -} diff --git a/android/leafless/src/main/java/com/locoslab/capi/android/leafless/cache/IObjectFactory.java b/android/leafless/src/main/java/com/locoslab/capi/android/leafless/cache/IObjectFactory.java deleted file mode 100644 index 74c596f..0000000 --- a/android/leafless/src/main/java/com/locoslab/capi/android/leafless/cache/IObjectFactory.java +++ /dev/null @@ -1,50 +0,0 @@ -package com.locoslab.capi.android.leafless.cache; - -import java.io.InputStream; - -/** - * Creates an object from a downloaded byte sequence - * or an http error code. - * - * @author Marcus - * - * @param The object type. - */ -public interface IObjectFactory { - - /** - * Returns the accepted mime type. - * - * @return The accepted mime type. - */ - public String getMimeType(); - - /** - * Creates an object from a sequence of bytes. - * - * @param mimeType The mime type. - * @param bytes The bytes. - * @return The object or null, if the object - * cannot be decoded. - */ - public O createObject(String mimeType, byte[] bytes); - - /** - * Creates an object from an input stream. - * - * @param mimeType The mime type. - * @param input The input stream. - * @return The object or null, if the object cannot be - * decoded. - */ - public O createObject(String mimeType, InputStream input); - - /** - * Creates an object from an http error code. - * - * @param error The error code. - * @return The object or null. - */ - public O createObject(int error); - -} diff --git a/android/leafless/src/main/java/com/locoslab/capi/android/leafless/cache/IObjectRequest.java b/android/leafless/src/main/java/com/locoslab/capi/android/leafless/cache/IObjectRequest.java deleted file mode 100644 index ba46ef6..0000000 --- a/android/leafless/src/main/java/com/locoslab/capi/android/leafless/cache/IObjectRequest.java +++ /dev/null @@ -1,32 +0,0 @@ -package com.locoslab.capi.android.leafless.cache; - -/** - * The request and callback. - * - * @author Marcus - * - * @param The type of the object. - */ -public interface IObjectRequest { - - /** - * Returns the request url. - * - * @return The request url. - */ - public String getUrl(); - - /** - * Called when an object is loaded. - * - * @param object The object. - */ - public void onCompletion(O object); - - /** - * Returns the object creator. - * - * @return The object creator. - */ - public IObjectFactory getCreator(); -} diff --git a/android/leafless/src/main/java/com/locoslab/capi/android/leafless/circle/Circle.java b/android/leafless/src/main/java/com/locoslab/capi/android/leafless/circle/Circle.java deleted file mode 100644 index 628a579..0000000 --- a/android/leafless/src/main/java/com/locoslab/capi/android/leafless/circle/Circle.java +++ /dev/null @@ -1,214 +0,0 @@ -package com.locoslab.capi.android.leafless.circle; - -import android.graphics.Canvas; -import android.graphics.Paint; -import com.locoslab.api.data.maps.model.Box; -import com.locoslab.api.data.maps.model.Coordinate; -import com.locoslab.api.data.maps.util.Coordinates; -import com.locoslab.capi.android.leafless.AbstractElement; -import com.locoslab.capi.android.leafless.MapViewState; - -/** - * A circle shape with a configurable radius that can be placed - * on the map. The radius can either be given by means of a - * distance in pixels or by a distance in meters. The former will - * create a circle whose size does not depend on the map zoom. - * The later will be zoomed accordingly. - * - * @author Marcus - */ -public class Circle extends AbstractElement { - - /** - * The center of the circle. - */ - protected Coordinate center = new Coordinate(); - - /** - * The radius of the circle that has to be interpreted - * according to the unit. - */ - protected double radius = 1; - - /** - * The unit to compute the radius. - */ - protected CircleUnit unit = CircleUnit.METER; - - /** - * Creates a new marker with the specified options. - * - * @param options The options. - */ - public Circle(CircleOptions options) { - super(new CircleOptions(options)); - } - - /** - * Returns the current geographical position of the circle. - * - * @return The center coordinate. This is a copy that can - * be freely modified. Changes will not be made in the - * actual position of the circle. - */ - public Coordinate getCenter() { - Coordinate c = new Coordinate(); - c.setLatitude(center.getLatitude()); - c.setLongitude(center.getLongitude()); - return c; - } - - /** - * Sets the latitude. - * - * @param latitude The latitude. - */ - public void setLatitude(double latitude) { - this.center.setLatitude(latitude); - invalidate(); - } - - /** - * Sets the longitude. - * - * @param longitude The longitude. - */ - public void setLongitude(double longitude) { - this.center.setLongitude(longitude); - invalidate(); - } - - /** - * Changes the circle position to the given point. - * - * @param center The coordinate to change the circle center position. - */ - public void setCenter(Coordinate center) { - this.center.setLatitude(center.getLatitude()); - this.center.setLongitude(center.getLongitude()); - invalidate(); - } - - /** - * Returns the radius of the circle. - * - * @return The radius of the circle. - */ - public double getRadius() { - return radius; - } - - /** - * Returns the unit of the radius. - * - * @return The unit of the radius. - */ - public CircleUnit getUnit() { - return unit; - } - - /** - * Sets the radius of the circle. The radius is interpreted - * based on the mode. - * - * @param unit The circle unit of the radius - * @param radius The new radius of the circle. - */ - public void setRadius(double radius, CircleUnit unit) { - this.radius = radius; - this.unit = unit; - invalidate(); - } - - /** - * Returns the paint to draw the line. - * - * @param state The map view state. - * @return The paint to draw. - */ - private Paint getPaint(MapViewState state) { - Paint p = options.linePaint; - p = new Paint(p); - float density = options.densityIndependent?1:state.getDensity(); - p.setStrokeWidth((float)(p.getStrokeWidth() * density)); - return p; - } - - @Override - public void drawObject(Canvas canvas) { - MapViewState state = getMapViewState(); - if (state != null) { - float[] p1 = state.coordinateToPixel(center.getLongitude(), center.getLatitude()); - float pr = getPixelRadius(state); - if (options.fillPaint != null) { - canvas.drawCircle(p1[0], p1[1], pr, options.fillPaint); - } - if (options.linePaint != null) { - canvas.drawCircle(p1[0], p1[1], pr, getPaint(state)); - } - } - } - - /** - * Returns the radius in pixels for the current map state. - * - * @param state The current map state. - * @return The radius in pixels. - */ - protected float getPixelRadius(MapViewState state) { - switch (unit) { - case METER: { - double dlng = getLongitudeRadius(state); - float[] p1 = state.coordinateToPixel(center.getLongitude(), center.getLatitude()); - float[] p2 = state.coordinateToPixel(center.getLongitude() + dlng, center.getLatitude()); - float dx = p1[0] - p2[0]; - float dy = p1[1] - p2[1]; - return (float)Math.sqrt(dx * dx + dy * dy); - } - case PIXEL: { - float density = options.densityIndependent?1:state.getDensity(); - return (float)(radius * density); - } - } - throw new RuntimeException("Invalid radius mode (" + unit + ")."); - } - - /** - * Returns the radius in delta longitude. - * - * @param state The current map state. - * @return The radius in delta longitude. - */ - protected double getLongitudeRadius(MapViewState state) { - switch (unit) { - case METER: { - double distance = Coordinates.distanceInMeters(center.getLongitude(), center.getLatitude(), center.getLongitude() + 0.001, center.getLatitude()); - return 0.001 / distance * radius; - } - case PIXEL: { - float pixels = getPixelRadius(state); - float[] p1 = state.coordinateToPixel(center.getLongitude(), center.getLatitude()); - double[] p2 = state.pixelToCoordinate(p1[0] + pixels, p1[1]); - double dlat = p2[1] - center.getLatitude(); - double dlng = p2[0] - center.getLongitude(); - return Math.sqrt(dlat * dlat + dlng * dlng); - } - } - throw new RuntimeException("Invalid radius unit (" + unit + ")."); - } - - @Override - public Box getBounds() { - MapViewState state = getMapViewState(); - if (state != null) { - double delta = getLongitudeRadius(state); - double minLon = center.getLongitude() - delta; - double maxLon = center.getLongitude() + delta; - double minLat = center.getLatitude() - delta; - double maxLat = center.getLatitude() + delta; - return new Box(minLon, minLat, maxLon, maxLat); - } else { - return new Box(center, center); - } - } -} diff --git a/android/leafless/src/main/java/com/locoslab/capi/android/leafless/circle/CircleOptions.java b/android/leafless/src/main/java/com/locoslab/capi/android/leafless/circle/CircleOptions.java deleted file mode 100644 index 9542da4..0000000 --- a/android/leafless/src/main/java/com/locoslab/capi/android/leafless/circle/CircleOptions.java +++ /dev/null @@ -1,63 +0,0 @@ -package com.locoslab.capi.android.leafless.circle; - -import android.graphics.Color; -import android.graphics.Paint; -import com.locoslab.capi.android.leafless.FixedElementOptions; -import com.locoslab.capi.android.leafless.polyline.PolylineOptions; - -/** - * An options object for circles. - * - * @author Marcus - */ -public class CircleOptions extends FixedElementOptions { - - /** - * The paint that we use, if none is specified. - */ - private static final Paint DEFAULT_PAINT = new Paint(); - - static { - DEFAULT_PAINT.setColor(Color.BLUE); - DEFAULT_PAINT.setStrokeWidth(5); - DEFAULT_PAINT.setStrokeMiter(4); - DEFAULT_PAINT.setStrokeJoin(Paint.Join.ROUND); - DEFAULT_PAINT.setStyle(Paint.Style.STROKE); - DEFAULT_PAINT.setAlpha(128); - } - - /** - * The line paint which is used to configure - * the color, stroking, etc. Set to null, to - * not draw the outline at all. - */ - public Paint linePaint = new Paint(DEFAULT_PAINT); - - /** - * The fill paint which is used to fill the - * circle. Set to null, to not fill it. - */ - public Paint fillPaint; - - /** - * Creates new polyline options. - */ - public CircleOptions() { - super(); - } - - /** - * Creates polyline options by copying the passed ones. - * - * @param options The options to copy. - */ - public CircleOptions(CircleOptions options) { - super(options); - if (options.linePaint != null) { - linePaint = new Paint(options.linePaint); - } - if (options.fillPaint != null) { - fillPaint = new Paint(options.fillPaint); - } - } -} diff --git a/android/leafless/src/main/java/com/locoslab/capi/android/leafless/circle/CircleUnit.java b/android/leafless/src/main/java/com/locoslab/capi/android/leafless/circle/CircleUnit.java deleted file mode 100644 index 028761f..0000000 --- a/android/leafless/src/main/java/com/locoslab/capi/android/leafless/circle/CircleUnit.java +++ /dev/null @@ -1,22 +0,0 @@ -package com.locoslab.capi.android.leafless.circle; - -/** - * An enumeration to define the radius of the - * circle based on different distance units. - * - * @author Marcus - */ -public enum CircleUnit { - /** - * The radius is specified in meters. - */ - METER, - /** - * The radius is specified in pixels. - * Depending on the density settings - * in the circle options, the pixels - * are interpreted as being display - * independent or raw pixels. - */ - PIXEL; -} diff --git a/android/leafless/src/main/java/com/locoslab/capi/android/leafless/control/AbstractControl.java b/android/leafless/src/main/java/com/locoslab/capi/android/leafless/control/AbstractControl.java deleted file mode 100644 index 9412ea2..0000000 --- a/android/leafless/src/main/java/com/locoslab/capi/android/leafless/control/AbstractControl.java +++ /dev/null @@ -1,144 +0,0 @@ -package com.locoslab.capi.android.leafless.control; - -import com.locoslab.api.data.maps.model.Box; -import com.locoslab.capi.android.leafless.AbstractElement; -import com.locoslab.capi.android.leafless.MapPoint; -import com.locoslab.capi.android.leafless.MapViewState; -import com.locoslab.capi.android.leafless.icon.Icon; - -import android.graphics.Canvas; -import android.graphics.Rect; - -/** - * An abstract class to implement controls that are positioned at a fixed - * position on the screen. - * - * @author Marcus - * - * @param The options type of the control. - */ -public abstract class AbstractControl extends AbstractElement { - - /** - * The icons that this control needs to draw itself. Sub - * classes should set this array so that the loading - * takes place before or while the control is drawn. - */ - protected Icon[] icons = new Icon[0]; - - /** - * Creates a new control from the options. - * - * @param options The options. - */ - public AbstractControl(O options) { - super(options); - } - - /** - * Returns the size that this control will draw itself with. - * - * @return The size that the control draws itself with. - */ - public MapPoint getSize() { - int x = options.size.getX(); - int y = options.size.getY(); - MapPoint pref = getPreferredSize(); - if (x < 0) x = pref.getX(); - if (y < 0) y = pref.getY(); - return new MapPoint(x, y); - } - - /** - * Sets the size. If one of the dimensions is -1, the - * control's preferred size will be used. - * - * @param size The size to set. - */ - public void setSize(MapPoint size) { - this.options.size.setX(size.getX()); - this.options.size.setY(size.getY()); - invalidate(); - } - - /** - * Returns the position of the control. - * - * @return The position. - */ - public MapPoint getPosition() { - return new MapPoint(options.position.getX(), options.position.getY()); - } - - /** - * Sets the position (i.e. the top left corner) of the - * control. - * - * @param pos The position to use. - */ - public void setPosition(MapPoint pos) { - this.options.position.setX(pos.getX()); - this.options.position.setY(pos.getY()); - invalidate(); - } - - /** - * Returns the preferred size of the control. - * - * @return The preferred size of the control. - */ - public abstract MapPoint getPreferredSize(); - - /** - * Draws the shadow onto the canvas. Subclasses - * may override. The default does nothing. - * - * @param canvas The canvas. - */ - public void drawShadow(Canvas canvas) { - // do nothing, let subclass do something - } - - /** - * Returns the icons that this control needs. - * - * @return The icons to be loaded. - */ - public Icon[] getIcons() { - return icons; - } - - - @Override - public Box getBounds() { - // return the top left point as bounds - // since we overwrite contains, this is not - // a problem - MapViewState state = getMapViewState(); - if (state != null) { - double[] lnglat = state.pixelToCoordinate(options.position.getX(), options.position.getY()); - return new Box(lnglat[0], lnglat[1], lnglat[0], lnglat[1]); - } - return null; - } - - @Override - public boolean contains(int x, int y) { - return getRegion().contains(x, y); - } - - @Override - public Rect getRegion() { - MapPoint p = getPosition(); - MapPoint s = getSize(); - MapViewState state = getMapViewState(); - double density = 1; - if (!options.densityIndependent && state != null) { - density = state.getDensity(); - } - int x = (int)(p.getX() * density); - int y = (int)(p.getY() * density); - return new Rect(x, y, (int)(x + (density * s.getX())), (int)(y + (density * s.getY()))); - } - -} diff --git a/android/leafless/src/main/java/com/locoslab/capi/android/leafless/control/CompassControl.java b/android/leafless/src/main/java/com/locoslab/capi/android/leafless/control/CompassControl.java deleted file mode 100644 index 8fee035..0000000 --- a/android/leafless/src/main/java/com/locoslab/capi/android/leafless/control/CompassControl.java +++ /dev/null @@ -1,110 +0,0 @@ -package com.locoslab.capi.android.leafless.control; - -import com.locoslab.capi.android.leafless.MapPoint; -import com.locoslab.capi.android.leafless.MapViewState; -import com.locoslab.capi.android.leafless.icon.Icon; -import com.locoslab.capi.android.leafless.icon.IconImage; - -import android.graphics.Bitmap; -import android.graphics.Canvas; -import android.graphics.Rect; - -/** - * A control that shows an image at a particular point that - * is rotated together with the base map such that it can be - * used to create a compass. - * - * @author Marcus - */ -public class CompassControl extends AbstractControl { - - /** - * Creates a new control with the options. - * - * @param options The options. - */ - public CompassControl(CompassControlOptions options) { - super(new CompassControlOptions(options)); - icons = new Icon[] { options.icon }; - } - - /** - * Sets the icon. - * - * @param icon The icon. - */ - public void setIcon(Icon icon) { - this.options.icon = icon; - icons[0] = icon; - invalidate(); - } - - /** - * Returns the icon. - * - * @return The icon. - */ - public Icon getIcon() { - return this.options.icon; - } - - @Override - public MapPoint getPreferredSize() { - MapPoint s = options.icon.getIconImage().getSize(); - Bitmap b = options.icon.getIconImage().getBitmap(); - int x = s.getX(); - int y = s.getY(); - if (x < 0 && b != null) x = b.getWidth(); - if (y < 0 && b != null) y = b.getHeight(); - return new MapPoint((int)(x), (int)(y)); - } - - @Override - public void drawObject(Canvas canvas) { - MapViewState state = getMapViewState(); - IconImage image = this.options.icon.getIconImage(); - if (state != null && image != null) { - drawImage(canvas, state, image); - } - } - - @Override - public void drawShadow(Canvas canvas) { - MapViewState state = getMapViewState(); - IconImage image = this.options.icon.getShadowImage(); - if (state != null && image != null) { - drawImage(canvas, state, image); - } - } - - /** - * Draws the image onto the canvas with the anchor placed at the center. - * - * @param canvas The canvas. - * @param state The state. - * @param image The image. - */ - protected void drawImage(Canvas canvas, MapViewState state, IconImage image) { - Bitmap b = image.getBitmap(); - if (b != null) { - canvas.save(); - MapPoint position = getPosition(); - MapPoint size = getSize(); - float density = options.densityIndependent?1:state.getDensity(); - canvas.translate(density * position.getX() + density * size.getX() / 2, density * position.getY() + density * size.getY() / 2); - canvas.rotate((float)(this.options.angle + state.getAngle())); - int ax = (int)(image.getAnchor().getX() * density); - int ay = (int)(image.getAnchor().getY() * density); - Rect src = new Rect(0, 0, b.getWidth(), b.getHeight()); - int w = (int)(image.getSize().getX() * density); - if (w < 0) w = (int)(b.getWidth() * density); - int h = (int)(image.getSize().getY() * density); - if (h < 0) h = (int)(b.getHeight() * density); - Rect dest = new Rect(-ax, -ay, w - ax, h - ay); - canvas.drawBitmap(b, src, dest, null); - canvas.restore(); - } - } - - -} diff --git a/android/leafless/src/main/java/com/locoslab/capi/android/leafless/control/CompassControlOptions.java b/android/leafless/src/main/java/com/locoslab/capi/android/leafless/control/CompassControlOptions.java deleted file mode 100644 index e651e04..0000000 --- a/android/leafless/src/main/java/com/locoslab/capi/android/leafless/control/CompassControlOptions.java +++ /dev/null @@ -1,44 +0,0 @@ -package com.locoslab.capi.android.leafless.control; - -import com.locoslab.capi.android.leafless.icon.Icon; - -/** - * The options for the compass. The options here contain a - * reference to an image. - * - * @author Marcus - */ -public class CompassControlOptions extends ControlOptions { - - /** - * The icon that will be rotated. - */ - public Icon icon; - - /** - * An offset to the angle. This should - * be 0 if the icon is facing north. - */ - public double angle; - - /** - * Creates a compass with the specified icon. - * - * @param icon The icon. - */ - public CompassControlOptions(Icon icon) { - this.icon = icon; - } - - /** - * Creates the compass options by copying to options. - * - * @param options The options to copy. - */ - public CompassControlOptions(CompassControlOptions options) { - super(options); - this.icon = options.icon; - this.angle = options.angle; - } - -} diff --git a/android/leafless/src/main/java/com/locoslab/capi/android/leafless/control/ControlOptions.java b/android/leafless/src/main/java/com/locoslab/capi/android/leafless/control/ControlOptions.java deleted file mode 100644 index ba7939e..0000000 --- a/android/leafless/src/main/java/com/locoslab/capi/android/leafless/control/ControlOptions.java +++ /dev/null @@ -1,43 +0,0 @@ -package com.locoslab.capi.android.leafless.control; - -import com.locoslab.capi.android.leafless.FixedElementOptions; -import com.locoslab.capi.android.leafless.MapPoint; - -/** - * The base class for control options. - * - * @author Marcus - */ -public class ControlOptions extends FixedElementOptions { - - /** - * The top left position of the control. - */ - public MapPoint position = new MapPoint(0, 0); - - /** - * The size of the control. Set to negative - * values to use the control's preferred size. - */ - public MapPoint size = new MapPoint(-1, -1); - - - /** - * Creates new control options. - */ - public ControlOptions() { - super(); - } - - /** - * Creates new control options copied from the passed options. - * - * @param options The options to copy. - */ - public ControlOptions(ControlOptions options) { - super(options); - this.position = new MapPoint(options.position.getX(), options.position.getY()); - this.size = new MapPoint(options.size.getX(), options.size.getY()); - } - -} diff --git a/android/leafless/src/main/java/com/locoslab/capi/android/leafless/geojson/GeojsonLoader.java b/android/leafless/src/main/java/com/locoslab/capi/android/leafless/geojson/GeojsonLoader.java deleted file mode 100644 index 9286945..0000000 --- a/android/leafless/src/main/java/com/locoslab/capi/android/leafless/geojson/GeojsonLoader.java +++ /dev/null @@ -1,142 +0,0 @@ -package com.locoslab.capi.android.leafless.geojson; - -import java.io.ByteArrayInputStream; -import java.io.InputStream; - -import org.geojson.FeatureCollection; - -import com.fasterxml.jackson.databind.ObjectMapper; -import com.locoslab.capi.android.leafless.cache.CacheObjectLoader; -import com.locoslab.capi.android.leafless.cache.IObjectFactory; -import com.locoslab.capi.android.leafless.cache.IObjectRequest; - -/** - * A wrapper that enables the loading of feature collections via the cached - * object loader. - * - * @author Marcus - */ -public class GeojsonLoader implements IGeojsonLoader { - - /** - * The factory to enable the loading of geojson feature collections. - */ - public static final IObjectFactory FEATURE_FACTORY = new IObjectFactory() { - - private ObjectMapper mapper = new ObjectMapper(); - - @Override - public FeatureCollection createObject(int code) { - // TODO: create an error - return new FeatureCollection(); - } - - @Override - public FeatureCollection createObject(String mimeType, byte[] bytes) { - return createObject(mimeType, new ByteArrayInputStream(bytes)); - } - - @Override - public FeatureCollection createObject(String mimeType, InputStream input) { - try { - return mapper.readValue(input, FeatureCollection.class); - } catch (Exception e) { - e.printStackTrace(); - return null; - } - } - - @Override - public String getMimeType() { - return "application/geo+json"; - } - - }; - - /** - * A wrapper for geo json requests - * - * @author Marcus - */ - public static class GeojsonObjectRequest implements IObjectRequest { - - /** - * The geojson to be loaded. - */ - private IGeojson geojson; - - /** - * Creates a new request for geojson. - * - * @param geojson - * The request. - */ - public GeojsonObjectRequest(IGeojson geojson) { - this.geojson = geojson; - } - - @Override - public IObjectFactory getCreator() { - return FEATURE_FACTORY; - } - - @Override - public String getUrl() { - return geojson.getUrl(); - } - - @Override - public void onCompletion(FeatureCollection object) { - geojson.setFeatures(object); - } - - @Override - public int hashCode() { - return geojson.hashCode(); - } - - @Override - public boolean equals(Object obj) { - if (obj == null || obj.getClass() != getClass()) - return false; - return ((GeojsonObjectRequest) obj).geojson == geojson; - } - } - - /** - * The object loader. - */ - private CacheObjectLoader loader; - - /** - * Creates a new image loader. - */ - public GeojsonLoader() { - super(); - } - - /** - * Sets the cached loader used as base. - * - * @param loader - * The loader. - */ - public void setLoader(CacheObjectLoader loader) { - this.loader = loader; - } - - @Override - public synchronized void requestObject(IGeojson image) { - if (loader != null) { - loader.requestObject(new GeojsonObjectRequest(image)); - } - } - - @Override - public synchronized void releaseObject(IGeojson image) { - if (loader != null) { - loader.releaseObject(new GeojsonObjectRequest(image)); - } - } - -} diff --git a/android/leafless/src/main/java/com/locoslab/capi/android/leafless/geojson/IGeojson.java b/android/leafless/src/main/java/com/locoslab/capi/android/leafless/geojson/IGeojson.java deleted file mode 100644 index de816ba..0000000 --- a/android/leafless/src/main/java/com/locoslab/capi/android/leafless/geojson/IGeojson.java +++ /dev/null @@ -1,20 +0,0 @@ -package com.locoslab.capi.android.leafless.geojson; - -import com.locoslab.capi.android.leafless.ILoadable; -import org.geojson.FeatureCollection; - -/** - * A feature collection to be loaded. - * - * @author Marcus - */ -public interface IGeojson extends ILoadable { - - /** - * Sets the feature collection. - * - * @param collection The feature collection. - */ - public void setFeatures(FeatureCollection collection); - -} diff --git a/android/leafless/src/main/java/com/locoslab/capi/android/leafless/geojson/IGeojsonLoader.java b/android/leafless/src/main/java/com/locoslab/capi/android/leafless/geojson/IGeojsonLoader.java deleted file mode 100644 index 164bc48..0000000 --- a/android/leafless/src/main/java/com/locoslab/capi/android/leafless/geojson/IGeojsonLoader.java +++ /dev/null @@ -1,12 +0,0 @@ -package com.locoslab.capi.android.leafless.geojson; - -import com.locoslab.capi.android.leafless.ILoader; - -/** - * The interface for a geojson loader. - * - * @author Marcus - */ -public interface IGeojsonLoader extends ILoader { - -} diff --git a/android/leafless/src/main/java/com/locoslab/capi/android/leafless/icon/Icon.java b/android/leafless/src/main/java/com/locoslab/capi/android/leafless/icon/Icon.java deleted file mode 100644 index 3c6ed51..0000000 --- a/android/leafless/src/main/java/com/locoslab/capi/android/leafless/icon/Icon.java +++ /dev/null @@ -1,52 +0,0 @@ -package com.locoslab.capi.android.leafless.icon; - -/** - * An icon that should contain a regular image and can optionally contain a shadow image. - * - * @author Marcus - * - */ -public class Icon { - - /** - * The icon image. - */ - private IconImage iconImage; - - /** - * The (optional) shadow image. - */ - private IconImage shadowImage; - - /** - * Creates an icon with specific options. - * - * @param options The icon options. - */ - public Icon(IconOptions options) { - this.iconImage = new IconImage(options.iconUrl, options.iconSize, options.iconAnchor); - if (options.shadowUrl != null) { - this.shadowImage = new IconImage(options.shadowUrl, options.shadowSize, options.shadowAnchor); - } - } - - /** - * Returns the icon image. - * - * @return The icon image. - */ - public IconImage getIconImage() { - return iconImage; - } - - /** - * Returns the shadow image. - * - * @return The shadow image. - */ - public IconImage getShadowImage() { - return shadowImage; - } - - -} diff --git a/android/leafless/src/main/java/com/locoslab/capi/android/leafless/icon/IconImage.java b/android/leafless/src/main/java/com/locoslab/capi/android/leafless/icon/IconImage.java deleted file mode 100644 index 8a0fff8..0000000 --- a/android/leafless/src/main/java/com/locoslab/capi/android/leafless/icon/IconImage.java +++ /dev/null @@ -1,99 +0,0 @@ -package com.locoslab.capi.android.leafless.icon; - -import com.locoslab.capi.android.leafless.MapPoint; -import com.locoslab.capi.android.leafless.image.IImage; - -import android.graphics.Bitmap; - -/** - * An icon image that is used to represent the - * regular as well as the shadow image. The - * image can specify its size and an anchor point - * that will be used during drawing operations. - * - * @author Marcus - */ -public class IconImage implements IImage { - - /** - * The url where to load the image. - */ - private String url; - - /** - * The bitmap if loaded (may be null). - */ - private Bitmap bitmap; - - /** - * The size of the image to draw it. - * Images will be stretched or shrinked accordingly. - */ - private MapPoint size; - - /** - * The anchor point. - */ - private MapPoint anchor; - - /** - * Creates a new icon image that is loaded from a particular url. - * - * @param url The url. - * @param size The size of the image. - * @param anchor The anchor point. - */ - public IconImage(String url, MapPoint size, MapPoint anchor) { - this.url = url; - this.size = size; - this.anchor = anchor; - } - - @Override - public String getUrl() { - return url; - } - - /** - * Returns the bitmap, may be null - * while not loaded. - * - * @return The bitmap or null. - */ - public Bitmap getBitmap() { - return bitmap; - }; - - /** - * Returns the size. - * - * @return The size. - */ - public MapPoint getSize() { - return size; - } - - /** - * Returns the anchor point. - * - * @return The anchor point. - */ - public MapPoint getAnchor() { - return anchor; - } - - @Override - public void setBitmap(Bitmap bitmap) { - this.bitmap = bitmap; - if (bitmap != null) { - if (size.getX() < 0) { - size.setX(bitmap.getWidth()); - } - if (size.getY() < 0) { - size.setY(bitmap.getHeight()); - } - } - } - - -} diff --git a/android/leafless/src/main/java/com/locoslab/capi/android/leafless/icon/IconOptions.java b/android/leafless/src/main/java/com/locoslab/capi/android/leafless/icon/IconOptions.java deleted file mode 100644 index 5e560e2..0000000 --- a/android/leafless/src/main/java/com/locoslab/capi/android/leafless/icon/IconOptions.java +++ /dev/null @@ -1,65 +0,0 @@ -package com.locoslab.capi.android.leafless.icon; - -import com.locoslab.capi.android.leafless.MapPoint; - -/** - * The options for creating icons. - * - * @author Marcus - */ -public class IconOptions { - - /** - * (required) The URL to the icon image (absolute or relative to your script path). - */ - public String iconUrl; - - /** - * Size of the icon image in pixels. - */ - public MapPoint iconSize = new MapPoint(-1, -1); - - /** - * The coordinates of the "tip" of the icon (relative to its top left corner). The icon will be aligned so that this point is at the marker's geographical location. Centered by default if size is specified, also can be set in CSS with negative margins. - */ - public MapPoint iconAnchor = new MapPoint(0, 0); - - /** - * The URL to the icon shadow image. If not specified, no shadow image will be created. - */ - public String shadowUrl; - - /** - * Size of the shadow image in pixels. - */ - public MapPoint shadowSize = new MapPoint(-1, -1); - - /** - * The coordinates of the "tip" of the shadow (relative to its top left corner) (the same as iconAnchor if not specified). - */ - public MapPoint shadowAnchor = new MapPoint(0, 0); - - /** - * Creates new icon options with the specified icon url. - * - * @param iconUrl The icon url (required). - */ - public IconOptions(String iconUrl) { - this.iconUrl = iconUrl; - } - - /** - * Creates the icon options as a copy. - * - * @param copy The copy. - */ - public IconOptions(IconOptions copy) { - this.iconUrl = copy.iconUrl; - this.iconSize = copy.iconSize; - this.iconAnchor = copy.iconAnchor; - this.shadowUrl = copy.shadowUrl; - this.shadowSize = copy.shadowSize; - this.shadowAnchor = copy.shadowAnchor; - } - -} diff --git a/android/leafless/src/main/java/com/locoslab/capi/android/leafless/image/IImage.java b/android/leafless/src/main/java/com/locoslab/capi/android/leafless/image/IImage.java deleted file mode 100644 index 80f665e..0000000 --- a/android/leafless/src/main/java/com/locoslab/capi/android/leafless/image/IImage.java +++ /dev/null @@ -1,20 +0,0 @@ -package com.locoslab.capi.android.leafless.image; - -import android.graphics.Bitmap; -import com.locoslab.capi.android.leafless.ILoadable; - -/** - * An image to be displayed on the map. - * - * @author Marcus - */ -public interface IImage extends ILoadable { - - /** - * Sets the bitmap. - * - * @param bitmap The bitmap. - */ - public void setBitmap(Bitmap bitmap); - -} diff --git a/android/leafless/src/main/java/com/locoslab/capi/android/leafless/image/IImageLoader.java b/android/leafless/src/main/java/com/locoslab/capi/android/leafless/image/IImageLoader.java deleted file mode 100644 index 922ccd9..0000000 --- a/android/leafless/src/main/java/com/locoslab/capi/android/leafless/image/IImageLoader.java +++ /dev/null @@ -1,12 +0,0 @@ -package com.locoslab.capi.android.leafless.image; - -import com.locoslab.capi.android.leafless.ILoader; - -/** - * The interface for an image loader. - * - * @author Marcus - */ -public interface IImageLoader extends ILoader{ - -} diff --git a/android/leafless/src/main/java/com/locoslab/capi/android/leafless/image/ImageLoader.java b/android/leafless/src/main/java/com/locoslab/capi/android/leafless/image/ImageLoader.java deleted file mode 100644 index 85cbfee..0000000 --- a/android/leafless/src/main/java/com/locoslab/capi/android/leafless/image/ImageLoader.java +++ /dev/null @@ -1,147 +0,0 @@ -package com.locoslab.capi.android.leafless.image; - -import java.io.InputStream; - -import com.locoslab.capi.android.leafless.cache.CacheObjectLoader; -import com.locoslab.capi.android.leafless.cache.IObjectFactory; -import com.locoslab.capi.android.leafless.cache.IObjectRequest; - -import android.graphics.Bitmap; -import android.graphics.Bitmap.Config; -import android.graphics.BitmapFactory; -import android.graphics.Canvas; -import android.graphics.Color; -import android.graphics.Paint; -import android.graphics.Rect; - -/** - * A wrapper that enables the loading of map images via the - * cached object loader. - * - * @author Marcus - */ -public class ImageLoader implements IImageLoader { - - /** - * The factory to enable the loading of bitmaps. - */ - public static final IObjectFactory BITMAP_FACTORY = new IObjectFactory() { - - @Override - public Bitmap createObject(int code) { - Bitmap b = Bitmap.createBitmap(100, 100, Config.RGB_565); - Canvas c = new Canvas(b); - Paint p = new Paint(); - p.setStyle(Paint.Style.FILL); - p.setColor(Color.RED); - p.setTextSize(48f); - c.drawRect(new Rect(0, 0, 100, 100), p); - if (code >= 0) { - p.setColor(Color.BLACK); - float w = p.measureText(Integer.toString(code)); - c.drawText(Integer.toString(code), 50 - w / 2, 50 - p.ascent() / 2, p); - } - return b; - } - - @Override - public Bitmap createObject(String mimeType, byte[] bytes) { - return BitmapFactory.decodeByteArray(bytes, 0, bytes.length); - } - - @Override - public Bitmap createObject(String mimeType, InputStream input) { - return BitmapFactory.decodeStream(input); - } - - @Override - public String getMimeType() { - return "image/*"; - } - - }; - - /** - * A wrapper for map images. - * - * @author Marcus - */ - public static class ImageObjectRequest implements IObjectRequest { - - /** - * The map image to be loaded. - */ - private IImage image; - - /** - * Creates a new request for an image. - * - * @param image The image. - */ - public ImageObjectRequest(IImage image) { - this.image = image; - } - - @Override - public IObjectFactory getCreator() { - return BITMAP_FACTORY; - } - - @Override - public String getUrl() { - return image.getUrl(); - } - - @Override - public void onCompletion(Bitmap object) { - image.setBitmap(object); - } - - @Override - public int hashCode() { - return image.hashCode(); - } - - @Override - public boolean equals(Object obj) { - if (obj == null || obj.getClass() != getClass()) return false; - return ((ImageObjectRequest)obj).image == image; - } - } - - /** - * The object loader. - */ - private CacheObjectLoader loader; - - /** - * Creates a new image loader. - */ - public ImageLoader() { - super(); - } - - /** - * Sets the cached loader used as base. - * - * @param loader The loader. - */ - public void setLoader(CacheObjectLoader loader) { - this.loader = loader; - } - - @Override - public synchronized void requestObject(IImage image) { - if (loader != null) { - loader.requestObject(new ImageObjectRequest(image)); - } - } - - @Override - public synchronized void releaseObject(IImage image) { - if (loader != null) { - loader.releaseObject(new ImageObjectRequest(image)); - } - } - -} diff --git a/android/leafless/src/main/java/com/locoslab/capi/android/leafless/layer/AbstractLayer.java b/android/leafless/src/main/java/com/locoslab/capi/android/leafless/layer/AbstractLayer.java deleted file mode 100644 index f3b0678..0000000 --- a/android/leafless/src/main/java/com/locoslab/capi/android/leafless/layer/AbstractLayer.java +++ /dev/null @@ -1,41 +0,0 @@ -package com.locoslab.capi.android.leafless.layer; - -import com.locoslab.capi.android.leafless.AbstractElement; -import com.locoslab.capi.android.leafless.ILoader; -import com.locoslab.capi.android.leafless.cache.CacheObjectLoader; -import com.locoslab.capi.android.leafless.image.ImageLoader; - -/** - * An abstract base class for layers. - * - * @author Marcus - * - * @param The type of options of the layer. - */ -public abstract class AbstractLayer extends AbstractElement { - - /** - * The loader that is currently used. - */ - protected L loader; - - /** - * Creates a new map element with the specified options. - * - * @param options The options. - */ - public AbstractLayer(O options, L loader) { - super(options); - this.loader = loader; - } - - /** - * Sets or unsets the base loader to be used to load data for the layer. - * - * @param loader The loader to load data. - */ - public void setLoader(CacheObjectLoader loader) { - this.loader.setLoader(loader); - } - -} diff --git a/android/leafless/src/main/java/com/locoslab/capi/android/leafless/layer/LayerOptions.java b/android/leafless/src/main/java/com/locoslab/capi/android/leafless/layer/LayerOptions.java deleted file mode 100644 index 3d4bc13..0000000 --- a/android/leafless/src/main/java/com/locoslab/capi/android/leafless/layer/LayerOptions.java +++ /dev/null @@ -1,60 +0,0 @@ -package com.locoslab.capi.android.leafless.layer; - -import com.locoslab.api.data.maps.model.Box; -import com.locoslab.capi.android.leafless.ElementOptions; - -/** - * The options to create a tile layer. - * - * @author Marcus - */ -public class LayerOptions extends ElementOptions { - - /** - * The url pattern. - */ - public String url; - - /** - * Minimum zoom number. - */ - public int minZoom = 0; - - /** - * Maximum zoom number. - */ - public int maxZoom = 18; - - /** - * The zoom number used in tile URLs will be offset with this value. - */ - public int zoomOffset = 0; - - /** - * The bounds of the layer. - */ - public Box bounds = new Box(-180, -90, 180, 90); - - /** - * Creates new tile layer options with the url. - * - * @param url The url. - */ - public LayerOptions(String url) { - this.url = url; - } - - /** - * Copies the tile layer options. - * - * @param copy The options to copy. - */ - public LayerOptions(LayerOptions copy) { - super(copy); - this.url = copy.url; - this.minZoom = copy.minZoom; - this.maxZoom = copy.maxZoom; - this.zoomOffset = copy.zoomOffset; - this.bounds = new Box(copy.bounds.getMinimumLongitude(), copy.bounds.getMinimumLatitude(), copy.bounds.getMaximumLongitude(), copy.bounds.getMaximumLatitude()); - } -} diff --git a/android/leafless/src/main/java/com/locoslab/capi/android/leafless/marker/Marker.java b/android/leafless/src/main/java/com/locoslab/capi/android/leafless/marker/Marker.java deleted file mode 100644 index c777d65..0000000 --- a/android/leafless/src/main/java/com/locoslab/capi/android/leafless/marker/Marker.java +++ /dev/null @@ -1,253 +0,0 @@ -package com.locoslab.capi.android.leafless.marker; - -import com.locoslab.api.data.maps.model.Box; -import com.locoslab.api.data.maps.model.Coordinate; -import com.locoslab.capi.android.leafless.AbstractMovableElement; -import com.locoslab.capi.android.leafless.MapPoint; -import com.locoslab.capi.android.leafless.MapView; -import com.locoslab.capi.android.leafless.MapViewState; -import com.locoslab.capi.android.leafless.MoveEvent; -import com.locoslab.capi.android.leafless.TouchEvent; -import com.locoslab.capi.android.leafless.icon.Icon; -import com.locoslab.capi.android.leafless.icon.IconImage; - -import android.graphics.Bitmap; -import android.graphics.Canvas; -import android.graphics.Rect; - -/** - * A marker on the map. - * - * @author Marcus - */ -public class Marker extends AbstractMovableElement { - - /** - * The current coordinate. - */ - protected Coordinate coordinate = new Coordinate(); - - /** - * Creates a new marker with the specified options. - * - * @param options The options. - */ - public Marker(MarkerOptions options) { - super(new MarkerOptions(options)); - } - - /** - * Returns the current geographical position of the marker. - * - * @return The marker coordinate. This is a copy that can - * be freely modified. Changes will not be made in the - * actual position of the marker. - */ - public Coordinate getCoordinate() { - Coordinate c = new Coordinate(); - c.setLatitude(coordinate.getLatitude()); - c.setLongitude(coordinate.getLongitude()); - return c; - } - - /** - * Sets the latitude. - * - * @param latitude The latitude. - */ - public void setLatitude(double latitude) { - this.coordinate.setLatitude(latitude); - invalidate(); - } - - /** - * Sets the longitude. - * - * @param longitude The longitude. - */ - public void setLongitude(double longitude) { - this.coordinate.setLongitude(longitude); - invalidate(); - } - - /** - * Changes the marker position to the given point. - * - * @param coordinate The coordinates to change the marker position to. - */ - public void setCoordinate(Coordinate coordinate) { - this.coordinate.setLatitude(coordinate.getLatitude()); - this.coordinate.setLongitude(coordinate.getLongitude()); - invalidate(); - } - - /** - * Changes the marker icon. - * - * @param icon The icon to set. - */ - public void setIcon(Icon icon) { - this.options.icon = icon; - invalidate(); - } - - /** - * Returns the icon. - * - * @return The icon. - */ - public Icon getIcon() { - return this.options.icon; - } - - /** - * Changes the zIndex offset of the marker. - * - * @param offset The offset to set. - */ - public void setZIndexOffset(int offset) { - this.options.zIndexOffset = offset; - invalidate(); - } - - /** - * Returns the zindex offset. - * - * @return The zindex offset. - */ - public int getZIndexOffset() { - return this.options.zIndexOffset; - } - - /** - * Changes the opacity of the marker. - * - * @param opacity the opacity to set. - */ - public void setOpacity(double opacity) { - this.options.opacity = opacity; - invalidate(); - } - - /** - * Returns the opacity. - * - * @return The opacity. - */ - public double getOpacity() { - return this.options.opacity; - } - - @Override - public void drawObject(Canvas canvas) { - IconImage image = this.options.icon.getIconImage(); - if (image != null) { - drawImage(canvas, getMapViewState(), image); - } - } - - /** - * Draws the shadow of the object onto the canvas. During this call, - * the map view state will be accessible. - * - * @param canvas The canvas. - */ - public void drawShadow(Canvas canvas) { - IconImage image = this.options.icon.getShadowImage(); - if (image != null) { - drawImage(canvas, getMapViewState(), image); - } - } - - /** - * Draws the image accoring to the current settings. - * - * @param canvas The canvas. - * @param state The map state. - * @param image The image. - */ - protected void drawImage(Canvas canvas, MapViewState state, IconImage image) { - Bitmap b = image.getBitmap(); - if (b != null) { - canvas.save(); - float density = options.densityIndependent?1:state.getDensity(); - float[] xy = state.coordinateToPixel(coordinate.getLongitude(), coordinate.getLatitude()); - canvas.translate(xy[0] - (int)(image.getAnchor().getX() * density), xy[1] - (int)(image.getAnchor().getY() * density)); - Rect src = new Rect(0, 0, b.getWidth(), b.getHeight()); - int w = (int)(image.getSize().getX() * density); - if (w < 0) w = (int)(b.getWidth() * density); - int h = (int)(image.getSize().getY() * density); - if (h < 0) h = (int)(b.getHeight() * density); - Rect dest = new Rect(0, 0, w, h); - canvas.drawBitmap(b, src, dest, null); - canvas.restore(); - } - } - - @Override - public boolean contains(int x, int y) { - Rect region = getRegion(); - if (region != null) { - return (x >= region.left && x <= region.right && y >= region.top && y <= region.bottom); - } - return false; - } - - @Override - public Rect getRegion() { - MapViewState state = getMapViewState(); - if (state != null) { - float density = options.densityIndependent?1:state.getDensity(); - MapPoint size = options.icon.getIconImage().getSize(); - MapPoint anchor = options.icon.getIconImage().getAnchor(); - float[] xy = state.coordinateToPixel(coordinate.getLongitude(), coordinate.getLatitude()); - int left = (int)xy[0] - (int)(anchor.getX() * density); - int top = (int)xy[1] - (int)(anchor.getY() * density); - int right = left + (int)(size.getX() * density); - int bottom = top + (int)(size.getY() * density); - return new Rect(left, top, right, bottom); - } - return null; - } - - @Override - public void moveBy(int x, int y) { - MapView view = getMapView(); - MapViewState state = getMapViewState(); - if (view != null) { - float[] xy = state.coordinateToPixel(coordinate.getLongitude(), coordinate.getLatitude()); - double[] c = state.pixelToCoordinate(xy[0] + x, xy[1] + y); - Coordinate sc = new Coordinate(); - sc.setLatitude(coordinate.getLatitude()); - sc.setLongitude(coordinate.getLongitude()); - Coordinate tc = new Coordinate(); - tc.setLongitude(c[0]); - tc.setLatitude(c[1]); - setCoordinate(tc); - MapPoint sp = new MapPoint((int)xy[0], (int)xy[1]); - MapPoint tp = new MapPoint((int)xy[0] + x, (int)xy[1] + y); - MoveEvent event = new MoveEvent(view, sp, sc, tp, tc); - moveListeners.fireEvent(event); - } - } - - @Override - protected TouchEvent createTouch(int x, int y) { - MapView view = getMapView(); - if (view != null) { - Coordinate c = new Coordinate(); - c.setLatitude(coordinate.getLatitude()); - c.setLongitude(coordinate.getLongitude()); - return new TouchEvent(view, new MapPoint(x, y), c); - } else { - return null; - } - } - - @Override - public Box getBounds() { - return new Box(coordinate.getLongitude(), coordinate.getLatitude(), - coordinate.getLongitude(), coordinate.getLatitude()); - } - -} diff --git a/android/leafless/src/main/java/com/locoslab/capi/android/leafless/marker/MarkerOptions.java b/android/leafless/src/main/java/com/locoslab/capi/android/leafless/marker/MarkerOptions.java deleted file mode 100644 index 84ca91a..0000000 --- a/android/leafless/src/main/java/com/locoslab/capi/android/leafless/marker/MarkerOptions.java +++ /dev/null @@ -1,51 +0,0 @@ -package com.locoslab.capi.android.leafless.marker; - -import com.locoslab.capi.android.leafless.FixedElementOptions; -import com.locoslab.capi.android.leafless.icon.Icon; - -/** - * The options to create markers. - * - * @author Marcus - */ -public class MarkerOptions extends FixedElementOptions { - - /** - * Icon class to use for rendering the marker. See Icon documentation for details on how to customize the marker icon. - */ - public Icon icon; - - /** - * By default, marker images zIndex is set automatically based on its latitude. - * Use this option if you want to put the marker on top of all others (or below), - * specifying a high value like 1000 (or high negative value, respectively). - */ - public int zIndexOffset = 0; - - /** - * The opacity of the marker. - */ - public double opacity = 1.0; - - /** - * Creates a new marker options object with defaults. - * - * @param icon The icon. - */ - public MarkerOptions(Icon icon) { - this.icon = icon; - } - - /** - * Creates a new marker options object as a copy. - * - * @param copy The copy. - */ - public MarkerOptions(MarkerOptions copy) { - super(copy); - this.icon = copy.icon; - this.zIndexOffset = copy.zIndexOffset; - this.opacity = copy.opacity; - } - -} diff --git a/android/leafless/src/main/java/com/locoslab/capi/android/leafless/marker/RotatedMarker.java b/android/leafless/src/main/java/com/locoslab/capi/android/leafless/marker/RotatedMarker.java deleted file mode 100644 index 58a0b3f..0000000 --- a/android/leafless/src/main/java/com/locoslab/capi/android/leafless/marker/RotatedMarker.java +++ /dev/null @@ -1,145 +0,0 @@ -/** - * - */ -package com.locoslab.capi.android.leafless.marker; - -import com.locoslab.capi.android.leafless.InterimRotation; -import com.locoslab.capi.android.leafless.MapViewState; -import com.locoslab.capi.android.leafless.icon.IconImage; - -import android.graphics.Bitmap; -import android.graphics.Canvas; -import android.graphics.Rect; - -/** - * A marker that can be rotated. - * - * @author Marcus - */ -public class RotatedMarker extends Marker { - - /** - * The options for the marker. - */ - private RotatedMarkerOptions options; - - /** - * Creates a new marker with the specified options. - * - * @param options the options. - */ - public RotatedMarker(RotatedMarkerOptions options) { - super(options); - this.options = new RotatedMarkerOptions(options); - } - - /** - * Returns the current angle. - * - * @return The angle. - */ - public double getAngle() { - return options.angle; - } - - /** - * Sets the angle. - * - * @param angle The angle. - */ - public void setAngle(double angle) { - this.options.angle = angle; - invalidate(); - } - - /** - * Sets the angle to be relative or absolute. - * - * @param relative True for relative, false for absolute. - */ - public void setRelative(boolean relative) { - this.options.relative = relative; - invalidate(); - } - - /** - * Determines whether the angle is relative. - * - * @return True if relative, false if absolute. - */ - public boolean isRelative() { - return this.options.relative; - } - - /** - * Draws the image according to the current settings. - * - * @param canvas The canvas. - * @param state The map state. - * @param image The image. - */ - protected void drawImage(Canvas canvas, MapViewState state, IconImage image) { - Bitmap b = image.getBitmap(); - if (b != null) { - canvas.save(); - float[] xy = state.coordinateToPixel(coordinate.getLongitude(), coordinate.getLatitude()); - canvas.translate(xy[0], xy[1]); - canvas.rotate((float)(this.options.relative?this.options.angle:(this.options.angle + state.getAngle()))); - float density = options.densityIndependent?1:state.getDensity(); - int ax = (int)(image.getAnchor().getX() * density); - int ay = (int)(image.getAnchor().getY() * density); - Rect src = new Rect(0, 0, b.getWidth(), b.getHeight()); - int w = (int)(image.getSize().getX() * density); - if (w < 0) w = (int)(b.getWidth() * density); - int h = (int)(image.getSize().getY() * density); - if (h < 0) h = (int)(b.getHeight() * density); - Rect dest = new Rect(-ax, -ay, w - ax, h - ay); - canvas.drawBitmap(b, src, dest, null); - canvas.restore(); - } - } - - @Override - public boolean contains(int x, int y) { - MapViewState state = getMapViewState(); - if (state != null) { - // rotate the point around the anchor in the inverse direction to reuse the logic in the base class - float[] xy = state.coordinateToPixel(coordinate.getLongitude(), coordinate.getLatitude()); - InterimRotation r = getRotation(state); - float[] n = r.rotateForward(new float[] { x, y }, xy); - return super.contains((int)(n[0]), (int)(n[1])); - } - return false; - } - - /** - * Returns the interrim rotation for the marker. - * - * @param state The map view state. - * @return The rotation constants for the marker. - */ - private InterimRotation getRotation(MapViewState state) { - return new InterimRotation(-(this.options.relative?this.options.angle:(this.options.angle + state.getAngle()))); - } - - @Override - public Rect getRegion() { - MapViewState state = getMapViewState(); - Rect region = super.getRegion(); - if (state != null && region != null) { - float[] xy = state.coordinateToPixel(coordinate.getLongitude(), coordinate.getLatitude()); - InterimRotation r = getRotation(state); - float[] a = r.rotateForward(new float[] { region.left, region.top }, xy); - float[] b = r.rotateForward(new float[] { region.left, region.bottom }, xy); - float[] c = r.rotateForward(new float[] { region.right, region.top }, xy); - float[] d = r.rotateForward(new float[] { region.right, region.bottom }, xy); - float left = Math.min(a[0], Math.min(b[0], Math.min(c[0], d[0]))); - float top = Math.min(a[1], Math.min(b[1], Math.min(c[1], d[1]))); - float right = Math.max(a[0], Math.max(b[0], Math.max(c[0], d[0]))); - float bottom = Math.max(a[1], Math.max(b[1], Math.max(c[1], d[1]))); - return new Rect((int)left, (int)top, (int)right, (int) bottom); - } - return null; - } - -} diff --git a/android/leafless/src/main/java/com/locoslab/capi/android/leafless/marker/RotatedMarkerOptions.java b/android/leafless/src/main/java/com/locoslab/capi/android/leafless/marker/RotatedMarkerOptions.java deleted file mode 100644 index bfeb78b..0000000 --- a/android/leafless/src/main/java/com/locoslab/capi/android/leafless/marker/RotatedMarkerOptions.java +++ /dev/null @@ -1,46 +0,0 @@ -package com.locoslab.capi.android.leafless.marker; - -import com.locoslab.capi.android.leafless.icon.Icon; - -/** - * The options for rotated markers. - * - * @author Marcus - */ -public class RotatedMarkerOptions extends MarkerOptions { - - /** - * A flag indicating whether the angle is relative or - * absolute. If it is relative, the angle will not be - * changed by rotations in the underlying map. If it - * is absolute, the angle will be corrected during the - * drawing such that 0 faces north. - */ - public boolean relative = true; - - /** - * The angle in degrees. - */ - public double angle = 0; - - /** - * Creates rotated maker options with a particular icon. - * - * @param icon The marker icon. - */ - public RotatedMarkerOptions(Icon icon) { - super(icon); - } - - /** - * Creates rotated marker options copied from the copy. - * - * @param copy The blueprint to copy from. - */ - public RotatedMarkerOptions(RotatedMarkerOptions copy) { - super(copy); - this.angle = copy.angle; - this.relative = copy.relative; - } - -} diff --git a/android/leafless/src/main/java/com/locoslab/capi/android/leafless/polyline/Polyline.java b/android/leafless/src/main/java/com/locoslab/capi/android/leafless/polyline/Polyline.java deleted file mode 100644 index 4ca516b..0000000 --- a/android/leafless/src/main/java/com/locoslab/capi/android/leafless/polyline/Polyline.java +++ /dev/null @@ -1,186 +0,0 @@ -package com.locoslab.capi.android.leafless.polyline; - -import java.util.ArrayList; -import java.util.List; - -import com.locoslab.api.data.maps.model.Box; -import com.locoslab.api.data.maps.model.Coordinate; -import com.locoslab.api.data.maps.util.Coordinates; -import com.locoslab.api.data.maps.util.Polylines; -import com.locoslab.capi.android.leafless.AbstractElement; -import com.locoslab.capi.android.leafless.MapViewState; - -import android.graphics.Canvas; -import android.graphics.Paint; -import android.graphics.Path; -import android.graphics.Rect; -import android.graphics.RectF; - -/** - * A polyline that draws itself onto the map. - * - * @author Marcus - * - */ -public class Polyline extends AbstractElement { - - /** - * The original coordinates (zoom level 15 and up) - */ - private List coordinatesHigh = new ArrayList<>(); - - /** - * The medium detailed coordinates (zoom level 11 to 14). - */ - private List coordinatesMedium; - - /** - * The low detailed coordinates (zoom level <= 10). - */ - private List coordinatesLow; - - /** - * The bounds. - */ - private Box bounds; - - /** - * Creates a new polyline. - * - * @param coordinates The coordinates. - * @param options The options. - */ - public Polyline(List coordinates, PolylineOptions options) { - super(new PolylineOptions(options)); - this.bounds = new Box(coordinates); - this.coordinatesHigh.addAll(coordinates); - } - - /** - * Returns the paint to draw the line. - * - * @param state The map view state. - * @return The paint to draw. - */ - private Paint getPaint(MapViewState state) { - Paint p = options.linePaint; - p = new Paint(p); - float density = options.densityIndependent?1:state.getDensity(); - p.setStrokeWidth((float)(p.getStrokeWidth() * density * state.getScale())); - return p; - } - - /** - * Returns the coordinates simplified for a particular zoom level. - * - * @param state The state. - * @return The list of coordinates. - */ - private List getCoordinates(MapViewState state) { - if (state.getZoom() > 14) { - return coordinatesHigh; - } else if (state.getZoom() > 10) { - if (coordinatesMedium == null) { - this.coordinatesMedium = Polylines.simplify(coordinatesHigh, 25); - } - return coordinatesMedium; - } else { - if (coordinatesLow == null) { - this.coordinatesLow = Polylines.simplify(coordinatesHigh, 250); - } - return coordinatesLow; - } - } - - @Override - public boolean contains(int x, int y) { - MapViewState state = getMapViewState(); - if (state != null) { - Paint p = getPaint(state); - List cs = getCoordinates(state); - float maxDistance = (p.getStrokeWidth()) * (p.getStrokeWidth()); - double[] lnglat = state.pixelToCoordinate(x, y); - Coordinate search = new Coordinate(); - search.setLatitude(lnglat[1]); - search.setLongitude(lnglat[0]); - for (int i = 1; i < cs.size(); i++) { - Coordinate next = Coordinates.closestPointOnLine(cs.get(i - 1), cs.get(i), search); - float[] xy = state.coordinateToPixel(next.getLongitude(), next.getLatitude()); - float dx = xy[0] - x; - float dy = xy[1] - y; - if ((dx * dx + dy * dy) < maxDistance) { - return true; - } - } - } - return false; - } - - - @Override - public void drawObject(Canvas canvas) { - MapViewState state = getMapViewState(); - - Path path = getPath(state); - if (options.fillPaint != null) { - canvas.drawPath(path, options.fillPaint); - } - if (options.linePaint != null) { - Paint paint = getPaint(state); - canvas.drawPath(path, paint); - } - } - - /** - * Computes the path that we need to draw. - * - * @param state The state. - * @return The path. - */ - private Path getPath(MapViewState state) { - List coordinates = getCoordinates(state); - Path path = new Path(); - float[] pos = null; // current drawing position - float[] prev = null; // previous decoded point - for (int i = 0; i < coordinates.size(); i++) { - Coordinate c = coordinates.get(i); - float[] next = state.coordinateToPixel(c.getLongitude(), c.getLatitude()); - if (prev != null) { - float[] line = PolylineClipper.clip(0, 0, state.getPixelWidth(), state.getPixelHeight(), prev[0], prev[1], next[0], next[1]); - if (line != null) { - if (pos == null || pos[0] != line[0] || pos[1] != line[1]) { - path.moveTo(line[0], line[1]); - pos = new float[2]; - } - path.lineTo(line[2], line[3]); - pos[0] = line[2]; - pos[1] = line[3]; - } - } - prev = next; - } - return path; - } - - @Override - public Box getBounds() { - return bounds; - } - - @Override - public Rect getRegion() { - MapViewState state = getMapViewState(); - if (state != null) { - Path p = getPath(state); - Paint paint = getPaint(state); - RectF bounds = new RectF(); - p.computeBounds(bounds, true); - int width = Math.max(1, (int)paint.getStrokeWidth() / 2); - return new Rect((int)bounds.left - width, (int)bounds.top - width, (int)bounds.right + width, (int)bounds.bottom + width); - } - return null; - } - - - -} diff --git a/android/leafless/src/main/java/com/locoslab/capi/android/leafless/polyline/PolylineClipper.java b/android/leafless/src/main/java/com/locoslab/capi/android/leafless/polyline/PolylineClipper.java deleted file mode 100644 index 88ead5d..0000000 --- a/android/leafless/src/main/java/com/locoslab/capi/android/leafless/polyline/PolylineClipper.java +++ /dev/null @@ -1,125 +0,0 @@ -package com.locoslab.capi.android.leafless.polyline; - -/** - * A line clipper algorithm that can be used to clip a line - * with a rectangle. This is an implementation of the - * Cohen-Sutherland line clipping algorithm for rectangles - * (see http://en.wikipedia.org/wiki/Cohen-Sutherland). - * - * @author Marcus - */ -public class PolylineClipper { - - /** - * The quadrant definitions. - */ - public static final int INSIDE = 0; - /** - * We are left from the clipping region. - */ - public static final int LEFT = 1; - /** - * We are right from the clipping region. - */ - public static final int RIGHT = 2; - /** - * We are below the clipping region. - */ - public static final int BOTTOM = 4; - /** - * We are above the clipping region. - */ - public static final int TOP = 8; - - /** - * Computes the quadrant code for a given coordinate - * and a clipping rectangle. - * - * @param minX The minimum x of the clipping rectangle. - * @param maxX The maximum x of the clipping rectangle. - * @param minY The minimum y of the clipping rectangle. - * @param maxY The maximum y of the clipping rectangle. - * @param x The x coordinate. - * @param y The y coordinate. - * @return The computed code which defines the quadrant - * in which the point is lying. - */ - public static int getQuadrant(float minX, float minY, float maxX, float maxY, float x, float y) { - int code = INSIDE; - if (x < minX) { - code |= LEFT; - } else if (x > maxX) { - code |= RIGHT; - } - if (y < minY) { - code |= BOTTOM; - } else if (y > maxY) { - code |= TOP; - } - return code; - } - - /** - * Execute line clipping using Cohen-Sutherland algorithm from - * http://en.wikipedia.org/wiki/Cohen-Sutherland - * - * @param minX The minimum x of the clipping rectangle. - * @param maxX The maximum x of the clipping rectangle. - * @param minY The minimum y of the clipping rectangle. - * @param maxY The maximum y of the clipping rectangle. - * @param x0 The x coordinate of the first point. - * @param y0 The y coordinate of the first point. - * @param x1 The x coordinate of the second point. - * @param y1 The y coordinate of the second point. - * @return The segment of the line inside the clipping region or - * null, if the line lies completely outside of the clipping region. - * If not null, the resulting array will contain x0, y0, x1, y1 in - * this order. - */ - public static float[] clip(float minX, float minY, float maxX, float maxY, float x0, float y0, float x1, float y1) { - int outCode0 = getQuadrant(minX, minY, maxX, maxY, x0, y0); - int outCode1 = getQuadrant(minX, minY, maxX, maxY, x1, y1); - boolean accept = false; - while (true) { - if ((outCode0 | outCode1) == 0) { // everything inside - accept = true; - break; - } else if ((outCode0 & outCode1) != 0) { // everything outside - break; - } else { - float x, y; - // pick at least one point outside rectangle - int outCodeOut = (outCode0 != 0) ? outCode0 : outCode1; - // find the intersection point; - if ((outCodeOut & TOP) != 0) { - x = x0 + (x1 - x0) * (maxY - y0) / (y1 - y0); - y = maxY; - } else if ((outCodeOut & BOTTOM) != 0) { - x = x0 + (x1 - x0) * (minY - y0) / (y1 - y0); - y = minY; - } else if ((outCodeOut & RIGHT) != 0) { - y = y0 + (y1 - y0) * (maxX - x0) / (x1 - x0); - x = maxX; - } else { - y = y0 + (y1 - y0) * (minX - x0) / (x1 - x0); - x = minX; - } - // move outside point to intersection point to clip - if (outCodeOut == outCode0) { - x0 = x; - y0 = y; - outCode0 = getQuadrant(minX, minY, maxX, maxY, x0, y0); - } else { - x1 = x; - y1 = y; - outCode1 = getQuadrant(minX, minY, maxX, maxY, x1, y1); - } - } - } - if (accept) { - return new float[] { x0, y0, x1, y1 }; - } - return null; - } - -} \ No newline at end of file diff --git a/android/leafless/src/main/java/com/locoslab/capi/android/leafless/polyline/PolylineOptions.java b/android/leafless/src/main/java/com/locoslab/capi/android/leafless/polyline/PolylineOptions.java deleted file mode 100644 index 4fc358a..0000000 --- a/android/leafless/src/main/java/com/locoslab/capi/android/leafless/polyline/PolylineOptions.java +++ /dev/null @@ -1,67 +0,0 @@ -package com.locoslab.capi.android.leafless.polyline; - -import com.locoslab.capi.android.leafless.FixedElementOptions; - -import android.graphics.Color; -import android.graphics.Paint; -import android.graphics.Paint.Join; -import android.graphics.Paint.Style; - -/** - * The polyline options used to construct shapes. - * - * @author Marcus - */ -public class PolylineOptions extends FixedElementOptions { - - /** - * The paint that we use, if none is specified. - */ - private static final Paint DEFAULT_PAINT = new Paint(); - - static { - DEFAULT_PAINT.setColor(Color.BLUE); - DEFAULT_PAINT.setStrokeWidth(5); - DEFAULT_PAINT.setStrokeMiter(4); - DEFAULT_PAINT.setStrokeJoin(Join.ROUND); - DEFAULT_PAINT.setStyle(Style.STROKE); - DEFAULT_PAINT.setAlpha(128); - } - - /** - * The line paint which is used to configure - * the color, stroking, etc. Set to null, to - * not draw the outline at all. - */ - public Paint linePaint = new Paint(DEFAULT_PAINT); - - /** - * The fill paint which is used to fill the - * polyline, if it actually represents a polygon. - * Set to null, to not fill it. - */ - public Paint fillPaint; - - /** - * Creates new polyline options. - */ - public PolylineOptions() { - super(); - } - - /** - * Creates polyline options by copying the passed ones. - * - * @param options The options to copy. - */ - public PolylineOptions(PolylineOptions options) { - super(options); - if (options.linePaint != null) { - linePaint = new Paint(options.linePaint); - } - if (options.fillPaint != null) { - fillPaint = new Paint(options.fillPaint); - } - } - -} diff --git a/android/leafless/src/main/java/com/locoslab/capi/android/leafless/tile/TileImage.java b/android/leafless/src/main/java/com/locoslab/capi/android/leafless/tile/TileImage.java deleted file mode 100644 index 41ef7f7..0000000 --- a/android/leafless/src/main/java/com/locoslab/capi/android/leafless/tile/TileImage.java +++ /dev/null @@ -1,159 +0,0 @@ -package com.locoslab.capi.android.leafless.tile; - -import com.locoslab.capi.android.leafless.image.IImage; - -import android.graphics.Bitmap; -import android.graphics.Canvas; -import android.graphics.Color; -import android.graphics.Paint; -import android.graphics.Rect; - -/** - * An image that is used for a single tile in a tile layer. - * - * @author Marcus - */ -public class TileImage implements IImage { - - /** - * A black paint. - */ - public static final Paint BLACK = new Paint(); - - /** - * A white paint. - */ - public static final Paint WHITE = new Paint(); - - static { - BLACK.setColor(Color.BLACK); - BLACK.setTextSize(26f); - BLACK.setStyle(Paint.Style.STROKE); - WHITE.setColor(Color.WHITE); - WHITE.setStyle(Paint.Style.FILL); - } - - /** - * The x index of the tile. - */ - private int x; - /** - * The y index of the tile. - */ - private int y; - /** - * The z index of the tile. - */ - private int z; - - /** - * The url where the tile is coming from. - */ - private String url; - - /** - * The bitmap of the tile which may be null - * while the tile is loaded. - */ - private Bitmap bitmap; - - /** - * The source rectangle. - */ - private Rect sourceRectangle = new Rect(); - - /** - * Creates a new tile image. - * - * @param url The url. - * @param x The x index. - * @param y The y index - * @param z The z index. - */ - public TileImage(String url, int x, int y, int z) { - this.url = url; - this.x = x; - this.y = y; - this.z = z; - } - - /** - * Returns the url. - * - * @return The url to load the tile. - */ - public String getUrl() { - return url; - } - - /** - * The x index. - * - * @return The x index. - */ - public int getX() { - return x; - } - - /** - * The y index. - * - * @return The y index. - */ - public int getY() { - return y; - } - - /** - * The z index. - * - * @return The z index. - */ - public int getZ() { - return z; - } - - /** - * Sets the bitmap to be drawn. - * - * @param bitmap The bitmap. - */ - public void setBitmap(Bitmap bitmap) { - this.bitmap = bitmap; - if (bitmap != null) { - this.sourceRectangle.left = 0; - this.sourceRectangle.top = 0; - this.sourceRectangle.right = bitmap.getWidth(); - this.sourceRectangle.bottom = bitmap.getHeight(); - } - } - - /** - * Returns the bitmap to be drawn. - * - * @return The bitmpa. - */ - public Bitmap getBitmap() { - return bitmap; - } - - /** - * Draws the image onto the canvas. If the image has not been - * loaded yet, this will draw the tile indexes. - * - * @param canvas The canvas. - */ - public void drawObject(Canvas canvas, Rect target) { - if (bitmap == null) { - canvas.drawRect(target, WHITE); - canvas.drawRect(target, BLACK); - char[] chars = (z + "," + x + "," + y).toCharArray(); - BLACK.getTextBounds(chars, 0, chars.length, sourceRectangle); - canvas.drawText(chars, 0, chars.length, (target.right - sourceRectangle.right) / 2 , target.bottom / 2, BLACK); - } else { - canvas.drawBitmap(bitmap, sourceRectangle, target, null); - } - } - - -} diff --git a/android/leafless/src/main/java/com/locoslab/capi/android/leafless/tile/TileLayer.java b/android/leafless/src/main/java/com/locoslab/capi/android/leafless/tile/TileLayer.java deleted file mode 100644 index cf579b8..0000000 --- a/android/leafless/src/main/java/com/locoslab/capi/android/leafless/tile/TileLayer.java +++ /dev/null @@ -1,152 +0,0 @@ -package com.locoslab.capi.android.leafless.tile; - -import java.util.ArrayList; -import java.util.List; - -import com.locoslab.api.data.carta.tile.Tile; -import com.locoslab.api.data.carta.tile.Tiles; -import com.locoslab.api.data.maps.model.Box; -import com.locoslab.api.data.maps.model.Coordinate; -import com.locoslab.capi.android.leafless.MapViewState; -import com.locoslab.capi.android.leafless.image.IImageLoader; -import com.locoslab.capi.android.leafless.image.ImageLoader; -import com.locoslab.capi.android.leafless.layer.AbstractLayer; - -import android.graphics.Canvas; -import android.graphics.Rect; - -/** - * Implements a tile layer. - * - * @author Marcus - */ -public class TileLayer extends AbstractLayer { - - /** - * The tile images. - */ - private List images = new ArrayList<>(); - - /** - * Creates a tile layer with the specified options. - * - * @param options The tile layer options. - */ - public TileLayer(TileLayerOptions options) { - super(new TileLayerOptions(options), new ImageLoader()); - } - - @Override - public Box getBounds() { - return options.bounds; - } - - @Override - public boolean contains(int x, int y) { - MapViewState state = getMapViewState(); - if (state != null) { - if (state.getZoom() >= options.minZoom && state.getZoom() <= options.maxZoom) { - return super.contains(x, y); - } - } - return false; - } - - @Override - public void drawObject(Canvas canvas) { - MapViewState state = getMapViewState(); - int pixels = (int)(256 * state.getDensity()); - int zoom = state.getZoom(); - List cache = new ArrayList<>(); - if (zoom >= options.minZoom && zoom <= options.maxZoom) { - canvas.save(); - canvas.translate(state.getPixelCenterX(), state.getPixelCenterY()); - canvas.scale((float)state.getScale(), (float)state.getScale()); - canvas.rotate((float)state.getAngle()); - Box viewport = state.getViewport(); - Box bounds = getBounds(); - Box region = new Box(Math.max(viewport.getMinimumLongitude(), bounds.getMinimumLongitude()), - Math.max(viewport.getMinimumLatitude(), bounds.getMinimumLatitude()), - Math.min(viewport.getMaximumLongitude(), bounds.getMaximumLongitude()), - Math.min(viewport.getMaximumLatitude(), bounds.getMaximumLatitude())); - Tile topLeft = Tiles.getTile(region.getMinimumLongitude(), region.getMaximumLatitude(), zoom); - Tile bottomRight = Tiles.getTile(region.getMaximumLongitude(), region.getMinimumLatitude(), zoom); - double[] offset = getOffset(state, Tiles.getNorthWest(topLeft)); - canvas.translate((float)offset[0], (float)offset[1]); - Rect target = new Rect(0, 0, pixels, pixels); - for (int j = topLeft.getY(); j <= bottomRight.getY(); j++) { - for (int i = topLeft.getX(); i <= bottomRight.getX(); i++) { - TileImage image = removeImage(i, j, zoom); - image.drawObject(canvas, target); - canvas.translate(pixels, 0); - cache.add(image); - } - canvas.translate(-(bottomRight.getX() - topLeft.getX() + 1) * pixels, pixels); - } - canvas.restore(); - } - for (TileImage image: images) { - if (loader != null) { - loader.releaseObject(image); - } - } - images = cache; - } - - /** - * Computes the offset of the coordinate. - * - * @param state The state. - * @param c The coordinate. - * @return The offset. - */ - private double[] getOffset(MapViewState state, Coordinate c) { - Coordinate viewCenter = state.getCenter(); - double[] center = state.getProjection().project(viewCenter.getLongitude(), viewCenter.getLatitude()); - double[] point = state.getProjection().project(c.getLongitude(), c.getLatitude()); - double numberOfPixels = 256 * state.getDensity() * (1 << state.getZoom()); - double cx = center[0] * numberOfPixels; - double cy = center[1] * numberOfPixels; - double px = point[0] * numberOfPixels; - double py = point[1] * numberOfPixels; - return new double[] { px - cx, py - cy }; - } - - /** - * Requests a tile to be loaded. - * - * @param x The x-coordinate of the tile. - * @param y The y-coordinate of the tile. - * @param z The zoom level of the tile. - * @return The tile (which may or may not be loaded). - */ - private TileImage removeImage(int x, int y, int z) { - for (int i = 0; i < images.size(); i++) { - TileImage image = images.get(i); - if (image.getX() == x && image.getY() == y && image.getZ() == z) { - return images.remove(i); - } - } - TileImage image = new TileImage(getUrl(x, y, z), x, y, z); - if (loader != null) { - loader.requestObject(image); - } - return image; - } - - /** - * Computes the url for a tile. - * - * @param x The x-coordinate of the tile. - * @param y The y-coordinate of the tile. - * @param z The zoom level of the tile. - * @return The url for the tile. - */ - private String getUrl(int x, int y, int z) { - String r = options.url.replace("{x}", Integer.toString(x)); - r = r.replace("{y}", Integer.toString(y)); - r = r.replace("{z}", Integer.toString(z + options.zoomOffset)); - return r; - } - -} diff --git a/android/leafless/src/main/java/com/locoslab/capi/android/leafless/tile/TileLayerOptions.java b/android/leafless/src/main/java/com/locoslab/capi/android/leafless/tile/TileLayerOptions.java deleted file mode 100644 index 83050b8..0000000 --- a/android/leafless/src/main/java/com/locoslab/capi/android/leafless/tile/TileLayerOptions.java +++ /dev/null @@ -1,29 +0,0 @@ -package com.locoslab.capi.android.leafless.tile; - -import com.locoslab.capi.android.leafless.layer.LayerOptions; - -/** - * The options to create a tile layer. - * - * @author Marcus - */ -public class TileLayerOptions extends LayerOptions { - - /** - * Creates new tile layer options with the url. - * - * @param url The url. - */ - public TileLayerOptions(String url) { - super(url); - } - - /** - * Copies the tile layer options. - * - * @param copy The options to copy. - */ - public TileLayerOptions(TileLayerOptions copy) { - super(copy); - } -} diff --git a/android/leafless/src/main/java/com/locoslab/capi/android/leafless/touch/BasicRecognizer.java b/android/leafless/src/main/java/com/locoslab/capi/android/leafless/touch/BasicRecognizer.java deleted file mode 100644 index 2369ecc..0000000 --- a/android/leafless/src/main/java/com/locoslab/capi/android/leafless/touch/BasicRecognizer.java +++ /dev/null @@ -1,408 +0,0 @@ -package com.locoslab.capi.android.leafless.touch; - -import java.lang.annotation.Target; -import java.util.ArrayList; -import java.util.List; - -import android.annotation.TargetApi; -import android.view.MotionEvent; -import android.view.ViewConfiguration; - -/** - * A touch recognizer for map views. - * - * @author Marcus - */ -@TargetApi(8) -public class BasicRecognizer implements IRecognizer { - - /** - * The view configuration. - */ - private ViewConfiguration configuration; - - /** - * The map view to which we attach. - */ - private IBasicView view; - - /** - * The list of pointers that we can handle but - * that is currently not touching the screen. - */ - private List passive = new ArrayList<>(); - - /** - * The list of active pointers that have touched - * the strean. - */ - private List active = new ArrayList<>(); - - /** - * The scale that we have applied already. - */ - private double scale = 0; - /** - * The angle change that we have applied already. - */ - private double angle = 0; - /** - * The movement applied already. - */ - private int[] move = new int[2]; - /** - * The current movable, if there is one. - */ - private IMovableTarget movable; - - /** - * The slop to avoid issuing move on tap. - */ - private final float slopSquare; - - /** - * The timeout after which a short press becomes a long press. - */ - private final long longPressTimeout; - - /** - * Creates a new gesture recognizer for the specified view. - * - * @param view The view. - */ - public BasicRecognizer(IBasicView view) { - this.configuration = ViewConfiguration.get(view.getContext()); - this.view = view; - this.passive.add(new Pointer()); - this.passive.add(new Pointer()); - slopSquare = this.configuration.getScaledTouchSlop(); - longPressTimeout = ViewConfiguration.getLongPressTimeout(); - } - - /** - * Called when a new motion event occurs. - * - * @param event The event. - * @return Always true, since we consume it. - */ - @Override - public boolean onEvent(MotionEvent event) { - int action = event.getActionMasked(); - int pointerCount = event.getPointerCount(); - int index = event.getActionIndex(); - int id = event.getPointerId(index); - switch (action) { - case MotionEvent.ACTION_DOWN: - case MotionEvent.ACTION_POINTER_DOWN: - resetGesture(); - resetPointers(); - Pointer d = activatePointer(id, event.getX(index), event.getY(index), event.getEventTime()); - if (d != null && active.size() == 1) { - movable = view.getMovable((int)event.getX(index), (int)event.getY(index)); - } - break; - case MotionEvent.ACTION_MOVE: - int historySize = event.getHistorySize(); - for (int h = 0; h < historySize; h++) { - for (int i = 0; i < pointerCount; i++) { - int hid = event.getPointerId(i); - float hx = event.getHistoricalX(i, h); - float hy = event.getHistoricalY(i, h); - long htime = event.getHistoricalEventTime(h); - updatePointer(hid, hx, hy, htime); - } - } - updatePointer(id, event.getX(index), event.getY(index), event.getEventTime()); - if (active.size() > 1) { - onTwist(); - } else if (active.size() > 0) { - onMove(); - } - break; - case MotionEvent.ACTION_CANCEL: - case MotionEvent.ACTION_UP: - case MotionEvent.ACTION_POINTER_UP: - Pointer p = updatePointer(id, event.getX(index), event.getY(index), event.getEventTime()); - if (p != null) { - if (action != MotionEvent.ACTION_CANCEL) { - if (active.size() > 1) { - onTwist(); - } else if (active.size() > 0){ - onRelease(); - } - } - deactivatePointer(id); - resetPointers(); - resetGesture(); - } - break; - default: - break; - } - return true; - } - - /** - * Called when a two finger move is detected. - */ - private void onTwist() { - Pointer p1 = active.get(0); - Pointer p2 = active.get(1); - if (p1.distance > slopSquare || p2.distance > slopSquare) { - // scale the view - double dstart = Math.max(1, distance(p1.startXY, p2.startXY)); - double dlast = Math.max(1, distance(p1.lastXY, p2.lastXY)); - double scale = 0; - if (dstart > dlast) scale = 1 - dstart / dlast; - else scale = dlast / dstart - 1; - double dscale = scale - this.scale; - if (Math.abs(dscale) > 0.02) { - this.scale = scale; - view.scaleBy(dscale / 2); - } - // rotate the view - double astart = angle(p1.startXY, p2.startXY); - double aend = angle(p1.lastXY, p2.lastXY); - double adelta = aend - astart; - double da = adelta - this.angle; - if (Math.abs(da) > 0.25) { - this.angle = adelta; - view.rotateBy(da); - } - } - } - - /** - * Called when a one finger move is detected. - */ - private void onMove() { - Pointer p1 = active.get(0); - if (movable != null && p1.distance > slopSquare) { - float dx = p1.lastXY[0] - p1.startXY[0] - move[0]; - float dy = p1.lastXY[1] - p1.startXY[1] - move[1]; - int x = (int)dx; - int y = (int)dy; - move[0] += dx; - move[1] += dy; - movable.moveBy(x, y); - } - } - - /** - * Called when a tap is detected. - */ - private void onRelease() { - Pointer p1 = active.get(0); - long time = p1.lastTime - p1.startTime; - if (p1.distance < slopSquare) { - if (p1.alone) { - int x = (int)p1.startXY[0]; - int y = (int)p1.startXY[1]; - if (time < longPressTimeout) { - view.shortTap(x, y); - } else { - view.longTap(x, y); - } - } else { - Pointer p2 = lastPointer(); - if (p2 != null && p2.distance < slopSquare) { - if (p1.lastTime - p2.lastTime < 100 && Math.abs(p1.startTime - p2.startTime) < 100) { - int x1 = (int)p1.startXY[0]; - int y1 = (int)p1.startXY[1]; - int x2 = (int)p2.startXY[0]; - int y2 = (int)p2.startXY[1]; - if (Math.min(p1.lastTime, p2.lastTime) - Math.max(p1.startTime, p2.startTime) < longPressTimeout) { - view.shortTwoTap(x1, y1, x2, y2); - } else { - view.longTwoTap(x1, y1, x2, y2); - } - } - } - } - } - } - - /** - * Resets the internal state. - */ - private void resetGesture() { - this.angle = 0; - this.scale = 0; - this.move[0] = 0; - this.move[1] = 0; - this.movable = null; - } - - /** - * Returns an existing active pointer that is - * currently touching the screen or null. - * - * @param id The id. - * @return The pointer or null, if this id is ignored - * or has not touched. - */ - private Pointer getPointer(int id) { - for (int i = active.size() - 1; i >= 0; i--) { - Pointer p = active.get(i); - if (p.id == id) { - return p; - } - } - return null; - } - - /** - * Activates a passive pointer, if there is one - * available and initializes the values and returns - * the pointer. - * - * @param id The id. - * @param x The x coordinate. - * @param y The y coordinate. - * @return The pointer or null, if there are already - * enough pointers on the screen. - */ - private Pointer activatePointer(int id, float x, float y, long time) { - if (passive.size() > 0) { - Pointer p = passive.remove(0); - p.id = id; - p.startXY[0] = x; - p.lastXY[0] = x; - p.startXY[1] = y; - p.lastXY[1] = y; - p.startTime = time; - p.lastTime = time; - p.distance = 0; - active.add(p); - for (int i = active.size() - 1; i >= 0; i--) { - Pointer a = active.get(i); - a.alone = active.size() <= 1; - } - return p; - } - return null; - } - - /** - * Returns the last pointer that left the surface. - * - * @return The last released pointer. - */ - private Pointer lastPointer() { - Pointer result = null; - for (int i = passive.size() - 1; i >= 0; i--) { - Pointer next = passive.get(i); - if (result == null || result.lastTime < next.lastTime) { - result = next; - } - } - return result; - } - - - /** - * Deactivates the specified pointer. - * - * @param id The id of the pointer. - * @return The deactivated pointer or null. - */ - private Pointer deactivatePointer(int id) { - for (int i = active.size() - 1; i >= 0; i--) { - Pointer p = active.get(i); - if (p.id == id) { - active.remove(i); - passive.add(p); - return p; - } - } - return null; - } - - /** - * Updates an active pointer. - * - * @param id The pointer id. - * @param x The x coordinate. - * @param y The y coordinate. - * @param time The time. - */ - private Pointer updatePointer(int id, float x, float y, long time) { - Pointer p = getPointer(id); - if (p != null) { - float dx = x - p.lastXY[0]; - float dy = y - p.lastXY[1]; - if (p.distance <= slopSquare) { - p.distance += (dx * dx) + (dy * dy); - } - p.lastTime = time; - p.lastXY[0] = x; - p.lastXY[1] = y; - return p; - } - return null; - } - - /** - * Resets the active pointers. - */ - private void resetPointers() { - for (int i = active.size() - 1; i >= 0; i--) { - Pointer p = active.get(i); - p.startXY[0] = p.lastXY[0]; - p.startXY[1] = p.lastXY[1]; - p.distance = 0; - p.alone = false; - } - } - - /** - * Computes the distance between two points. - * - * @param xy1 The first point. - * @param xy2 The second point. - * @return The distance between the points. - */ - private double distance(float[] xy1, float[] xy2) { - float dx = xy1[0] - xy2[0]; - float dy = xy1[1] - xy2[1]; - return Math.sqrt(dx * dx + dy * dy); - } - - /** - * Computes the angle between two points. - * - * @param xy1 The first point. - * @param xy2 The second point. - * @return The angle between the points or NaN, - * if the points are identical. - */ - private double angle(float[] xy1, float[] xy2) { - double dx = xy2[0] - xy1[0]; - double dy = xy2[1] - xy1[1]; - // check special case (pointing up or down) - if (dx == 0) { - if (dy > 0) { - return 90; - } else if (dy < 0) { - return -90; - } else { - return Double.NaN; - } - } else { - // this goes from -90 to 90 - double angle = Math.toDegrees(Math.atan(dy/dx)); - // determine direction based on vector (to get full 360) - if (dx < 0) { - // make sure the result moves between -/+180 - if (angle >= 0) { - return angle - 180; - } else { - return angle + 180; - } - } else { - return angle; - } - } - } - -} diff --git a/android/leafless/src/main/java/com/locoslab/capi/android/leafless/touch/DoubleTapRecognizer.java b/android/leafless/src/main/java/com/locoslab/capi/android/leafless/touch/DoubleTapRecognizer.java deleted file mode 100644 index 912ce15..0000000 --- a/android/leafless/src/main/java/com/locoslab/capi/android/leafless/touch/DoubleTapRecognizer.java +++ /dev/null @@ -1,195 +0,0 @@ -package com.locoslab.capi.android.leafless.touch; - -import android.content.Context; -import android.os.Handler; -import android.view.MotionEvent; -import android.view.ViewConfiguration; - -/** - * An extension to the gesture recognizer that also detects - * short double taps. - * - * @author Marcus - */ -public class DoubleTapRecognizer implements IBasicView, IRecognizer, IMovableTarget { - - /** - * The actual gesture recognizer. - */ - private BasicRecognizer recognizer; - - /** - * The target. - */ - private IDoubleTapView target; - - /** - * The handler to detect events. - */ - private Handler handler = new Handler(); - - /** - * The double tap timeout. - */ - private int timeout; - - /** - * A runnable to trigger the timeout. - */ - private Runnable trigger = new Runnable() { - @Override - public void run() { - processPendingTap(false); - } - }; - - /** - * The coordinates of a pending event. This will have - * the length of two for single taps and the - * length of four for two finger taps. - */ - private int[] pending; - - /** - * The movable target that we emulate. - */ - private IMovableTarget movable; - - /** - * The gesture target that we will interact with. - * - * @param target The target. - */ - public DoubleTapRecognizer(IDoubleTapView target) { - this.target = target; - timeout = ViewConfiguration.getDoubleTapTimeout(); - recognizer = new BasicRecognizer(this); - } - - /** - * Sets the double tap timeout in ms. - * - * @param timeout The timeout. - */ - public void setTimeout(int timeout) { - this.timeout = timeout; - } - - /** - * Returns the double tap timeout in ms. - * - * @return The timeout in ms. - */ - public int getTimeout() { - return timeout; - } - - @Override - public boolean onEvent(MotionEvent event) { - return recognizer.onEvent(event); - } - - - @Override - public Context getContext() { - return target.getContext(); - } - - @Override - public IMovableTarget getMovable(int x, int y) { - movable = target.getMovable(x, y); - if (movable != null) { - return this; - } else { - return null; - } - } - - @Override - public void moveBy(int x, int y) { - processPendingTap(false); - movable.moveBy(x, y); - } - - @Override - public void longTap(int x, int y) { - movable = null; - processPendingTap(false); - target.longTap(x, y); - - } - - @Override - public void longTwoTap(int x1, int y1, int x2, int y2) { - movable = null; - processPendingTap(false); - target.longTwoTap(x1, y1, x2, y2); - } - - @Override - public void rotateBy(double angle) { - movable = null; - processPendingTap(false); - target.rotateBy(angle); - } - - @Override - public void scaleBy(double scale) { - movable = null; - processPendingTap(false); - target.scaleBy(scale); - } - @Override - public void shortTap(int x, int y) { - movable = null; - if (timeout > 0) { - scheduleTap(new int[] { x, y }); - } else { - target.shortTap(x, y); - } - } - - @Override - public void shortTwoTap(int x1, int y1, int x2, int y2) { - movable = null; - if (timeout > 0) { - scheduleTap(new int[] { x1, y1, x2, y2 }); - } else { - target.shortTwoTap(x1, y1, x2, y2); - } - } - - private void scheduleTap(int[] coords) { - if (pending != null) { - if (coords.length == pending.length) { - processPendingTap(true); - return; - } else { - processPendingTap(false); - } - } - this.pending = coords; - handler.postDelayed(trigger, timeout); - } - - private void processPendingTap(boolean doubleTap) { - if (pending != null) { - handler.removeCallbacks(trigger); - if (pending.length == 2) { - if (doubleTap) { - target.doubleTap(pending[0], pending[1]); - } else { - target.shortTap(pending[0], pending[1]); - } - } else if (pending.length == 4) { - if (doubleTap) { - target.doubleTwoTap(pending[0], pending[1], pending[2], pending[3]); - } else { - target.shortTwoTap(pending[0], pending[1], pending[2], pending[3]); - } - } - pending = null; - } - } - -} diff --git a/android/leafless/src/main/java/com/locoslab/capi/android/leafless/touch/IBasicView.java b/android/leafless/src/main/java/com/locoslab/capi/android/leafless/touch/IBasicView.java deleted file mode 100644 index ec3d88e..0000000 --- a/android/leafless/src/main/java/com/locoslab/capi/android/leafless/touch/IBasicView.java +++ /dev/null @@ -1,80 +0,0 @@ -package com.locoslab.capi.android.leafless.touch; - -import android.content.Context; - -/** - * An interface for views that integrate with the - * gesture recognizer. - * - * @author Marcus - */ -public interface IBasicView { - - /** - * Returns the movable element placed at - * a particular pixel. - * - * @param x The x. - * @param y The y. - * @return The movable element. - */ - public IMovableTarget getMovable(int x, int y); - - /** - * Sends a short tap to the pixel. - * - * @param x The x. - * @param y The y. - */ - public void shortTap(int x, int y); - - /** - * Sends a long tap to the pixel. - * - * @param x The x. - * @param y The y. - */ - public void longTap(int x, int y); - - /** - * Short two finger tap. - * - * @param x1 First x coordinate. - * @param y1 First y coordinate. - * @param x2 Second x coordinate. - * @param y2 Second y coordinate. - */ - public void shortTwoTap(int x1, int y1, int x2, int y2); - - /** - * Long two finger tap. - * - * @param x1 First x coordinate. - * @param y1 First y coordinate. - * @param x2 Second x coordinate. - * @param y2 Second y coordinate. - */ - public void longTwoTap(int x1, int y1, int x2, int y2); - - /** - * Rotates the view by the angle. - * - * @param angle The angle to rotate. - */ - public void rotateBy(double angle); - - /** - * Scales the view by the factor. - * - * @param factor The scale factor. - */ - public void scaleBy(double scale); - - /** - * Returns the context of the view. - * - * @return The view context. - */ - public Context getContext(); - -} diff --git a/android/leafless/src/main/java/com/locoslab/capi/android/leafless/touch/IDoubleTapView.java b/android/leafless/src/main/java/com/locoslab/capi/android/leafless/touch/IDoubleTapView.java deleted file mode 100644 index 2563f4a..0000000 --- a/android/leafless/src/main/java/com/locoslab/capi/android/leafless/touch/IDoubleTapView.java +++ /dev/null @@ -1,28 +0,0 @@ -package com.locoslab.capi.android.leafless.touch; - -/** - * An extension to the view that also receives double taps. - * - * @author Marcus - */ -public interface IDoubleTapView extends IBasicView { - - /** - * Called when a double tap occurs. - * - * @param x The x of the first tap. - * @param y The y of the first tap. - */ - public void doubleTap(int x, int y); - - /** - * Called when a double tap with two fingers occurs. - * - * @param x1 The x of the first pointer in the first tap. - * @param y1 The y of the first pointer in the first tap. - * @param x2 The x of the second pointer in the first tap. - * @param y2 The y of the second pointer in the first tap. - */ - public void doubleTwoTap(int x1, int y1, int x2, int y2); - -} diff --git a/android/leafless/src/main/java/com/locoslab/capi/android/leafless/touch/IMovableTarget.java b/android/leafless/src/main/java/com/locoslab/capi/android/leafless/touch/IMovableTarget.java deleted file mode 100644 index 09017cc..0000000 --- a/android/leafless/src/main/java/com/locoslab/capi/android/leafless/touch/IMovableTarget.java +++ /dev/null @@ -1,18 +0,0 @@ -package com.locoslab.capi.android.leafless.touch; - -/** - * Interface for movables. - * - * @author Marcus - */ -public interface IMovableTarget { - - /** - * Requests a move on the view. - * - * @param x The delta x. - * @param y The delta y. - */ - public void moveBy(int x, int y); - -} diff --git a/android/leafless/src/main/java/com/locoslab/capi/android/leafless/touch/IRecognizer.java b/android/leafless/src/main/java/com/locoslab/capi/android/leafless/touch/IRecognizer.java deleted file mode 100644 index 2f15981..0000000 --- a/android/leafless/src/main/java/com/locoslab/capi/android/leafless/touch/IRecognizer.java +++ /dev/null @@ -1,20 +0,0 @@ -package com.locoslab.capi.android.leafless.touch; - -import android.view.MotionEvent; - -/** - * An interface for recognizers. - * - * @author Marcus - */ -public interface IRecognizer { - - /** - * Should be called when a touch event is detected. - * - * @param event The event. - * @return True if consumed, false otherwise. - */ - public boolean onEvent(MotionEvent event); - -} diff --git a/android/leafless/src/main/java/com/locoslab/capi/android/leafless/touch/Pointer.java b/android/leafless/src/main/java/com/locoslab/capi/android/leafless/touch/Pointer.java deleted file mode 100644 index 0c1796c..0000000 --- a/android/leafless/src/main/java/com/locoslab/capi/android/leafless/touch/Pointer.java +++ /dev/null @@ -1,77 +0,0 @@ -package com.locoslab.capi.android.leafless.touch; - -/** - * This class is used to represent a pointer in the recognizer. - * The pointer keeps track of the pointer id, the start coordinate - * where the pointer when down, the last coordinate where the - * pointer is now as well as the start time and the last time of - * the update. In addition, it is used to continously compute the - * distance that the pointer has traveled. - * - * @author Marcus - */ -class Pointer { - - /** - * The id of the pointer. - */ - public int id; - - /** - * The start coordinate with x (at 0) and y (at 1). - */ - public final float[] startXY = new float[2]; - - /** - * The start time of the pointer (when the pointer hit - * the surface), reported by android as uptime millis. - */ - public long startTime; - - /** - * The last (most recent) coordinate with x (at 0) and y (at 1). - */ - public final float[] lastXY = new float[2]; - - /** - * The last time of the event (when the pointer was last - * seen on the surface), reported by android as uptime millis. - */ - public long lastTime; - - /** - * The distance that the pointer has traveled. Note that this - * is actually the distance squared, since we do not want to - * compute the square root all the time when updating this. - */ - public double distance; - - /** - * Memorizes whether this pointer was always alone on the screen. - * Pointers that were not alone at some point, should not emit taps. - */ - public boolean alone; - - @Override - public String toString() { - StringBuilder b = new StringBuilder(); - b.append("id: "); - b.append(id); - b.append(" start: "); - b.append(startXY[0]); - b.append(","); - b.append(startXY[1]); - b.append(" @" + startTime); - b.append(" last: "); - b.append(lastXY[0]); - b.append(","); - b.append(lastXY[1]); - b.append(" @" + lastTime); - b.append(" dist: "); - b.append(distance); - b.append(" alone: "); - b.append(true); - return b.toString(); - } - -} diff --git a/android/leafless/src/main/java/com/locoslab/capi/android/leafless/vector/VectorLayer.java b/android/leafless/src/main/java/com/locoslab/capi/android/leafless/vector/VectorLayer.java deleted file mode 100644 index 4f6bd04..0000000 --- a/android/leafless/src/main/java/com/locoslab/capi/android/leafless/vector/VectorLayer.java +++ /dev/null @@ -1,135 +0,0 @@ -package com.locoslab.capi.android.leafless.vector; - -import java.util.ArrayList; -import java.util.List; - -import com.locoslab.api.data.carta.tile.Tile; -import com.locoslab.api.data.carta.tile.Tiles; -import com.locoslab.api.data.maps.model.Box; -import com.locoslab.capi.android.leafless.AbstractElement; -import com.locoslab.capi.android.leafless.MapViewState; -import com.locoslab.capi.android.leafless.geojson.GeojsonLoader; -import com.locoslab.capi.android.leafless.geojson.IGeojsonLoader; -import com.locoslab.capi.android.leafless.layer.AbstractLayer; - -import android.graphics.Canvas; - -/** - * Implements a vector layer using geojson - * data tiles. - * - * @author Marcus - */ -public class VectorLayer extends AbstractLayer { - - /** - * The tile images. - */ - private List images = new ArrayList<>(); - - /** - * The tile loader to load images. - */ - private IGeojsonLoader loader; - - /** - * Creates a tile layer with the specified options. - * - * @param options The tile layer options. - */ - public VectorLayer(VectorLayerOptions options) { - super(new VectorLayerOptions(options), new GeojsonLoader()); - } - - @Override - public Box getBounds() { - return options.bounds; - } - - @Override - public boolean contains(int x, int y) { - MapViewState state = getMapViewState(); - if (state != null) { - if (state.getZoom() >= options.minZoom && state.getZoom() <= options.maxZoom) { - return super.contains(x, y); - } - } - return false; - } - - @Override - public void drawObject(Canvas canvas) { - MapViewState state = getMapViewState(); - int zoom = state.getZoom(); - List cache = new ArrayList<>(); - if (zoom >= options.minZoom && zoom <= options.maxZoom) { - Box viewport = state.getViewport(); - Box bounds = getBounds(); - Box region = new Box(Math.max(viewport.getMinimumLongitude(), bounds.getMinimumLongitude()), - Math.max(viewport.getMinimumLatitude(), bounds.getMinimumLatitude()), - Math.min(viewport.getMaximumLongitude(), bounds.getMaximumLongitude()), - Math.min(viewport.getMaximumLatitude(), bounds.getMaximumLatitude())); - Tile topLeft = Tiles.getTile(region.getMinimumLongitude(), region.getMaximumLatitude(), zoom); - Tile bottomRight = Tiles.getTile(region.getMaximumLongitude(), region.getMinimumLatitude(), zoom); - for (int j = topLeft.getY(); j <= bottomRight.getY(); j++) { - for (int i = topLeft.getX(); i <= bottomRight.getX(); i++) { - VectorTile image = removeImage(i, j, zoom); - List> elements = image.getElements(); - // small hack - for (AbstractElement element: elements) { - element.setMap(getMapView()); - element.drawObject(canvas); - element.setMap(null); - } - cache.add(image); - } - } - } - for (VectorTile image: images) { - if (loader != null) { - loader.releaseObject(image); - } - } - images = cache; - canvas.restore(); - } - - - /** - * Requests a tile to be loaded. - * - * @param x The x-coordinate of the tile. - * @param y The y-coordinate of the tile. - * @param z The zoom level of the tile. - * @return The tile (which may or may not be loaded). - */ - private VectorTile removeImage(int x, int y, int z) { - for (int i = 0; i < images.size(); i++) { - VectorTile image = images.get(i); - if (image.getX() == x && image.getY() == y && image.getZ() == z) { - return images.remove(i); - } - } - VectorTile image = new VectorTile(getUrl(x, y, z), x, y, z); - if (loader != null) { - loader.requestObject(image); - } - return image; - } - - /** - * Computes the url for a tile. - * - * @param x The x-coordinate of the tile. - * @param y The y-coordinate of the tile. - * @param z The zoom level of the tile. - * @return The url for the tile. - */ - private String getUrl(int x, int y, int z) { - String r = options.url.replace("{x}", Integer.toString(x)); - r = r.replace("{y}", Integer.toString(y)); - r = r.replace("{z}", Integer.toString(z + options.zoomOffset)); - return r; - } - -} diff --git a/android/leafless/src/main/java/com/locoslab/capi/android/leafless/vector/VectorLayerOptions.java b/android/leafless/src/main/java/com/locoslab/capi/android/leafless/vector/VectorLayerOptions.java deleted file mode 100644 index 6275a1e..0000000 --- a/android/leafless/src/main/java/com/locoslab/capi/android/leafless/vector/VectorLayerOptions.java +++ /dev/null @@ -1,31 +0,0 @@ -package com.locoslab.capi.android.leafless.vector; - -import com.locoslab.capi.android.leafless.layer.LayerOptions; - -/** - * The options to create a tile layer. - * - * @author Marcus - */ -public class VectorLayerOptions extends LayerOptions { - - /** - * Creates new tile layer options with the url. - * - * @param url - * The url. - */ - public VectorLayerOptions(String url) { - super(url); - } - - /** - * Copies the tile layer options. - * - * @param copy - * The options to copy. - */ - public VectorLayerOptions(VectorLayerOptions copy) { - super(copy); - } -} diff --git a/android/leafless/src/main/java/com/locoslab/capi/android/leafless/vector/VectorTile.java b/android/leafless/src/main/java/com/locoslab/capi/android/leafless/vector/VectorTile.java deleted file mode 100644 index 2546aca..0000000 --- a/android/leafless/src/main/java/com/locoslab/capi/android/leafless/vector/VectorTile.java +++ /dev/null @@ -1,160 +0,0 @@ -package com.locoslab.capi.android.leafless.vector; - -import java.util.ArrayList; -import java.util.Collections; -import java.util.List; - -import org.geojson.Feature; -import org.geojson.FeatureCollection; -import org.geojson.GeoJsonObject; -import org.geojson.LineString; -import org.geojson.LngLatAlt; - -import com.locoslab.api.data.maps.model.Coordinate; -import com.locoslab.capi.android.leafless.AbstractElement; -import com.locoslab.capi.android.leafless.geojson.IGeojson; -import com.locoslab.capi.android.leafless.polyline.Polyline; -import com.locoslab.capi.android.leafless.polyline.PolylineOptions; - -/** - * An image that is used for a single tile in a tile layer. - * - * @author Marcus - */ -public class VectorTile implements IGeojson { - - /** - * The x index of the tile. - */ - private int x; - /** - * The y index of the tile. - */ - private int y; - /** - * The z index of the tile. - */ - private int z; - - /** - * The url where the tile is coming from. - */ - private String url; - - /** - * The features stored in the tile. - */ - private FeatureCollection features; - - /** - * The elements, once the features are loaded. - */ - private List> elements; - - /** - * Creates a new tile image. - * - * @param url The url. - * @param x The x index. - * @param y The y index - * @param z The z index. - */ - public VectorTile(String url, int x, int y, int z) { - this.url = url; - this.x = x; - this.y = y; - this.z = z; - } - - /** - * Returns the url. - * - * @return The url to load the tile. - */ - public String getUrl() { - return url; - } - - /** - * The x index. - * - * @return The x index. - */ - public int getX() { - return x; - } - - /** - * The y index. - * - * @return The y index. - */ - public int getY() { - return y; - } - - /** - * The z index. - * - * @return The z index. - */ - public int getZ() { - return z; - } - - /** - * Sets the bitmap to be drawn. - * - * @param bitmap The bitmap. - */ - public void setFeatures(FeatureCollection features) { - this.features = features; - } - - /** - * Returns the features. - * - * @return The features. - */ - public FeatureCollection getFeatures() { - return features; - } - - /** - * Returns the elements to be drawn. - * - * @return The elements to be drawn. - */ - public List> getElements() { - if (elements == null) { - if (features == null) { - return Collections.emptyList(); - } else { - createElements(); - } - } - return elements; - } - - /** - * Initializes the elements. - */ - private void createElements() { - elements = new ArrayList<>(); - for (Feature feature: features) { - GeoJsonObject geometry = feature.getGeometry(); - if (geometry instanceof LineString) { - LineString ls = (LineString)geometry; - List coordinates = new ArrayList<>(ls.getCoordinates().size()); - for (LngLatAlt lla : ls.getCoordinates()) { - Coordinate c = new Coordinate(); - c.setLatitude(lla.getLatitude()); - c.setLongitude(lla.getLongitude()); - coordinates.add(c); - } - elements.add(new Polyline(coordinates, new PolylineOptions())); - } - } - } - -} diff --git a/android/pom.xml b/android/pom.xml deleted file mode 100644 index 9148757..0000000 --- a/android/pom.xml +++ /dev/null @@ -1,110 +0,0 @@ - - - 4.0.0 - - com.maptology - all - 0.0.1-SNAPSHOT - - android - Maptology Android - Android code for maptology. - pom - - 7.0_r2 - 25.3.1 - 3.5.1 - - - app - feign - leafless - - - - - - com.simpligility.maven.plugins - android-maven-plugin - 4.5.0 - - - 25 - - ${project.basedir}/src/main/res - ${project.basedir}/src/main/AndroidManifest.xml - ${project.basedir}/src/main/assets - - --no-version-vectors - - - false - true - true - ${project.build.sourceDirectory} - true - ${project.build.outputDirectory} - - true - true - - true - - - - - - - - org.robolectric - robolectric - ${version.robolectric} - test - - - org.robolectric - shadows-supportv4 - ${version.robolectric} - test - - - android - android - ${version.android.sdk} - jar - provided - - - com.android.support - design - ${version.android.support} - aar - - - com.android.support - appcompat-v7 - ${version.android.support} - aar - - - com.android.support - preference-v7 - ${version.android.support} - aar - - - com.android.support - cardview-v7 - ${version.android.support} - aar - - - com.android.support - recyclerview-v7 - ${version.android.support} - aar - - - - diff --git a/build.gradle b/build.gradle new file mode 100644 index 0000000..b4fc836 --- /dev/null +++ b/build.gradle @@ -0,0 +1,84 @@ +buildscript { + dependencies { + classpath 'com.android.tools.build:gradle:3.4.2' + classpath 'org.jfrog.buildinfo:build-info-extractor-gradle:4.8.1' + } + repositories { + mavenCentral() + jcenter() + google() + } +} + + +allprojects { + // set version for our project + group = 'com.maptology' + version = '0.0.2-SNAPSHOT' + + // set versions for our libraries + ext { + // api dependencies + versionJavaee = '7.0' + versionJaxb = '2.3.1' + versionAnnotation = '1.3.2' + versionSwagger = '1.5.22' + // widlfly dependencies, keep in sync + versionJackson = '2.9.9' + versionResteasy = '3.7.0.Final' + versionWildfly = '17.0.1.Final' + versionPicketbox = '5.0.3.Final' + // testing dependencies + versionJunit = '4.12' + versionArquillianContainer = '2.2.0.Final' + versionArquillianJunit = '1.4.1.Final' + // thorntail dependencies + versionH2database = '1.4.196' + versionThorntail = '2.5.0.Final' + + // android stuff + versionRobolectric = '4.3' + versionSupport = "28.0.0" + } +} + +subprojects { + apply plugin: 'maven-publish' + + if (name.equals('android-app')) { + apply plugin: 'com.android.application' + } else { + apply plugin: 'java' + sourceCompatibility = '1.8' + + task sourcesJar(type: Jar) { + classifier = 'sources' + from(sourceSets.main.allJava) + } + + publishing { + publications { + maven(MavenPublication) { + from(components.java) + artifact(sourcesJar) + } + } + } + + tasks.withType(JavaCompile) { + options.encoding = 'UTF-8' + } + + } + + repositories { + mavenLocal() + mavenCentral() + jcenter() + maven() { url = 'https://project.nes.uni-due.de/artifactory/releases'; credentials { username = 'public'; password = 'public' } } + maven() { url = 'https://project.nes.uni-due.de/artifactory/snaphsots'; credentials { username = 'public'; password = 'public'} } + } + + + +} diff --git a/common-api/build.gradle b/common-api/build.gradle new file mode 100644 index 0000000..117de4d --- /dev/null +++ b/common-api/build.gradle @@ -0,0 +1,82 @@ +plugins { + id 'com.benjaminsproule.swagger' version '1.0.6' +} + +description = 'Maptology Common Api' + +dependencies { + testCompile "junit:junit:${versionJunit}" + compileOnly "javax.xml.bind:jaxb-api:${versionJaxb}" + compileOnly "javax:javaee-api:${versionJavaee}" + compileOnly "io.swagger:swagger-annotations:${versionSwagger}" + compileOnly "com.fasterxml.jackson.core:jackson-annotations:${versionJackson}" +} + +// add compile only dependencies to testCompile without duplicating them +sourceSets { + test.compileClasspath += configurations.compileOnly +} + +// generate swagger documenation from api using a plugin +swagger { + apiSource { + attachSwaggerArtifact = true + locations = [ + 'com.maptology.api.user.IUserService', + 'com.maptology.api.notice.INoticeService', + 'com.maptology.api.log.ILogService', + 'com.maptology.api.version.IVersionService', + 'com.maptology.api.device.IDeviceService', + 'com.maptology.api.share.IShareService', + 'com.maptology.api.location.ILocationService', + 'com.maptology.api.privilege.IPrivilegeService', + 'com.maptology.api.history.IHistoryService' + ] + schemes = [ 'http', 'https'] + basePath = '/api' + info { + title = 'Maptology Service' + version = "${version}" + description = 'Maptology Service' + termsOfService = 'https://maptology.com/terms-of-service' + contact { + email = 'nes-admin@uni-due.de' + name = 'NES Universität Duisburg-Essen' + url = 'https://www.nes.uni-due.de' + } + license { + url = 'https://www.maptology.com/license' + name = 'Proprietary' + } + } + swaggerFileName = 'maptology' + swaggerDirectory = "${project.buildDir}/swagger" + securityDefinition { + name = 'device' + description = 'Operations requiring device privileges.' + type = 'apiKey' + keyLocation = 'header' + keyName = 'Authorization' + } + securityDefinition { + name = 'user' + description = 'Operations requiring a valid user.' + type = 'basic' + } + securityDefinition { + name = 'admin' + description = 'Operations requiring admin privileges.' + type = 'basic' + } + } +} + +// add the swagger defintion to the artifacts published by this module +publishing { + publications { + maven(MavenPublication) { + artifact source: "${project.buildDir}/swagger/maptology.json", extension: "swagger" + } + } +} + diff --git a/api/pom.xml b/common-api/pom.xml similarity index 95% rename from api/pom.xml rename to common-api/pom.xml index de39714..c30f0cb 100644 --- a/api/pom.xml +++ b/common-api/pom.xml @@ -4,12 +4,12 @@ 4.0.0 com.maptology - all + project 0.0.1-SNAPSHOT - api - Maptology Api - Api of the maptology service. + common-api + Maptology Common Api + Common api of the maptology service. @@ -25,7 +25,6 @@ - false @@ -103,7 +102,6 @@ - javax diff --git a/api/src/main/java/com/maptology/api/Entity.java b/common-api/src/main/java/com/maptology/api/Entity.java similarity index 100% rename from api/src/main/java/com/maptology/api/Entity.java rename to common-api/src/main/java/com/maptology/api/Entity.java diff --git a/api/src/main/java/com/maptology/api/Page.java b/common-api/src/main/java/com/maptology/api/Page.java similarity index 100% rename from api/src/main/java/com/maptology/api/Page.java rename to common-api/src/main/java/com/maptology/api/Page.java diff --git a/api/src/main/java/com/maptology/api/PageConfig.java b/common-api/src/main/java/com/maptology/api/PageConfig.java similarity index 100% rename from api/src/main/java/com/maptology/api/PageConfig.java rename to common-api/src/main/java/com/maptology/api/PageConfig.java diff --git a/api/src/main/java/com/maptology/api/Tags.java b/common-api/src/main/java/com/maptology/api/Tags.java similarity index 100% rename from api/src/main/java/com/maptology/api/Tags.java rename to common-api/src/main/java/com/maptology/api/Tags.java diff --git a/api/src/main/java/com/maptology/api/access/Authorizations.java b/common-api/src/main/java/com/maptology/api/access/Authorizations.java similarity index 100% rename from api/src/main/java/com/maptology/api/access/Authorizations.java rename to common-api/src/main/java/com/maptology/api/access/Authorizations.java diff --git a/api/src/main/java/com/maptology/api/access/Roles.java b/common-api/src/main/java/com/maptology/api/access/Roles.java similarity index 100% rename from api/src/main/java/com/maptology/api/access/Roles.java rename to common-api/src/main/java/com/maptology/api/access/Roles.java diff --git a/api/src/main/java/com/maptology/api/access/package-info.java b/common-api/src/main/java/com/maptology/api/access/package-info.java similarity index 100% rename from api/src/main/java/com/maptology/api/access/package-info.java rename to common-api/src/main/java/com/maptology/api/access/package-info.java diff --git a/api/src/main/java/com/maptology/api/device/Device.java b/common-api/src/main/java/com/maptology/api/device/Device.java similarity index 100% rename from api/src/main/java/com/maptology/api/device/Device.java rename to common-api/src/main/java/com/maptology/api/device/Device.java diff --git a/api/src/main/java/com/maptology/api/device/DeviceHandle.java b/common-api/src/main/java/com/maptology/api/device/DeviceHandle.java similarity index 100% rename from api/src/main/java/com/maptology/api/device/DeviceHandle.java rename to common-api/src/main/java/com/maptology/api/device/DeviceHandle.java diff --git a/api/src/main/java/com/maptology/api/device/DeviceInfo.java b/common-api/src/main/java/com/maptology/api/device/DeviceInfo.java similarity index 100% rename from api/src/main/java/com/maptology/api/device/DeviceInfo.java rename to common-api/src/main/java/com/maptology/api/device/DeviceInfo.java diff --git a/api/src/main/java/com/maptology/api/device/DevicePage.java b/common-api/src/main/java/com/maptology/api/device/DevicePage.java similarity index 100% rename from api/src/main/java/com/maptology/api/device/DevicePage.java rename to common-api/src/main/java/com/maptology/api/device/DevicePage.java diff --git a/api/src/main/java/com/maptology/api/device/IDeviceService.java b/common-api/src/main/java/com/maptology/api/device/IDeviceService.java similarity index 100% rename from api/src/main/java/com/maptology/api/device/IDeviceService.java rename to common-api/src/main/java/com/maptology/api/device/IDeviceService.java diff --git a/api/src/main/java/com/maptology/api/device/OperatingSystem.java b/common-api/src/main/java/com/maptology/api/device/OperatingSystem.java similarity index 100% rename from api/src/main/java/com/maptology/api/device/OperatingSystem.java rename to common-api/src/main/java/com/maptology/api/device/OperatingSystem.java diff --git a/api/src/main/java/com/maptology/api/device/package-info.java b/common-api/src/main/java/com/maptology/api/device/package-info.java similarity index 100% rename from api/src/main/java/com/maptology/api/device/package-info.java rename to common-api/src/main/java/com/maptology/api/device/package-info.java diff --git a/api/src/main/java/com/maptology/api/history/IHistoryService.java b/common-api/src/main/java/com/maptology/api/history/IHistoryService.java similarity index 100% rename from api/src/main/java/com/maptology/api/history/IHistoryService.java rename to common-api/src/main/java/com/maptology/api/history/IHistoryService.java diff --git a/api/src/main/java/com/maptology/api/history/Place.java b/common-api/src/main/java/com/maptology/api/history/Place.java similarity index 100% rename from api/src/main/java/com/maptology/api/history/Place.java rename to common-api/src/main/java/com/maptology/api/history/Place.java diff --git a/api/src/main/java/com/maptology/api/history/PlacePage.java b/common-api/src/main/java/com/maptology/api/history/PlacePage.java similarity index 100% rename from api/src/main/java/com/maptology/api/history/PlacePage.java rename to common-api/src/main/java/com/maptology/api/history/PlacePage.java diff --git a/api/src/main/java/com/maptology/api/history/Visit.java b/common-api/src/main/java/com/maptology/api/history/Visit.java similarity index 100% rename from api/src/main/java/com/maptology/api/history/Visit.java rename to common-api/src/main/java/com/maptology/api/history/Visit.java diff --git a/api/src/main/java/com/maptology/api/history/VisitPage.java b/common-api/src/main/java/com/maptology/api/history/VisitPage.java similarity index 100% rename from api/src/main/java/com/maptology/api/history/VisitPage.java rename to common-api/src/main/java/com/maptology/api/history/VisitPage.java diff --git a/api/src/main/java/com/maptology/api/history/package-info.java b/common-api/src/main/java/com/maptology/api/history/package-info.java similarity index 100% rename from api/src/main/java/com/maptology/api/history/package-info.java rename to common-api/src/main/java/com/maptology/api/history/package-info.java diff --git a/api/src/main/java/com/maptology/api/location/Availability.java b/common-api/src/main/java/com/maptology/api/location/Availability.java similarity index 100% rename from api/src/main/java/com/maptology/api/location/Availability.java rename to common-api/src/main/java/com/maptology/api/location/Availability.java diff --git a/api/src/main/java/com/maptology/api/location/Coordinate.java b/common-api/src/main/java/com/maptology/api/location/Coordinate.java similarity index 100% rename from api/src/main/java/com/maptology/api/location/Coordinate.java rename to common-api/src/main/java/com/maptology/api/location/Coordinate.java diff --git a/api/src/main/java/com/maptology/api/location/DetailedLocation.java b/common-api/src/main/java/com/maptology/api/location/DetailedLocation.java similarity index 100% rename from api/src/main/java/com/maptology/api/location/DetailedLocation.java rename to common-api/src/main/java/com/maptology/api/location/DetailedLocation.java diff --git a/api/src/main/java/com/maptology/api/location/ILocationService.java b/common-api/src/main/java/com/maptology/api/location/ILocationService.java similarity index 100% rename from api/src/main/java/com/maptology/api/location/ILocationService.java rename to common-api/src/main/java/com/maptology/api/location/ILocationService.java diff --git a/api/src/main/java/com/maptology/api/location/Location.java b/common-api/src/main/java/com/maptology/api/location/Location.java similarity index 100% rename from api/src/main/java/com/maptology/api/location/Location.java rename to common-api/src/main/java/com/maptology/api/location/Location.java diff --git a/api/src/main/java/com/maptology/api/location/LocationUpdate.java b/common-api/src/main/java/com/maptology/api/location/LocationUpdate.java similarity index 100% rename from api/src/main/java/com/maptology/api/location/LocationUpdate.java rename to common-api/src/main/java/com/maptology/api/location/LocationUpdate.java diff --git a/api/src/main/java/com/maptology/api/location/Position.java b/common-api/src/main/java/com/maptology/api/location/Position.java similarity index 100% rename from api/src/main/java/com/maptology/api/location/Position.java rename to common-api/src/main/java/com/maptology/api/location/Position.java diff --git a/api/src/main/java/com/maptology/api/location/PositionPage.java b/common-api/src/main/java/com/maptology/api/location/PositionPage.java similarity index 100% rename from api/src/main/java/com/maptology/api/location/PositionPage.java rename to common-api/src/main/java/com/maptology/api/location/PositionPage.java diff --git a/api/src/main/java/com/maptology/api/location/ReleasedLocation.java b/common-api/src/main/java/com/maptology/api/location/ReleasedLocation.java similarity index 100% rename from api/src/main/java/com/maptology/api/location/ReleasedLocation.java rename to common-api/src/main/java/com/maptology/api/location/ReleasedLocation.java diff --git a/api/src/main/java/com/maptology/api/location/package-info.java b/common-api/src/main/java/com/maptology/api/location/package-info.java similarity index 100% rename from api/src/main/java/com/maptology/api/location/package-info.java rename to common-api/src/main/java/com/maptology/api/location/package-info.java diff --git a/api/src/main/java/com/maptology/api/log/EntityStatistic.java b/common-api/src/main/java/com/maptology/api/log/EntityStatistic.java similarity index 100% rename from api/src/main/java/com/maptology/api/log/EntityStatistic.java rename to common-api/src/main/java/com/maptology/api/log/EntityStatistic.java diff --git a/api/src/main/java/com/maptology/api/log/ILogService.java b/common-api/src/main/java/com/maptology/api/log/ILogService.java similarity index 100% rename from api/src/main/java/com/maptology/api/log/ILogService.java rename to common-api/src/main/java/com/maptology/api/log/ILogService.java diff --git a/api/src/main/java/com/maptology/api/log/LoadStatistic.java b/common-api/src/main/java/com/maptology/api/log/LoadStatistic.java similarity index 100% rename from api/src/main/java/com/maptology/api/log/LoadStatistic.java rename to common-api/src/main/java/com/maptology/api/log/LoadStatistic.java diff --git a/api/src/main/java/com/maptology/api/log/LogMessage.java b/common-api/src/main/java/com/maptology/api/log/LogMessage.java similarity index 100% rename from api/src/main/java/com/maptology/api/log/LogMessage.java rename to common-api/src/main/java/com/maptology/api/log/LogMessage.java diff --git a/api/src/main/java/com/maptology/api/log/SystemStatistic.java b/common-api/src/main/java/com/maptology/api/log/SystemStatistic.java similarity index 100% rename from api/src/main/java/com/maptology/api/log/SystemStatistic.java rename to common-api/src/main/java/com/maptology/api/log/SystemStatistic.java diff --git a/api/src/main/java/com/maptology/api/log/package-info.java b/common-api/src/main/java/com/maptology/api/log/package-info.java similarity index 100% rename from api/src/main/java/com/maptology/api/log/package-info.java rename to common-api/src/main/java/com/maptology/api/log/package-info.java diff --git a/api/src/main/java/com/maptology/api/notice/INoticeService.java b/common-api/src/main/java/com/maptology/api/notice/INoticeService.java similarity index 100% rename from api/src/main/java/com/maptology/api/notice/INoticeService.java rename to common-api/src/main/java/com/maptology/api/notice/INoticeService.java diff --git a/api/src/main/java/com/maptology/api/notice/Language.java b/common-api/src/main/java/com/maptology/api/notice/Language.java similarity index 100% rename from api/src/main/java/com/maptology/api/notice/Language.java rename to common-api/src/main/java/com/maptology/api/notice/Language.java diff --git a/api/src/main/java/com/maptology/api/notice/Message.java b/common-api/src/main/java/com/maptology/api/notice/Message.java similarity index 100% rename from api/src/main/java/com/maptology/api/notice/Message.java rename to common-api/src/main/java/com/maptology/api/notice/Message.java diff --git a/api/src/main/java/com/maptology/api/notice/Notice.java b/common-api/src/main/java/com/maptology/api/notice/Notice.java similarity index 100% rename from api/src/main/java/com/maptology/api/notice/Notice.java rename to common-api/src/main/java/com/maptology/api/notice/Notice.java diff --git a/api/src/main/java/com/maptology/api/notice/NoticePage.java b/common-api/src/main/java/com/maptology/api/notice/NoticePage.java similarity index 100% rename from api/src/main/java/com/maptology/api/notice/NoticePage.java rename to common-api/src/main/java/com/maptology/api/notice/NoticePage.java diff --git a/api/src/main/java/com/maptology/api/notice/package-info.java b/common-api/src/main/java/com/maptology/api/notice/package-info.java similarity index 100% rename from api/src/main/java/com/maptology/api/notice/package-info.java rename to common-api/src/main/java/com/maptology/api/notice/package-info.java diff --git a/api/src/main/java/com/maptology/api/package-info.java b/common-api/src/main/java/com/maptology/api/package-info.java similarity index 100% rename from api/src/main/java/com/maptology/api/package-info.java rename to common-api/src/main/java/com/maptology/api/package-info.java diff --git a/api/src/main/java/com/maptology/api/privilege/IPrivilegeService.java b/common-api/src/main/java/com/maptology/api/privilege/IPrivilegeService.java similarity index 100% rename from api/src/main/java/com/maptology/api/privilege/IPrivilegeService.java rename to common-api/src/main/java/com/maptology/api/privilege/IPrivilegeService.java diff --git a/api/src/main/java/com/maptology/api/privilege/Privilege.java b/common-api/src/main/java/com/maptology/api/privilege/Privilege.java similarity index 100% rename from api/src/main/java/com/maptology/api/privilege/Privilege.java rename to common-api/src/main/java/com/maptology/api/privilege/Privilege.java diff --git a/api/src/main/java/com/maptology/api/privilege/PrivilegePage.java b/common-api/src/main/java/com/maptology/api/privilege/PrivilegePage.java similarity index 100% rename from api/src/main/java/com/maptology/api/privilege/PrivilegePage.java rename to common-api/src/main/java/com/maptology/api/privilege/PrivilegePage.java diff --git a/api/src/main/java/com/maptology/api/privilege/package-info.java b/common-api/src/main/java/com/maptology/api/privilege/package-info.java similarity index 100% rename from api/src/main/java/com/maptology/api/privilege/package-info.java rename to common-api/src/main/java/com/maptology/api/privilege/package-info.java diff --git a/api/src/main/java/com/maptology/api/share/IShareService.java b/common-api/src/main/java/com/maptology/api/share/IShareService.java similarity index 100% rename from api/src/main/java/com/maptology/api/share/IShareService.java rename to common-api/src/main/java/com/maptology/api/share/IShareService.java diff --git a/api/src/main/java/com/maptology/api/share/Share.java b/common-api/src/main/java/com/maptology/api/share/Share.java similarity index 100% rename from api/src/main/java/com/maptology/api/share/Share.java rename to common-api/src/main/java/com/maptology/api/share/Share.java diff --git a/api/src/main/java/com/maptology/api/share/ShareInfo.java b/common-api/src/main/java/com/maptology/api/share/ShareInfo.java similarity index 100% rename from api/src/main/java/com/maptology/api/share/ShareInfo.java rename to common-api/src/main/java/com/maptology/api/share/ShareInfo.java diff --git a/api/src/main/java/com/maptology/api/share/SharePage.java b/common-api/src/main/java/com/maptology/api/share/SharePage.java similarity index 100% rename from api/src/main/java/com/maptology/api/share/SharePage.java rename to common-api/src/main/java/com/maptology/api/share/SharePage.java diff --git a/api/src/main/java/com/maptology/api/share/package-info.java b/common-api/src/main/java/com/maptology/api/share/package-info.java similarity index 100% rename from api/src/main/java/com/maptology/api/share/package-info.java rename to common-api/src/main/java/com/maptology/api/share/package-info.java diff --git a/api/src/main/java/com/maptology/api/user/Email.java b/common-api/src/main/java/com/maptology/api/user/Email.java similarity index 100% rename from api/src/main/java/com/maptology/api/user/Email.java rename to common-api/src/main/java/com/maptology/api/user/Email.java diff --git a/api/src/main/java/com/maptology/api/user/IUserService.java b/common-api/src/main/java/com/maptology/api/user/IUserService.java similarity index 100% rename from api/src/main/java/com/maptology/api/user/IUserService.java rename to common-api/src/main/java/com/maptology/api/user/IUserService.java diff --git a/api/src/main/java/com/maptology/api/user/User.java b/common-api/src/main/java/com/maptology/api/user/User.java similarity index 100% rename from api/src/main/java/com/maptology/api/user/User.java rename to common-api/src/main/java/com/maptology/api/user/User.java diff --git a/api/src/main/java/com/maptology/api/user/UserPage.java b/common-api/src/main/java/com/maptology/api/user/UserPage.java similarity index 100% rename from api/src/main/java/com/maptology/api/user/UserPage.java rename to common-api/src/main/java/com/maptology/api/user/UserPage.java diff --git a/api/src/main/java/com/maptology/api/user/UserPassword.java b/common-api/src/main/java/com/maptology/api/user/UserPassword.java similarity index 100% rename from api/src/main/java/com/maptology/api/user/UserPassword.java rename to common-api/src/main/java/com/maptology/api/user/UserPassword.java diff --git a/api/src/main/java/com/maptology/api/user/UserRegistration.java b/common-api/src/main/java/com/maptology/api/user/UserRegistration.java similarity index 100% rename from api/src/main/java/com/maptology/api/user/UserRegistration.java rename to common-api/src/main/java/com/maptology/api/user/UserRegistration.java diff --git a/api/src/main/java/com/maptology/api/user/package-info.java b/common-api/src/main/java/com/maptology/api/user/package-info.java similarity index 100% rename from api/src/main/java/com/maptology/api/user/package-info.java rename to common-api/src/main/java/com/maptology/api/user/package-info.java diff --git a/api/src/main/java/com/maptology/api/validation/EmailGroup.java b/common-api/src/main/java/com/maptology/api/validation/EmailGroup.java similarity index 100% rename from api/src/main/java/com/maptology/api/validation/EmailGroup.java rename to common-api/src/main/java/com/maptology/api/validation/EmailGroup.java diff --git a/api/src/main/java/com/maptology/api/validation/EmailGroupValidator.java b/common-api/src/main/java/com/maptology/api/validation/EmailGroupValidator.java similarity index 100% rename from api/src/main/java/com/maptology/api/validation/EmailGroupValidator.java rename to common-api/src/main/java/com/maptology/api/validation/EmailGroupValidator.java diff --git a/api/src/main/java/com/maptology/api/validation/package-info.java b/common-api/src/main/java/com/maptology/api/validation/package-info.java similarity index 100% rename from api/src/main/java/com/maptology/api/validation/package-info.java rename to common-api/src/main/java/com/maptology/api/validation/package-info.java diff --git a/api/src/main/java/com/maptology/api/version/BuildVersion.java b/common-api/src/main/java/com/maptology/api/version/BuildVersion.java similarity index 100% rename from api/src/main/java/com/maptology/api/version/BuildVersion.java rename to common-api/src/main/java/com/maptology/api/version/BuildVersion.java diff --git a/api/src/main/java/com/maptology/api/version/IVersionService.java b/common-api/src/main/java/com/maptology/api/version/IVersionService.java similarity index 100% rename from api/src/main/java/com/maptology/api/version/IVersionService.java rename to common-api/src/main/java/com/maptology/api/version/IVersionService.java diff --git a/api/src/main/java/com/maptology/api/version/package-info.java b/common-api/src/main/java/com/maptology/api/version/package-info.java similarity index 100% rename from api/src/main/java/com/maptology/api/version/package-info.java rename to common-api/src/main/java/com/maptology/api/version/package-info.java diff --git a/api/src/main/resources/security-admin.json b/common-api/src/main/resources/security-admin.json similarity index 100% rename from api/src/main/resources/security-admin.json rename to common-api/src/main/resources/security-admin.json diff --git a/api/src/main/resources/security-device.json b/common-api/src/main/resources/security-device.json similarity index 100% rename from api/src/main/resources/security-device.json rename to common-api/src/main/resources/security-device.json diff --git a/api/src/main/resources/security-user.json b/common-api/src/main/resources/security-user.json similarity index 100% rename from api/src/main/resources/security-user.json rename to common-api/src/main/resources/security-user.json diff --git a/api/src/test/java/com/maptology/api/test/unit/NoticeTest.java b/common-api/src/test/java/com/maptology/api/test/unit/NoticeTest.java similarity index 100% rename from api/src/test/java/com/maptology/api/test/unit/NoticeTest.java rename to common-api/src/test/java/com/maptology/api/test/unit/NoticeTest.java diff --git a/api/src/test/java/com/maptology/api/test/unit/package-info.java b/common-api/src/test/java/com/maptology/api/test/unit/package-info.java similarity index 100% rename from api/src/test/java/com/maptology/api/test/unit/package-info.java rename to common-api/src/test/java/com/maptology/api/test/unit/package-info.java diff --git a/testing/api-client/gradle/wrapper/gradle-wrapper.properties b/gradle/wrapper/gradle-wrapper.properties similarity index 79% rename from testing/api-client/gradle/wrapper/gradle-wrapper.properties rename to gradle/wrapper/gradle-wrapper.properties index b7a3647..a69aa6b 100644 --- a/testing/api-client/gradle/wrapper/gradle-wrapper.properties +++ b/gradle/wrapper/gradle-wrapper.properties @@ -1,6 +1,6 @@ -#Tue May 17 23:08:05 CST 2016 +#Sun Jul 21 19:24:12 CEST 2019 distributionBase=GRADLE_USER_HOME distributionPath=wrapper/dists zipStoreBase=GRADLE_USER_HOME zipStorePath=wrapper/dists -distributionUrl=https\://services.gradle.org/distributions/gradle-2.6-bin.zip +distributionUrl=https\://services.gradle.org/distributions/gradle-5.5.1-all.zip diff --git a/testing/api-client/gradlew b/gradlew similarity index 75% rename from testing/api-client/gradlew rename to gradlew index 9d82f78..8e25e6c 100644 --- a/testing/api-client/gradlew +++ b/gradlew @@ -1,4 +1,20 @@ -#!/usr/bin/env bash +#!/usr/bin/env sh + +# +# Copyright 2015 the original author or authors. +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# https://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# ############################################################################## ## @@ -6,42 +22,6 @@ ## ############################################################################## -# Add default JVM options here. You can also use JAVA_OPTS and GRADLE_OPTS to pass JVM options to this script. -DEFAULT_JVM_OPTS="" - -APP_NAME="Gradle" -APP_BASE_NAME=`basename "$0"` - -# Use the maximum available, or set MAX_FD != -1 to use that value. -MAX_FD="maximum" - -warn ( ) { - echo "$*" -} - -die ( ) { - echo - echo "$*" - echo - exit 1 -} - -# OS specific support (must be 'true' or 'false'). -cygwin=false -msys=false -darwin=false -case "`uname`" in - CYGWIN* ) - cygwin=true - ;; - Darwin* ) - darwin=true - ;; - MINGW* ) - msys=true - ;; -esac - # Attempt to set APP_HOME # Resolve links: $0 may be a link PRG="$0" @@ -60,6 +40,46 @@ cd "`dirname \"$PRG\"`/" >/dev/null APP_HOME="`pwd -P`" cd "$SAVED" >/dev/null +APP_NAME="Gradle" +APP_BASE_NAME=`basename "$0"` + +# Add default JVM options here. You can also use JAVA_OPTS and GRADLE_OPTS to pass JVM options to this script. +DEFAULT_JVM_OPTS='"-Xmx64m" "-Xms64m"' + +# Use the maximum available, or set MAX_FD != -1 to use that value. +MAX_FD="maximum" + +warn () { + echo "$*" +} + +die () { + echo + echo "$*" + echo + exit 1 +} + +# OS specific support (must be 'true' or 'false'). +cygwin=false +msys=false +darwin=false +nonstop=false +case "`uname`" in + CYGWIN* ) + cygwin=true + ;; + Darwin* ) + darwin=true + ;; + MINGW* ) + msys=true + ;; + NONSTOP* ) + nonstop=true + ;; +esac + CLASSPATH=$APP_HOME/gradle/wrapper/gradle-wrapper.jar # Determine the Java command to use to start the JVM. @@ -85,7 +105,7 @@ location of your Java installation." fi # Increase the maximum file descriptors if we can. -if [ "$cygwin" = "false" -a "$darwin" = "false" ] ; then +if [ "$cygwin" = "false" -a "$darwin" = "false" -a "$nonstop" = "false" ] ; then MAX_FD_LIMIT=`ulimit -H -n` if [ $? -eq 0 ] ; then if [ "$MAX_FD" = "maximum" -o "$MAX_FD" = "max" ] ; then @@ -150,11 +170,19 @@ if $cygwin ; then esac fi -# Split up the JVM_OPTS And GRADLE_OPTS values into an array, following the shell quoting and substitution rules -function splitJvmOpts() { - JVM_OPTS=("$@") +# Escape application args +save () { + for i do printf %s\\n "$i" | sed "s/'/'\\\\''/g;1s/^/'/;\$s/\$/' \\\\/" ; done + echo " " } -eval splitJvmOpts $DEFAULT_JVM_OPTS $JAVA_OPTS $GRADLE_OPTS -JVM_OPTS[${#JVM_OPTS[*]}]="-Dorg.gradle.appname=$APP_BASE_NAME" +APP_ARGS=$(save "$@") -exec "$JAVACMD" "${JVM_OPTS[@]}" -classpath "$CLASSPATH" org.gradle.wrapper.GradleWrapperMain "$@" +# Collect all arguments for the java command, following the shell quoting and substitution rules +eval set -- $DEFAULT_JVM_OPTS $JAVA_OPTS $GRADLE_OPTS "\"-Dorg.gradle.appname=$APP_BASE_NAME\"" -classpath "\"$CLASSPATH\"" org.gradle.wrapper.GradleWrapperMain "$APP_ARGS" + +# by default we should be in the correct project dir, but when run from Finder on Mac, the cwd is wrong +if [ "$(uname)" = "Darwin" ] && [ "$HOME" = "$PWD" ]; then + cd "$(dirname "$0")" +fi + +exec "$JAVACMD" "$@" diff --git a/testing/api-client/gradlew.bat b/gradlew.bat similarity index 75% rename from testing/api-client/gradlew.bat rename to gradlew.bat index 5f19212..9618d8d 100644 --- a/testing/api-client/gradlew.bat +++ b/gradlew.bat @@ -1,3 +1,19 @@ +@rem +@rem Copyright 2015 the original author or authors. +@rem +@rem Licensed under the Apache License, Version 2.0 (the "License"); +@rem you may not use this file except in compliance with the License. +@rem You may obtain a copy of the License at +@rem +@rem https://www.apache.org/licenses/LICENSE-2.0 +@rem +@rem Unless required by applicable law or agreed to in writing, software +@rem distributed under the License is distributed on an "AS IS" BASIS, +@rem WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +@rem See the License for the specific language governing permissions and +@rem limitations under the License. +@rem + @if "%DEBUG%" == "" @echo off @rem ########################################################################## @rem @@ -8,14 +24,14 @@ @rem Set local scope for the variables with windows NT shell if "%OS%"=="Windows_NT" setlocal -@rem Add default JVM options here. You can also use JAVA_OPTS and GRADLE_OPTS to pass JVM options to this script. -set DEFAULT_JVM_OPTS= - set DIRNAME=%~dp0 if "%DIRNAME%" == "" set DIRNAME=. set APP_BASE_NAME=%~n0 set APP_HOME=%DIRNAME% +@rem Add default JVM options here. You can also use JAVA_OPTS and GRADLE_OPTS to pass JVM options to this script. +set DEFAULT_JVM_OPTS="-Xmx64m" "-Xms64m" + @rem Find java.exe if defined JAVA_HOME goto findJavaFromJavaHome @@ -49,7 +65,6 @@ goto fail @rem Get command-line arguments, handling Windows variants if not "%OS%" == "Windows_NT" goto win9xME_args -if "%@eval[2+2]" == "4" goto 4NT_args :win9xME_args @rem Slurp the command line arguments. @@ -60,11 +75,6 @@ set _SKIP=2 if "x%~1" == "x" goto execute set CMD_LINE_ARGS=%* -goto execute - -:4NT_args -@rem Get arguments from the 4NT Shell from JP Software -set CMD_LINE_ARGS=%$ :execute @rem Setup the command line diff --git a/local.properties b/local.properties new file mode 100644 index 0000000..ca0d5d3 --- /dev/null +++ b/local.properties @@ -0,0 +1,8 @@ +## This file must *NOT* be checked into Version Control Systems, +# as it contains information specific to your local configuration. +# +# Location of the SDK. This is only used by Gradle. +# For customization when using a Version Control System, please read the +# header note. +#Sun Jul 21 19:04:56 CEST 2019 +sdk.dir=C\:\\Program Files\\Java\\Android SDK diff --git a/pom.xml b/pom.xml index 5377b17..20b8ffb 100644 --- a/pom.xml +++ b/pom.xml @@ -3,20 +3,37 @@ xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd"> 4.0.0 com.maptology - all + project Maptology Root project for maptology. 0.0.1-SNAPSHOT pom UTF-8 + + 17.0.1.Final + 3.0.19.Final + 2.4.1 + + 7.0_r2 + 25.3.1 + 3.5.1 + + v10.16.0 + 6.9.0 - api - android - service - web - ear + common-api + android-app + android-feign + service-wildfly + service-geocode + service-ejb + service-war + service-swarm + web-angular + web-war + site-ear @@ -43,7 +60,7 @@ maven-surefire-plugin - 2.20.1 + 3.0.0-M3 maven-clean-plugin @@ -71,11 +88,10 @@ maven-compiler-plugin - 3.7.0 + 3.8.1 - - 1.7 - 1.7 + 1.8 + 1.8 @@ -98,6 +114,33 @@ frontend-maven-plugin 1.6 + + com.simpligility.maven.plugins + android-maven-plugin + 4.5.0 + + + 25 + + ${project.basedir}/src/main/res + ${project.basedir}/src/main/AndroidManifest.xml + ${project.basedir}/src/main/assets + + --no-version-vectors + + + false + true + true + ${project.build.sourceDirectory} + true + ${project.build.outputDirectory} + + true + true + + true + org.eclipse.m2e @@ -155,6 +198,16 @@ + + javax.xml.bind + jaxb-api + 2.3.1 + + + javax.annotation + javax.annotation-api + 1.3.2 + javax javaee-api @@ -169,6 +222,78 @@ 4.12 test + + + org.jboss.arquillian.junit + arquillian-junit-container + 1.4.1.Final + test + + + org.wildfly.arquillian + wildfly-arquillian-container-embedded + 2.2.0.Final + test + + + org.wildfly.arquillian + wildfly-arquillian-container-managed + 2.2.0.Final + test + + + + org.robolectric + robolectric + ${version.robolectric} + test + + + org.robolectric + shadows-supportv4 + ${version.robolectric} + test + + + android + android + ${version.android.sdk} + jar + provided + + + com.android.support + design + ${version.android.support} + aar + + + com.android.support + appcompat-v7 + ${version.android.support} + aar + + + com.android.support + preference-v7 + ${version.android.support} + aar + + + com.android.support + cardview-v7 + ${version.android.support} + aar + + + com.android.support + recyclerview-v7 + ${version.android.support} + aar + + + + diff --git a/service-ejb/build.gradle b/service-ejb/build.gradle new file mode 100644 index 0000000..150dda3 --- /dev/null +++ b/service-ejb/build.gradle @@ -0,0 +1,19 @@ +description = 'Maptology Service Ejb' + +dependencies { + compileOnly "javax:javaee-api:${versionJavaee}" + compileOnly "com.fasterxml.jackson.core:jackson-annotations:${versionJackson}" + compile project(':common-api') + compile project(':service-geocode') + + testCompile "javax:javaee-api:${versionJavaee}" + testCompile "javax.xml.bind:jaxb-api:${versionJaxb}" + testCompile "com.fasterxml.jackson.core:jackson-databind:${versionJackson}" + testCompile "junit:junit:${versionJunit}" + testCompile "org.picketbox:picketbox:${versionPicketbox}" + testCompile "org.jboss.arquillian.junit:arquillian-junit-container:${versionArquillianJunit}" + testCompile "org.wildfly.arquillian:wildfly-arquillian-container-managed:${versionArquillianContainer}" +} + +// depend on wildfly task for testing +test.dependsOn(project(":service-wildfly").tasks["build"]) diff --git a/service/ejb/pom.xml b/service-ejb/pom.xml similarity index 89% rename from service/ejb/pom.xml rename to service-ejb/pom.xml index a547560..a6740cf 100644 --- a/service/ejb/pom.xml +++ b/service-ejb/pom.xml @@ -4,11 +4,11 @@ 4.0.0 com.maptology - service + project 0.0.1-SNAPSHOT - com.maptology.service - ejb + com.maptology + service-ejb Maptology Service Ejb Ejbs for the maptology service. ejb @@ -40,12 +40,12 @@ com.maptology - api + common-api ${project.version} - com.maptology.service - geocode + com.maptology + service-geocode ${project.version} @@ -72,8 +72,8 @@ - com.maptology.service - wildfly + com.maptology + service-wildfly ${project.version} pom test diff --git a/service/ejb/src/main/java/com/maptology/service/conversion/AbstractConverter.java b/service-ejb/src/main/java/com/maptology/service/conversion/AbstractConverter.java similarity index 100% rename from service/ejb/src/main/java/com/maptology/service/conversion/AbstractConverter.java rename to service-ejb/src/main/java/com/maptology/service/conversion/AbstractConverter.java diff --git a/service/ejb/src/main/java/com/maptology/service/conversion/AbstractDeviceConverter.java b/service-ejb/src/main/java/com/maptology/service/conversion/AbstractDeviceConverter.java similarity index 100% rename from service/ejb/src/main/java/com/maptology/service/conversion/AbstractDeviceConverter.java rename to service-ejb/src/main/java/com/maptology/service/conversion/AbstractDeviceConverter.java diff --git a/service/ejb/src/main/java/com/maptology/service/conversion/AbstractEntityConverter.java b/service-ejb/src/main/java/com/maptology/service/conversion/AbstractEntityConverter.java similarity index 100% rename from service/ejb/src/main/java/com/maptology/service/conversion/AbstractEntityConverter.java rename to service-ejb/src/main/java/com/maptology/service/conversion/AbstractEntityConverter.java diff --git a/service/ejb/src/main/java/com/maptology/service/conversion/DeviceConverter.java b/service-ejb/src/main/java/com/maptology/service/conversion/DeviceConverter.java similarity index 100% rename from service/ejb/src/main/java/com/maptology/service/conversion/DeviceConverter.java rename to service-ejb/src/main/java/com/maptology/service/conversion/DeviceConverter.java diff --git a/service/ejb/src/main/java/com/maptology/service/conversion/DeviceHandleConverter.java b/service-ejb/src/main/java/com/maptology/service/conversion/DeviceHandleConverter.java similarity index 100% rename from service/ejb/src/main/java/com/maptology/service/conversion/DeviceHandleConverter.java rename to service-ejb/src/main/java/com/maptology/service/conversion/DeviceHandleConverter.java diff --git a/service/ejb/src/main/java/com/maptology/service/conversion/EmailConverter.java b/service-ejb/src/main/java/com/maptology/service/conversion/EmailConverter.java similarity index 100% rename from service/ejb/src/main/java/com/maptology/service/conversion/EmailConverter.java rename to service-ejb/src/main/java/com/maptology/service/conversion/EmailConverter.java diff --git a/service/ejb/src/main/java/com/maptology/service/conversion/IConverter.java b/service-ejb/src/main/java/com/maptology/service/conversion/IConverter.java similarity index 100% rename from service/ejb/src/main/java/com/maptology/service/conversion/IConverter.java rename to service-ejb/src/main/java/com/maptology/service/conversion/IConverter.java diff --git a/service/ejb/src/main/java/com/maptology/service/conversion/LocationConverter.java b/service-ejb/src/main/java/com/maptology/service/conversion/LocationConverter.java similarity index 100% rename from service/ejb/src/main/java/com/maptology/service/conversion/LocationConverter.java rename to service-ejb/src/main/java/com/maptology/service/conversion/LocationConverter.java diff --git a/service/ejb/src/main/java/com/maptology/service/conversion/MessageConverter.java b/service-ejb/src/main/java/com/maptology/service/conversion/MessageConverter.java similarity index 100% rename from service/ejb/src/main/java/com/maptology/service/conversion/MessageConverter.java rename to service-ejb/src/main/java/com/maptology/service/conversion/MessageConverter.java diff --git a/service/ejb/src/main/java/com/maptology/service/conversion/NoticeConverter.java b/service-ejb/src/main/java/com/maptology/service/conversion/NoticeConverter.java similarity index 100% rename from service/ejb/src/main/java/com/maptology/service/conversion/NoticeConverter.java rename to service-ejb/src/main/java/com/maptology/service/conversion/NoticeConverter.java diff --git a/service/ejb/src/main/java/com/maptology/service/conversion/PlaceConverter.java b/service-ejb/src/main/java/com/maptology/service/conversion/PlaceConverter.java similarity index 100% rename from service/ejb/src/main/java/com/maptology/service/conversion/PlaceConverter.java rename to service-ejb/src/main/java/com/maptology/service/conversion/PlaceConverter.java diff --git a/service/ejb/src/main/java/com/maptology/service/conversion/PositionConverter.java b/service-ejb/src/main/java/com/maptology/service/conversion/PositionConverter.java similarity index 100% rename from service/ejb/src/main/java/com/maptology/service/conversion/PositionConverter.java rename to service-ejb/src/main/java/com/maptology/service/conversion/PositionConverter.java diff --git a/service/ejb/src/main/java/com/maptology/service/conversion/PrivilegeConverter.java b/service-ejb/src/main/java/com/maptology/service/conversion/PrivilegeConverter.java similarity index 100% rename from service/ejb/src/main/java/com/maptology/service/conversion/PrivilegeConverter.java rename to service-ejb/src/main/java/com/maptology/service/conversion/PrivilegeConverter.java diff --git a/service/ejb/src/main/java/com/maptology/service/conversion/ShareConverter.java b/service-ejb/src/main/java/com/maptology/service/conversion/ShareConverter.java similarity index 100% rename from service/ejb/src/main/java/com/maptology/service/conversion/ShareConverter.java rename to service-ejb/src/main/java/com/maptology/service/conversion/ShareConverter.java diff --git a/service/ejb/src/main/java/com/maptology/service/conversion/ShareInfoConverter.java b/service-ejb/src/main/java/com/maptology/service/conversion/ShareInfoConverter.java similarity index 100% rename from service/ejb/src/main/java/com/maptology/service/conversion/ShareInfoConverter.java rename to service-ejb/src/main/java/com/maptology/service/conversion/ShareInfoConverter.java diff --git a/service/ejb/src/main/java/com/maptology/service/conversion/UserConverter.java b/service-ejb/src/main/java/com/maptology/service/conversion/UserConverter.java similarity index 100% rename from service/ejb/src/main/java/com/maptology/service/conversion/UserConverter.java rename to service-ejb/src/main/java/com/maptology/service/conversion/UserConverter.java diff --git a/service/ejb/src/main/java/com/maptology/service/conversion/VisitConverter.java b/service-ejb/src/main/java/com/maptology/service/conversion/VisitConverter.java similarity index 100% rename from service/ejb/src/main/java/com/maptology/service/conversion/VisitConverter.java rename to service-ejb/src/main/java/com/maptology/service/conversion/VisitConverter.java diff --git a/service/ejb/src/main/java/com/maptology/service/conversion/package-info.java b/service-ejb/src/main/java/com/maptology/service/conversion/package-info.java similarity index 100% rename from service/ejb/src/main/java/com/maptology/service/conversion/package-info.java rename to service-ejb/src/main/java/com/maptology/service/conversion/package-info.java diff --git a/service/ejb/src/main/java/com/maptology/service/crypto/SecureException.java b/service-ejb/src/main/java/com/maptology/service/crypto/SecureException.java similarity index 100% rename from service/ejb/src/main/java/com/maptology/service/crypto/SecureException.java rename to service-ejb/src/main/java/com/maptology/service/crypto/SecureException.java diff --git a/service/ejb/src/main/java/com/maptology/service/crypto/SecureHash.java b/service-ejb/src/main/java/com/maptology/service/crypto/SecureHash.java similarity index 100% rename from service/ejb/src/main/java/com/maptology/service/crypto/SecureHash.java rename to service-ejb/src/main/java/com/maptology/service/crypto/SecureHash.java diff --git a/service/ejb/src/main/java/com/maptology/service/crypto/SecureToken.java b/service-ejb/src/main/java/com/maptology/service/crypto/SecureToken.java similarity index 100% rename from service/ejb/src/main/java/com/maptology/service/crypto/SecureToken.java rename to service-ejb/src/main/java/com/maptology/service/crypto/SecureToken.java diff --git a/service/ejb/src/main/java/com/maptology/service/crypto/TokenType.java b/service-ejb/src/main/java/com/maptology/service/crypto/TokenType.java similarity index 100% rename from service/ejb/src/main/java/com/maptology/service/crypto/TokenType.java rename to service-ejb/src/main/java/com/maptology/service/crypto/TokenType.java diff --git a/service/ejb/src/main/java/com/maptology/service/crypto/package-info.java b/service-ejb/src/main/java/com/maptology/service/crypto/package-info.java similarity index 100% rename from service/ejb/src/main/java/com/maptology/service/crypto/package-info.java rename to service-ejb/src/main/java/com/maptology/service/crypto/package-info.java diff --git a/service/ejb/src/main/java/com/maptology/service/entity/AbstractEntity.java b/service-ejb/src/main/java/com/maptology/service/entity/AbstractEntity.java similarity index 100% rename from service/ejb/src/main/java/com/maptology/service/entity/AbstractEntity.java rename to service-ejb/src/main/java/com/maptology/service/entity/AbstractEntity.java diff --git a/service/ejb/src/main/java/com/maptology/service/entity/AbstractUserSpecificEntity.java b/service-ejb/src/main/java/com/maptology/service/entity/AbstractUserSpecificEntity.java similarity index 100% rename from service/ejb/src/main/java/com/maptology/service/entity/AbstractUserSpecificEntity.java rename to service-ejb/src/main/java/com/maptology/service/entity/AbstractUserSpecificEntity.java diff --git a/service/ejb/src/main/java/com/maptology/service/entity/CodeEntity.java b/service-ejb/src/main/java/com/maptology/service/entity/CodeEntity.java similarity index 100% rename from service/ejb/src/main/java/com/maptology/service/entity/CodeEntity.java rename to service-ejb/src/main/java/com/maptology/service/entity/CodeEntity.java diff --git a/service/ejb/src/main/java/com/maptology/service/entity/CodeType.java b/service-ejb/src/main/java/com/maptology/service/entity/CodeType.java similarity index 100% rename from service/ejb/src/main/java/com/maptology/service/entity/CodeType.java rename to service-ejb/src/main/java/com/maptology/service/entity/CodeType.java diff --git a/service/ejb/src/main/java/com/maptology/service/entity/DeviceEntity.java b/service-ejb/src/main/java/com/maptology/service/entity/DeviceEntity.java similarity index 100% rename from service/ejb/src/main/java/com/maptology/service/entity/DeviceEntity.java rename to service-ejb/src/main/java/com/maptology/service/entity/DeviceEntity.java diff --git a/service/ejb/src/main/java/com/maptology/service/entity/EmailEntity.java b/service-ejb/src/main/java/com/maptology/service/entity/EmailEntity.java similarity index 100% rename from service/ejb/src/main/java/com/maptology/service/entity/EmailEntity.java rename to service-ejb/src/main/java/com/maptology/service/entity/EmailEntity.java diff --git a/service/ejb/src/main/java/com/maptology/service/entity/EmbeddedCoordinate.java b/service-ejb/src/main/java/com/maptology/service/entity/EmbeddedCoordinate.java similarity index 100% rename from service/ejb/src/main/java/com/maptology/service/entity/EmbeddedCoordinate.java rename to service-ejb/src/main/java/com/maptology/service/entity/EmbeddedCoordinate.java diff --git a/service/ejb/src/main/java/com/maptology/service/entity/EmbeddedMessage.java b/service-ejb/src/main/java/com/maptology/service/entity/EmbeddedMessage.java similarity index 100% rename from service/ejb/src/main/java/com/maptology/service/entity/EmbeddedMessage.java rename to service-ejb/src/main/java/com/maptology/service/entity/EmbeddedMessage.java diff --git a/service/ejb/src/main/java/com/maptology/service/entity/EntityConflictException.java b/service-ejb/src/main/java/com/maptology/service/entity/EntityConflictException.java similarity index 100% rename from service/ejb/src/main/java/com/maptology/service/entity/EntityConflictException.java rename to service-ejb/src/main/java/com/maptology/service/entity/EntityConflictException.java diff --git a/service/ejb/src/main/java/com/maptology/service/entity/EntityException.java b/service-ejb/src/main/java/com/maptology/service/entity/EntityException.java similarity index 100% rename from service/ejb/src/main/java/com/maptology/service/entity/EntityException.java rename to service-ejb/src/main/java/com/maptology/service/entity/EntityException.java diff --git a/service/ejb/src/main/java/com/maptology/service/entity/EntityForbiddenException.java b/service-ejb/src/main/java/com/maptology/service/entity/EntityForbiddenException.java similarity index 100% rename from service/ejb/src/main/java/com/maptology/service/entity/EntityForbiddenException.java rename to service-ejb/src/main/java/com/maptology/service/entity/EntityForbiddenException.java diff --git a/service/ejb/src/main/java/com/maptology/service/entity/EntityNotFoundException.java b/service-ejb/src/main/java/com/maptology/service/entity/EntityNotFoundException.java similarity index 100% rename from service/ejb/src/main/java/com/maptology/service/entity/EntityNotFoundException.java rename to service-ejb/src/main/java/com/maptology/service/entity/EntityNotFoundException.java diff --git a/service/ejb/src/main/java/com/maptology/service/entity/LocationEntity.java b/service-ejb/src/main/java/com/maptology/service/entity/LocationEntity.java similarity index 100% rename from service/ejb/src/main/java/com/maptology/service/entity/LocationEntity.java rename to service-ejb/src/main/java/com/maptology/service/entity/LocationEntity.java diff --git a/service/ejb/src/main/java/com/maptology/service/entity/NoticeEntity.java b/service-ejb/src/main/java/com/maptology/service/entity/NoticeEntity.java similarity index 100% rename from service/ejb/src/main/java/com/maptology/service/entity/NoticeEntity.java rename to service-ejb/src/main/java/com/maptology/service/entity/NoticeEntity.java diff --git a/service/ejb/src/main/java/com/maptology/service/entity/OrderCriterion.java b/service-ejb/src/main/java/com/maptology/service/entity/OrderCriterion.java similarity index 100% rename from service/ejb/src/main/java/com/maptology/service/entity/OrderCriterion.java rename to service-ejb/src/main/java/com/maptology/service/entity/OrderCriterion.java diff --git a/service/ejb/src/main/java/com/maptology/service/entity/PlaceEntity.java b/service-ejb/src/main/java/com/maptology/service/entity/PlaceEntity.java similarity index 100% rename from service/ejb/src/main/java/com/maptology/service/entity/PlaceEntity.java rename to service-ejb/src/main/java/com/maptology/service/entity/PlaceEntity.java diff --git a/service/ejb/src/main/java/com/maptology/service/entity/PositionEntity.java b/service-ejb/src/main/java/com/maptology/service/entity/PositionEntity.java similarity index 100% rename from service/ejb/src/main/java/com/maptology/service/entity/PositionEntity.java rename to service-ejb/src/main/java/com/maptology/service/entity/PositionEntity.java diff --git a/service/ejb/src/main/java/com/maptology/service/entity/PrivilegeEntity.java b/service-ejb/src/main/java/com/maptology/service/entity/PrivilegeEntity.java similarity index 100% rename from service/ejb/src/main/java/com/maptology/service/entity/PrivilegeEntity.java rename to service-ejb/src/main/java/com/maptology/service/entity/PrivilegeEntity.java diff --git a/service/ejb/src/main/java/com/maptology/service/entity/RoleEntity.java b/service-ejb/src/main/java/com/maptology/service/entity/RoleEntity.java similarity index 100% rename from service/ejb/src/main/java/com/maptology/service/entity/RoleEntity.java rename to service-ejb/src/main/java/com/maptology/service/entity/RoleEntity.java diff --git a/service/ejb/src/main/java/com/maptology/service/entity/ShareEntity.java b/service-ejb/src/main/java/com/maptology/service/entity/ShareEntity.java similarity index 100% rename from service/ejb/src/main/java/com/maptology/service/entity/ShareEntity.java rename to service-ejb/src/main/java/com/maptology/service/entity/ShareEntity.java diff --git a/service/ejb/src/main/java/com/maptology/service/entity/UserEntity.java b/service-ejb/src/main/java/com/maptology/service/entity/UserEntity.java similarity index 100% rename from service/ejb/src/main/java/com/maptology/service/entity/UserEntity.java rename to service-ejb/src/main/java/com/maptology/service/entity/UserEntity.java diff --git a/service/ejb/src/main/java/com/maptology/service/entity/VisitEntity.java b/service-ejb/src/main/java/com/maptology/service/entity/VisitEntity.java similarity index 100% rename from service/ejb/src/main/java/com/maptology/service/entity/VisitEntity.java rename to service-ejb/src/main/java/com/maptology/service/entity/VisitEntity.java diff --git a/service/ejb/src/main/java/com/maptology/service/entity/package-info.java b/service-ejb/src/main/java/com/maptology/service/entity/package-info.java similarity index 100% rename from service/ejb/src/main/java/com/maptology/service/entity/package-info.java rename to service-ejb/src/main/java/com/maptology/service/entity/package-info.java diff --git a/service/ejb/src/main/java/com/maptology/service/injection/Datasources.java b/service-ejb/src/main/java/com/maptology/service/injection/Datasources.java similarity index 100% rename from service/ejb/src/main/java/com/maptology/service/injection/Datasources.java rename to service-ejb/src/main/java/com/maptology/service/injection/Datasources.java diff --git a/service/ejb/src/main/java/com/maptology/service/injection/Loggers.java b/service-ejb/src/main/java/com/maptology/service/injection/Loggers.java similarity index 100% rename from service/ejb/src/main/java/com/maptology/service/injection/Loggers.java rename to service-ejb/src/main/java/com/maptology/service/injection/Loggers.java diff --git a/service/ejb/src/main/java/com/maptology/service/injection/Public.java b/service-ejb/src/main/java/com/maptology/service/injection/Public.java similarity index 100% rename from service/ejb/src/main/java/com/maptology/service/injection/Public.java rename to service-ejb/src/main/java/com/maptology/service/injection/Public.java diff --git a/service/ejb/src/main/java/com/maptology/service/injection/Sessions.java b/service-ejb/src/main/java/com/maptology/service/injection/Sessions.java similarity index 100% rename from service/ejb/src/main/java/com/maptology/service/injection/Sessions.java rename to service-ejb/src/main/java/com/maptology/service/injection/Sessions.java diff --git a/service/ejb/src/main/java/com/maptology/service/injection/package-info.java b/service-ejb/src/main/java/com/maptology/service/injection/package-info.java similarity index 100% rename from service/ejb/src/main/java/com/maptology/service/injection/package-info.java rename to service-ejb/src/main/java/com/maptology/service/injection/package-info.java diff --git a/service/ejb/src/main/java/com/maptology/service/principal/LoginManager.java b/service-ejb/src/main/java/com/maptology/service/principal/LoginManager.java similarity index 100% rename from service/ejb/src/main/java/com/maptology/service/principal/LoginManager.java rename to service-ejb/src/main/java/com/maptology/service/principal/LoginManager.java diff --git a/service/ejb/src/main/java/com/maptology/service/principal/MaptologyPrincipal.java b/service-ejb/src/main/java/com/maptology/service/principal/MaptologyPrincipal.java similarity index 100% rename from service/ejb/src/main/java/com/maptology/service/principal/MaptologyPrincipal.java rename to service-ejb/src/main/java/com/maptology/service/principal/MaptologyPrincipal.java diff --git a/service/ejb/src/main/java/com/maptology/service/session/AbstractPrincipalSessionBean.java b/service-ejb/src/main/java/com/maptology/service/session/AbstractPrincipalSessionBean.java similarity index 100% rename from service/ejb/src/main/java/com/maptology/service/session/AbstractPrincipalSessionBean.java rename to service-ejb/src/main/java/com/maptology/service/session/AbstractPrincipalSessionBean.java diff --git a/service/ejb/src/main/java/com/maptology/service/session/AbstractSessionBean.java b/service-ejb/src/main/java/com/maptology/service/session/AbstractSessionBean.java similarity index 100% rename from service/ejb/src/main/java/com/maptology/service/session/AbstractSessionBean.java rename to service-ejb/src/main/java/com/maptology/service/session/AbstractSessionBean.java diff --git a/service/ejb/src/main/java/com/maptology/service/session/AbstractUserSpecificSessionBean.java b/service-ejb/src/main/java/com/maptology/service/session/AbstractUserSpecificSessionBean.java similarity index 100% rename from service/ejb/src/main/java/com/maptology/service/session/AbstractUserSpecificSessionBean.java rename to service-ejb/src/main/java/com/maptology/service/session/AbstractUserSpecificSessionBean.java diff --git a/service/ejb/src/main/java/com/maptology/service/session/DataSessionBean.java b/service-ejb/src/main/java/com/maptology/service/session/DataSessionBean.java similarity index 100% rename from service/ejb/src/main/java/com/maptology/service/session/DataSessionBean.java rename to service-ejb/src/main/java/com/maptology/service/session/DataSessionBean.java diff --git a/service/ejb/src/main/java/com/maptology/service/session/DebugDataSessionBean.java b/service-ejb/src/main/java/com/maptology/service/session/DebugDataSessionBean.java similarity index 100% rename from service/ejb/src/main/java/com/maptology/service/session/DebugDataSessionBean.java rename to service-ejb/src/main/java/com/maptology/service/session/DebugDataSessionBean.java diff --git a/service/ejb/src/main/java/com/maptology/service/session/DebugEmailSessionBean.java b/service-ejb/src/main/java/com/maptology/service/session/DebugEmailSessionBean.java similarity index 100% rename from service/ejb/src/main/java/com/maptology/service/session/DebugEmailSessionBean.java rename to service-ejb/src/main/java/com/maptology/service/session/DebugEmailSessionBean.java diff --git a/service/ejb/src/main/java/com/maptology/service/session/DebugPositionSessionBean.java b/service-ejb/src/main/java/com/maptology/service/session/DebugPositionSessionBean.java similarity index 100% rename from service/ejb/src/main/java/com/maptology/service/session/DebugPositionSessionBean.java rename to service-ejb/src/main/java/com/maptology/service/session/DebugPositionSessionBean.java diff --git a/service/ejb/src/main/java/com/maptology/service/session/DeviceSessionBean.java b/service-ejb/src/main/java/com/maptology/service/session/DeviceSessionBean.java similarity index 100% rename from service/ejb/src/main/java/com/maptology/service/session/DeviceSessionBean.java rename to service-ejb/src/main/java/com/maptology/service/session/DeviceSessionBean.java diff --git a/service/ejb/src/main/java/com/maptology/service/session/EmailSessionBean.java b/service-ejb/src/main/java/com/maptology/service/session/EmailSessionBean.java similarity index 100% rename from service/ejb/src/main/java/com/maptology/service/session/EmailSessionBean.java rename to service-ejb/src/main/java/com/maptology/service/session/EmailSessionBean.java diff --git a/service/ejb/src/main/java/com/maptology/service/session/GeocoderSessionBean.java b/service-ejb/src/main/java/com/maptology/service/session/GeocoderSessionBean.java similarity index 100% rename from service/ejb/src/main/java/com/maptology/service/session/GeocoderSessionBean.java rename to service-ejb/src/main/java/com/maptology/service/session/GeocoderSessionBean.java diff --git a/service/ejb/src/main/java/com/maptology/service/session/IDataSessionBean.java b/service-ejb/src/main/java/com/maptology/service/session/IDataSessionBean.java similarity index 100% rename from service/ejb/src/main/java/com/maptology/service/session/IDataSessionBean.java rename to service-ejb/src/main/java/com/maptology/service/session/IDataSessionBean.java diff --git a/service/ejb/src/main/java/com/maptology/service/session/IDebugEmailSessionBean.java b/service-ejb/src/main/java/com/maptology/service/session/IDebugEmailSessionBean.java similarity index 100% rename from service/ejb/src/main/java/com/maptology/service/session/IDebugEmailSessionBean.java rename to service-ejb/src/main/java/com/maptology/service/session/IDebugEmailSessionBean.java diff --git a/service/ejb/src/main/java/com/maptology/service/session/IEmailSessionBean.java b/service-ejb/src/main/java/com/maptology/service/session/IEmailSessionBean.java similarity index 100% rename from service/ejb/src/main/java/com/maptology/service/session/IEmailSessionBean.java rename to service-ejb/src/main/java/com/maptology/service/session/IEmailSessionBean.java diff --git a/service/ejb/src/main/java/com/maptology/service/session/IPositionSessionBean.java b/service-ejb/src/main/java/com/maptology/service/session/IPositionSessionBean.java similarity index 100% rename from service/ejb/src/main/java/com/maptology/service/session/IPositionSessionBean.java rename to service-ejb/src/main/java/com/maptology/service/session/IPositionSessionBean.java diff --git a/service/ejb/src/main/java/com/maptology/service/session/LocationSessionBean.java b/service-ejb/src/main/java/com/maptology/service/session/LocationSessionBean.java similarity index 100% rename from service/ejb/src/main/java/com/maptology/service/session/LocationSessionBean.java rename to service-ejb/src/main/java/com/maptology/service/session/LocationSessionBean.java diff --git a/service/ejb/src/main/java/com/maptology/service/session/LogSessionBean.java b/service-ejb/src/main/java/com/maptology/service/session/LogSessionBean.java similarity index 100% rename from service/ejb/src/main/java/com/maptology/service/session/LogSessionBean.java rename to service-ejb/src/main/java/com/maptology/service/session/LogSessionBean.java diff --git a/service/ejb/src/main/java/com/maptology/service/session/NoticeSessionBean.java b/service-ejb/src/main/java/com/maptology/service/session/NoticeSessionBean.java similarity index 100% rename from service/ejb/src/main/java/com/maptology/service/session/NoticeSessionBean.java rename to service-ejb/src/main/java/com/maptology/service/session/NoticeSessionBean.java diff --git a/service/ejb/src/main/java/com/maptology/service/session/PlaceSessionBean.java b/service-ejb/src/main/java/com/maptology/service/session/PlaceSessionBean.java similarity index 100% rename from service/ejb/src/main/java/com/maptology/service/session/PlaceSessionBean.java rename to service-ejb/src/main/java/com/maptology/service/session/PlaceSessionBean.java diff --git a/service/ejb/src/main/java/com/maptology/service/session/PositionSessionBean.java b/service-ejb/src/main/java/com/maptology/service/session/PositionSessionBean.java similarity index 100% rename from service/ejb/src/main/java/com/maptology/service/session/PositionSessionBean.java rename to service-ejb/src/main/java/com/maptology/service/session/PositionSessionBean.java diff --git a/service/ejb/src/main/java/com/maptology/service/session/PrivilegeSessionBean.java b/service-ejb/src/main/java/com/maptology/service/session/PrivilegeSessionBean.java similarity index 100% rename from service/ejb/src/main/java/com/maptology/service/session/PrivilegeSessionBean.java rename to service-ejb/src/main/java/com/maptology/service/session/PrivilegeSessionBean.java diff --git a/service/ejb/src/main/java/com/maptology/service/session/ShareSessionBean.java b/service-ejb/src/main/java/com/maptology/service/session/ShareSessionBean.java similarity index 100% rename from service/ejb/src/main/java/com/maptology/service/session/ShareSessionBean.java rename to service-ejb/src/main/java/com/maptology/service/session/ShareSessionBean.java diff --git a/service/ejb/src/main/java/com/maptology/service/session/StartupBean.java b/service-ejb/src/main/java/com/maptology/service/session/StartupBean.java similarity index 100% rename from service/ejb/src/main/java/com/maptology/service/session/StartupBean.java rename to service-ejb/src/main/java/com/maptology/service/session/StartupBean.java diff --git a/service/ejb/src/main/java/com/maptology/service/session/StatisticsSessionBean.java b/service-ejb/src/main/java/com/maptology/service/session/StatisticsSessionBean.java similarity index 100% rename from service/ejb/src/main/java/com/maptology/service/session/StatisticsSessionBean.java rename to service-ejb/src/main/java/com/maptology/service/session/StatisticsSessionBean.java diff --git a/service/ejb/src/main/java/com/maptology/service/session/UserSessionBean.java b/service-ejb/src/main/java/com/maptology/service/session/UserSessionBean.java similarity index 100% rename from service/ejb/src/main/java/com/maptology/service/session/UserSessionBean.java rename to service-ejb/src/main/java/com/maptology/service/session/UserSessionBean.java diff --git a/service/ejb/src/main/java/com/maptology/service/session/VersionSessionBean.java b/service-ejb/src/main/java/com/maptology/service/session/VersionSessionBean.java similarity index 100% rename from service/ejb/src/main/java/com/maptology/service/session/VersionSessionBean.java rename to service-ejb/src/main/java/com/maptology/service/session/VersionSessionBean.java diff --git a/service/ejb/src/main/java/com/maptology/service/session/VisitSessionBean.java b/service-ejb/src/main/java/com/maptology/service/session/VisitSessionBean.java similarity index 100% rename from service/ejb/src/main/java/com/maptology/service/session/VisitSessionBean.java rename to service-ejb/src/main/java/com/maptology/service/session/VisitSessionBean.java diff --git a/service/ejb/src/main/java/com/maptology/service/session/package-info.java b/service-ejb/src/main/java/com/maptology/service/session/package-info.java similarity index 100% rename from service/ejb/src/main/java/com/maptology/service/session/package-info.java rename to service-ejb/src/main/java/com/maptology/service/session/package-info.java diff --git a/service/ejb/src/main/java/com/maptology/service/template/EmailAssignment.java b/service-ejb/src/main/java/com/maptology/service/template/EmailAssignment.java similarity index 100% rename from service/ejb/src/main/java/com/maptology/service/template/EmailAssignment.java rename to service-ejb/src/main/java/com/maptology/service/template/EmailAssignment.java diff --git a/service/ejb/src/main/java/com/maptology/service/template/EmailMessage.java b/service-ejb/src/main/java/com/maptology/service/template/EmailMessage.java similarity index 100% rename from service/ejb/src/main/java/com/maptology/service/template/EmailMessage.java rename to service-ejb/src/main/java/com/maptology/service/template/EmailMessage.java diff --git a/service/ejb/src/main/java/com/maptology/service/template/EmailTemplate.java b/service-ejb/src/main/java/com/maptology/service/template/EmailTemplate.java similarity index 100% rename from service/ejb/src/main/java/com/maptology/service/template/EmailTemplate.java rename to service-ejb/src/main/java/com/maptology/service/template/EmailTemplate.java diff --git a/service/ejb/src/main/java/com/maptology/service/template/Template.java b/service-ejb/src/main/java/com/maptology/service/template/Template.java similarity index 100% rename from service/ejb/src/main/java/com/maptology/service/template/Template.java rename to service-ejb/src/main/java/com/maptology/service/template/Template.java diff --git a/service/ejb/src/main/java/com/maptology/service/template/package-info.java b/service-ejb/src/main/java/com/maptology/service/template/package-info.java similarity index 100% rename from service/ejb/src/main/java/com/maptology/service/template/package-info.java rename to service-ejb/src/main/java/com/maptology/service/template/package-info.java diff --git a/service/ejb/src/main/resources/META-INF/beans.xml b/service-ejb/src/main/resources/META-INF/beans.xml similarity index 100% rename from service/ejb/src/main/resources/META-INF/beans.xml rename to service-ejb/src/main/resources/META-INF/beans.xml diff --git a/service/ejb/src/main/resources/META-INF/jboss-ejb3.xml b/service-ejb/src/main/resources/META-INF/jboss-ejb3.xml similarity index 100% rename from service/ejb/src/main/resources/META-INF/jboss-ejb3.xml rename to service-ejb/src/main/resources/META-INF/jboss-ejb3.xml diff --git a/service/ejb/src/main/resources/META-INF/persistence.xml b/service-ejb/src/main/resources/META-INF/persistence.xml similarity index 100% rename from service/ejb/src/main/resources/META-INF/persistence.xml rename to service-ejb/src/main/resources/META-INF/persistence.xml diff --git a/service/ejb/src/main/resources/emails/new-email.txt b/service-ejb/src/main/resources/emails/new-email.txt similarity index 100% rename from service/ejb/src/main/resources/emails/new-email.txt rename to service-ejb/src/main/resources/emails/new-email.txt diff --git a/service/ejb/src/main/resources/emails/new-user.txt b/service-ejb/src/main/resources/emails/new-user.txt similarity index 100% rename from service/ejb/src/main/resources/emails/new-user.txt rename to service-ejb/src/main/resources/emails/new-user.txt diff --git a/service/ejb/src/main/resources/emails/reset-user.txt b/service-ejb/src/main/resources/emails/reset-user.txt similarity index 100% rename from service/ejb/src/main/resources/emails/reset-user.txt rename to service-ejb/src/main/resources/emails/reset-user.txt diff --git a/service/ejb/src/test/java/com/maptology/service/test/EjbDeployment.java b/service-ejb/src/test/java/com/maptology/service/test/EjbDeployment.java similarity index 100% rename from service/ejb/src/test/java/com/maptology/service/test/EjbDeployment.java rename to service-ejb/src/test/java/com/maptology/service/test/EjbDeployment.java diff --git a/service/ejb/src/test/java/com/maptology/service/test/login/LoginModule.java b/service-ejb/src/test/java/com/maptology/service/test/login/LoginModule.java similarity index 100% rename from service/ejb/src/test/java/com/maptology/service/test/login/LoginModule.java rename to service-ejb/src/test/java/com/maptology/service/test/login/LoginModule.java diff --git a/service/ejb/src/test/java/com/maptology/service/test/login/package-info.java b/service-ejb/src/test/java/com/maptology/service/test/login/package-info.java similarity index 100% rename from service/ejb/src/test/java/com/maptology/service/test/login/package-info.java rename to service-ejb/src/test/java/com/maptology/service/test/login/package-info.java diff --git a/service/ejb/src/test/java/com/maptology/service/test/package-info.java b/service-ejb/src/test/java/com/maptology/service/test/package-info.java similarity index 100% rename from service/ejb/src/test/java/com/maptology/service/test/package-info.java rename to service-ejb/src/test/java/com/maptology/service/test/package-info.java diff --git a/service/ejb/src/test/java/com/maptology/service/test/session/AbstractSessionTest.java b/service-ejb/src/test/java/com/maptology/service/test/session/AbstractSessionTest.java similarity index 100% rename from service/ejb/src/test/java/com/maptology/service/test/session/AbstractSessionTest.java rename to service-ejb/src/test/java/com/maptology/service/test/session/AbstractSessionTest.java diff --git a/service/ejb/src/test/java/com/maptology/service/test/session/DeviceSessionTest.java b/service-ejb/src/test/java/com/maptology/service/test/session/DeviceSessionTest.java similarity index 100% rename from service/ejb/src/test/java/com/maptology/service/test/session/DeviceSessionTest.java rename to service-ejb/src/test/java/com/maptology/service/test/session/DeviceSessionTest.java diff --git a/service/ejb/src/test/java/com/maptology/service/test/session/HistorySessionTest.java b/service-ejb/src/test/java/com/maptology/service/test/session/HistorySessionTest.java similarity index 100% rename from service/ejb/src/test/java/com/maptology/service/test/session/HistorySessionTest.java rename to service-ejb/src/test/java/com/maptology/service/test/session/HistorySessionTest.java diff --git a/service/ejb/src/test/java/com/maptology/service/test/session/LocationSessionTest.java b/service-ejb/src/test/java/com/maptology/service/test/session/LocationSessionTest.java similarity index 100% rename from service/ejb/src/test/java/com/maptology/service/test/session/LocationSessionTest.java rename to service-ejb/src/test/java/com/maptology/service/test/session/LocationSessionTest.java diff --git a/service/ejb/src/test/java/com/maptology/service/test/session/LogSessionTest.java b/service-ejb/src/test/java/com/maptology/service/test/session/LogSessionTest.java similarity index 100% rename from service/ejb/src/test/java/com/maptology/service/test/session/LogSessionTest.java rename to service-ejb/src/test/java/com/maptology/service/test/session/LogSessionTest.java diff --git a/service/ejb/src/test/java/com/maptology/service/test/session/NoticeSessionTest.java b/service-ejb/src/test/java/com/maptology/service/test/session/NoticeSessionTest.java similarity index 100% rename from service/ejb/src/test/java/com/maptology/service/test/session/NoticeSessionTest.java rename to service-ejb/src/test/java/com/maptology/service/test/session/NoticeSessionTest.java diff --git a/service/ejb/src/test/java/com/maptology/service/test/session/PrivilegeSessionTest.java b/service-ejb/src/test/java/com/maptology/service/test/session/PrivilegeSessionTest.java similarity index 100% rename from service/ejb/src/test/java/com/maptology/service/test/session/PrivilegeSessionTest.java rename to service-ejb/src/test/java/com/maptology/service/test/session/PrivilegeSessionTest.java diff --git a/service/ejb/src/test/java/com/maptology/service/test/session/ShareSessionTest.java b/service-ejb/src/test/java/com/maptology/service/test/session/ShareSessionTest.java similarity index 100% rename from service/ejb/src/test/java/com/maptology/service/test/session/ShareSessionTest.java rename to service-ejb/src/test/java/com/maptology/service/test/session/ShareSessionTest.java diff --git a/service/ejb/src/test/java/com/maptology/service/test/session/UserSessionTest.java b/service-ejb/src/test/java/com/maptology/service/test/session/UserSessionTest.java similarity index 100% rename from service/ejb/src/test/java/com/maptology/service/test/session/UserSessionTest.java rename to service-ejb/src/test/java/com/maptology/service/test/session/UserSessionTest.java diff --git a/service/ejb/src/test/java/com/maptology/service/test/session/VersionSessionTest.java b/service-ejb/src/test/java/com/maptology/service/test/session/VersionSessionTest.java similarity index 100% rename from service/ejb/src/test/java/com/maptology/service/test/session/VersionSessionTest.java rename to service-ejb/src/test/java/com/maptology/service/test/session/VersionSessionTest.java diff --git a/service/ejb/src/test/java/com/maptology/service/test/session/package-info.java b/service-ejb/src/test/java/com/maptology/service/test/session/package-info.java similarity index 100% rename from service/ejb/src/test/java/com/maptology/service/test/session/package-info.java rename to service-ejb/src/test/java/com/maptology/service/test/session/package-info.java diff --git a/service/ejb/src/test/java/com/maptology/service/test/unit/EmailTemplateTest.java b/service-ejb/src/test/java/com/maptology/service/test/unit/EmailTemplateTest.java similarity index 100% rename from service/ejb/src/test/java/com/maptology/service/test/unit/EmailTemplateTest.java rename to service-ejb/src/test/java/com/maptology/service/test/unit/EmailTemplateTest.java diff --git a/service/ejb/src/test/java/com/maptology/service/test/unit/package-info.java b/service-ejb/src/test/java/com/maptology/service/test/unit/package-info.java similarity index 100% rename from service/ejb/src/test/java/com/maptology/service/test/unit/package-info.java rename to service-ejb/src/test/java/com/maptology/service/test/unit/package-info.java diff --git a/service/ejb/src/test/resources/META-INF/beans.xml b/service-ejb/src/test/resources/META-INF/beans.xml similarity index 100% rename from service/ejb/src/test/resources/META-INF/beans.xml rename to service-ejb/src/test/resources/META-INF/beans.xml diff --git a/service/ejb/src/test/resources/META-INF/persistence.xml b/service-ejb/src/test/resources/META-INF/persistence.xml similarity index 100% rename from service/ejb/src/test/resources/META-INF/persistence.xml rename to service-ejb/src/test/resources/META-INF/persistence.xml diff --git a/service/ejb/src/test/resources/arquillian.xml b/service-ejb/src/test/resources/arquillian.xml similarity index 76% rename from service/ejb/src/test/resources/arquillian.xml rename to service-ejb/src/test/resources/arquillian.xml index f269afb..a8f4d90 100644 --- a/service/ejb/src/test/resources/arquillian.xml +++ b/service-ejb/src/test/resources/arquillian.xml @@ -17,9 +17,9 @@ -Djboss.socket.binding.port-offset=1000 - ../wildfly/wildfly-10.1.0.Final - org.jboss.logmanager.LogManager - ../../../../ejb/src/test/resources/wildfly.xml + ../service-wildfly/wildfly-17.0.1.Final + + ../../../../service-ejb/src/test/resources/wildfly.xml diff --git a/service/ejb/src/test/resources/emails/new-email.txt b/service-ejb/src/test/resources/emails/new-email.txt similarity index 100% rename from service/ejb/src/test/resources/emails/new-email.txt rename to service-ejb/src/test/resources/emails/new-email.txt diff --git a/service/ejb/src/test/resources/emails/new-user.txt b/service-ejb/src/test/resources/emails/new-user.txt similarity index 100% rename from service/ejb/src/test/resources/emails/new-user.txt rename to service-ejb/src/test/resources/emails/new-user.txt diff --git a/service/ejb/src/test/resources/emails/reset-user.txt b/service-ejb/src/test/resources/emails/reset-user.txt similarity index 100% rename from service/ejb/src/test/resources/emails/reset-user.txt rename to service-ejb/src/test/resources/emails/reset-user.txt diff --git a/service/ejb/src/test/resources/wildfly.xml b/service-ejb/src/test/resources/wildfly.xml similarity index 100% rename from service/ejb/src/test/resources/wildfly.xml rename to service-ejb/src/test/resources/wildfly.xml diff --git a/service-geocode/build.gradle b/service-geocode/build.gradle new file mode 100644 index 0000000..1ac85d9 --- /dev/null +++ b/service-geocode/build.gradle @@ -0,0 +1,14 @@ +description = 'Maptology Service Geocode' + +dependencies { + compileOnly "javax.xml.bind:jaxb-api:${versionJaxb}" + compileOnly "org.jboss.resteasy:resteasy-client:${versionResteasy}" + compileOnly "org.jboss.resteasy:resteasy-jackson2-provider:${versionResteasy}" + testCompile "junit:junit:${versionJunit}" +} + +// make compile only dependencies available for testing +sourceSets { + test.compileClasspath += configurations.compileOnly + test.runtimeClasspath += configurations.compileOnly +} \ No newline at end of file diff --git a/service/geocode/pom.xml b/service-geocode/pom.xml similarity index 85% rename from service/geocode/pom.xml rename to service-geocode/pom.xml index 0515921..1ce4536 100644 --- a/service/geocode/pom.xml +++ b/service-geocode/pom.xml @@ -4,11 +4,11 @@ 4.0.0 com.maptology - service + project 0.0.1-SNAPSHOT - com.maptology.service - geocode + com.maptology + service-geocode Maptology Service Geocode Remote geocoding API from Locoslab. jar @@ -24,6 +24,10 @@ + + javax.xml.bind + jaxb-api + org.jboss.resteasy resteasy-client diff --git a/service/geocode/src/main/java/com/maptology/service/geocode/GeoLocation.java b/service-geocode/src/main/java/com/maptology/service/geocode/GeoLocation.java similarity index 100% rename from service/geocode/src/main/java/com/maptology/service/geocode/GeoLocation.java rename to service-geocode/src/main/java/com/maptology/service/geocode/GeoLocation.java diff --git a/service/geocode/src/main/java/com/maptology/service/geocode/GeoLocationSubtype.java b/service-geocode/src/main/java/com/maptology/service/geocode/GeoLocationSubtype.java similarity index 100% rename from service/geocode/src/main/java/com/maptology/service/geocode/GeoLocationSubtype.java rename to service-geocode/src/main/java/com/maptology/service/geocode/GeoLocationSubtype.java diff --git a/service/geocode/src/main/java/com/maptology/service/geocode/GeoLocationType.java b/service-geocode/src/main/java/com/maptology/service/geocode/GeoLocationType.java similarity index 100% rename from service/geocode/src/main/java/com/maptology/service/geocode/GeoLocationType.java rename to service-geocode/src/main/java/com/maptology/service/geocode/GeoLocationType.java diff --git a/service/geocode/src/main/java/com/maptology/service/geocode/GeocoderBuilder.java b/service-geocode/src/main/java/com/maptology/service/geocode/GeocoderBuilder.java similarity index 100% rename from service/geocode/src/main/java/com/maptology/service/geocode/GeocoderBuilder.java rename to service-geocode/src/main/java/com/maptology/service/geocode/GeocoderBuilder.java diff --git a/service/geocode/src/main/java/com/maptology/service/geocode/IGeocoderService.java b/service-geocode/src/main/java/com/maptology/service/geocode/IGeocoderService.java similarity index 100% rename from service/geocode/src/main/java/com/maptology/service/geocode/IGeocoderService.java rename to service-geocode/src/main/java/com/maptology/service/geocode/IGeocoderService.java diff --git a/service/geocode/src/main/java/com/maptology/service/geocode/package-info.java b/service-geocode/src/main/java/com/maptology/service/geocode/package-info.java similarity index 100% rename from service/geocode/src/main/java/com/maptology/service/geocode/package-info.java rename to service-geocode/src/main/java/com/maptology/service/geocode/package-info.java diff --git a/service/geocode/src/test/java/com/maptology/service/geocode/GeocoderServiceTest.java b/service-geocode/src/test/java/com/maptology/service/geocode/GeocoderServiceTest.java similarity index 100% rename from service/geocode/src/test/java/com/maptology/service/geocode/GeocoderServiceTest.java rename to service-geocode/src/test/java/com/maptology/service/geocode/GeocoderServiceTest.java diff --git a/service-thorntail/build.gradle b/service-thorntail/build.gradle new file mode 100644 index 0000000..e89e70b --- /dev/null +++ b/service-thorntail/build.gradle @@ -0,0 +1,16 @@ +description = 'Maptology Service Swarm' + +dependencies { + compile "io.thorntail:datasources:${versionThorntail}" + compile "io.thorntail:jaxrs:${versionThorntail}" + compile "io.thorntail:jpa:${versionThorntail}" + compile "io.thorntail:jaxrs-validator:${versionThorntail}" + compile "io.thorntail:ejb:${versionThorntail}" + compile "io.thorntail:cdi:${versionThorntail}" + compile "io.thorntail:security:${versionThorntail}" + compile "io.thorntail:mail:${versionThorntail}" + compile "com.h2database:h2:${versionH2database}" + compile "io.swagger:swagger-jaxrs:${versionSwagger}" + compile project(':service-war') +} + diff --git a/service/swarm/pom.xml b/service-thorntail/pom.xml similarity index 93% rename from service/swarm/pom.xml rename to service-thorntail/pom.xml index 449a226..4f230bf 100644 --- a/service/swarm/pom.xml +++ b/service-thorntail/pom.xml @@ -4,11 +4,11 @@ 4.0.0 com.maptology - service + project 0.0.1-SNAPSHOT - com.maptology.service - swarm + com.maptology + service-swarm Maptology Service Swarm Wildfly swarms launcher for war module. jar @@ -78,8 +78,8 @@ 1.4.196 - com.maptology.service - war + com.maptology + service-war ${project.version} classes diff --git a/service/swarm/src/main/java/com/maptology/service/app/MaptologySwarmApplication.java b/service-thorntail/src/main/java/com/maptology/service/app/MaptologySwarmApplication.java similarity index 100% rename from service/swarm/src/main/java/com/maptology/service/app/MaptologySwarmApplication.java rename to service-thorntail/src/main/java/com/maptology/service/app/MaptologySwarmApplication.java diff --git a/service/swarm/src/main/java/com/maptology/service/rest/MaptologySwaggerListing.java b/service-thorntail/src/main/java/com/maptology/service/rest/MaptologySwaggerListing.java similarity index 100% rename from service/swarm/src/main/java/com/maptology/service/rest/MaptologySwaggerListing.java rename to service-thorntail/src/main/java/com/maptology/service/rest/MaptologySwaggerListing.java diff --git a/service/swarm/src/main/java/com/maptology/service/swarm/MaptologySwarm.java b/service-thorntail/src/main/java/com/maptology/service/swarm/MaptologySwarm.java similarity index 100% rename from service/swarm/src/main/java/com/maptology/service/swarm/MaptologySwarm.java rename to service-thorntail/src/main/java/com/maptology/service/swarm/MaptologySwarm.java diff --git a/service/swarm/src/main/resources/beans.xml b/service-thorntail/src/main/resources/beans.xml similarity index 100% rename from service/swarm/src/main/resources/beans.xml rename to service-thorntail/src/main/resources/beans.xml diff --git a/service/swarm/src/main/resources/jboss-ejb3.xml b/service-thorntail/src/main/resources/jboss-ejb3.xml similarity index 100% rename from service/swarm/src/main/resources/jboss-ejb3.xml rename to service-thorntail/src/main/resources/jboss-ejb3.xml diff --git a/service/swarm/src/main/resources/jboss-web.xml b/service-thorntail/src/main/resources/jboss-web.xml similarity index 100% rename from service/swarm/src/main/resources/jboss-web.xml rename to service-thorntail/src/main/resources/jboss-web.xml diff --git a/service/swarm/src/main/resources/persistence.xml b/service-thorntail/src/main/resources/persistence.xml similarity index 100% rename from service/swarm/src/main/resources/persistence.xml rename to service-thorntail/src/main/resources/persistence.xml diff --git a/service/swarm/src/main/resources/web.xml b/service-thorntail/src/main/resources/web.xml similarity index 100% rename from service/swarm/src/main/resources/web.xml rename to service-thorntail/src/main/resources/web.xml diff --git a/service/swarm/src/main/webapp/favicon-16x16.png b/service-thorntail/src/main/webapp/favicon-16x16.png similarity index 100% rename from service/swarm/src/main/webapp/favicon-16x16.png rename to service-thorntail/src/main/webapp/favicon-16x16.png diff --git a/service/swarm/src/main/webapp/favicon-32x32.png b/service-thorntail/src/main/webapp/favicon-32x32.png similarity index 100% rename from service/swarm/src/main/webapp/favicon-32x32.png rename to service-thorntail/src/main/webapp/favicon-32x32.png diff --git a/service/swarm/src/main/webapp/index.html b/service-thorntail/src/main/webapp/index.html similarity index 100% rename from service/swarm/src/main/webapp/index.html rename to service-thorntail/src/main/webapp/index.html diff --git a/service/swarm/src/main/webapp/oauth2-redirect.html b/service-thorntail/src/main/webapp/oauth2-redirect.html similarity index 100% rename from service/swarm/src/main/webapp/oauth2-redirect.html rename to service-thorntail/src/main/webapp/oauth2-redirect.html diff --git a/service/swarm/src/main/webapp/swagger-ui-bundle.js b/service-thorntail/src/main/webapp/swagger-ui-bundle.js similarity index 100% rename from service/swarm/src/main/webapp/swagger-ui-bundle.js rename to service-thorntail/src/main/webapp/swagger-ui-bundle.js diff --git a/service/swarm/src/main/webapp/swagger-ui-standalone-preset.js b/service-thorntail/src/main/webapp/swagger-ui-standalone-preset.js similarity index 100% rename from service/swarm/src/main/webapp/swagger-ui-standalone-preset.js rename to service-thorntail/src/main/webapp/swagger-ui-standalone-preset.js diff --git a/service/swarm/src/main/webapp/swagger-ui.css b/service-thorntail/src/main/webapp/swagger-ui.css similarity index 100% rename from service/swarm/src/main/webapp/swagger-ui.css rename to service-thorntail/src/main/webapp/swagger-ui.css diff --git a/service/swarm/src/main/webapp/swagger-ui.css.map b/service-thorntail/src/main/webapp/swagger-ui.css.map similarity index 100% rename from service/swarm/src/main/webapp/swagger-ui.css.map rename to service-thorntail/src/main/webapp/swagger-ui.css.map diff --git a/service/swarm/src/main/webapp/swagger-ui.js b/service-thorntail/src/main/webapp/swagger-ui.js similarity index 100% rename from service/swarm/src/main/webapp/swagger-ui.js rename to service-thorntail/src/main/webapp/swagger-ui.js diff --git a/service/swarm/src/main/webapp/swagger-ui.js.map b/service-thorntail/src/main/webapp/swagger-ui.js.map similarity index 100% rename from service/swarm/src/main/webapp/swagger-ui.js.map rename to service-thorntail/src/main/webapp/swagger-ui.js.map diff --git a/service-war/build.gradle b/service-war/build.gradle new file mode 100644 index 0000000..51a8651 --- /dev/null +++ b/service-war/build.gradle @@ -0,0 +1,28 @@ +plugins { + id 'war' +} + +description = 'Maptology Service War' + +dependencies { + compile project(':service-ejb') + testCompile "junit:junit:${versionJunit}" + testCompile "org.jboss.arquillian.junit:arquillian-junit-container:${versionArquillianJunit}" + testCompile "org.wildfly.arquillian:wildfly-arquillian-container-managed:${versionArquillianContainer}" + providedCompile "javax:javaee-api:${versionJavaee}" + providedCompile "com.fasterxml.jackson.core:jackson-databind:${versionJackson}" + providedCompile "org.jboss.resteasy:resteasy-client:${versionResteasy}" +} + +jar { + enabled = true +} + +war { + from( new File(project(":common-api").buildDir, "/swagger/") ) { + include 'maptology.json' + } +} + +// depend on wildfly task for testing +test.dependsOn(project(":service-wildfly").tasks["build"]) diff --git a/service/war/pom.xml b/service-war/pom.xml similarity index 92% rename from service/war/pom.xml rename to service-war/pom.xml index 985db8a..ca5d323 100644 --- a/service/war/pom.xml +++ b/service-war/pom.xml @@ -4,11 +4,11 @@ 4.0.0 com.maptology - service + project 0.0.1-SNAPSHOT - com.maptology.service - war + com.maptology + service-war Maptology Service War War of the maptology service. war @@ -27,7 +27,7 @@ com.maptology - api + common-api ${project.version} swagger maptology.json @@ -70,8 +70,8 @@ - com.maptology.service - ejb + com.maptology + service-ejb ${project.version} @@ -106,8 +106,8 @@ - com.maptology.service - wildfly + com.maptology + service-wildfly ${project.version} pom test diff --git a/service/war/src/main/java/com/maptology/service/access/AccessControlFilter.java b/service-war/src/main/java/com/maptology/service/access/AccessControlFilter.java similarity index 100% rename from service/war/src/main/java/com/maptology/service/access/AccessControlFilter.java rename to service-war/src/main/java/com/maptology/service/access/AccessControlFilter.java diff --git a/service/war/src/main/java/com/maptology/service/access/package-info.java b/service-war/src/main/java/com/maptology/service/access/package-info.java similarity index 100% rename from service/war/src/main/java/com/maptology/service/access/package-info.java rename to service-war/src/main/java/com/maptology/service/access/package-info.java diff --git a/service/war/src/main/java/com/maptology/service/app/MaptologyApplication.java b/service-war/src/main/java/com/maptology/service/app/MaptologyApplication.java similarity index 100% rename from service/war/src/main/java/com/maptology/service/app/MaptologyApplication.java rename to service-war/src/main/java/com/maptology/service/app/MaptologyApplication.java diff --git a/service/war/src/main/java/com/maptology/service/app/MaptologyContextListener.java b/service-war/src/main/java/com/maptology/service/app/MaptologyContextListener.java similarity index 100% rename from service/war/src/main/java/com/maptology/service/app/MaptologyContextListener.java rename to service-war/src/main/java/com/maptology/service/app/MaptologyContextListener.java diff --git a/service/war/src/main/java/com/maptology/service/app/MaptologyTime.java b/service-war/src/main/java/com/maptology/service/app/MaptologyTime.java similarity index 100% rename from service/war/src/main/java/com/maptology/service/app/MaptologyTime.java rename to service-war/src/main/java/com/maptology/service/app/MaptologyTime.java diff --git a/service/war/src/main/java/com/maptology/service/auth/MaptologyAuthConfig.java b/service-war/src/main/java/com/maptology/service/auth/MaptologyAuthConfig.java similarity index 100% rename from service/war/src/main/java/com/maptology/service/auth/MaptologyAuthConfig.java rename to service-war/src/main/java/com/maptology/service/auth/MaptologyAuthConfig.java diff --git a/service/war/src/main/java/com/maptology/service/auth/MaptologyAuthContext.java b/service-war/src/main/java/com/maptology/service/auth/MaptologyAuthContext.java similarity index 100% rename from service/war/src/main/java/com/maptology/service/auth/MaptologyAuthContext.java rename to service-war/src/main/java/com/maptology/service/auth/MaptologyAuthContext.java diff --git a/service/war/src/main/java/com/maptology/service/auth/MaptologyAuthModule.java b/service-war/src/main/java/com/maptology/service/auth/MaptologyAuthModule.java similarity index 100% rename from service/war/src/main/java/com/maptology/service/auth/MaptologyAuthModule.java rename to service-war/src/main/java/com/maptology/service/auth/MaptologyAuthModule.java diff --git a/service/war/src/main/java/com/maptology/service/auth/MaptologyAuthProvider.java b/service-war/src/main/java/com/maptology/service/auth/MaptologyAuthProvider.java similarity index 100% rename from service/war/src/main/java/com/maptology/service/auth/MaptologyAuthProvider.java rename to service-war/src/main/java/com/maptology/service/auth/MaptologyAuthProvider.java diff --git a/service/war/src/main/java/com/maptology/service/auth/basic/BasicAuthCredential.java b/service-war/src/main/java/com/maptology/service/auth/basic/BasicAuthCredential.java similarity index 100% rename from service/war/src/main/java/com/maptology/service/auth/basic/BasicAuthCredential.java rename to service-war/src/main/java/com/maptology/service/auth/basic/BasicAuthCredential.java diff --git a/service/war/src/main/java/com/maptology/service/auth/bearer/BearerAuthCredential.java b/service-war/src/main/java/com/maptology/service/auth/bearer/BearerAuthCredential.java similarity index 100% rename from service/war/src/main/java/com/maptology/service/auth/bearer/BearerAuthCredential.java rename to service-war/src/main/java/com/maptology/service/auth/bearer/BearerAuthCredential.java diff --git a/service/war/src/main/java/com/maptology/service/auth/http/AbstractHttpServletAuthModule.java b/service-war/src/main/java/com/maptology/service/auth/http/AbstractHttpServletAuthModule.java similarity index 100% rename from service/war/src/main/java/com/maptology/service/auth/http/AbstractHttpServletAuthModule.java rename to service-war/src/main/java/com/maptology/service/auth/http/AbstractHttpServletAuthModule.java diff --git a/service/war/src/main/java/com/maptology/service/auth/http/HttpServletMessageInfo.java b/service-war/src/main/java/com/maptology/service/auth/http/HttpServletMessageInfo.java similarity index 100% rename from service/war/src/main/java/com/maptology/service/auth/http/HttpServletMessageInfo.java rename to service-war/src/main/java/com/maptology/service/auth/http/HttpServletMessageInfo.java diff --git a/service/war/src/main/java/com/maptology/service/auth/package-info.java b/service-war/src/main/java/com/maptology/service/auth/package-info.java similarity index 100% rename from service/war/src/main/java/com/maptology/service/auth/package-info.java rename to service-war/src/main/java/com/maptology/service/auth/package-info.java diff --git a/service/war/src/main/java/com/maptology/service/rest/DeviceResource.java b/service-war/src/main/java/com/maptology/service/rest/DeviceResource.java similarity index 100% rename from service/war/src/main/java/com/maptology/service/rest/DeviceResource.java rename to service-war/src/main/java/com/maptology/service/rest/DeviceResource.java diff --git a/service/war/src/main/java/com/maptology/service/rest/HistoryResource.java b/service-war/src/main/java/com/maptology/service/rest/HistoryResource.java similarity index 100% rename from service/war/src/main/java/com/maptology/service/rest/HistoryResource.java rename to service-war/src/main/java/com/maptology/service/rest/HistoryResource.java diff --git a/service/war/src/main/java/com/maptology/service/rest/LocationResource.java b/service-war/src/main/java/com/maptology/service/rest/LocationResource.java similarity index 100% rename from service/war/src/main/java/com/maptology/service/rest/LocationResource.java rename to service-war/src/main/java/com/maptology/service/rest/LocationResource.java diff --git a/service/war/src/main/java/com/maptology/service/rest/LogResource.java b/service-war/src/main/java/com/maptology/service/rest/LogResource.java similarity index 100% rename from service/war/src/main/java/com/maptology/service/rest/LogResource.java rename to service-war/src/main/java/com/maptology/service/rest/LogResource.java diff --git a/service/war/src/main/java/com/maptology/service/rest/NoticeResource.java b/service-war/src/main/java/com/maptology/service/rest/NoticeResource.java similarity index 100% rename from service/war/src/main/java/com/maptology/service/rest/NoticeResource.java rename to service-war/src/main/java/com/maptology/service/rest/NoticeResource.java diff --git a/service/war/src/main/java/com/maptology/service/rest/PrivilegeResource.java b/service-war/src/main/java/com/maptology/service/rest/PrivilegeResource.java similarity index 100% rename from service/war/src/main/java/com/maptology/service/rest/PrivilegeResource.java rename to service-war/src/main/java/com/maptology/service/rest/PrivilegeResource.java diff --git a/service/war/src/main/java/com/maptology/service/rest/ProcessingTimeFilter.java b/service-war/src/main/java/com/maptology/service/rest/ProcessingTimeFilter.java similarity index 100% rename from service/war/src/main/java/com/maptology/service/rest/ProcessingTimeFilter.java rename to service-war/src/main/java/com/maptology/service/rest/ProcessingTimeFilter.java diff --git a/service/war/src/main/java/com/maptology/service/rest/ServerDebugFilter.java b/service-war/src/main/java/com/maptology/service/rest/ServerDebugFilter.java similarity index 100% rename from service/war/src/main/java/com/maptology/service/rest/ServerDebugFilter.java rename to service-war/src/main/java/com/maptology/service/rest/ServerDebugFilter.java diff --git a/service/war/src/main/java/com/maptology/service/rest/ShareResource.java b/service-war/src/main/java/com/maptology/service/rest/ShareResource.java similarity index 100% rename from service/war/src/main/java/com/maptology/service/rest/ShareResource.java rename to service-war/src/main/java/com/maptology/service/rest/ShareResource.java diff --git a/service/war/src/main/java/com/maptology/service/rest/UserResource.java b/service-war/src/main/java/com/maptology/service/rest/UserResource.java similarity index 100% rename from service/war/src/main/java/com/maptology/service/rest/UserResource.java rename to service-war/src/main/java/com/maptology/service/rest/UserResource.java diff --git a/service/war/src/main/java/com/maptology/service/rest/VersionResource.java b/service-war/src/main/java/com/maptology/service/rest/VersionResource.java similarity index 100% rename from service/war/src/main/java/com/maptology/service/rest/VersionResource.java rename to service-war/src/main/java/com/maptology/service/rest/VersionResource.java diff --git a/service/war/src/main/java/com/maptology/service/servlet/TestServlet.java b/service-war/src/main/java/com/maptology/service/servlet/TestServlet.java similarity index 100% rename from service/war/src/main/java/com/maptology/service/servlet/TestServlet.java rename to service-war/src/main/java/com/maptology/service/servlet/TestServlet.java diff --git a/service/war/src/main/java/com/maptology/service/socket/LogMessageEncoder.java b/service-war/src/main/java/com/maptology/service/socket/LogMessageEncoder.java similarity index 100% rename from service/war/src/main/java/com/maptology/service/socket/LogMessageEncoder.java rename to service-war/src/main/java/com/maptology/service/socket/LogMessageEncoder.java diff --git a/service/war/src/main/java/com/maptology/service/socket/LogMessageSender.java b/service-war/src/main/java/com/maptology/service/socket/LogMessageSender.java similarity index 100% rename from service/war/src/main/java/com/maptology/service/socket/LogMessageSender.java rename to service-war/src/main/java/com/maptology/service/socket/LogMessageSender.java diff --git a/service/war/src/main/java/com/maptology/service/socket/LogStreamSocket.java b/service-war/src/main/java/com/maptology/service/socket/LogStreamSocket.java similarity index 100% rename from service/war/src/main/java/com/maptology/service/socket/LogStreamSocket.java rename to service-war/src/main/java/com/maptology/service/socket/LogStreamSocket.java diff --git a/service/war/src/main/java/com/maptology/service/socket/package-info.java b/service-war/src/main/java/com/maptology/service/socket/package-info.java similarity index 100% rename from service/war/src/main/java/com/maptology/service/socket/package-info.java rename to service-war/src/main/java/com/maptology/service/socket/package-info.java diff --git a/service/war/src/main/webapp/WEB-INF/jboss-web.xml b/service-war/src/main/webapp/WEB-INF/jboss-web.xml similarity index 100% rename from service/war/src/main/webapp/WEB-INF/jboss-web.xml rename to service-war/src/main/webapp/WEB-INF/jboss-web.xml diff --git a/service/war/src/main/webapp/WEB-INF/web.xml b/service-war/src/main/webapp/WEB-INF/web.xml similarity index 100% rename from service/war/src/main/webapp/WEB-INF/web.xml rename to service-war/src/main/webapp/WEB-INF/web.xml diff --git a/service/war/src/main/webapp/favicon-16x16.png b/service-war/src/main/webapp/favicon-16x16.png similarity index 100% rename from service/war/src/main/webapp/favicon-16x16.png rename to service-war/src/main/webapp/favicon-16x16.png diff --git a/service/war/src/main/webapp/favicon-32x32.png b/service-war/src/main/webapp/favicon-32x32.png similarity index 100% rename from service/war/src/main/webapp/favicon-32x32.png rename to service-war/src/main/webapp/favicon-32x32.png diff --git a/service/war/src/main/webapp/index.html b/service-war/src/main/webapp/index.html similarity index 100% rename from service/war/src/main/webapp/index.html rename to service-war/src/main/webapp/index.html diff --git a/service/war/src/main/webapp/oauth2-redirect.html b/service-war/src/main/webapp/oauth2-redirect.html similarity index 100% rename from service/war/src/main/webapp/oauth2-redirect.html rename to service-war/src/main/webapp/oauth2-redirect.html diff --git a/service/war/src/main/webapp/swagger-ui-bundle.js b/service-war/src/main/webapp/swagger-ui-bundle.js similarity index 100% rename from service/war/src/main/webapp/swagger-ui-bundle.js rename to service-war/src/main/webapp/swagger-ui-bundle.js diff --git a/service/war/src/main/webapp/swagger-ui-standalone-preset.js b/service-war/src/main/webapp/swagger-ui-standalone-preset.js similarity index 100% rename from service/war/src/main/webapp/swagger-ui-standalone-preset.js rename to service-war/src/main/webapp/swagger-ui-standalone-preset.js diff --git a/service/war/src/main/webapp/swagger-ui.css b/service-war/src/main/webapp/swagger-ui.css similarity index 100% rename from service/war/src/main/webapp/swagger-ui.css rename to service-war/src/main/webapp/swagger-ui.css diff --git a/service/war/src/main/webapp/swagger-ui.css.map b/service-war/src/main/webapp/swagger-ui.css.map similarity index 100% rename from service/war/src/main/webapp/swagger-ui.css.map rename to service-war/src/main/webapp/swagger-ui.css.map diff --git a/service/war/src/main/webapp/swagger-ui.js b/service-war/src/main/webapp/swagger-ui.js similarity index 100% rename from service/war/src/main/webapp/swagger-ui.js rename to service-war/src/main/webapp/swagger-ui.js diff --git a/service/war/src/main/webapp/swagger-ui.js.map b/service-war/src/main/webapp/swagger-ui.js.map similarity index 100% rename from service/war/src/main/webapp/swagger-ui.js.map rename to service-war/src/main/webapp/swagger-ui.js.map diff --git a/service/war/src/test/java/com/maptology/service/test/WarDeployment.java b/service-war/src/test/java/com/maptology/service/test/WarDeployment.java similarity index 100% rename from service/war/src/test/java/com/maptology/service/test/WarDeployment.java rename to service-war/src/test/java/com/maptology/service/test/WarDeployment.java diff --git a/service/war/src/test/java/com/maptology/service/test/package-info.java b/service-war/src/test/java/com/maptology/service/test/package-info.java similarity index 100% rename from service/war/src/test/java/com/maptology/service/test/package-info.java rename to service-war/src/test/java/com/maptology/service/test/package-info.java diff --git a/service/war/src/test/java/com/maptology/service/test/rest/AbstractResourceTest.java b/service-war/src/test/java/com/maptology/service/test/rest/AbstractResourceTest.java similarity index 100% rename from service/war/src/test/java/com/maptology/service/test/rest/AbstractResourceTest.java rename to service-war/src/test/java/com/maptology/service/test/rest/AbstractResourceTest.java diff --git a/service/war/src/test/java/com/maptology/service/test/rest/AssertResponse.java b/service-war/src/test/java/com/maptology/service/test/rest/AssertResponse.java similarity index 100% rename from service/war/src/test/java/com/maptology/service/test/rest/AssertResponse.java rename to service-war/src/test/java/com/maptology/service/test/rest/AssertResponse.java diff --git a/service/war/src/test/java/com/maptology/service/test/rest/DeviceResourceTest.java b/service-war/src/test/java/com/maptology/service/test/rest/DeviceResourceTest.java similarity index 100% rename from service/war/src/test/java/com/maptology/service/test/rest/DeviceResourceTest.java rename to service-war/src/test/java/com/maptology/service/test/rest/DeviceResourceTest.java diff --git a/service/war/src/test/java/com/maptology/service/test/rest/LogResourceTest.java b/service-war/src/test/java/com/maptology/service/test/rest/LogResourceTest.java similarity index 100% rename from service/war/src/test/java/com/maptology/service/test/rest/LogResourceTest.java rename to service-war/src/test/java/com/maptology/service/test/rest/LogResourceTest.java diff --git a/service/war/src/test/java/com/maptology/service/test/rest/NoticeResourceTest.java b/service-war/src/test/java/com/maptology/service/test/rest/NoticeResourceTest.java similarity index 100% rename from service/war/src/test/java/com/maptology/service/test/rest/NoticeResourceTest.java rename to service-war/src/test/java/com/maptology/service/test/rest/NoticeResourceTest.java diff --git a/service/war/src/test/java/com/maptology/service/test/rest/ShareResourceTest.java b/service-war/src/test/java/com/maptology/service/test/rest/ShareResourceTest.java similarity index 100% rename from service/war/src/test/java/com/maptology/service/test/rest/ShareResourceTest.java rename to service-war/src/test/java/com/maptology/service/test/rest/ShareResourceTest.java diff --git a/service/war/src/test/java/com/maptology/service/test/rest/UserResourceTest.java b/service-war/src/test/java/com/maptology/service/test/rest/UserResourceTest.java similarity index 100% rename from service/war/src/test/java/com/maptology/service/test/rest/UserResourceTest.java rename to service-war/src/test/java/com/maptology/service/test/rest/UserResourceTest.java diff --git a/service/war/src/test/java/com/maptology/service/test/rest/VersionResourceTest.java b/service-war/src/test/java/com/maptology/service/test/rest/VersionResourceTest.java similarity index 100% rename from service/war/src/test/java/com/maptology/service/test/rest/VersionResourceTest.java rename to service-war/src/test/java/com/maptology/service/test/rest/VersionResourceTest.java diff --git a/service/war/src/test/java/com/maptology/service/test/rest/package-info.java b/service-war/src/test/java/com/maptology/service/test/rest/package-info.java similarity index 100% rename from service/war/src/test/java/com/maptology/service/test/rest/package-info.java rename to service-war/src/test/java/com/maptology/service/test/rest/package-info.java diff --git a/service/war/src/test/java/com/maptology/service/test/unit/BasicAuthCredentialTest.java b/service-war/src/test/java/com/maptology/service/test/unit/BasicAuthCredentialTest.java similarity index 100% rename from service/war/src/test/java/com/maptology/service/test/unit/BasicAuthCredentialTest.java rename to service-war/src/test/java/com/maptology/service/test/unit/BasicAuthCredentialTest.java diff --git a/service/war/src/test/java/com/maptology/service/test/unit/package-info.java b/service-war/src/test/java/com/maptology/service/test/unit/package-info.java similarity index 100% rename from service/war/src/test/java/com/maptology/service/test/unit/package-info.java rename to service-war/src/test/java/com/maptology/service/test/unit/package-info.java diff --git a/service/war/src/test/resources/META-INF/application.xml b/service-war/src/test/resources/META-INF/application.xml similarity index 100% rename from service/war/src/test/resources/META-INF/application.xml rename to service-war/src/test/resources/META-INF/application.xml diff --git a/service/war/src/test/resources/META-INF/beans.xml b/service-war/src/test/resources/META-INF/beans.xml similarity index 100% rename from service/war/src/test/resources/META-INF/beans.xml rename to service-war/src/test/resources/META-INF/beans.xml diff --git a/service/war/src/test/resources/META-INF/jboss-ejb3.xml b/service-war/src/test/resources/META-INF/jboss-ejb3.xml similarity index 100% rename from service/war/src/test/resources/META-INF/jboss-ejb3.xml rename to service-war/src/test/resources/META-INF/jboss-ejb3.xml diff --git a/service/war/src/test/resources/META-INF/persistence.xml b/service-war/src/test/resources/META-INF/persistence.xml similarity index 100% rename from service/war/src/test/resources/META-INF/persistence.xml rename to service-war/src/test/resources/META-INF/persistence.xml diff --git a/service/war/src/test/resources/arquillian.xml b/service-war/src/test/resources/arquillian.xml similarity index 84% rename from service/war/src/test/resources/arquillian.xml rename to service-war/src/test/resources/arquillian.xml index ab049de..fc40014 100644 --- a/service/war/src/test/resources/arquillian.xml +++ b/service-war/src/test/resources/arquillian.xml @@ -17,8 +17,7 @@ -Djboss.socket.binding.port-offset=1000 - ../wildfly/wildfly-10.1.0.Final - org.jboss.logmanager.LogManager + ../service-wildfly/wildfly-17.0.1.Final diff --git a/service/wildfly/.gitignore b/service-wildfly/.gitignore similarity index 53% rename from service/wildfly/.gitignore rename to service-wildfly/.gitignore index 4a1dc22..6633896 100644 --- a/service/wildfly/.gitignore +++ b/service-wildfly/.gitignore @@ -1,2 +1,2 @@ # ignore wildfly install -wildfly-10.1.0.Final/ \ No newline at end of file +wildfly-17.0.1.Final/ diff --git a/service-wildfly/build.gradle b/service-wildfly/build.gradle new file mode 100644 index 0000000..b8fd7ba --- /dev/null +++ b/service-wildfly/build.gradle @@ -0,0 +1,24 @@ +// define a special configuration +configurations { + wildfly +} + +dependencies { + wildfly "org.wildfly:wildfly-dist:${versionWildfly}@zip" +} + +// unpack the wildfly dependencies into the project directory +task resolveWildfly(type: Copy) { + destinationDir = file("${project.projectDir}") + from { zipTree(configurations.wildfly.singleFile) } +} + +// make sure wildfly is resolved as part of build +build.dependsOn resolveWildfly + +// add a task to enable the manual removal of the wildfly container +tasks.register("cleanWildfly") { + doLast { + delete "${project.projectDir}/wildfly-${versionWildfly}/" + } +} \ No newline at end of file diff --git a/service/wildfly/pom.xml b/service-wildfly/pom.xml similarity index 94% rename from service/wildfly/pom.xml rename to service-wildfly/pom.xml index bd68b08..ce7b795 100644 --- a/service/wildfly/pom.xml +++ b/service-wildfly/pom.xml @@ -4,11 +4,11 @@ 4.0.0 com.maptology - service + project 0.0.1-SNAPSHOT - com.maptology.service - wildfly + com.maptology + service-wildfly Maptology Service Wildfly Installs wildfly as test environment for unit tests. - 10.1.0.Final - 3.0.19.Final - 2.4.1 - - - wildfly - geocode - ejb - war - swarm - - - - - - org.jboss.arquillian.junit - arquillian-junit-container - 1.1.13.Final - test - - - org.wildfly.arquillian - wildfly-arquillian-container-embedded - 2.1.0.Final - test - - - org.wildfly.arquillian - wildfly-arquillian-container-managed - 2.1.0.Final - test - - - - - - - - maven-compiler-plugin - 3.7.0 - - - 1.8 - 1.8 - - - - - - - diff --git a/settings.gradle b/settings.gradle new file mode 100644 index 0000000..3b785a3 --- /dev/null +++ b/settings.gradle @@ -0,0 +1,12 @@ +rootProject.name = 'project' +include(':common-api') +include(':android-app') +include(':android-feign') +include(':service-wildfly') +include(':service-geocode') +include(':service-ejb') +include(':service-war') +include(':service-thorntail') +include(':web-angular') +include(':web-war') +include(':site-ear') diff --git a/site-ear/build.gradle b/site-ear/build.gradle new file mode 100644 index 0000000..5db7035 --- /dev/null +++ b/site-ear/build.gradle @@ -0,0 +1,37 @@ + +plugins { + id 'ear' +} + +description = 'Maptology Site Ear' + +dependencies { + deploy project(path: ':service-war', configuration: 'archives') + deploy project(path: ':web-war', configuration: 'archives') +} + +ear { + appDirName 'src/main/app' + libDirName 'libs' + deploymentDescriptor { + version = "7" // same as the default value + applicationName = "maptology" + initializeInOrder = true + displayName = "Maptology" + webModule("service-war-${project.version}.war", "api") + webModule("web-war-${project.version}.war", "app") + withXml { provider -> // add a custom node to the XML + provider.asNode().appendNode("Implementation-Build", "testing") + } + } + manifest { + attributes( + 'Built-By' : System.properties['user.name'], + 'Build-Timestamp': new java.text.SimpleDateFormat("yyyy-MM-dd'T'HH:mm:ss.SSSZ").format(new Date()), + 'Created-By' : "Gradle ${gradle.gradleVersion}", + 'Build-Jdk' : "${System.properties['java.version']} (${System.properties['java.vendor']} ${System.properties['java.vm.version']})", + 'Build-OS' : "${System.properties['os.name']} ${System.properties['os.arch']} ${System.properties['os.version']}", + 'Implementation-Build' : "${System.properties['jenkins.build.number']}" + ) + } +} diff --git a/ear/pom.xml b/site-ear/pom.xml similarity index 78% rename from ear/pom.xml rename to site-ear/pom.xml index f3542e2..ffab08d 100644 --- a/ear/pom.xml +++ b/site-ear/pom.xml @@ -4,11 +4,11 @@ 4.0.0 com.maptology - all + project 0.0.1-SNAPSHOT - ear - Maptology Ear + site-ear + Maptology Site Ear Ear with the maptology service and webapp. ear @@ -19,13 +19,13 @@ maptology - com.maptology.service - war + com.maptology + service-war api - com.maptology.web - webapp + com.maptology + web-war app @@ -47,14 +47,14 @@ - com.maptology.service - war + com.maptology + service-war war ${project.version} - com.maptology.web - webapp + com.maptology + web-war war ${project.version} diff --git a/testing/api-client/.gitignore b/testing/api-client/.gitignore deleted file mode 100644 index a530464..0000000 --- a/testing/api-client/.gitignore +++ /dev/null @@ -1,21 +0,0 @@ -*.class - -# Mobile Tools for Java (J2ME) -.mtj.tmp/ - -# Package Files # -*.jar -*.war -*.ear - -# exclude jar for gradle wrapper -!gradle/wrapper/*.jar - -# virtual machine crash logs, see http://www.java.com/en/download/help/error_hotspot.xml -hs_err_pid* - -# build files -**/target -target -.gradle -build diff --git a/testing/api-client/.swagger-codegen-ignore b/testing/api-client/.swagger-codegen-ignore deleted file mode 100644 index c5fa491..0000000 --- a/testing/api-client/.swagger-codegen-ignore +++ /dev/null @@ -1,23 +0,0 @@ -# Swagger Codegen Ignore -# Generated by swagger-codegen https://github.com/swagger-api/swagger-codegen - -# Use this file to prevent files from being overwritten by the generator. -# The patterns follow closely to .gitignore or .dockerignore. - -# As an example, the C# client generator defines ApiClient.cs. -# You can make changes and tell Swagger Codgen to ignore just this file by uncommenting the following line: -#ApiClient.cs - -# You can match any string of characters against a directory, file or extension with a single asterisk (*): -#foo/*/qux -# The above matches foo/bar/qux and foo/baz/qux, but not foo/bar/baz/qux - -# You can recursively match patterns against a directory, file or extension with a double asterisk (**): -#foo/**/qux -# This matches foo/bar/qux, foo/baz/qux, and foo/bar/baz/qux - -# You can also negate patterns with an exclamation (!). -# For example, you can ignore all files in a docs folder with the file extension .md: -#docs/*.md -# Then explicitly reverse the ignore rule for a single file: -#!docs/README.md diff --git a/testing/api-client/.swagger-codegen/VERSION b/testing/api-client/.swagger-codegen/VERSION deleted file mode 100644 index 717311e..0000000 --- a/testing/api-client/.swagger-codegen/VERSION +++ /dev/null @@ -1 +0,0 @@ -unset \ No newline at end of file diff --git a/testing/api-client/.travis.yml b/testing/api-client/.travis.yml deleted file mode 100644 index 70cb81a..0000000 --- a/testing/api-client/.travis.yml +++ /dev/null @@ -1,17 +0,0 @@ -# -# Generated by: https://github.com/swagger-api/swagger-codegen.git -# -language: java -jdk: - - oraclejdk8 - - oraclejdk7 -before_install: - # ensure gradlew has proper permission - - chmod a+x ./gradlew -script: - # test using maven - - mvn test - # uncomment below to test using gradle - # - gradle test - # uncomment below to test using sbt - # - sbt test diff --git a/testing/api-client/README.md b/testing/api-client/README.md deleted file mode 100644 index e64cd88..0000000 --- a/testing/api-client/README.md +++ /dev/null @@ -1,264 +0,0 @@ -# swagger-java-client - -## Requirements - -Building the API client library requires [Maven](https://maven.apache.org/) to be installed. - -## Installation - -To install the API client library to your local Maven repository, simply execute: - -```shell -mvn install -``` - -To deploy it to a remote Maven repository instead, configure the settings of the repository and execute: - -```shell -mvn deploy -``` - -Refer to the [official documentation](https://maven.apache.org/plugins/maven-deploy-plugin/usage.html) for more information. - -### Maven users - -Add this dependency to your project's POM: - -```xml - - io.swagger - swagger-java-client - 1.0.0 - compile - -``` - -### Gradle users - -Add this dependency to your project's build file: - -```groovy -compile "io.swagger:swagger-java-client:1.0.0" -``` - -### Others - -At first generate the JAR by executing: - - mvn package - -Then manually install the following JARs: - -* target/swagger-java-client-1.0.0.jar -* target/lib/*.jar - -## Getting Started - -Please follow the [installation](#installation) instruction and execute the following Java code: - -```java - -import io.swagger.client.*; -import io.swagger.client.auth.*; -import io.swagger.client.model.*; -import io.swagger.client.api.DefaultApi; - -import java.io.File; -import java.util.*; - -public class DefaultApiExample { - - public static void main(String[] args) { - ApiClient defaultClient = Configuration.getDefaultApiClient(); - - // Configure HTTP basic authorization: user - HttpBasicAuth user = (HttpBasicAuth) defaultClient.getAuthentication("user"); - user.setUsername("YOUR USERNAME"); - user.setPassword("YOUR PASSWORD"); - - DefaultApi apiInstance = new DefaultApi(); - String share = "share_example"; // String | The token of the share. - try { - Privilege result = apiInstance.addCurrentUserPrivilege(share); - System.out.println(result); - } catch (ApiException e) { - System.err.println("Exception when calling DefaultApi#addCurrentUserPrivilege"); - e.printStackTrace(); - } - } -} - -``` - -## Documentation for API Endpoints - -All URIs are relative to *http://localhost/api* - -Class | Method | HTTP request | Description ------------- | ------------- | ------------- | ------------- -*DefaultApi* | [**addCurrentUserPrivilege**](docs/DefaultApi.md#addCurrentUserPrivilege) | **POST** /users/current/privileges | Add a privilege for the specified user. -*DefaultApi* | [**addLocations**](docs/DefaultApi.md#addLocations) | **POST** /devices/current/locations | Updates the locations of the current device. -*DefaultApi* | [**addNotice**](docs/DefaultApi.md#addNotice) | **POST** /notices | Adds a new notice and returns the notice as well as its location. -*DefaultApi* | [**addUser**](docs/DefaultApi.md#addUser) | **POST** /users | Adds a user account with the specified roles and emails. -*DefaultApi* | [**addUserPrivilege**](docs/DefaultApi.md#addUserPrivilege) | **POST** /users/{id}/privileges | Returns the privileges for a particular user. -*DefaultApi* | [**createDevice**](docs/DefaultApi.md#createDevice) | **POST** /devices | Creates a new device and returns its handle. -*DefaultApi* | [**createShare**](docs/DefaultApi.md#createShare) | **POST** /shares | Creates a new share. -*DefaultApi* | [**deleteCurrentDevice**](docs/DefaultApi.md#deleteCurrentDevice) | **DELETE** /devices/current | Deletes the current device. -*DefaultApi* | [**deleteDevice**](docs/DefaultApi.md#deleteDevice) | **DELETE** /devices/{id} | Deletes a device. -*DefaultApi* | [**deletePrivilege**](docs/DefaultApi.md#deletePrivilege) | **DELETE** /privileges/{id} | Deletes a particular privilege. -*DefaultApi* | [**deleteShare**](docs/DefaultApi.md#deleteShare) | **DELETE** /shares/{id} | Delete a share. -*DefaultApi* | [**getActiveNotices**](docs/DefaultApi.md#getActiveNotices) | **GET** /notices/active | Returns a page of notices. -*DefaultApi* | [**getBuildVersion**](docs/DefaultApi.md#getBuildVersion) | **GET** /versions/build | Returns the build version. -*DefaultApi* | [**getCurrentDevice**](docs/DefaultApi.md#getCurrentDevice) | **GET** /devices/current | Returns the current device. -*DefaultApi* | [**getCurrentUser**](docs/DefaultApi.md#getCurrentUser) | **GET** /users/current | Returns the user currently authorized. -*DefaultApi* | [**getCurrentUserDevices**](docs/DefaultApi.md#getCurrentUserDevices) | **GET** /users/current/devices | Returns the list of devices for the current user. -*DefaultApi* | [**getCurrentUserPlaces**](docs/DefaultApi.md#getCurrentUserPlaces) | **GET** /users/current/places | Returns the places for the current user. -*DefaultApi* | [**getCurrentUserPrivileges**](docs/DefaultApi.md#getCurrentUserPrivileges) | **GET** /users/current/privileges | Returns the privileges for the current user. -*DefaultApi* | [**getDevice**](docs/DefaultApi.md#getDevice) | **GET** /devices/{id} | Gets a device. -*DefaultApi* | [**getDeviceLocation**](docs/DefaultApi.md#getDeviceLocation) | **GET** /devices/{id}/location | Gets the last device location. -*DefaultApi* | [**getDeviceVisits**](docs/DefaultApi.md#getDeviceVisits) | **GET** /devices/{id}/visits | Gets the last device location. -*DefaultApi* | [**getDevices**](docs/DefaultApi.md#getDevices) | **GET** /devices | Returns all devices. -*DefaultApi* | [**getEntityStatistics**](docs/DefaultApi.md#getEntityStatistics) | **GET** /log/entities | Returns a list of entity statistics. -*DefaultApi* | [**getLoadStatistic**](docs/DefaultApi.md#getLoadStatistic) | **GET** /log/load | Returns the current load statistic. -*DefaultApi* | [**getLogMessages**](docs/DefaultApi.md#getLogMessages) | **GET** /log/messages | Returns a list of log messages starting from a particular id. -*DefaultApi* | [**getNotice**](docs/DefaultApi.md#getNotice) | **GET** /notices/{id} | Returns the notice with the specified id. -*DefaultApi* | [**getNotices**](docs/DefaultApi.md#getNotices) | **GET** /notices | Returns a page of notices. -*DefaultApi* | [**getPlace**](docs/DefaultApi.md#getPlace) | **GET** /places/{id} | Returns the place with the specified id. -*DefaultApi* | [**getPlaceVisits**](docs/DefaultApi.md#getPlaceVisits) | **GET** /places/{id}/visits | Returns the visits for a particular place. -*DefaultApi* | [**getPrivilege**](docs/DefaultApi.md#getPrivilege) | **GET** /privileges/{id} | Returns the privileges for a particular user. -*DefaultApi* | [**getPrivilegeLocation**](docs/DefaultApi.md#getPrivilegeLocation) | **GET** /privileges/{id}/location | Returns the location for a particular privilege. -*DefaultApi* | [**getShare**](docs/DefaultApi.md#getShare) | **GET** /shares/{id} | Returns a share. -*DefaultApi* | [**getShareInfo**](docs/DefaultApi.md#getShareInfo) | **GET** /shares/{token}/info | Get a share info by its secret token. -*DefaultApi* | [**getShareLocation**](docs/DefaultApi.md#getShareLocation) | **GET** /shares/{token}/location | Get a shared location by its secret token. -*DefaultApi* | [**getSystemStatistic**](docs/DefaultApi.md#getSystemStatistic) | **GET** /log/system | Returns the system statistic. -*DefaultApi* | [**getUpdatedNotices**](docs/DefaultApi.md#getUpdatedNotices) | **GET** /notices/updated | Returns all active notices modified after the date. -*DefaultApi* | [**getUser**](docs/DefaultApi.md#getUser) | **GET** /users/{id} | Returns the user account with the specified id. -*DefaultApi* | [**getUserPlaces**](docs/DefaultApi.md#getUserPlaces) | **GET** /users/{id}/places | Returns the places for a particular user. -*DefaultApi* | [**getUserPrivileges**](docs/DefaultApi.md#getUserPrivileges) | **GET** /users/{id}/privileges | Returns the privileges for a particular user. -*DefaultApi* | [**getUsers**](docs/DefaultApi.md#getUsers) | **GET** /users | Returns a list of users. -*DefaultApi* | [**registerUser**](docs/DefaultApi.md#registerUser) | **POST** /users/register | Registers a new user and sends an email account verification. -*DefaultApi* | [**resetUser**](docs/DefaultApi.md#resetUser) | **POST** /users/reset | Sends a password reset email to the correspondence email account of a user. -*DefaultApi* | [**resetUserPassword**](docs/DefaultApi.md#resetUserPassword) | **PUT** /users/password/{token} | Sets the password of a user account using a token received via email. -*DefaultApi* | [**searchUsers**](docs/DefaultApi.md#searchUsers) | **GET** /users/search | Returns a list of users whose login name or name contains the term. -*DefaultApi* | [**setCurrentPassword**](docs/DefaultApi.md#setCurrentPassword) | **PUT** /users/current/password | Sets the password of the currently authorized user. -*DefaultApi* | [**setCurrentUser**](docs/DefaultApi.md#setCurrentUser) | **PUT** /users/current | Updates the currently authorized user. -*DefaultApi* | [**setDevice**](docs/DefaultApi.md#setDevice) | **PUT** /devices/{id} | Sets the values of a device. -*DefaultApi* | [**setNotice**](docs/DefaultApi.md#setNotice) | **PUT** /notices/{id} | Updates an existing notice. -*DefaultApi* | [**setPlace**](docs/DefaultApi.md#setPlace) | **PUT** /places/{id} | Updates the place with the specified id. -*DefaultApi* | [**setShare**](docs/DefaultApi.md#setShare) | **PUT** /shares/{id} | Updates an existing share. -*DefaultApi* | [**setUser**](docs/DefaultApi.md#setUser) | **PUT** /users/{id} | Updates the values of a particular user account. -*DefaultApi* | [**setUserPassword**](docs/DefaultApi.md#setUserPassword) | **PUT** /users/{id}/password | Sets the password of a user. -*DefaultApi* | [**verifyUserEmail**](docs/DefaultApi.md#verifyUserEmail) | **PUT** /users/verify/{token} | Verifies an email address using a token received via email. -*DeviceApi* | [**addLocations**](docs/DeviceApi.md#addLocations) | **POST** /devices/current/locations | Updates the locations of the current device. -*DeviceApi* | [**createDevice**](docs/DeviceApi.md#createDevice) | **POST** /devices | Creates a new device and returns its handle. -*DeviceApi* | [**deleteCurrentDevice**](docs/DeviceApi.md#deleteCurrentDevice) | **DELETE** /devices/current | Deletes the current device. -*DeviceApi* | [**deleteDevice**](docs/DeviceApi.md#deleteDevice) | **DELETE** /devices/{id} | Deletes a device. -*DeviceApi* | [**getCurrentDevice**](docs/DeviceApi.md#getCurrentDevice) | **GET** /devices/current | Returns the current device. -*DeviceApi* | [**getCurrentUserDevices**](docs/DeviceApi.md#getCurrentUserDevices) | **GET** /users/current/devices | Returns the list of devices for the current user. -*DeviceApi* | [**getDevice**](docs/DeviceApi.md#getDevice) | **GET** /devices/{id} | Gets a device. -*DeviceApi* | [**getDeviceLocation**](docs/DeviceApi.md#getDeviceLocation) | **GET** /devices/{id}/location | Gets the last device location. -*DeviceApi* | [**getDeviceVisits**](docs/DeviceApi.md#getDeviceVisits) | **GET** /devices/{id}/visits | Gets the last device location. -*DeviceApi* | [**getDevices**](docs/DeviceApi.md#getDevices) | **GET** /devices | Returns all devices. -*DeviceApi* | [**setDevice**](docs/DeviceApi.md#setDevice) | **PUT** /devices/{id} | Sets the values of a device. -*PlaceApi* | [**getPlace**](docs/PlaceApi.md#getPlace) | **GET** /places/{id} | Returns the place with the specified id. -*PlaceApi* | [**getPlaceVisits**](docs/PlaceApi.md#getPlaceVisits) | **GET** /places/{id}/visits | Returns the visits for a particular place. -*PlaceApi* | [**setPlace**](docs/PlaceApi.md#setPlace) | **PUT** /places/{id} | Updates the place with the specified id. -*PrivilegeApi* | [**deletePrivilege**](docs/PrivilegeApi.md#deletePrivilege) | **DELETE** /privileges/{id} | Deletes a particular privilege. -*PrivilegeApi* | [**getPrivilege**](docs/PrivilegeApi.md#getPrivilege) | **GET** /privileges/{id} | Returns the privileges for a particular user. -*PrivilegeApi* | [**getPrivilegeLocation**](docs/PrivilegeApi.md#getPrivilegeLocation) | **GET** /privileges/{id}/location | Returns the location for a particular privilege. -*ServiceApi* | [**addNotice**](docs/ServiceApi.md#addNotice) | **POST** /notices | Adds a new notice and returns the notice as well as its location. -*ServiceApi* | [**getActiveNotices**](docs/ServiceApi.md#getActiveNotices) | **GET** /notices/active | Returns a page of notices. -*ServiceApi* | [**getBuildVersion**](docs/ServiceApi.md#getBuildVersion) | **GET** /versions/build | Returns the build version. -*ServiceApi* | [**getEntityStatistics**](docs/ServiceApi.md#getEntityStatistics) | **GET** /log/entities | Returns a list of entity statistics. -*ServiceApi* | [**getLoadStatistic**](docs/ServiceApi.md#getLoadStatistic) | **GET** /log/load | Returns the current load statistic. -*ServiceApi* | [**getLogMessages**](docs/ServiceApi.md#getLogMessages) | **GET** /log/messages | Returns a list of log messages starting from a particular id. -*ServiceApi* | [**getNotice**](docs/ServiceApi.md#getNotice) | **GET** /notices/{id} | Returns the notice with the specified id. -*ServiceApi* | [**getNotices**](docs/ServiceApi.md#getNotices) | **GET** /notices | Returns a page of notices. -*ServiceApi* | [**getSystemStatistic**](docs/ServiceApi.md#getSystemStatistic) | **GET** /log/system | Returns the system statistic. -*ServiceApi* | [**getUpdatedNotices**](docs/ServiceApi.md#getUpdatedNotices) | **GET** /notices/updated | Returns all active notices modified after the date. -*ServiceApi* | [**setNotice**](docs/ServiceApi.md#setNotice) | **PUT** /notices/{id} | Updates an existing notice. -*ShareApi* | [**createShare**](docs/ShareApi.md#createShare) | **POST** /shares | Creates a new share. -*ShareApi* | [**deleteShare**](docs/ShareApi.md#deleteShare) | **DELETE** /shares/{id} | Delete a share. -*ShareApi* | [**getShare**](docs/ShareApi.md#getShare) | **GET** /shares/{id} | Returns a share. -*ShareApi* | [**getShareInfo**](docs/ShareApi.md#getShareInfo) | **GET** /shares/{token}/info | Get a share info by its secret token. -*ShareApi* | [**getShareLocation**](docs/ShareApi.md#getShareLocation) | **GET** /shares/{token}/location | Get a shared location by its secret token. -*ShareApi* | [**setShare**](docs/ShareApi.md#setShare) | **PUT** /shares/{id} | Updates an existing share. -*UserApi* | [**addCurrentUserPrivilege**](docs/UserApi.md#addCurrentUserPrivilege) | **POST** /users/current/privileges | Add a privilege for the specified user. -*UserApi* | [**addUser**](docs/UserApi.md#addUser) | **POST** /users | Adds a user account with the specified roles and emails. -*UserApi* | [**addUserPrivilege**](docs/UserApi.md#addUserPrivilege) | **POST** /users/{id}/privileges | Returns the privileges for a particular user. -*UserApi* | [**getCurrentUser**](docs/UserApi.md#getCurrentUser) | **GET** /users/current | Returns the user currently authorized. -*UserApi* | [**getCurrentUserPlaces**](docs/UserApi.md#getCurrentUserPlaces) | **GET** /users/current/places | Returns the places for the current user. -*UserApi* | [**getCurrentUserPrivileges**](docs/UserApi.md#getCurrentUserPrivileges) | **GET** /users/current/privileges | Returns the privileges for the current user. -*UserApi* | [**getUser**](docs/UserApi.md#getUser) | **GET** /users/{id} | Returns the user account with the specified id. -*UserApi* | [**getUserPlaces**](docs/UserApi.md#getUserPlaces) | **GET** /users/{id}/places | Returns the places for a particular user. -*UserApi* | [**getUserPrivileges**](docs/UserApi.md#getUserPrivileges) | **GET** /users/{id}/privileges | Returns the privileges for a particular user. -*UserApi* | [**getUsers**](docs/UserApi.md#getUsers) | **GET** /users | Returns a list of users. -*UserApi* | [**registerUser**](docs/UserApi.md#registerUser) | **POST** /users/register | Registers a new user and sends an email account verification. -*UserApi* | [**resetUser**](docs/UserApi.md#resetUser) | **POST** /users/reset | Sends a password reset email to the correspondence email account of a user. -*UserApi* | [**resetUserPassword**](docs/UserApi.md#resetUserPassword) | **PUT** /users/password/{token} | Sets the password of a user account using a token received via email. -*UserApi* | [**searchUsers**](docs/UserApi.md#searchUsers) | **GET** /users/search | Returns a list of users whose login name or name contains the term. -*UserApi* | [**setCurrentPassword**](docs/UserApi.md#setCurrentPassword) | **PUT** /users/current/password | Sets the password of the currently authorized user. -*UserApi* | [**setCurrentUser**](docs/UserApi.md#setCurrentUser) | **PUT** /users/current | Updates the currently authorized user. -*UserApi* | [**setUser**](docs/UserApi.md#setUser) | **PUT** /users/{id} | Updates the values of a particular user account. -*UserApi* | [**setUserPassword**](docs/UserApi.md#setUserPassword) | **PUT** /users/{id}/password | Sets the password of a user. -*UserApi* | [**verifyUserEmail**](docs/UserApi.md#verifyUserEmail) | **PUT** /users/verify/{token} | Verifies an email address using a token received via email. - - -## Documentation for Models - - - [BuildVersion](docs/BuildVersion.md) - - [Coordinate](docs/Coordinate.md) - - [Device](docs/Device.md) - - [DeviceHandle](docs/DeviceHandle.md) - - [DeviceInfo](docs/DeviceInfo.md) - - [DevicePage](docs/DevicePage.md) - - [Email](docs/Email.md) - - [EntityStatistic](docs/EntityStatistic.md) - - [LoadStatistic](docs/LoadStatistic.md) - - [Location](docs/Location.md) - - [LocationUpdate](docs/LocationUpdate.md) - - [LogMessage](docs/LogMessage.md) - - [Message](docs/Message.md) - - [Notice](docs/Notice.md) - - [NoticePage](docs/NoticePage.md) - - [Place](docs/Place.md) - - [PlacePage](docs/PlacePage.md) - - [Privilege](docs/Privilege.md) - - [PrivilegePage](docs/PrivilegePage.md) - - [ReleasedLocation](docs/ReleasedLocation.md) - - [Share](docs/Share.md) - - [ShareInfo](docs/ShareInfo.md) - - [User](docs/User.md) - - [UserPage](docs/UserPage.md) - - [UserPassword](docs/UserPassword.md) - - [UserRegistration](docs/UserRegistration.md) - - [Visit](docs/Visit.md) - - [VisitPage](docs/VisitPage.md) - - -## Documentation for Authorization - -Authentication schemes defined for the API: -### admin - -- **Type**: HTTP basic authentication - -### device - -- **Type**: API key -- **API key parameter name**: Authorization -- **Location**: HTTP header - -### user - -- **Type**: HTTP basic authentication - - -## Recommendation - -It's recommended to create an instance of `ApiClient` per thread in a multithreaded environment to avoid any potential issues. - -## Author - -nes-admin@uni-due.de - diff --git a/testing/api-client/build.gradle b/testing/api-client/build.gradle deleted file mode 100644 index 1ac0bc0..0000000 --- a/testing/api-client/build.gradle +++ /dev/null @@ -1,103 +0,0 @@ -apply plugin: 'idea' -apply plugin: 'eclipse' - -group = 'io.swagger' -version = '1.0.0' - -buildscript { - repositories { - jcenter() - } - dependencies { - classpath 'com.android.tools.build:gradle:2.3.+' - classpath 'com.github.dcendents:android-maven-gradle-plugin:1.5' - } -} - -repositories { - jcenter() -} - - -if(hasProperty('target') && target == 'android') { - - apply plugin: 'com.android.library' - apply plugin: 'com.github.dcendents.android-maven' - - android { - compileSdkVersion 25 - buildToolsVersion '25.0.2' - defaultConfig { - minSdkVersion 14 - targetSdkVersion 25 - } - compileOptions { - sourceCompatibility JavaVersion.VERSION_1_7 - targetCompatibility JavaVersion.VERSION_1_7 - } - - // Rename the aar correctly - libraryVariants.all { variant -> - variant.outputs.each { output -> - def outputFile = output.outputFile - if (outputFile != null && outputFile.name.endsWith('.aar')) { - def fileName = "${project.name}-${variant.baseName}-${version}.aar" - output.outputFile = new File(outputFile.parent, fileName) - } - } - } - - dependencies { - provided 'javax.annotation:jsr250-api:1.0' - } - } - - afterEvaluate { - android.libraryVariants.all { variant -> - def task = project.tasks.create "jar${variant.name.capitalize()}", Jar - task.description = "Create jar artifact for ${variant.name}" - task.dependsOn variant.javaCompile - task.from variant.javaCompile.destinationDir - task.destinationDir = project.file("${project.buildDir}/outputs/jar") - task.archiveName = "${project.name}-${variant.baseName}-${version}.jar" - artifacts.add('archives', task); - } - } - - task sourcesJar(type: Jar) { - from android.sourceSets.main.java.srcDirs - classifier = 'sources' - } - - artifacts { - archives sourcesJar - } - -} else { - - apply plugin: 'java' - apply plugin: 'maven' - - sourceCompatibility = JavaVersion.VERSION_1_7 - targetCompatibility = JavaVersion.VERSION_1_7 - - install { - repositories.mavenInstaller { - pom.artifactId = 'swagger-java-client' - } - } - - task execute(type:JavaExec) { - main = System.getProperty('mainClass') - classpath = sourceSets.main.runtimeClasspath - } -} - -dependencies { - compile 'io.swagger:swagger-annotations:1.5.15' - compile 'com.squareup.okhttp:okhttp:2.7.5' - compile 'com.squareup.okhttp:logging-interceptor:2.7.5' - compile 'com.google.code.gson:gson:2.8.1' - compile 'joda-time:joda-time:2.9.9' - testCompile 'junit:junit:4.12' -} diff --git a/testing/api-client/build.sbt b/testing/api-client/build.sbt deleted file mode 100644 index 1f40fff..0000000 --- a/testing/api-client/build.sbt +++ /dev/null @@ -1,20 +0,0 @@ -lazy val root = (project in file(".")). - settings( - organization := "io.swagger", - name := "swagger-java-client", - version := "1.0.0", - scalaVersion := "2.11.4", - scalacOptions ++= Seq("-feature"), - javacOptions in compile ++= Seq("-Xlint:deprecation"), - publishArtifact in (Compile, packageDoc) := false, - resolvers += Resolver.mavenLocal, - libraryDependencies ++= Seq( - "io.swagger" % "swagger-annotations" % "1.5.15", - "com.squareup.okhttp" % "okhttp" % "2.7.5", - "com.squareup.okhttp" % "logging-interceptor" % "2.7.5", - "com.google.code.gson" % "gson" % "2.8.1", - "joda-time" % "joda-time" % "2.9.9" % "compile", - "junit" % "junit" % "4.12" % "test", - "com.novocode" % "junit-interface" % "0.10" % "test" - ) - ) diff --git a/testing/api-client/docs/BuildVersion.md b/testing/api-client/docs/BuildVersion.md deleted file mode 100644 index 8032e41..0000000 --- a/testing/api-client/docs/BuildVersion.md +++ /dev/null @@ -1,13 +0,0 @@ - -# BuildVersion - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**time** | **Long** | The build time in Epoch milliseconds. | -**build** | **String** | The build number. | -**creator** | **String** | The creator of the build. | -**version** | **String** | The version of the build. | - - - diff --git a/testing/api-client/docs/Coordinate.md b/testing/api-client/docs/Coordinate.md deleted file mode 100644 index d9b61fa..0000000 --- a/testing/api-client/docs/Coordinate.md +++ /dev/null @@ -1,11 +0,0 @@ - -# Coordinate - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**longitude** | **Double** | The longitude of a location. | -**latitude** | **Double** | The latitude of a location. | - - - diff --git a/testing/api-client/docs/DefaultApi.md b/testing/api-client/docs/DefaultApi.md deleted file mode 100644 index d8aed25..0000000 --- a/testing/api-client/docs/DefaultApi.md +++ /dev/null @@ -1,2845 +0,0 @@ -# DefaultApi - -All URIs are relative to *http://localhost/api* - -Method | HTTP request | Description -------------- | ------------- | ------------- -[**addCurrentUserPrivilege**](DefaultApi.md#addCurrentUserPrivilege) | **POST** /users/current/privileges | Add a privilege for the specified user. -[**addLocations**](DefaultApi.md#addLocations) | **POST** /devices/current/locations | Updates the locations of the current device. -[**addNotice**](DefaultApi.md#addNotice) | **POST** /notices | Adds a new notice and returns the notice as well as its location. -[**addUser**](DefaultApi.md#addUser) | **POST** /users | Adds a user account with the specified roles and emails. -[**addUserPrivilege**](DefaultApi.md#addUserPrivilege) | **POST** /users/{id}/privileges | Returns the privileges for a particular user. -[**createDevice**](DefaultApi.md#createDevice) | **POST** /devices | Creates a new device and returns its handle. -[**createShare**](DefaultApi.md#createShare) | **POST** /shares | Creates a new share. -[**deleteCurrentDevice**](DefaultApi.md#deleteCurrentDevice) | **DELETE** /devices/current | Deletes the current device. -[**deleteDevice**](DefaultApi.md#deleteDevice) | **DELETE** /devices/{id} | Deletes a device. -[**deletePrivilege**](DefaultApi.md#deletePrivilege) | **DELETE** /privileges/{id} | Deletes a particular privilege. -[**deleteShare**](DefaultApi.md#deleteShare) | **DELETE** /shares/{id} | Delete a share. -[**getActiveNotices**](DefaultApi.md#getActiveNotices) | **GET** /notices/active | Returns a page of notices. -[**getBuildVersion**](DefaultApi.md#getBuildVersion) | **GET** /versions/build | Returns the build version. -[**getCurrentDevice**](DefaultApi.md#getCurrentDevice) | **GET** /devices/current | Returns the current device. -[**getCurrentUser**](DefaultApi.md#getCurrentUser) | **GET** /users/current | Returns the user currently authorized. -[**getCurrentUserDevices**](DefaultApi.md#getCurrentUserDevices) | **GET** /users/current/devices | Returns the list of devices for the current user. -[**getCurrentUserPlaces**](DefaultApi.md#getCurrentUserPlaces) | **GET** /users/current/places | Returns the places for the current user. -[**getCurrentUserPrivileges**](DefaultApi.md#getCurrentUserPrivileges) | **GET** /users/current/privileges | Returns the privileges for the current user. -[**getDevice**](DefaultApi.md#getDevice) | **GET** /devices/{id} | Gets a device. -[**getDeviceLocation**](DefaultApi.md#getDeviceLocation) | **GET** /devices/{id}/location | Gets the last device location. -[**getDeviceVisits**](DefaultApi.md#getDeviceVisits) | **GET** /devices/{id}/visits | Gets the last device location. -[**getDevices**](DefaultApi.md#getDevices) | **GET** /devices | Returns all devices. -[**getEntityStatistics**](DefaultApi.md#getEntityStatistics) | **GET** /log/entities | Returns a list of entity statistics. -[**getLoadStatistic**](DefaultApi.md#getLoadStatistic) | **GET** /log/load | Returns the current load statistic. -[**getLogMessages**](DefaultApi.md#getLogMessages) | **GET** /log/messages | Returns a list of log messages starting from a particular id. -[**getNotice**](DefaultApi.md#getNotice) | **GET** /notices/{id} | Returns the notice with the specified id. -[**getNotices**](DefaultApi.md#getNotices) | **GET** /notices | Returns a page of notices. -[**getPlace**](DefaultApi.md#getPlace) | **GET** /places/{id} | Returns the place with the specified id. -[**getPlaceVisits**](DefaultApi.md#getPlaceVisits) | **GET** /places/{id}/visits | Returns the visits for a particular place. -[**getPrivilege**](DefaultApi.md#getPrivilege) | **GET** /privileges/{id} | Returns the privileges for a particular user. -[**getPrivilegeLocation**](DefaultApi.md#getPrivilegeLocation) | **GET** /privileges/{id}/location | Returns the location for a particular privilege. -[**getShare**](DefaultApi.md#getShare) | **GET** /shares/{id} | Returns a share. -[**getShareInfo**](DefaultApi.md#getShareInfo) | **GET** /shares/{token}/info | Get a share info by its secret token. -[**getShareLocation**](DefaultApi.md#getShareLocation) | **GET** /shares/{token}/location | Get a shared location by its secret token. -[**getSystemStatistic**](DefaultApi.md#getSystemStatistic) | **GET** /log/system | Returns the system statistic. -[**getUpdatedNotices**](DefaultApi.md#getUpdatedNotices) | **GET** /notices/updated | Returns all active notices modified after the date. -[**getUser**](DefaultApi.md#getUser) | **GET** /users/{id} | Returns the user account with the specified id. -[**getUserPlaces**](DefaultApi.md#getUserPlaces) | **GET** /users/{id}/places | Returns the places for a particular user. -[**getUserPrivileges**](DefaultApi.md#getUserPrivileges) | **GET** /users/{id}/privileges | Returns the privileges for a particular user. -[**getUsers**](DefaultApi.md#getUsers) | **GET** /users | Returns a list of users. -[**registerUser**](DefaultApi.md#registerUser) | **POST** /users/register | Registers a new user and sends an email account verification. -[**resetUser**](DefaultApi.md#resetUser) | **POST** /users/reset | Sends a password reset email to the correspondence email account of a user. -[**resetUserPassword**](DefaultApi.md#resetUserPassword) | **PUT** /users/password/{token} | Sets the password of a user account using a token received via email. -[**searchUsers**](DefaultApi.md#searchUsers) | **GET** /users/search | Returns a list of users whose login name or name contains the term. -[**setCurrentPassword**](DefaultApi.md#setCurrentPassword) | **PUT** /users/current/password | Sets the password of the currently authorized user. -[**setCurrentUser**](DefaultApi.md#setCurrentUser) | **PUT** /users/current | Updates the currently authorized user. -[**setDevice**](DefaultApi.md#setDevice) | **PUT** /devices/{id} | Sets the values of a device. -[**setNotice**](DefaultApi.md#setNotice) | **PUT** /notices/{id} | Updates an existing notice. -[**setPlace**](DefaultApi.md#setPlace) | **PUT** /places/{id} | Updates the place with the specified id. -[**setShare**](DefaultApi.md#setShare) | **PUT** /shares/{id} | Updates an existing share. -[**setUser**](DefaultApi.md#setUser) | **PUT** /users/{id} | Updates the values of a particular user account. -[**setUserPassword**](DefaultApi.md#setUserPassword) | **PUT** /users/{id}/password | Sets the password of a user. -[**verifyUserEmail**](DefaultApi.md#verifyUserEmail) | **PUT** /users/verify/{token} | Verifies an email address using a token received via email. - - - -# **addCurrentUserPrivilege** -> Privilege addCurrentUserPrivilege(share) - -Add a privilege for the specified user. - - - -### Example -```java -// Import classes: -//import io.swagger.client.ApiClient; -//import io.swagger.client.ApiException; -//import io.swagger.client.Configuration; -//import io.swagger.client.auth.*; -//import io.swagger.client.api.DefaultApi; - -ApiClient defaultClient = Configuration.getDefaultApiClient(); - -// Configure HTTP basic authorization: user -HttpBasicAuth user = (HttpBasicAuth) defaultClient.getAuthentication("user"); -user.setUsername("YOUR USERNAME"); -user.setPassword("YOUR PASSWORD"); - -DefaultApi apiInstance = new DefaultApi(); -String share = "share_example"; // String | The token of the share. -try { - Privilege result = apiInstance.addCurrentUserPrivilege(share); - System.out.println(result); -} catch (ApiException e) { - System.err.println("Exception when calling DefaultApi#addCurrentUserPrivilege"); - e.printStackTrace(); -} -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **share** | **String**| The token of the share. | - -### Return type - -[**Privilege**](Privilege.md) - -### Authorization - -[user](../README.md#user) - -### HTTP request headers - - - **Content-Type**: application/json, application/xml - - **Accept**: application/json, application/xml - - -# **addLocations** -> addLocations(body) - -Updates the locations of the current device. - - - -### Example -```java -// Import classes: -//import io.swagger.client.ApiClient; -//import io.swagger.client.ApiException; -//import io.swagger.client.Configuration; -//import io.swagger.client.auth.*; -//import io.swagger.client.api.DefaultApi; - -ApiClient defaultClient = Configuration.getDefaultApiClient(); - -// Configure API key authorization: device -ApiKeyAuth device = (ApiKeyAuth) defaultClient.getAuthentication("device"); -device.setApiKey("YOUR API KEY"); -// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null) -//device.setApiKeyPrefix("Token"); - -DefaultApi apiInstance = new DefaultApi(); -LocationUpdate body = new LocationUpdate(); // LocationUpdate | The location update with the locations to add. -try { - apiInstance.addLocations(body); -} catch (ApiException e) { - System.err.println("Exception when calling DefaultApi#addLocations"); - e.printStackTrace(); -} -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **body** | [**LocationUpdate**](LocationUpdate.md)| The location update with the locations to add. | - -### Return type - -null (empty response body) - -### Authorization - -[device](../README.md#device) - -### HTTP request headers - - - **Content-Type**: application/json, application/xml - - **Accept**: application/json, application/xml - - -# **addNotice** -> Notice addNotice(body) - -Adds a new notice and returns the notice as well as its location. - - - -### Example -```java -// Import classes: -//import io.swagger.client.ApiClient; -//import io.swagger.client.ApiException; -//import io.swagger.client.Configuration; -//import io.swagger.client.auth.*; -//import io.swagger.client.api.DefaultApi; - -ApiClient defaultClient = Configuration.getDefaultApiClient(); - -// Configure HTTP basic authorization: admin -HttpBasicAuth admin = (HttpBasicAuth) defaultClient.getAuthentication("admin"); -admin.setUsername("YOUR USERNAME"); -admin.setPassword("YOUR PASSWORD"); - -DefaultApi apiInstance = new DefaultApi(); -Notice body = new Notice(); // Notice | The new notice to add. -try { - Notice result = apiInstance.addNotice(body); - System.out.println(result); -} catch (ApiException e) { - System.err.println("Exception when calling DefaultApi#addNotice"); - e.printStackTrace(); -} -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **body** | [**Notice**](Notice.md)| The new notice to add. | - -### Return type - -[**Notice**](Notice.md) - -### Authorization - -[admin](../README.md#admin) - -### HTTP request headers - - - **Content-Type**: application/json, application/xml - - **Accept**: application/json, application/xml - - -# **addUser** -> User addUser(body) - -Adds a user account with the specified roles and emails. - - - -### Example -```java -// Import classes: -//import io.swagger.client.ApiClient; -//import io.swagger.client.ApiException; -//import io.swagger.client.Configuration; -//import io.swagger.client.auth.*; -//import io.swagger.client.api.DefaultApi; - -ApiClient defaultClient = Configuration.getDefaultApiClient(); - -// Configure HTTP basic authorization: admin -HttpBasicAuth admin = (HttpBasicAuth) defaultClient.getAuthentication("admin"); -admin.setUsername("YOUR USERNAME"); -admin.setPassword("YOUR PASSWORD"); - -DefaultApi apiInstance = new DefaultApi(); -User body = new User(); // User | The data for the new user. -try { - User result = apiInstance.addUser(body); - System.out.println(result); -} catch (ApiException e) { - System.err.println("Exception when calling DefaultApi#addUser"); - e.printStackTrace(); -} -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **body** | [**User**](User.md)| The data for the new user. | - -### Return type - -[**User**](User.md) - -### Authorization - -[admin](../README.md#admin) - -### HTTP request headers - - - **Content-Type**: application/json, application/xml - - **Accept**: application/json, application/xml - - -# **addUserPrivilege** -> Privilege addUserPrivilege(id, share) - -Returns the privileges for a particular user. - - - -### Example -```java -// Import classes: -//import io.swagger.client.ApiClient; -//import io.swagger.client.ApiException; -//import io.swagger.client.Configuration; -//import io.swagger.client.auth.*; -//import io.swagger.client.api.DefaultApi; - -ApiClient defaultClient = Configuration.getDefaultApiClient(); - -// Configure HTTP basic authorization: admin -HttpBasicAuth admin = (HttpBasicAuth) defaultClient.getAuthentication("admin"); -admin.setUsername("YOUR USERNAME"); -admin.setPassword("YOUR PASSWORD"); - -DefaultApi apiInstance = new DefaultApi(); -Long id = 789L; // Long | The user id. -String share = "share_example"; // String | The token of the share. -try { - Privilege result = apiInstance.addUserPrivilege(id, share); - System.out.println(result); -} catch (ApiException e) { - System.err.println("Exception when calling DefaultApi#addUserPrivilege"); - e.printStackTrace(); -} -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **id** | **Long**| The user id. | - **share** | **String**| The token of the share. | - -### Return type - -[**Privilege**](Privilege.md) - -### Authorization - -[admin](../README.md#admin) - -### HTTP request headers - - - **Content-Type**: application/json, application/xml - - **Accept**: application/json, application/xml - - -# **createDevice** -> DeviceHandle createDevice(body) - -Creates a new device and returns its handle. - -The response will include the auth token to be stored on the device and supplied as authentication on all subsequent api calls. Note that the auth token can not be requested after creation, so when losing the auth token you may lose access to the device data. - -### Example -```java -// Import classes: -//import io.swagger.client.ApiException; -//import io.swagger.client.api.DefaultApi; - - -DefaultApi apiInstance = new DefaultApi(); -DeviceInfo body = new DeviceInfo(); // DeviceInfo | Necessary data from to create a device. -try { - DeviceHandle result = apiInstance.createDevice(body); - System.out.println(result); -} catch (ApiException e) { - System.err.println("Exception when calling DefaultApi#createDevice"); - e.printStackTrace(); -} -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **body** | [**DeviceInfo**](DeviceInfo.md)| Necessary data from to create a device. | - -### Return type - -[**DeviceHandle**](DeviceHandle.md) - -### Authorization - -No authorization required - -### HTTP request headers - - - **Content-Type**: application/json, application/xml - - **Accept**: application/json, application/xml - - -# **createShare** -> Share createShare(body) - -Creates a new share. - - - -### Example -```java -// Import classes: -//import io.swagger.client.ApiClient; -//import io.swagger.client.ApiException; -//import io.swagger.client.Configuration; -//import io.swagger.client.auth.*; -//import io.swagger.client.api.DefaultApi; - -ApiClient defaultClient = Configuration.getDefaultApiClient(); - -// Configure API key authorization: device -ApiKeyAuth device = (ApiKeyAuth) defaultClient.getAuthentication("device"); -device.setApiKey("YOUR API KEY"); -// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null) -//device.setApiKeyPrefix("Token"); - -DefaultApi apiInstance = new DefaultApi(); -ShareInfo body = new ShareInfo(); // ShareInfo | Necessary data from to create a share. -try { - Share result = apiInstance.createShare(body); - System.out.println(result); -} catch (ApiException e) { - System.err.println("Exception when calling DefaultApi#createShare"); - e.printStackTrace(); -} -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **body** | [**ShareInfo**](ShareInfo.md)| Necessary data from to create a share. | - -### Return type - -[**Share**](Share.md) - -### Authorization - -[device](../README.md#device) - -### HTTP request headers - - - **Content-Type**: application/json, application/xml - - **Accept**: application/json, application/xml - - -# **deleteCurrentDevice** -> deleteCurrentDevice() - -Deletes the current device. - - - -### Example -```java -// Import classes: -//import io.swagger.client.ApiClient; -//import io.swagger.client.ApiException; -//import io.swagger.client.Configuration; -//import io.swagger.client.auth.*; -//import io.swagger.client.api.DefaultApi; - -ApiClient defaultClient = Configuration.getDefaultApiClient(); - -// Configure API key authorization: device -ApiKeyAuth device = (ApiKeyAuth) defaultClient.getAuthentication("device"); -device.setApiKey("YOUR API KEY"); -// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null) -//device.setApiKeyPrefix("Token"); - -DefaultApi apiInstance = new DefaultApi(); -try { - apiInstance.deleteCurrentDevice(); -} catch (ApiException e) { - System.err.println("Exception when calling DefaultApi#deleteCurrentDevice"); - e.printStackTrace(); -} -``` - -### Parameters -This endpoint does not need any parameter. - -### Return type - -null (empty response body) - -### Authorization - -[device](../README.md#device) - -### HTTP request headers - - - **Content-Type**: application/json, application/xml - - **Accept**: application/json, application/xml - - -# **deleteDevice** -> deleteDevice(id) - -Deletes a device. - - - -### Example -```java -// Import classes: -//import io.swagger.client.ApiClient; -//import io.swagger.client.ApiException; -//import io.swagger.client.Configuration; -//import io.swagger.client.auth.*; -//import io.swagger.client.api.DefaultApi; - -ApiClient defaultClient = Configuration.getDefaultApiClient(); - -// Configure HTTP basic authorization: admin -HttpBasicAuth admin = (HttpBasicAuth) defaultClient.getAuthentication("admin"); -admin.setUsername("YOUR USERNAME"); -admin.setPassword("YOUR PASSWORD"); - -// Configure HTTP basic authorization: user -HttpBasicAuth user = (HttpBasicAuth) defaultClient.getAuthentication("user"); -user.setUsername("YOUR USERNAME"); -user.setPassword("YOUR PASSWORD"); - -DefaultApi apiInstance = new DefaultApi(); -Long id = 789L; // Long | The device id. -try { - apiInstance.deleteDevice(id); -} catch (ApiException e) { - System.err.println("Exception when calling DefaultApi#deleteDevice"); - e.printStackTrace(); -} -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **id** | **Long**| The device id. | - -### Return type - -null (empty response body) - -### Authorization - -[admin](../README.md#admin), [user](../README.md#user) - -### HTTP request headers - - - **Content-Type**: application/json, application/xml - - **Accept**: application/json, application/xml - - -# **deletePrivilege** -> deletePrivilege(id) - -Deletes a particular privilege. - - - -### Example -```java -// Import classes: -//import io.swagger.client.ApiClient; -//import io.swagger.client.ApiException; -//import io.swagger.client.Configuration; -//import io.swagger.client.auth.*; -//import io.swagger.client.api.DefaultApi; - -ApiClient defaultClient = Configuration.getDefaultApiClient(); - -// Configure HTTP basic authorization: admin -HttpBasicAuth admin = (HttpBasicAuth) defaultClient.getAuthentication("admin"); -admin.setUsername("YOUR USERNAME"); -admin.setPassword("YOUR PASSWORD"); - -// Configure HTTP basic authorization: user -HttpBasicAuth user = (HttpBasicAuth) defaultClient.getAuthentication("user"); -user.setUsername("YOUR USERNAME"); -user.setPassword("YOUR PASSWORD"); - -DefaultApi apiInstance = new DefaultApi(); -Long id = 789L; // Long | The privilege id. -try { - apiInstance.deletePrivilege(id); -} catch (ApiException e) { - System.err.println("Exception when calling DefaultApi#deletePrivilege"); - e.printStackTrace(); -} -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **id** | **Long**| The privilege id. | - -### Return type - -null (empty response body) - -### Authorization - -[admin](../README.md#admin), [user](../README.md#user) - -### HTTP request headers - - - **Content-Type**: application/json, application/xml - - **Accept**: application/json, application/xml - - -# **deleteShare** -> deleteShare(id) - -Delete a share. - - - -### Example -```java -// Import classes: -//import io.swagger.client.ApiClient; -//import io.swagger.client.ApiException; -//import io.swagger.client.Configuration; -//import io.swagger.client.auth.*; -//import io.swagger.client.api.DefaultApi; - -ApiClient defaultClient = Configuration.getDefaultApiClient(); - -// Configure API key authorization: device -ApiKeyAuth device = (ApiKeyAuth) defaultClient.getAuthentication("device"); -device.setApiKey("YOUR API KEY"); -// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null) -//device.setApiKeyPrefix("Token"); - -DefaultApi apiInstance = new DefaultApi(); -Long id = 789L; // Long | The share id. -try { - apiInstance.deleteShare(id); -} catch (ApiException e) { - System.err.println("Exception when calling DefaultApi#deleteShare"); - e.printStackTrace(); -} -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **id** | **Long**| The share id. | - -### Return type - -null (empty response body) - -### Authorization - -[device](../README.md#device) - -### HTTP request headers - - - **Content-Type**: application/json, application/xml - - **Accept**: application/json, application/xml - - -# **getActiveNotices** -> NoticePage getActiveNotices(pageOffset, pageSize) - -Returns a page of notices. - - - -### Example -```java -// Import classes: -//import io.swagger.client.ApiException; -//import io.swagger.client.api.DefaultApi; - - -DefaultApi apiInstance = new DefaultApi(); -Integer pageOffset = 0; // Integer | The offset in terms of elements. -Integer pageSize = 20; // Integer | The maximum number of elements on the page. -try { - NoticePage result = apiInstance.getActiveNotices(pageOffset, pageSize); - System.out.println(result); -} catch (ApiException e) { - System.err.println("Exception when calling DefaultApi#getActiveNotices"); - e.printStackTrace(); -} -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **pageOffset** | **Integer**| The offset in terms of elements. | [optional] [default to 0] - **pageSize** | **Integer**| The maximum number of elements on the page. | [optional] [default to 20] - -### Return type - -[**NoticePage**](NoticePage.md) - -### Authorization - -No authorization required - -### HTTP request headers - - - **Content-Type**: application/json, application/xml - - **Accept**: application/json, application/xml - - -# **getBuildVersion** -> BuildVersion getBuildVersion() - -Returns the build version. - - - -### Example -```java -// Import classes: -//import io.swagger.client.ApiException; -//import io.swagger.client.api.DefaultApi; - - -DefaultApi apiInstance = new DefaultApi(); -try { - BuildVersion result = apiInstance.getBuildVersion(); - System.out.println(result); -} catch (ApiException e) { - System.err.println("Exception when calling DefaultApi#getBuildVersion"); - e.printStackTrace(); -} -``` - -### Parameters -This endpoint does not need any parameter. - -### Return type - -[**BuildVersion**](BuildVersion.md) - -### Authorization - -No authorization required - -### HTTP request headers - - - **Content-Type**: Not defined - - **Accept**: application/json, application/xml - - -# **getCurrentDevice** -> Device getCurrentDevice() - -Returns the current device. - - - -### Example -```java -// Import classes: -//import io.swagger.client.ApiClient; -//import io.swagger.client.ApiException; -//import io.swagger.client.Configuration; -//import io.swagger.client.auth.*; -//import io.swagger.client.api.DefaultApi; - -ApiClient defaultClient = Configuration.getDefaultApiClient(); - -// Configure API key authorization: device -ApiKeyAuth device = (ApiKeyAuth) defaultClient.getAuthentication("device"); -device.setApiKey("YOUR API KEY"); -// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null) -//device.setApiKeyPrefix("Token"); - -DefaultApi apiInstance = new DefaultApi(); -try { - Device result = apiInstance.getCurrentDevice(); - System.out.println(result); -} catch (ApiException e) { - System.err.println("Exception when calling DefaultApi#getCurrentDevice"); - e.printStackTrace(); -} -``` - -### Parameters -This endpoint does not need any parameter. - -### Return type - -[**Device**](Device.md) - -### Authorization - -[device](../README.md#device) - -### HTTP request headers - - - **Content-Type**: application/json, application/xml - - **Accept**: application/json, application/xml - - -# **getCurrentUser** -> User getCurrentUser() - -Returns the user currently authorized. - - - -### Example -```java -// Import classes: -//import io.swagger.client.ApiClient; -//import io.swagger.client.ApiException; -//import io.swagger.client.Configuration; -//import io.swagger.client.auth.*; -//import io.swagger.client.api.DefaultApi; - -ApiClient defaultClient = Configuration.getDefaultApiClient(); - -// Configure HTTP basic authorization: user -HttpBasicAuth user = (HttpBasicAuth) defaultClient.getAuthentication("user"); -user.setUsername("YOUR USERNAME"); -user.setPassword("YOUR PASSWORD"); - -DefaultApi apiInstance = new DefaultApi(); -try { - User result = apiInstance.getCurrentUser(); - System.out.println(result); -} catch (ApiException e) { - System.err.println("Exception when calling DefaultApi#getCurrentUser"); - e.printStackTrace(); -} -``` - -### Parameters -This endpoint does not need any parameter. - -### Return type - -[**User**](User.md) - -### Authorization - -[user](../README.md#user) - -### HTTP request headers - - - **Content-Type**: application/json, application/xml - - **Accept**: application/json, application/xml - - -# **getCurrentUserDevices** -> DevicePage getCurrentUserDevices(pageOffset, pageSize) - -Returns the list of devices for the current user. - - - -### Example -```java -// Import classes: -//import io.swagger.client.ApiClient; -//import io.swagger.client.ApiException; -//import io.swagger.client.Configuration; -//import io.swagger.client.auth.*; -//import io.swagger.client.api.DefaultApi; - -ApiClient defaultClient = Configuration.getDefaultApiClient(); - -// Configure HTTP basic authorization: user -HttpBasicAuth user = (HttpBasicAuth) defaultClient.getAuthentication("user"); -user.setUsername("YOUR USERNAME"); -user.setPassword("YOUR PASSWORD"); - -DefaultApi apiInstance = new DefaultApi(); -Integer pageOffset = 0; // Integer | The offset in terms of elements. -Integer pageSize = 20; // Integer | The maximum number of elements on the page. -try { - DevicePage result = apiInstance.getCurrentUserDevices(pageOffset, pageSize); - System.out.println(result); -} catch (ApiException e) { - System.err.println("Exception when calling DefaultApi#getCurrentUserDevices"); - e.printStackTrace(); -} -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **pageOffset** | **Integer**| The offset in terms of elements. | [optional] [default to 0] - **pageSize** | **Integer**| The maximum number of elements on the page. | [optional] [default to 20] - -### Return type - -[**DevicePage**](DevicePage.md) - -### Authorization - -[user](../README.md#user) - -### HTTP request headers - - - **Content-Type**: application/json, application/xml - - **Accept**: application/json, application/xml - - -# **getCurrentUserPlaces** -> PlacePage getCurrentUserPlaces(pageOffset, pageSize) - -Returns the places for the current user. - - - -### Example -```java -// Import classes: -//import io.swagger.client.ApiException; -//import io.swagger.client.api.DefaultApi; - - -DefaultApi apiInstance = new DefaultApi(); -Integer pageOffset = 0; // Integer | The offset in terms of elements. -Integer pageSize = 20; // Integer | The maximum number of elements on the page. -try { - PlacePage result = apiInstance.getCurrentUserPlaces(pageOffset, pageSize); - System.out.println(result); -} catch (ApiException e) { - System.err.println("Exception when calling DefaultApi#getCurrentUserPlaces"); - e.printStackTrace(); -} -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **pageOffset** | **Integer**| The offset in terms of elements. | [optional] [default to 0] - **pageSize** | **Integer**| The maximum number of elements on the page. | [optional] [default to 20] - -### Return type - -[**PlacePage**](PlacePage.md) - -### Authorization - -No authorization required - -### HTTP request headers - - - **Content-Type**: application/json, application/xml - - **Accept**: application/json, application/xml - - -# **getCurrentUserPrivileges** -> PrivilegePage getCurrentUserPrivileges(pageOffset, pageSize) - -Returns the privileges for the current user. - - - -### Example -```java -// Import classes: -//import io.swagger.client.ApiClient; -//import io.swagger.client.ApiException; -//import io.swagger.client.Configuration; -//import io.swagger.client.auth.*; -//import io.swagger.client.api.DefaultApi; - -ApiClient defaultClient = Configuration.getDefaultApiClient(); - -// Configure HTTP basic authorization: user -HttpBasicAuth user = (HttpBasicAuth) defaultClient.getAuthentication("user"); -user.setUsername("YOUR USERNAME"); -user.setPassword("YOUR PASSWORD"); - -DefaultApi apiInstance = new DefaultApi(); -Integer pageOffset = 0; // Integer | The offset in terms of elements. -Integer pageSize = 20; // Integer | The maximum number of elements on the page. -try { - PrivilegePage result = apiInstance.getCurrentUserPrivileges(pageOffset, pageSize); - System.out.println(result); -} catch (ApiException e) { - System.err.println("Exception when calling DefaultApi#getCurrentUserPrivileges"); - e.printStackTrace(); -} -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **pageOffset** | **Integer**| The offset in terms of elements. | [optional] [default to 0] - **pageSize** | **Integer**| The maximum number of elements on the page. | [optional] [default to 20] - -### Return type - -[**PrivilegePage**](PrivilegePage.md) - -### Authorization - -[user](../README.md#user) - -### HTTP request headers - - - **Content-Type**: application/json, application/xml - - **Accept**: application/json, application/xml - - -# **getDevice** -> Device getDevice(id) - -Gets a device. - - - -### Example -```java -// Import classes: -//import io.swagger.client.ApiClient; -//import io.swagger.client.ApiException; -//import io.swagger.client.Configuration; -//import io.swagger.client.auth.*; -//import io.swagger.client.api.DefaultApi; - -ApiClient defaultClient = Configuration.getDefaultApiClient(); - -// Configure HTTP basic authorization: admin -HttpBasicAuth admin = (HttpBasicAuth) defaultClient.getAuthentication("admin"); -admin.setUsername("YOUR USERNAME"); -admin.setPassword("YOUR PASSWORD"); - -// Configure HTTP basic authorization: user -HttpBasicAuth user = (HttpBasicAuth) defaultClient.getAuthentication("user"); -user.setUsername("YOUR USERNAME"); -user.setPassword("YOUR PASSWORD"); - -DefaultApi apiInstance = new DefaultApi(); -Long id = 789L; // Long | The device id. -try { - Device result = apiInstance.getDevice(id); - System.out.println(result); -} catch (ApiException e) { - System.err.println("Exception when calling DefaultApi#getDevice"); - e.printStackTrace(); -} -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **id** | **Long**| The device id. | - -### Return type - -[**Device**](Device.md) - -### Authorization - -[admin](../README.md#admin), [user](../README.md#user) - -### HTTP request headers - - - **Content-Type**: application/json, application/xml - - **Accept**: application/json, application/xml - - -# **getDeviceLocation** -> Location getDeviceLocation(id) - -Gets the last device location. - - - -### Example -```java -// Import classes: -//import io.swagger.client.ApiClient; -//import io.swagger.client.ApiException; -//import io.swagger.client.Configuration; -//import io.swagger.client.auth.*; -//import io.swagger.client.api.DefaultApi; - -ApiClient defaultClient = Configuration.getDefaultApiClient(); - -// Configure HTTP basic authorization: admin -HttpBasicAuth admin = (HttpBasicAuth) defaultClient.getAuthentication("admin"); -admin.setUsername("YOUR USERNAME"); -admin.setPassword("YOUR PASSWORD"); - -// Configure HTTP basic authorization: user -HttpBasicAuth user = (HttpBasicAuth) defaultClient.getAuthentication("user"); -user.setUsername("YOUR USERNAME"); -user.setPassword("YOUR PASSWORD"); - -DefaultApi apiInstance = new DefaultApi(); -Long id = 789L; // Long | The device id. -try { - Location result = apiInstance.getDeviceLocation(id); - System.out.println(result); -} catch (ApiException e) { - System.err.println("Exception when calling DefaultApi#getDeviceLocation"); - e.printStackTrace(); -} -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **id** | **Long**| The device id. | - -### Return type - -[**Location**](Location.md) - -### Authorization - -[admin](../README.md#admin), [user](../README.md#user) - -### HTTP request headers - - - **Content-Type**: application/json, application/xml - - **Accept**: application/json, application/xml - - -# **getDeviceVisits** -> List<Visit> getDeviceVisits(id, start, duration) - -Gets the last device location. - - - -### Example -```java -// Import classes: -//import io.swagger.client.ApiClient; -//import io.swagger.client.ApiException; -//import io.swagger.client.Configuration; -//import io.swagger.client.auth.*; -//import io.swagger.client.api.DefaultApi; - -ApiClient defaultClient = Configuration.getDefaultApiClient(); - -// Configure HTTP basic authorization: admin -HttpBasicAuth admin = (HttpBasicAuth) defaultClient.getAuthentication("admin"); -admin.setUsername("YOUR USERNAME"); -admin.setPassword("YOUR PASSWORD"); - -// Configure HTTP basic authorization: user -HttpBasicAuth user = (HttpBasicAuth) defaultClient.getAuthentication("user"); -user.setUsername("YOUR USERNAME"); -user.setPassword("YOUR PASSWORD"); - -DefaultApi apiInstance = new DefaultApi(); -Long id = 789L; // Long | The device id. -Long start = 789L; // Long | The start time in Epoch milliseconds. -Long duration = 789L; // Long | The duration in milliseconds. -try { - List result = apiInstance.getDeviceVisits(id, start, duration); - System.out.println(result); -} catch (ApiException e) { - System.err.println("Exception when calling DefaultApi#getDeviceVisits"); - e.printStackTrace(); -} -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **id** | **Long**| The device id. | - **start** | **Long**| The start time in Epoch milliseconds. | - **duration** | **Long**| The duration in milliseconds. | - -### Return type - -[**List<Visit>**](Visit.md) - -### Authorization - -[admin](../README.md#admin), [user](../README.md#user) - -### HTTP request headers - - - **Content-Type**: application/json, application/xml - - **Accept**: application/json, application/xml - - -# **getDevices** -> DevicePage getDevices(pageOffset, pageSize) - -Returns all devices. - - - -### Example -```java -// Import classes: -//import io.swagger.client.ApiClient; -//import io.swagger.client.ApiException; -//import io.swagger.client.Configuration; -//import io.swagger.client.auth.*; -//import io.swagger.client.api.DefaultApi; - -ApiClient defaultClient = Configuration.getDefaultApiClient(); - -// Configure HTTP basic authorization: admin -HttpBasicAuth admin = (HttpBasicAuth) defaultClient.getAuthentication("admin"); -admin.setUsername("YOUR USERNAME"); -admin.setPassword("YOUR PASSWORD"); - -DefaultApi apiInstance = new DefaultApi(); -Integer pageOffset = 0; // Integer | The offset in terms of elements. -Integer pageSize = 20; // Integer | The maximum number of elements on the page. -try { - DevicePage result = apiInstance.getDevices(pageOffset, pageSize); - System.out.println(result); -} catch (ApiException e) { - System.err.println("Exception when calling DefaultApi#getDevices"); - e.printStackTrace(); -} -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **pageOffset** | **Integer**| The offset in terms of elements. | [optional] [default to 0] - **pageSize** | **Integer**| The maximum number of elements on the page. | [optional] [default to 20] - -### Return type - -[**DevicePage**](DevicePage.md) - -### Authorization - -[admin](../README.md#admin) - -### HTTP request headers - - - **Content-Type**: application/json, application/xml - - **Accept**: application/json, application/xml - - -# **getEntityStatistics** -> List<EntityStatistic> getEntityStatistics() - -Returns a list of entity statistics. - - - -### Example -```java -// Import classes: -//import io.swagger.client.ApiClient; -//import io.swagger.client.ApiException; -//import io.swagger.client.Configuration; -//import io.swagger.client.auth.*; -//import io.swagger.client.api.DefaultApi; - -ApiClient defaultClient = Configuration.getDefaultApiClient(); - -// Configure HTTP basic authorization: admin -HttpBasicAuth admin = (HttpBasicAuth) defaultClient.getAuthentication("admin"); -admin.setUsername("YOUR USERNAME"); -admin.setPassword("YOUR PASSWORD"); - -DefaultApi apiInstance = new DefaultApi(); -try { - List result = apiInstance.getEntityStatistics(); - System.out.println(result); -} catch (ApiException e) { - System.err.println("Exception when calling DefaultApi#getEntityStatistics"); - e.printStackTrace(); -} -``` - -### Parameters -This endpoint does not need any parameter. - -### Return type - -[**List<EntityStatistic>**](EntityStatistic.md) - -### Authorization - -[admin](../README.md#admin) - -### HTTP request headers - - - **Content-Type**: Not defined - - **Accept**: application/json, application/xml - - -# **getLoadStatistic** -> LoadStatistic getLoadStatistic() - -Returns the current load statistic. - - - -### Example -```java -// Import classes: -//import io.swagger.client.ApiClient; -//import io.swagger.client.ApiException; -//import io.swagger.client.Configuration; -//import io.swagger.client.auth.*; -//import io.swagger.client.api.DefaultApi; - -ApiClient defaultClient = Configuration.getDefaultApiClient(); - -// Configure HTTP basic authorization: admin -HttpBasicAuth admin = (HttpBasicAuth) defaultClient.getAuthentication("admin"); -admin.setUsername("YOUR USERNAME"); -admin.setPassword("YOUR PASSWORD"); - -DefaultApi apiInstance = new DefaultApi(); -try { - LoadStatistic result = apiInstance.getLoadStatistic(); - System.out.println(result); -} catch (ApiException e) { - System.err.println("Exception when calling DefaultApi#getLoadStatistic"); - e.printStackTrace(); -} -``` - -### Parameters -This endpoint does not need any parameter. - -### Return type - -[**LoadStatistic**](LoadStatistic.md) - -### Authorization - -[admin](../README.md#admin) - -### HTTP request headers - - - **Content-Type**: Not defined - - **Accept**: application/json, application/xml - - -# **getLogMessages** -> List<LogMessage> getLogMessages(from) - -Returns a list of log messages starting from a particular id. - - - -### Example -```java -// Import classes: -//import io.swagger.client.ApiClient; -//import io.swagger.client.ApiException; -//import io.swagger.client.Configuration; -//import io.swagger.client.auth.*; -//import io.swagger.client.api.DefaultApi; - -ApiClient defaultClient = Configuration.getDefaultApiClient(); - -// Configure HTTP basic authorization: admin -HttpBasicAuth admin = (HttpBasicAuth) defaultClient.getAuthentication("admin"); -admin.setUsername("YOUR USERNAME"); -admin.setPassword("YOUR PASSWORD"); - -DefaultApi apiInstance = new DefaultApi(); -Long from = 0L; // Long | The id of the first message to retrieve. -try { - List result = apiInstance.getLogMessages(from); - System.out.println(result); -} catch (ApiException e) { - System.err.println("Exception when calling DefaultApi#getLogMessages"); - e.printStackTrace(); -} -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **from** | **Long**| The id of the first message to retrieve. | [optional] [default to 0] - -### Return type - -[**List<LogMessage>**](LogMessage.md) - -### Authorization - -[admin](../README.md#admin) - -### HTTP request headers - - - **Content-Type**: Not defined - - **Accept**: application/json, application/xml - - -# **getNotice** -> Notice getNotice(id) - -Returns the notice with the specified id. - - - -### Example -```java -// Import classes: -//import io.swagger.client.ApiClient; -//import io.swagger.client.ApiException; -//import io.swagger.client.Configuration; -//import io.swagger.client.auth.*; -//import io.swagger.client.api.DefaultApi; - -ApiClient defaultClient = Configuration.getDefaultApiClient(); - -// Configure HTTP basic authorization: admin -HttpBasicAuth admin = (HttpBasicAuth) defaultClient.getAuthentication("admin"); -admin.setUsername("YOUR USERNAME"); -admin.setPassword("YOUR PASSWORD"); - -DefaultApi apiInstance = new DefaultApi(); -Long id = 789L; // Long | The id of the notice. -try { - Notice result = apiInstance.getNotice(id); - System.out.println(result); -} catch (ApiException e) { - System.err.println("Exception when calling DefaultApi#getNotice"); - e.printStackTrace(); -} -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **id** | **Long**| The id of the notice. | - -### Return type - -[**Notice**](Notice.md) - -### Authorization - -[admin](../README.md#admin) - -### HTTP request headers - - - **Content-Type**: application/json, application/xml - - **Accept**: application/json, application/xml - - -# **getNotices** -> NoticePage getNotices(pageOffset, pageSize) - -Returns a page of notices. - - - -### Example -```java -// Import classes: -//import io.swagger.client.ApiClient; -//import io.swagger.client.ApiException; -//import io.swagger.client.Configuration; -//import io.swagger.client.auth.*; -//import io.swagger.client.api.DefaultApi; - -ApiClient defaultClient = Configuration.getDefaultApiClient(); - -// Configure HTTP basic authorization: admin -HttpBasicAuth admin = (HttpBasicAuth) defaultClient.getAuthentication("admin"); -admin.setUsername("YOUR USERNAME"); -admin.setPassword("YOUR PASSWORD"); - -DefaultApi apiInstance = new DefaultApi(); -Integer pageOffset = 0; // Integer | The offset in terms of elements. -Integer pageSize = 20; // Integer | The maximum number of elements on the page. -try { - NoticePage result = apiInstance.getNotices(pageOffset, pageSize); - System.out.println(result); -} catch (ApiException e) { - System.err.println("Exception when calling DefaultApi#getNotices"); - e.printStackTrace(); -} -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **pageOffset** | **Integer**| The offset in terms of elements. | [optional] [default to 0] - **pageSize** | **Integer**| The maximum number of elements on the page. | [optional] [default to 20] - -### Return type - -[**NoticePage**](NoticePage.md) - -### Authorization - -[admin](../README.md#admin) - -### HTTP request headers - - - **Content-Type**: application/json, application/xml - - **Accept**: application/json, application/xml - - -# **getPlace** -> Place getPlace(id) - -Returns the place with the specified id. - - - -### Example -```java -// Import classes: -//import io.swagger.client.ApiException; -//import io.swagger.client.api.DefaultApi; - - -DefaultApi apiInstance = new DefaultApi(); -Long id = 789L; // Long | The place id. -try { - Place result = apiInstance.getPlace(id); - System.out.println(result); -} catch (ApiException e) { - System.err.println("Exception when calling DefaultApi#getPlace"); - e.printStackTrace(); -} -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **id** | **Long**| The place id. | - -### Return type - -[**Place**](Place.md) - -### Authorization - -No authorization required - -### HTTP request headers - - - **Content-Type**: application/json, application/xml - - **Accept**: application/json, application/xml - - -# **getPlaceVisits** -> VisitPage getPlaceVisits(id, pageOffset, pageSize) - -Returns the visits for a particular place. - - - -### Example -```java -// Import classes: -//import io.swagger.client.ApiException; -//import io.swagger.client.api.DefaultApi; - - -DefaultApi apiInstance = new DefaultApi(); -Long id = 789L; // Long | The place id. -Integer pageOffset = 0; // Integer | The offset in terms of elements. -Integer pageSize = 20; // Integer | The maximum number of elements on the page. -try { - VisitPage result = apiInstance.getPlaceVisits(id, pageOffset, pageSize); - System.out.println(result); -} catch (ApiException e) { - System.err.println("Exception when calling DefaultApi#getPlaceVisits"); - e.printStackTrace(); -} -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **id** | **Long**| The place id. | - **pageOffset** | **Integer**| The offset in terms of elements. | [optional] [default to 0] - **pageSize** | **Integer**| The maximum number of elements on the page. | [optional] [default to 20] - -### Return type - -[**VisitPage**](VisitPage.md) - -### Authorization - -No authorization required - -### HTTP request headers - - - **Content-Type**: application/json, application/xml - - **Accept**: application/json, application/xml - - -# **getPrivilege** -> Privilege getPrivilege(id) - -Returns the privileges for a particular user. - - - -### Example -```java -// Import classes: -//import io.swagger.client.ApiClient; -//import io.swagger.client.ApiException; -//import io.swagger.client.Configuration; -//import io.swagger.client.auth.*; -//import io.swagger.client.api.DefaultApi; - -ApiClient defaultClient = Configuration.getDefaultApiClient(); - -// Configure HTTP basic authorization: admin -HttpBasicAuth admin = (HttpBasicAuth) defaultClient.getAuthentication("admin"); -admin.setUsername("YOUR USERNAME"); -admin.setPassword("YOUR PASSWORD"); - -// Configure HTTP basic authorization: user -HttpBasicAuth user = (HttpBasicAuth) defaultClient.getAuthentication("user"); -user.setUsername("YOUR USERNAME"); -user.setPassword("YOUR PASSWORD"); - -DefaultApi apiInstance = new DefaultApi(); -Long id = 789L; // Long | The privilege id. -try { - Privilege result = apiInstance.getPrivilege(id); - System.out.println(result); -} catch (ApiException e) { - System.err.println("Exception when calling DefaultApi#getPrivilege"); - e.printStackTrace(); -} -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **id** | **Long**| The privilege id. | - -### Return type - -[**Privilege**](Privilege.md) - -### Authorization - -[admin](../README.md#admin), [user](../README.md#user) - -### HTTP request headers - - - **Content-Type**: application/json, application/xml - - **Accept**: application/json, application/xml - - -# **getPrivilegeLocation** -> Location getPrivilegeLocation(id) - -Returns the location for a particular privilege. - - - -### Example -```java -// Import classes: -//import io.swagger.client.ApiClient; -//import io.swagger.client.ApiException; -//import io.swagger.client.Configuration; -//import io.swagger.client.auth.*; -//import io.swagger.client.api.DefaultApi; - -ApiClient defaultClient = Configuration.getDefaultApiClient(); - -// Configure HTTP basic authorization: admin -HttpBasicAuth admin = (HttpBasicAuth) defaultClient.getAuthentication("admin"); -admin.setUsername("YOUR USERNAME"); -admin.setPassword("YOUR PASSWORD"); - -// Configure HTTP basic authorization: user -HttpBasicAuth user = (HttpBasicAuth) defaultClient.getAuthentication("user"); -user.setUsername("YOUR USERNAME"); -user.setPassword("YOUR PASSWORD"); - -DefaultApi apiInstance = new DefaultApi(); -Long id = 789L; // Long | The privilege id. -try { - Location result = apiInstance.getPrivilegeLocation(id); - System.out.println(result); -} catch (ApiException e) { - System.err.println("Exception when calling DefaultApi#getPrivilegeLocation"); - e.printStackTrace(); -} -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **id** | **Long**| The privilege id. | - -### Return type - -[**Location**](Location.md) - -### Authorization - -[admin](../README.md#admin), [user](../README.md#user) - -### HTTP request headers - - - **Content-Type**: application/json, application/xml - - **Accept**: application/json, application/xml - - -# **getShare** -> Share getShare(id) - -Returns a share. - - - -### Example -```java -// Import classes: -//import io.swagger.client.ApiClient; -//import io.swagger.client.ApiException; -//import io.swagger.client.Configuration; -//import io.swagger.client.auth.*; -//import io.swagger.client.api.DefaultApi; - -ApiClient defaultClient = Configuration.getDefaultApiClient(); - -// Configure API key authorization: device -ApiKeyAuth device = (ApiKeyAuth) defaultClient.getAuthentication("device"); -device.setApiKey("YOUR API KEY"); -// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null) -//device.setApiKeyPrefix("Token"); - -DefaultApi apiInstance = new DefaultApi(); -Long id = 789L; // Long | The share id. -try { - Share result = apiInstance.getShare(id); - System.out.println(result); -} catch (ApiException e) { - System.err.println("Exception when calling DefaultApi#getShare"); - e.printStackTrace(); -} -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **id** | **Long**| The share id. | - -### Return type - -[**Share**](Share.md) - -### Authorization - -[device](../README.md#device) - -### HTTP request headers - - - **Content-Type**: application/json, application/xml - - **Accept**: application/json, application/xml - - -# **getShareInfo** -> ShareInfo getShareInfo(token) - -Get a share info by its secret token. - - - -### Example -```java -// Import classes: -//import io.swagger.client.ApiException; -//import io.swagger.client.api.DefaultApi; - - -DefaultApi apiInstance = new DefaultApi(); -String token = "token_example"; // String | The secret token. -try { - ShareInfo result = apiInstance.getShareInfo(token); - System.out.println(result); -} catch (ApiException e) { - System.err.println("Exception when calling DefaultApi#getShareInfo"); - e.printStackTrace(); -} -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **token** | **String**| The secret token. | - -### Return type - -[**ShareInfo**](ShareInfo.md) - -### Authorization - -No authorization required - -### HTTP request headers - - - **Content-Type**: application/json, application/xml - - **Accept**: application/json, application/xml - - -# **getShareLocation** -> Location getShareLocation(token) - -Get a shared location by its secret token. - - - -### Example -```java -// Import classes: -//import io.swagger.client.ApiException; -//import io.swagger.client.api.DefaultApi; - - -DefaultApi apiInstance = new DefaultApi(); -String token = "token_example"; // String | The secret token. -try { - Location result = apiInstance.getShareLocation(token); - System.out.println(result); -} catch (ApiException e) { - System.err.println("Exception when calling DefaultApi#getShareLocation"); - e.printStackTrace(); -} -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **token** | **String**| The secret token. | - -### Return type - -[**Location**](Location.md) - -### Authorization - -No authorization required - -### HTTP request headers - - - **Content-Type**: application/json, application/xml - - **Accept**: application/json, application/xml - - -# **getSystemStatistic** -> LoadStatistic getSystemStatistic() - -Returns the system statistic. - - - -### Example -```java -// Import classes: -//import io.swagger.client.ApiClient; -//import io.swagger.client.ApiException; -//import io.swagger.client.Configuration; -//import io.swagger.client.auth.*; -//import io.swagger.client.api.DefaultApi; - -ApiClient defaultClient = Configuration.getDefaultApiClient(); - -// Configure HTTP basic authorization: admin -HttpBasicAuth admin = (HttpBasicAuth) defaultClient.getAuthentication("admin"); -admin.setUsername("YOUR USERNAME"); -admin.setPassword("YOUR PASSWORD"); - -DefaultApi apiInstance = new DefaultApi(); -try { - LoadStatistic result = apiInstance.getSystemStatistic(); - System.out.println(result); -} catch (ApiException e) { - System.err.println("Exception when calling DefaultApi#getSystemStatistic"); - e.printStackTrace(); -} -``` - -### Parameters -This endpoint does not need any parameter. - -### Return type - -[**LoadStatistic**](LoadStatistic.md) - -### Authorization - -[admin](../README.md#admin) - -### HTTP request headers - - - **Content-Type**: Not defined - - **Accept**: application/json, application/xml - - -# **getUpdatedNotices** -> List<Notice> getUpdatedNotices(since) - -Returns all active notices modified after the date. - - - -### Example -```java -// Import classes: -//import io.swagger.client.ApiException; -//import io.swagger.client.api.DefaultApi; - - -DefaultApi apiInstance = new DefaultApi(); -Long since = 0L; // Long | The earlies time in epoch milliseconds. -try { - List result = apiInstance.getUpdatedNotices(since); - System.out.println(result); -} catch (ApiException e) { - System.err.println("Exception when calling DefaultApi#getUpdatedNotices"); - e.printStackTrace(); -} -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **since** | **Long**| The earlies time in epoch milliseconds. | [optional] [default to 0] - -### Return type - -[**List<Notice>**](Notice.md) - -### Authorization - -No authorization required - -### HTTP request headers - - - **Content-Type**: application/json, application/xml - - **Accept**: application/json, application/xml - - -# **getUser** -> User getUser(id) - -Returns the user account with the specified id. - - - -### Example -```java -// Import classes: -//import io.swagger.client.ApiClient; -//import io.swagger.client.ApiException; -//import io.swagger.client.Configuration; -//import io.swagger.client.auth.*; -//import io.swagger.client.api.DefaultApi; - -ApiClient defaultClient = Configuration.getDefaultApiClient(); - -// Configure HTTP basic authorization: admin -HttpBasicAuth admin = (HttpBasicAuth) defaultClient.getAuthentication("admin"); -admin.setUsername("YOUR USERNAME"); -admin.setPassword("YOUR PASSWORD"); - -DefaultApi apiInstance = new DefaultApi(); -Long id = 789L; // Long | The id of the user to retrieve. -try { - User result = apiInstance.getUser(id); - System.out.println(result); -} catch (ApiException e) { - System.err.println("Exception when calling DefaultApi#getUser"); - e.printStackTrace(); -} -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **id** | **Long**| The id of the user to retrieve. | - -### Return type - -[**User**](User.md) - -### Authorization - -[admin](../README.md#admin) - -### HTTP request headers - - - **Content-Type**: application/json, application/xml - - **Accept**: application/json, application/xml - - -# **getUserPlaces** -> PlacePage getUserPlaces(id, pageOffset, pageSize) - -Returns the places for a particular user. - - - -### Example -```java -// Import classes: -//import io.swagger.client.ApiException; -//import io.swagger.client.api.DefaultApi; - - -DefaultApi apiInstance = new DefaultApi(); -Long id = 789L; // Long | The user id. -Integer pageOffset = 0; // Integer | The offset in terms of elements. -Integer pageSize = 20; // Integer | The maximum number of elements on the page. -try { - PlacePage result = apiInstance.getUserPlaces(id, pageOffset, pageSize); - System.out.println(result); -} catch (ApiException e) { - System.err.println("Exception when calling DefaultApi#getUserPlaces"); - e.printStackTrace(); -} -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **id** | **Long**| The user id. | - **pageOffset** | **Integer**| The offset in terms of elements. | [optional] [default to 0] - **pageSize** | **Integer**| The maximum number of elements on the page. | [optional] [default to 20] - -### Return type - -[**PlacePage**](PlacePage.md) - -### Authorization - -No authorization required - -### HTTP request headers - - - **Content-Type**: application/json, application/xml - - **Accept**: application/json, application/xml - - -# **getUserPrivileges** -> PrivilegePage getUserPrivileges(id, pageOffset, pageSize) - -Returns the privileges for a particular user. - - - -### Example -```java -// Import classes: -//import io.swagger.client.ApiClient; -//import io.swagger.client.ApiException; -//import io.swagger.client.Configuration; -//import io.swagger.client.auth.*; -//import io.swagger.client.api.DefaultApi; - -ApiClient defaultClient = Configuration.getDefaultApiClient(); - -// Configure HTTP basic authorization: admin -HttpBasicAuth admin = (HttpBasicAuth) defaultClient.getAuthentication("admin"); -admin.setUsername("YOUR USERNAME"); -admin.setPassword("YOUR PASSWORD"); - -DefaultApi apiInstance = new DefaultApi(); -Long id = 789L; // Long | The user id. -Integer pageOffset = 0; // Integer | The offset in terms of elements. -Integer pageSize = 20; // Integer | The maximum number of elements on the page. -try { - PrivilegePage result = apiInstance.getUserPrivileges(id, pageOffset, pageSize); - System.out.println(result); -} catch (ApiException e) { - System.err.println("Exception when calling DefaultApi#getUserPrivileges"); - e.printStackTrace(); -} -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **id** | **Long**| The user id. | - **pageOffset** | **Integer**| The offset in terms of elements. | [optional] [default to 0] - **pageSize** | **Integer**| The maximum number of elements on the page. | [optional] [default to 20] - -### Return type - -[**PrivilegePage**](PrivilegePage.md) - -### Authorization - -[admin](../README.md#admin) - -### HTTP request headers - - - **Content-Type**: application/json, application/xml - - **Accept**: application/json, application/xml - - -# **getUsers** -> UserPage getUsers(pageOffset, pageSize) - -Returns a list of users. - - - -### Example -```java -// Import classes: -//import io.swagger.client.ApiClient; -//import io.swagger.client.ApiException; -//import io.swagger.client.Configuration; -//import io.swagger.client.auth.*; -//import io.swagger.client.api.DefaultApi; - -ApiClient defaultClient = Configuration.getDefaultApiClient(); - -// Configure HTTP basic authorization: admin -HttpBasicAuth admin = (HttpBasicAuth) defaultClient.getAuthentication("admin"); -admin.setUsername("YOUR USERNAME"); -admin.setPassword("YOUR PASSWORD"); - -DefaultApi apiInstance = new DefaultApi(); -Integer pageOffset = 0; // Integer | The offset in terms of elements. -Integer pageSize = 20; // Integer | The maximum number of elements on the page. -try { - UserPage result = apiInstance.getUsers(pageOffset, pageSize); - System.out.println(result); -} catch (ApiException e) { - System.err.println("Exception when calling DefaultApi#getUsers"); - e.printStackTrace(); -} -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **pageOffset** | **Integer**| The offset in terms of elements. | [optional] [default to 0] - **pageSize** | **Integer**| The maximum number of elements on the page. | [optional] [default to 20] - -### Return type - -[**UserPage**](UserPage.md) - -### Authorization - -[admin](../README.md#admin) - -### HTTP request headers - - - **Content-Type**: application/json, application/xml - - **Accept**: application/json, application/xml - - -# **registerUser** -> User registerUser(body) - -Registers a new user and sends an email account verification. - - - -### Example -```java -// Import classes: -//import io.swagger.client.ApiException; -//import io.swagger.client.api.DefaultApi; - - -DefaultApi apiInstance = new DefaultApi(); -UserRegistration body = new UserRegistration(); // UserRegistration | The data of the new user. -try { - User result = apiInstance.registerUser(body); - System.out.println(result); -} catch (ApiException e) { - System.err.println("Exception when calling DefaultApi#registerUser"); - e.printStackTrace(); -} -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **body** | [**UserRegistration**](UserRegistration.md)| The data of the new user. | - -### Return type - -[**User**](User.md) - -### Authorization - -No authorization required - -### HTTP request headers - - - **Content-Type**: application/json, application/xml - - **Accept**: application/json, application/xml - - -# **resetUser** -> resetUser(login) - -Sends a password reset email to the correspondence email account of a user. - - - -### Example -```java -// Import classes: -//import io.swagger.client.ApiException; -//import io.swagger.client.api.DefaultApi; - - -DefaultApi apiInstance = new DefaultApi(); -String login = "login_example"; // String | The login of the user to reset. -try { - apiInstance.resetUser(login); -} catch (ApiException e) { - System.err.println("Exception when calling DefaultApi#resetUser"); - e.printStackTrace(); -} -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **login** | **String**| The login of the user to reset. | - -### Return type - -null (empty response body) - -### Authorization - -No authorization required - -### HTTP request headers - - - **Content-Type**: application/json, application/xml - - **Accept**: application/json, application/xml - - -# **resetUserPassword** -> User resetUserPassword(token, body) - -Sets the password of a user account using a token received via email. - - - -### Example -```java -// Import classes: -//import io.swagger.client.ApiException; -//import io.swagger.client.api.DefaultApi; - - -DefaultApi apiInstance = new DefaultApi(); -String token = "token_example"; // String | The secret token received via email. -UserPassword body = new UserPassword(); // UserPassword | The new user password. -try { - User result = apiInstance.resetUserPassword(token, body); - System.out.println(result); -} catch (ApiException e) { - System.err.println("Exception when calling DefaultApi#resetUserPassword"); - e.printStackTrace(); -} -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **token** | **String**| The secret token received via email. | - **body** | [**UserPassword**](UserPassword.md)| The new user password. | - -### Return type - -[**User**](User.md) - -### Authorization - -No authorization required - -### HTTP request headers - - - **Content-Type**: application/json, application/xml - - **Accept**: application/json, application/xml - - -# **searchUsers** -> UserPage searchUsers(term, pageOffset, pageSize) - -Returns a list of users whose login name or name contains the term. - - - -### Example -```java -// Import classes: -//import io.swagger.client.ApiClient; -//import io.swagger.client.ApiException; -//import io.swagger.client.Configuration; -//import io.swagger.client.auth.*; -//import io.swagger.client.api.DefaultApi; - -ApiClient defaultClient = Configuration.getDefaultApiClient(); - -// Configure HTTP basic authorization: admin -HttpBasicAuth admin = (HttpBasicAuth) defaultClient.getAuthentication("admin"); -admin.setUsername("YOUR USERNAME"); -admin.setPassword("YOUR PASSWORD"); - -DefaultApi apiInstance = new DefaultApi(); -String term = "term_example"; // String | The search term. -Integer pageOffset = 0; // Integer | The offset in terms of elements. -Integer pageSize = 20; // Integer | The maximum number of elements on the page. -try { - UserPage result = apiInstance.searchUsers(term, pageOffset, pageSize); - System.out.println(result); -} catch (ApiException e) { - System.err.println("Exception when calling DefaultApi#searchUsers"); - e.printStackTrace(); -} -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **term** | **String**| The search term. | - **pageOffset** | **Integer**| The offset in terms of elements. | [optional] [default to 0] - **pageSize** | **Integer**| The maximum number of elements on the page. | [optional] [default to 20] - -### Return type - -[**UserPage**](UserPage.md) - -### Authorization - -[admin](../README.md#admin) - -### HTTP request headers - - - **Content-Type**: application/json, application/xml - - **Accept**: application/json, application/xml - - -# **setCurrentPassword** -> User setCurrentPassword(body) - -Sets the password of the currently authorized user. - - - -### Example -```java -// Import classes: -//import io.swagger.client.ApiClient; -//import io.swagger.client.ApiException; -//import io.swagger.client.Configuration; -//import io.swagger.client.auth.*; -//import io.swagger.client.api.DefaultApi; - -ApiClient defaultClient = Configuration.getDefaultApiClient(); - -// Configure HTTP basic authorization: user -HttpBasicAuth user = (HttpBasicAuth) defaultClient.getAuthentication("user"); -user.setUsername("YOUR USERNAME"); -user.setPassword("YOUR PASSWORD"); - -DefaultApi apiInstance = new DefaultApi(); -UserPassword body = new UserPassword(); // UserPassword | The new password to set. -try { - User result = apiInstance.setCurrentPassword(body); - System.out.println(result); -} catch (ApiException e) { - System.err.println("Exception when calling DefaultApi#setCurrentPassword"); - e.printStackTrace(); -} -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **body** | [**UserPassword**](UserPassword.md)| The new password to set. | - -### Return type - -[**User**](User.md) - -### Authorization - -[user](../README.md#user) - -### HTTP request headers - - - **Content-Type**: application/json, application/xml - - **Accept**: application/json, application/xml - - -# **setCurrentUser** -> User setCurrentUser(body) - -Updates the currently authorized user. - - - -### Example -```java -// Import classes: -//import io.swagger.client.ApiClient; -//import io.swagger.client.ApiException; -//import io.swagger.client.Configuration; -//import io.swagger.client.auth.*; -//import io.swagger.client.api.DefaultApi; - -ApiClient defaultClient = Configuration.getDefaultApiClient(); - -// Configure HTTP basic authorization: user -HttpBasicAuth user = (HttpBasicAuth) defaultClient.getAuthentication("user"); -user.setUsername("YOUR USERNAME"); -user.setPassword("YOUR PASSWORD"); - -DefaultApi apiInstance = new DefaultApi(); -User body = new User(); // User | The new user values to set. -try { - User result = apiInstance.setCurrentUser(body); - System.out.println(result); -} catch (ApiException e) { - System.err.println("Exception when calling DefaultApi#setCurrentUser"); - e.printStackTrace(); -} -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **body** | [**User**](User.md)| The new user values to set. | - -### Return type - -[**User**](User.md) - -### Authorization - -[user](../README.md#user) - -### HTTP request headers - - - **Content-Type**: application/json, application/xml - - **Accept**: application/json, application/xml - - -# **setDevice** -> Device setDevice(id, body) - -Sets the values of a device. - - - -### Example -```java -// Import classes: -//import io.swagger.client.ApiClient; -//import io.swagger.client.ApiException; -//import io.swagger.client.Configuration; -//import io.swagger.client.auth.*; -//import io.swagger.client.api.DefaultApi; - -ApiClient defaultClient = Configuration.getDefaultApiClient(); - -// Configure HTTP basic authorization: admin -HttpBasicAuth admin = (HttpBasicAuth) defaultClient.getAuthentication("admin"); -admin.setUsername("YOUR USERNAME"); -admin.setPassword("YOUR PASSWORD"); - -DefaultApi apiInstance = new DefaultApi(); -Long id = 789L; // Long | The device id. -Device body = new Device(); // Device | The device values. -try { - Device result = apiInstance.setDevice(id, body); - System.out.println(result); -} catch (ApiException e) { - System.err.println("Exception when calling DefaultApi#setDevice"); - e.printStackTrace(); -} -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **id** | **Long**| The device id. | - **body** | [**Device**](Device.md)| The device values. | [optional] - -### Return type - -[**Device**](Device.md) - -### Authorization - -[admin](../README.md#admin) - -### HTTP request headers - - - **Content-Type**: application/json, application/xml - - **Accept**: application/json, application/xml - - -# **setNotice** -> Notice setNotice(id, body) - -Updates an existing notice. - - - -### Example -```java -// Import classes: -//import io.swagger.client.ApiClient; -//import io.swagger.client.ApiException; -//import io.swagger.client.Configuration; -//import io.swagger.client.auth.*; -//import io.swagger.client.api.DefaultApi; - -ApiClient defaultClient = Configuration.getDefaultApiClient(); - -// Configure HTTP basic authorization: admin -HttpBasicAuth admin = (HttpBasicAuth) defaultClient.getAuthentication("admin"); -admin.setUsername("YOUR USERNAME"); -admin.setPassword("YOUR PASSWORD"); - -DefaultApi apiInstance = new DefaultApi(); -Long id = 789L; // Long | The id of the notice. -Notice body = new Notice(); // Notice | The data of the notice to set. -try { - Notice result = apiInstance.setNotice(id, body); - System.out.println(result); -} catch (ApiException e) { - System.err.println("Exception when calling DefaultApi#setNotice"); - e.printStackTrace(); -} -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **id** | **Long**| The id of the notice. | - **body** | [**Notice**](Notice.md)| The data of the notice to set. | - -### Return type - -[**Notice**](Notice.md) - -### Authorization - -[admin](../README.md#admin) - -### HTTP request headers - - - **Content-Type**: application/json, application/xml - - **Accept**: application/json, application/xml - - -# **setPlace** -> Place setPlace(id, body) - -Updates the place with the specified id. - - - -### Example -```java -// Import classes: -//import io.swagger.client.ApiException; -//import io.swagger.client.api.DefaultApi; - - -DefaultApi apiInstance = new DefaultApi(); -Long id = 789L; // Long | The place id. -Place body = new Place(); // Place | The place to set. -try { - Place result = apiInstance.setPlace(id, body); - System.out.println(result); -} catch (ApiException e) { - System.err.println("Exception when calling DefaultApi#setPlace"); - e.printStackTrace(); -} -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **id** | **Long**| The place id. | - **body** | [**Place**](Place.md)| The place to set. | - -### Return type - -[**Place**](Place.md) - -### Authorization - -No authorization required - -### HTTP request headers - - - **Content-Type**: application/json, application/xml - - **Accept**: application/json, application/xml - - -# **setShare** -> Share setShare(id, body) - -Updates an existing share. - - - -### Example -```java -// Import classes: -//import io.swagger.client.ApiClient; -//import io.swagger.client.ApiException; -//import io.swagger.client.Configuration; -//import io.swagger.client.auth.*; -//import io.swagger.client.api.DefaultApi; - -ApiClient defaultClient = Configuration.getDefaultApiClient(); - -// Configure API key authorization: device -ApiKeyAuth device = (ApiKeyAuth) defaultClient.getAuthentication("device"); -device.setApiKey("YOUR API KEY"); -// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null) -//device.setApiKeyPrefix("Token"); - -DefaultApi apiInstance = new DefaultApi(); -Long id = 789L; // Long | The share id. -Share body = new Share(); // Share | The new share to set. -try { - Share result = apiInstance.setShare(id, body); - System.out.println(result); -} catch (ApiException e) { - System.err.println("Exception when calling DefaultApi#setShare"); - e.printStackTrace(); -} -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **id** | **Long**| The share id. | - **body** | [**Share**](Share.md)| The new share to set. | [optional] - -### Return type - -[**Share**](Share.md) - -### Authorization - -[device](../README.md#device) - -### HTTP request headers - - - **Content-Type**: application/json, application/xml - - **Accept**: application/json, application/xml - - -# **setUser** -> User setUser(id, body) - -Updates the values of a particular user account. - - - -### Example -```java -// Import classes: -//import io.swagger.client.ApiClient; -//import io.swagger.client.ApiException; -//import io.swagger.client.Configuration; -//import io.swagger.client.auth.*; -//import io.swagger.client.api.DefaultApi; - -ApiClient defaultClient = Configuration.getDefaultApiClient(); - -// Configure HTTP basic authorization: admin -HttpBasicAuth admin = (HttpBasicAuth) defaultClient.getAuthentication("admin"); -admin.setUsername("YOUR USERNAME"); -admin.setPassword("YOUR PASSWORD"); - -DefaultApi apiInstance = new DefaultApi(); -Long id = 789L; // Long | The id of the user to set. -User body = new User(); // User | The new user data to set. -try { - User result = apiInstance.setUser(id, body); - System.out.println(result); -} catch (ApiException e) { - System.err.println("Exception when calling DefaultApi#setUser"); - e.printStackTrace(); -} -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **id** | **Long**| The id of the user to set. | - **body** | [**User**](User.md)| The new user data to set. | - -### Return type - -[**User**](User.md) - -### Authorization - -[admin](../README.md#admin) - -### HTTP request headers - - - **Content-Type**: application/json, application/xml - - **Accept**: application/json, application/xml - - -# **setUserPassword** -> User setUserPassword(id, body) - -Sets the password of a user. - - - -### Example -```java -// Import classes: -//import io.swagger.client.ApiClient; -//import io.swagger.client.ApiException; -//import io.swagger.client.Configuration; -//import io.swagger.client.auth.*; -//import io.swagger.client.api.DefaultApi; - -ApiClient defaultClient = Configuration.getDefaultApiClient(); - -// Configure HTTP basic authorization: admin -HttpBasicAuth admin = (HttpBasicAuth) defaultClient.getAuthentication("admin"); -admin.setUsername("YOUR USERNAME"); -admin.setPassword("YOUR PASSWORD"); - -DefaultApi apiInstance = new DefaultApi(); -Long id = 789L; // Long | The id of the user to change. -UserPassword body = new UserPassword(); // UserPassword | The new password. -try { - User result = apiInstance.setUserPassword(id, body); - System.out.println(result); -} catch (ApiException e) { - System.err.println("Exception when calling DefaultApi#setUserPassword"); - e.printStackTrace(); -} -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **id** | **Long**| The id of the user to change. | - **body** | [**UserPassword**](UserPassword.md)| The new password. | - -### Return type - -[**User**](User.md) - -### Authorization - -[admin](../README.md#admin) - -### HTTP request headers - - - **Content-Type**: application/json, application/xml - - **Accept**: application/json, application/xml - - -# **verifyUserEmail** -> verifyUserEmail(token) - -Verifies an email address using a token received via email. - - - -### Example -```java -// Import classes: -//import io.swagger.client.ApiException; -//import io.swagger.client.api.DefaultApi; - - -DefaultApi apiInstance = new DefaultApi(); -String token = "token_example"; // String | The secret token received via email. -try { - apiInstance.verifyUserEmail(token); -} catch (ApiException e) { - System.err.println("Exception when calling DefaultApi#verifyUserEmail"); - e.printStackTrace(); -} -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **token** | **String**| The secret token received via email. | - -### Return type - -null (empty response body) - -### Authorization - -No authorization required - -### HTTP request headers - - - **Content-Type**: application/json, application/xml - - **Accept**: application/json, application/xml - diff --git a/testing/api-client/docs/Device.md b/testing/api-client/docs/Device.md deleted file mode 100644 index f2c1e63..0000000 --- a/testing/api-client/docs/Device.md +++ /dev/null @@ -1,26 +0,0 @@ - -# Device - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**id** | **Long** | The unique identifier of the data. | [optional] -**creationTime** | **Long** | The time stamp when the data was created. | [optional] -**modificationTime** | **Long** | The time stamp when the data was created. | [optional] -**deleted** | **Boolean** | A flag to indicate whether the data was deleted. | [optional] -**user** | **Long** | The id of the owning user or null, if there is none. | [optional] -**os** | [**OsEnum**](#OsEnum) | The operating system. | -**manufacturer** | **String** | The manufacturer name, see android.os.Build.MANUFACTURER. | -**device** | **String** | The device name, see android.os.Build.DEVICE. | -**model** | **String** | The model name, see android.os.Build.MODEL. | - - - -## Enum: OsEnum -Name | Value ----- | ----- -ANDROID | "ANDROID" -IOS | "IOS" - - - diff --git a/testing/api-client/docs/DeviceApi.md b/testing/api-client/docs/DeviceApi.md deleted file mode 100644 index 0ed8073..0000000 --- a/testing/api-client/docs/DeviceApi.md +++ /dev/null @@ -1,626 +0,0 @@ -# DeviceApi - -All URIs are relative to *http://localhost/api* - -Method | HTTP request | Description -------------- | ------------- | ------------- -[**addLocations**](DeviceApi.md#addLocations) | **POST** /devices/current/locations | Updates the locations of the current device. -[**createDevice**](DeviceApi.md#createDevice) | **POST** /devices | Creates a new device and returns its handle. -[**deleteCurrentDevice**](DeviceApi.md#deleteCurrentDevice) | **DELETE** /devices/current | Deletes the current device. -[**deleteDevice**](DeviceApi.md#deleteDevice) | **DELETE** /devices/{id} | Deletes a device. -[**getCurrentDevice**](DeviceApi.md#getCurrentDevice) | **GET** /devices/current | Returns the current device. -[**getCurrentUserDevices**](DeviceApi.md#getCurrentUserDevices) | **GET** /users/current/devices | Returns the list of devices for the current user. -[**getDevice**](DeviceApi.md#getDevice) | **GET** /devices/{id} | Gets a device. -[**getDeviceLocation**](DeviceApi.md#getDeviceLocation) | **GET** /devices/{id}/location | Gets the last device location. -[**getDeviceVisits**](DeviceApi.md#getDeviceVisits) | **GET** /devices/{id}/visits | Gets the last device location. -[**getDevices**](DeviceApi.md#getDevices) | **GET** /devices | Returns all devices. -[**setDevice**](DeviceApi.md#setDevice) | **PUT** /devices/{id} | Sets the values of a device. - - - -# **addLocations** -> addLocations(body) - -Updates the locations of the current device. - - - -### Example -```java -// Import classes: -//import io.swagger.client.ApiClient; -//import io.swagger.client.ApiException; -//import io.swagger.client.Configuration; -//import io.swagger.client.auth.*; -//import io.swagger.client.api.DeviceApi; - -ApiClient defaultClient = Configuration.getDefaultApiClient(); - -// Configure API key authorization: device -ApiKeyAuth device = (ApiKeyAuth) defaultClient.getAuthentication("device"); -device.setApiKey("YOUR API KEY"); -// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null) -//device.setApiKeyPrefix("Token"); - -DeviceApi apiInstance = new DeviceApi(); -LocationUpdate body = new LocationUpdate(); // LocationUpdate | The location update with the locations to add. -try { - apiInstance.addLocations(body); -} catch (ApiException e) { - System.err.println("Exception when calling DeviceApi#addLocations"); - e.printStackTrace(); -} -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **body** | [**LocationUpdate**](LocationUpdate.md)| The location update with the locations to add. | - -### Return type - -null (empty response body) - -### Authorization - -[device](../README.md#device) - -### HTTP request headers - - - **Content-Type**: application/json, application/xml - - **Accept**: application/json, application/xml - - -# **createDevice** -> DeviceHandle createDevice(body) - -Creates a new device and returns its handle. - -The response will include the auth token to be stored on the device and supplied as authentication on all subsequent api calls. Note that the auth token can not be requested after creation, so when losing the auth token you may lose access to the device data. - -### Example -```java -// Import classes: -//import io.swagger.client.ApiException; -//import io.swagger.client.api.DeviceApi; - - -DeviceApi apiInstance = new DeviceApi(); -DeviceInfo body = new DeviceInfo(); // DeviceInfo | Necessary data from to create a device. -try { - DeviceHandle result = apiInstance.createDevice(body); - System.out.println(result); -} catch (ApiException e) { - System.err.println("Exception when calling DeviceApi#createDevice"); - e.printStackTrace(); -} -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **body** | [**DeviceInfo**](DeviceInfo.md)| Necessary data from to create a device. | - -### Return type - -[**DeviceHandle**](DeviceHandle.md) - -### Authorization - -No authorization required - -### HTTP request headers - - - **Content-Type**: application/json, application/xml - - **Accept**: application/json, application/xml - - -# **deleteCurrentDevice** -> deleteCurrentDevice() - -Deletes the current device. - - - -### Example -```java -// Import classes: -//import io.swagger.client.ApiClient; -//import io.swagger.client.ApiException; -//import io.swagger.client.Configuration; -//import io.swagger.client.auth.*; -//import io.swagger.client.api.DeviceApi; - -ApiClient defaultClient = Configuration.getDefaultApiClient(); - -// Configure API key authorization: device -ApiKeyAuth device = (ApiKeyAuth) defaultClient.getAuthentication("device"); -device.setApiKey("YOUR API KEY"); -// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null) -//device.setApiKeyPrefix("Token"); - -DeviceApi apiInstance = new DeviceApi(); -try { - apiInstance.deleteCurrentDevice(); -} catch (ApiException e) { - System.err.println("Exception when calling DeviceApi#deleteCurrentDevice"); - e.printStackTrace(); -} -``` - -### Parameters -This endpoint does not need any parameter. - -### Return type - -null (empty response body) - -### Authorization - -[device](../README.md#device) - -### HTTP request headers - - - **Content-Type**: application/json, application/xml - - **Accept**: application/json, application/xml - - -# **deleteDevice** -> deleteDevice(id) - -Deletes a device. - - - -### Example -```java -// Import classes: -//import io.swagger.client.ApiClient; -//import io.swagger.client.ApiException; -//import io.swagger.client.Configuration; -//import io.swagger.client.auth.*; -//import io.swagger.client.api.DeviceApi; - -ApiClient defaultClient = Configuration.getDefaultApiClient(); - -// Configure HTTP basic authorization: admin -HttpBasicAuth admin = (HttpBasicAuth) defaultClient.getAuthentication("admin"); -admin.setUsername("YOUR USERNAME"); -admin.setPassword("YOUR PASSWORD"); - -// Configure HTTP basic authorization: user -HttpBasicAuth user = (HttpBasicAuth) defaultClient.getAuthentication("user"); -user.setUsername("YOUR USERNAME"); -user.setPassword("YOUR PASSWORD"); - -DeviceApi apiInstance = new DeviceApi(); -Long id = 789L; // Long | The device id. -try { - apiInstance.deleteDevice(id); -} catch (ApiException e) { - System.err.println("Exception when calling DeviceApi#deleteDevice"); - e.printStackTrace(); -} -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **id** | **Long**| The device id. | - -### Return type - -null (empty response body) - -### Authorization - -[admin](../README.md#admin), [user](../README.md#user) - -### HTTP request headers - - - **Content-Type**: application/json, application/xml - - **Accept**: application/json, application/xml - - -# **getCurrentDevice** -> Device getCurrentDevice() - -Returns the current device. - - - -### Example -```java -// Import classes: -//import io.swagger.client.ApiClient; -//import io.swagger.client.ApiException; -//import io.swagger.client.Configuration; -//import io.swagger.client.auth.*; -//import io.swagger.client.api.DeviceApi; - -ApiClient defaultClient = Configuration.getDefaultApiClient(); - -// Configure API key authorization: device -ApiKeyAuth device = (ApiKeyAuth) defaultClient.getAuthentication("device"); -device.setApiKey("YOUR API KEY"); -// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null) -//device.setApiKeyPrefix("Token"); - -DeviceApi apiInstance = new DeviceApi(); -try { - Device result = apiInstance.getCurrentDevice(); - System.out.println(result); -} catch (ApiException e) { - System.err.println("Exception when calling DeviceApi#getCurrentDevice"); - e.printStackTrace(); -} -``` - -### Parameters -This endpoint does not need any parameter. - -### Return type - -[**Device**](Device.md) - -### Authorization - -[device](../README.md#device) - -### HTTP request headers - - - **Content-Type**: application/json, application/xml - - **Accept**: application/json, application/xml - - -# **getCurrentUserDevices** -> DevicePage getCurrentUserDevices(pageOffset, pageSize) - -Returns the list of devices for the current user. - - - -### Example -```java -// Import classes: -//import io.swagger.client.ApiClient; -//import io.swagger.client.ApiException; -//import io.swagger.client.Configuration; -//import io.swagger.client.auth.*; -//import io.swagger.client.api.DeviceApi; - -ApiClient defaultClient = Configuration.getDefaultApiClient(); - -// Configure HTTP basic authorization: user -HttpBasicAuth user = (HttpBasicAuth) defaultClient.getAuthentication("user"); -user.setUsername("YOUR USERNAME"); -user.setPassword("YOUR PASSWORD"); - -DeviceApi apiInstance = new DeviceApi(); -Integer pageOffset = 0; // Integer | The offset in terms of elements. -Integer pageSize = 20; // Integer | The maximum number of elements on the page. -try { - DevicePage result = apiInstance.getCurrentUserDevices(pageOffset, pageSize); - System.out.println(result); -} catch (ApiException e) { - System.err.println("Exception when calling DeviceApi#getCurrentUserDevices"); - e.printStackTrace(); -} -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **pageOffset** | **Integer**| The offset in terms of elements. | [optional] [default to 0] - **pageSize** | **Integer**| The maximum number of elements on the page. | [optional] [default to 20] - -### Return type - -[**DevicePage**](DevicePage.md) - -### Authorization - -[user](../README.md#user) - -### HTTP request headers - - - **Content-Type**: application/json, application/xml - - **Accept**: application/json, application/xml - - -# **getDevice** -> Device getDevice(id) - -Gets a device. - - - -### Example -```java -// Import classes: -//import io.swagger.client.ApiClient; -//import io.swagger.client.ApiException; -//import io.swagger.client.Configuration; -//import io.swagger.client.auth.*; -//import io.swagger.client.api.DeviceApi; - -ApiClient defaultClient = Configuration.getDefaultApiClient(); - -// Configure HTTP basic authorization: admin -HttpBasicAuth admin = (HttpBasicAuth) defaultClient.getAuthentication("admin"); -admin.setUsername("YOUR USERNAME"); -admin.setPassword("YOUR PASSWORD"); - -// Configure HTTP basic authorization: user -HttpBasicAuth user = (HttpBasicAuth) defaultClient.getAuthentication("user"); -user.setUsername("YOUR USERNAME"); -user.setPassword("YOUR PASSWORD"); - -DeviceApi apiInstance = new DeviceApi(); -Long id = 789L; // Long | The device id. -try { - Device result = apiInstance.getDevice(id); - System.out.println(result); -} catch (ApiException e) { - System.err.println("Exception when calling DeviceApi#getDevice"); - e.printStackTrace(); -} -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **id** | **Long**| The device id. | - -### Return type - -[**Device**](Device.md) - -### Authorization - -[admin](../README.md#admin), [user](../README.md#user) - -### HTTP request headers - - - **Content-Type**: application/json, application/xml - - **Accept**: application/json, application/xml - - -# **getDeviceLocation** -> Location getDeviceLocation(id) - -Gets the last device location. - - - -### Example -```java -// Import classes: -//import io.swagger.client.ApiClient; -//import io.swagger.client.ApiException; -//import io.swagger.client.Configuration; -//import io.swagger.client.auth.*; -//import io.swagger.client.api.DeviceApi; - -ApiClient defaultClient = Configuration.getDefaultApiClient(); - -// Configure HTTP basic authorization: admin -HttpBasicAuth admin = (HttpBasicAuth) defaultClient.getAuthentication("admin"); -admin.setUsername("YOUR USERNAME"); -admin.setPassword("YOUR PASSWORD"); - -// Configure HTTP basic authorization: user -HttpBasicAuth user = (HttpBasicAuth) defaultClient.getAuthentication("user"); -user.setUsername("YOUR USERNAME"); -user.setPassword("YOUR PASSWORD"); - -DeviceApi apiInstance = new DeviceApi(); -Long id = 789L; // Long | The device id. -try { - Location result = apiInstance.getDeviceLocation(id); - System.out.println(result); -} catch (ApiException e) { - System.err.println("Exception when calling DeviceApi#getDeviceLocation"); - e.printStackTrace(); -} -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **id** | **Long**| The device id. | - -### Return type - -[**Location**](Location.md) - -### Authorization - -[admin](../README.md#admin), [user](../README.md#user) - -### HTTP request headers - - - **Content-Type**: application/json, application/xml - - **Accept**: application/json, application/xml - - -# **getDeviceVisits** -> List<Visit> getDeviceVisits(id, start, duration) - -Gets the last device location. - - - -### Example -```java -// Import classes: -//import io.swagger.client.ApiClient; -//import io.swagger.client.ApiException; -//import io.swagger.client.Configuration; -//import io.swagger.client.auth.*; -//import io.swagger.client.api.DeviceApi; - -ApiClient defaultClient = Configuration.getDefaultApiClient(); - -// Configure HTTP basic authorization: admin -HttpBasicAuth admin = (HttpBasicAuth) defaultClient.getAuthentication("admin"); -admin.setUsername("YOUR USERNAME"); -admin.setPassword("YOUR PASSWORD"); - -// Configure HTTP basic authorization: user -HttpBasicAuth user = (HttpBasicAuth) defaultClient.getAuthentication("user"); -user.setUsername("YOUR USERNAME"); -user.setPassword("YOUR PASSWORD"); - -DeviceApi apiInstance = new DeviceApi(); -Long id = 789L; // Long | The device id. -Long start = 789L; // Long | The start time in Epoch milliseconds. -Long duration = 789L; // Long | The duration in milliseconds. -try { - List result = apiInstance.getDeviceVisits(id, start, duration); - System.out.println(result); -} catch (ApiException e) { - System.err.println("Exception when calling DeviceApi#getDeviceVisits"); - e.printStackTrace(); -} -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **id** | **Long**| The device id. | - **start** | **Long**| The start time in Epoch milliseconds. | - **duration** | **Long**| The duration in milliseconds. | - -### Return type - -[**List<Visit>**](Visit.md) - -### Authorization - -[admin](../README.md#admin), [user](../README.md#user) - -### HTTP request headers - - - **Content-Type**: application/json, application/xml - - **Accept**: application/json, application/xml - - -# **getDevices** -> DevicePage getDevices(pageOffset, pageSize) - -Returns all devices. - - - -### Example -```java -// Import classes: -//import io.swagger.client.ApiClient; -//import io.swagger.client.ApiException; -//import io.swagger.client.Configuration; -//import io.swagger.client.auth.*; -//import io.swagger.client.api.DeviceApi; - -ApiClient defaultClient = Configuration.getDefaultApiClient(); - -// Configure HTTP basic authorization: admin -HttpBasicAuth admin = (HttpBasicAuth) defaultClient.getAuthentication("admin"); -admin.setUsername("YOUR USERNAME"); -admin.setPassword("YOUR PASSWORD"); - -DeviceApi apiInstance = new DeviceApi(); -Integer pageOffset = 0; // Integer | The offset in terms of elements. -Integer pageSize = 20; // Integer | The maximum number of elements on the page. -try { - DevicePage result = apiInstance.getDevices(pageOffset, pageSize); - System.out.println(result); -} catch (ApiException e) { - System.err.println("Exception when calling DeviceApi#getDevices"); - e.printStackTrace(); -} -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **pageOffset** | **Integer**| The offset in terms of elements. | [optional] [default to 0] - **pageSize** | **Integer**| The maximum number of elements on the page. | [optional] [default to 20] - -### Return type - -[**DevicePage**](DevicePage.md) - -### Authorization - -[admin](../README.md#admin) - -### HTTP request headers - - - **Content-Type**: application/json, application/xml - - **Accept**: application/json, application/xml - - -# **setDevice** -> Device setDevice(id, body) - -Sets the values of a device. - - - -### Example -```java -// Import classes: -//import io.swagger.client.ApiClient; -//import io.swagger.client.ApiException; -//import io.swagger.client.Configuration; -//import io.swagger.client.auth.*; -//import io.swagger.client.api.DeviceApi; - -ApiClient defaultClient = Configuration.getDefaultApiClient(); - -// Configure HTTP basic authorization: admin -HttpBasicAuth admin = (HttpBasicAuth) defaultClient.getAuthentication("admin"); -admin.setUsername("YOUR USERNAME"); -admin.setPassword("YOUR PASSWORD"); - -DeviceApi apiInstance = new DeviceApi(); -Long id = 789L; // Long | The device id. -Device body = new Device(); // Device | The device values. -try { - Device result = apiInstance.setDevice(id, body); - System.out.println(result); -} catch (ApiException e) { - System.err.println("Exception when calling DeviceApi#setDevice"); - e.printStackTrace(); -} -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **id** | **Long**| The device id. | - **body** | [**Device**](Device.md)| The device values. | [optional] - -### Return type - -[**Device**](Device.md) - -### Authorization - -[admin](../README.md#admin) - -### HTTP request headers - - - **Content-Type**: application/json, application/xml - - **Accept**: application/json, application/xml - diff --git a/testing/api-client/docs/DeviceHandle.md b/testing/api-client/docs/DeviceHandle.md deleted file mode 100644 index 6d1efc9..0000000 --- a/testing/api-client/docs/DeviceHandle.md +++ /dev/null @@ -1,27 +0,0 @@ - -# DeviceHandle - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**id** | **Long** | The unique identifier of the data. | [optional] -**creationTime** | **Long** | The time stamp when the data was created. | [optional] -**modificationTime** | **Long** | The time stamp when the data was created. | [optional] -**deleted** | **Boolean** | A flag to indicate whether the data was deleted. | [optional] -**user** | **Long** | The id of the owning user or null, if there is none. | [optional] -**os** | [**OsEnum**](#OsEnum) | The operating system. | -**manufacturer** | **String** | The manufacturer name, see android.os.Build.MANUFACTURER. | -**device** | **String** | The device name, see android.os.Build.DEVICE. | -**model** | **String** | The model name, see android.os.Build.MODEL. | -**token** | **String** | The secret token used for authenticating the device. | - - - -## Enum: OsEnum -Name | Value ----- | ----- -ANDROID | "ANDROID" -IOS | "IOS" - - - diff --git a/testing/api-client/docs/DeviceInfo.md b/testing/api-client/docs/DeviceInfo.md deleted file mode 100644 index 0882400..0000000 --- a/testing/api-client/docs/DeviceInfo.md +++ /dev/null @@ -1,21 +0,0 @@ - -# DeviceInfo - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**os** | [**OsEnum**](#OsEnum) | The operating system. | -**manufacturer** | **String** | The manufacturer name, see android.os.Build.MANUFACTURER. | -**device** | **String** | The device name, see android.os.Build.DEVICE. | -**model** | **String** | The model name, see android.os.Build.MODEL. | - - - -## Enum: OsEnum -Name | Value ----- | ----- -ANDROID | "ANDROID" -IOS | "IOS" - - - diff --git a/testing/api-client/docs/DevicePage.md b/testing/api-client/docs/DevicePage.md deleted file mode 100644 index 8f08609..0000000 --- a/testing/api-client/docs/DevicePage.md +++ /dev/null @@ -1,13 +0,0 @@ - -# DevicePage - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**size** | **Integer** | The maximum number of elements on the page. | -**offset** | **Integer** | The page offset (0-based) in number of elements. | -**total** | **Integer** | The total number of elements available. | -**elements** | [**List<Device>**](Device.md) | The elements of the page. | - - - diff --git a/testing/api-client/docs/Email.md b/testing/api-client/docs/Email.md deleted file mode 100644 index 72d8685..0000000 --- a/testing/api-client/docs/Email.md +++ /dev/null @@ -1,16 +0,0 @@ - -# Email - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**id** | **Long** | The unique identifier of the data. | [optional] -**creationTime** | **Long** | The time stamp when the data was created. | [optional] -**modificationTime** | **Long** | The time stamp when the data was created. | [optional] -**deleted** | **Boolean** | A flag to indicate whether the data was deleted. | [optional] -**address** | **String** | The email address. | -**correspondence** | **Boolean** | A flag to mark the email address as primary email. | -**verified** | **Boolean** | A flag to mark the email address as verified. | - - - diff --git a/testing/api-client/docs/EntityStatistic.md b/testing/api-client/docs/EntityStatistic.md deleted file mode 100644 index af3a9c5..0000000 --- a/testing/api-client/docs/EntityStatistic.md +++ /dev/null @@ -1,12 +0,0 @@ - -# EntityStatistic - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**name** | **String** | The name of the entity. | -**total** | **Long** | The total number of stored entities. | -**deleted** | **Long** | The number of deleted entities. | - - - diff --git a/testing/api-client/docs/LoadStatistic.md b/testing/api-client/docs/LoadStatistic.md deleted file mode 100644 index 72428ad..0000000 --- a/testing/api-client/docs/LoadStatistic.md +++ /dev/null @@ -1,17 +0,0 @@ - -# LoadStatistic - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**cpuLoad** | **Double** | The average cpu load over the last minute. | -**uptime** | **Long** | The uptime of the jvm in milliseconds. | -**gcCount** | **Long** | The total number of garbage collector executions. | -**gcDuration** | **Long** | The total time for garbage collection in milliseconds. | -**maxHeapSize** | **Long** | The maximum heap size available in bytes. | -**usedHeapSize** | **Long** | The used heap size available in bytes. | -**maxNonHeapSize** | **Long** | The maximum non heap size available in bytes. | -**usedNonHeapSize** | **Long** | The used non heap size available in bytes. | - - - diff --git a/testing/api-client/docs/Location.md b/testing/api-client/docs/Location.md deleted file mode 100644 index 9cdd5f3..0000000 --- a/testing/api-client/docs/Location.md +++ /dev/null @@ -1,22 +0,0 @@ - -# Location - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**timestamp** | **Long** | The timestamp of the location. | -**coordinate** | [**Coordinate**](Coordinate.md) | The coordinate of the location. | [optional] -**availability** | [**AvailabilityEnum**](#AvailabilityEnum) | The availability information of the location. | - - - -## Enum: AvailabilityEnum -Name | Value ----- | ----- -FRESH | "FRESH" -CACHED | "CACHED" -UNABLE | "UNABLE" -PRIVATE | "PRIVATE" - - - diff --git a/testing/api-client/docs/LocationUpdate.md b/testing/api-client/docs/LocationUpdate.md deleted file mode 100644 index eb5b3de..0000000 --- a/testing/api-client/docs/LocationUpdate.md +++ /dev/null @@ -1,10 +0,0 @@ - -# LocationUpdate - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**locations** | [**List<ReleasedLocation>**](ReleasedLocation.md) | The locations released with this update. | - - - diff --git a/testing/api-client/docs/LogMessage.md b/testing/api-client/docs/LogMessage.md deleted file mode 100644 index 13a03c5..0000000 --- a/testing/api-client/docs/LogMessage.md +++ /dev/null @@ -1,18 +0,0 @@ - -# LogMessage - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**id** | **Long** | An auto-generated sequential id. | -**time** | **Long** | The creation time in Epoch milliseconds. | -**thread** | **Integer** | The id of the thread. | -**level** | **String** | The message severity. | -**loggerName** | **String** | The name of the logger. | -**className** | **String** | The name of the class. | -**methodName** | **String** | The name of the method. | -**message** | **String** | The actual (optional) message. | [optional] -**trace** | **String** | An optional stack trace. | [optional] - - - diff --git a/testing/api-client/docs/Message.md b/testing/api-client/docs/Message.md deleted file mode 100644 index 297c659..0000000 --- a/testing/api-client/docs/Message.md +++ /dev/null @@ -1,23 +0,0 @@ - -# Message - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**title** | **String** | The message title. | -**body** | **String** | The message body. | -**language** | [**LanguageEnum**](#LanguageEnum) | The two letter language code in lower case. | [optional] - - - -## Enum: LanguageEnum -Name | Value ----- | ----- -DE | "de" -EN | "en" -FR | "fr" -IT | "it" -ES | "es" - - - diff --git a/testing/api-client/docs/Notice.md b/testing/api-client/docs/Notice.md deleted file mode 100644 index 0e83654..0000000 --- a/testing/api-client/docs/Notice.md +++ /dev/null @@ -1,19 +0,0 @@ - -# Notice - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**id** | **Long** | The unique identifier of the data. | [optional] -**creationTime** | **Long** | The time stamp when the data was created. | [optional] -**modificationTime** | **Long** | The time stamp when the data was created. | [optional] -**deleted** | **Boolean** | A flag to indicate whether the data was deleted. | [optional] -**announced** | **Boolean** | A flag to indicate whether the message should be announced. | -**published** | **Boolean** | A flag to indicate whether the message is published. | -**minimumVersion** | **Integer** | The minimum app version to display the message or null. | [optional] -**maximumVersion** | **Integer** | The maximum app version to display the message or null. | [optional] -**expirationTime** | **Long** | The expiration time in epoch milliseconds. | -**messages** | [**List<Message>**](Message.md) | The list of translated messages. | - - - diff --git a/testing/api-client/docs/NoticePage.md b/testing/api-client/docs/NoticePage.md deleted file mode 100644 index 6460160..0000000 --- a/testing/api-client/docs/NoticePage.md +++ /dev/null @@ -1,13 +0,0 @@ - -# NoticePage - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**size** | **Integer** | The maximum number of elements on the page. | -**offset** | **Integer** | The page offset (0-based) in number of elements. | -**total** | **Integer** | The total number of elements available. | -**elements** | [**List<Notice>**](Notice.md) | The elements of the page. | - - - diff --git a/testing/api-client/docs/Place.md b/testing/api-client/docs/Place.md deleted file mode 100644 index 3382fe4..0000000 --- a/testing/api-client/docs/Place.md +++ /dev/null @@ -1,16 +0,0 @@ - -# Place - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**id** | **Long** | The unique identifier of the data. | [optional] -**creationTime** | **Long** | The time stamp when the data was created. | [optional] -**modificationTime** | **Long** | The time stamp when the data was created. | [optional] -**deleted** | **Boolean** | A flag to indicate whether the data was deleted. | [optional] -**coordinate** | [**Coordinate**](Coordinate.md) | The coordinate of the place. | [optional] -**address** | **String** | An automatically resolved address for the coordinate. | [optional] -**nickname** | **String** | A nickname for the place assigned by the user. | [optional] - - - diff --git a/testing/api-client/docs/PlaceApi.md b/testing/api-client/docs/PlaceApi.md deleted file mode 100644 index f8d3f9f..0000000 --- a/testing/api-client/docs/PlaceApi.md +++ /dev/null @@ -1,152 +0,0 @@ -# PlaceApi - -All URIs are relative to *http://localhost/api* - -Method | HTTP request | Description -------------- | ------------- | ------------- -[**getPlace**](PlaceApi.md#getPlace) | **GET** /places/{id} | Returns the place with the specified id. -[**getPlaceVisits**](PlaceApi.md#getPlaceVisits) | **GET** /places/{id}/visits | Returns the visits for a particular place. -[**setPlace**](PlaceApi.md#setPlace) | **PUT** /places/{id} | Updates the place with the specified id. - - - -# **getPlace** -> Place getPlace(id) - -Returns the place with the specified id. - - - -### Example -```java -// Import classes: -//import io.swagger.client.ApiException; -//import io.swagger.client.api.PlaceApi; - - -PlaceApi apiInstance = new PlaceApi(); -Long id = 789L; // Long | The place id. -try { - Place result = apiInstance.getPlace(id); - System.out.println(result); -} catch (ApiException e) { - System.err.println("Exception when calling PlaceApi#getPlace"); - e.printStackTrace(); -} -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **id** | **Long**| The place id. | - -### Return type - -[**Place**](Place.md) - -### Authorization - -No authorization required - -### HTTP request headers - - - **Content-Type**: application/json, application/xml - - **Accept**: application/json, application/xml - - -# **getPlaceVisits** -> VisitPage getPlaceVisits(id, pageOffset, pageSize) - -Returns the visits for a particular place. - - - -### Example -```java -// Import classes: -//import io.swagger.client.ApiException; -//import io.swagger.client.api.PlaceApi; - - -PlaceApi apiInstance = new PlaceApi(); -Long id = 789L; // Long | The place id. -Integer pageOffset = 0; // Integer | The offset in terms of elements. -Integer pageSize = 20; // Integer | The maximum number of elements on the page. -try { - VisitPage result = apiInstance.getPlaceVisits(id, pageOffset, pageSize); - System.out.println(result); -} catch (ApiException e) { - System.err.println("Exception when calling PlaceApi#getPlaceVisits"); - e.printStackTrace(); -} -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **id** | **Long**| The place id. | - **pageOffset** | **Integer**| The offset in terms of elements. | [optional] [default to 0] - **pageSize** | **Integer**| The maximum number of elements on the page. | [optional] [default to 20] - -### Return type - -[**VisitPage**](VisitPage.md) - -### Authorization - -No authorization required - -### HTTP request headers - - - **Content-Type**: application/json, application/xml - - **Accept**: application/json, application/xml - - -# **setPlace** -> Place setPlace(id, body) - -Updates the place with the specified id. - - - -### Example -```java -// Import classes: -//import io.swagger.client.ApiException; -//import io.swagger.client.api.PlaceApi; - - -PlaceApi apiInstance = new PlaceApi(); -Long id = 789L; // Long | The place id. -Place body = new Place(); // Place | The place to set. -try { - Place result = apiInstance.setPlace(id, body); - System.out.println(result); -} catch (ApiException e) { - System.err.println("Exception when calling PlaceApi#setPlace"); - e.printStackTrace(); -} -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **id** | **Long**| The place id. | - **body** | [**Place**](Place.md)| The place to set. | - -### Return type - -[**Place**](Place.md) - -### Authorization - -No authorization required - -### HTTP request headers - - - **Content-Type**: application/json, application/xml - - **Accept**: application/json, application/xml - diff --git a/testing/api-client/docs/PlacePage.md b/testing/api-client/docs/PlacePage.md deleted file mode 100644 index 72829ad..0000000 --- a/testing/api-client/docs/PlacePage.md +++ /dev/null @@ -1,13 +0,0 @@ - -# PlacePage - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**size** | **Integer** | The maximum number of elements on the page. | -**offset** | **Integer** | The page offset (0-based) in number of elements. | -**total** | **Integer** | The total number of elements available. | -**elements** | [**List<Place>**](Place.md) | The elements of the page. | - - - diff --git a/testing/api-client/docs/Privilege.md b/testing/api-client/docs/Privilege.md deleted file mode 100644 index c158ba2..0000000 --- a/testing/api-client/docs/Privilege.md +++ /dev/null @@ -1,15 +0,0 @@ - -# Privilege - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**id** | **Long** | The unique identifier of the data. | [optional] -**creationTime** | **Long** | The time stamp when the data was created. | [optional] -**modificationTime** | **Long** | The time stamp when the data was created. | [optional] -**deleted** | **Boolean** | A flag to indicate whether the data was deleted. | [optional] -**shareInfo** | [**ShareInfo**](ShareInfo.md) | The share info of the privilege. | [optional] -**token** | **String** | The token used to get the privilege. | [optional] - - - diff --git a/testing/api-client/docs/PrivilegeApi.md b/testing/api-client/docs/PrivilegeApi.md deleted file mode 100644 index bbf2529..0000000 --- a/testing/api-client/docs/PrivilegeApi.md +++ /dev/null @@ -1,187 +0,0 @@ -# PrivilegeApi - -All URIs are relative to *http://localhost/api* - -Method | HTTP request | Description -------------- | ------------- | ------------- -[**deletePrivilege**](PrivilegeApi.md#deletePrivilege) | **DELETE** /privileges/{id} | Deletes a particular privilege. -[**getPrivilege**](PrivilegeApi.md#getPrivilege) | **GET** /privileges/{id} | Returns the privileges for a particular user. -[**getPrivilegeLocation**](PrivilegeApi.md#getPrivilegeLocation) | **GET** /privileges/{id}/location | Returns the location for a particular privilege. - - - -# **deletePrivilege** -> deletePrivilege(id) - -Deletes a particular privilege. - - - -### Example -```java -// Import classes: -//import io.swagger.client.ApiClient; -//import io.swagger.client.ApiException; -//import io.swagger.client.Configuration; -//import io.swagger.client.auth.*; -//import io.swagger.client.api.PrivilegeApi; - -ApiClient defaultClient = Configuration.getDefaultApiClient(); - -// Configure HTTP basic authorization: admin -HttpBasicAuth admin = (HttpBasicAuth) defaultClient.getAuthentication("admin"); -admin.setUsername("YOUR USERNAME"); -admin.setPassword("YOUR PASSWORD"); - -// Configure HTTP basic authorization: user -HttpBasicAuth user = (HttpBasicAuth) defaultClient.getAuthentication("user"); -user.setUsername("YOUR USERNAME"); -user.setPassword("YOUR PASSWORD"); - -PrivilegeApi apiInstance = new PrivilegeApi(); -Long id = 789L; // Long | The privilege id. -try { - apiInstance.deletePrivilege(id); -} catch (ApiException e) { - System.err.println("Exception when calling PrivilegeApi#deletePrivilege"); - e.printStackTrace(); -} -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **id** | **Long**| The privilege id. | - -### Return type - -null (empty response body) - -### Authorization - -[admin](../README.md#admin), [user](../README.md#user) - -### HTTP request headers - - - **Content-Type**: application/json, application/xml - - **Accept**: application/json, application/xml - - -# **getPrivilege** -> Privilege getPrivilege(id) - -Returns the privileges for a particular user. - - - -### Example -```java -// Import classes: -//import io.swagger.client.ApiClient; -//import io.swagger.client.ApiException; -//import io.swagger.client.Configuration; -//import io.swagger.client.auth.*; -//import io.swagger.client.api.PrivilegeApi; - -ApiClient defaultClient = Configuration.getDefaultApiClient(); - -// Configure HTTP basic authorization: admin -HttpBasicAuth admin = (HttpBasicAuth) defaultClient.getAuthentication("admin"); -admin.setUsername("YOUR USERNAME"); -admin.setPassword("YOUR PASSWORD"); - -// Configure HTTP basic authorization: user -HttpBasicAuth user = (HttpBasicAuth) defaultClient.getAuthentication("user"); -user.setUsername("YOUR USERNAME"); -user.setPassword("YOUR PASSWORD"); - -PrivilegeApi apiInstance = new PrivilegeApi(); -Long id = 789L; // Long | The privilege id. -try { - Privilege result = apiInstance.getPrivilege(id); - System.out.println(result); -} catch (ApiException e) { - System.err.println("Exception when calling PrivilegeApi#getPrivilege"); - e.printStackTrace(); -} -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **id** | **Long**| The privilege id. | - -### Return type - -[**Privilege**](Privilege.md) - -### Authorization - -[admin](../README.md#admin), [user](../README.md#user) - -### HTTP request headers - - - **Content-Type**: application/json, application/xml - - **Accept**: application/json, application/xml - - -# **getPrivilegeLocation** -> Location getPrivilegeLocation(id) - -Returns the location for a particular privilege. - - - -### Example -```java -// Import classes: -//import io.swagger.client.ApiClient; -//import io.swagger.client.ApiException; -//import io.swagger.client.Configuration; -//import io.swagger.client.auth.*; -//import io.swagger.client.api.PrivilegeApi; - -ApiClient defaultClient = Configuration.getDefaultApiClient(); - -// Configure HTTP basic authorization: admin -HttpBasicAuth admin = (HttpBasicAuth) defaultClient.getAuthentication("admin"); -admin.setUsername("YOUR USERNAME"); -admin.setPassword("YOUR PASSWORD"); - -// Configure HTTP basic authorization: user -HttpBasicAuth user = (HttpBasicAuth) defaultClient.getAuthentication("user"); -user.setUsername("YOUR USERNAME"); -user.setPassword("YOUR PASSWORD"); - -PrivilegeApi apiInstance = new PrivilegeApi(); -Long id = 789L; // Long | The privilege id. -try { - Location result = apiInstance.getPrivilegeLocation(id); - System.out.println(result); -} catch (ApiException e) { - System.err.println("Exception when calling PrivilegeApi#getPrivilegeLocation"); - e.printStackTrace(); -} -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **id** | **Long**| The privilege id. | - -### Return type - -[**Location**](Location.md) - -### Authorization - -[admin](../README.md#admin), [user](../README.md#user) - -### HTTP request headers - - - **Content-Type**: application/json, application/xml - - **Accept**: application/json, application/xml - diff --git a/testing/api-client/docs/PrivilegePage.md b/testing/api-client/docs/PrivilegePage.md deleted file mode 100644 index becab06..0000000 --- a/testing/api-client/docs/PrivilegePage.md +++ /dev/null @@ -1,13 +0,0 @@ - -# PrivilegePage - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**size** | **Integer** | The maximum number of elements on the page. | -**offset** | **Integer** | The page offset (0-based) in number of elements. | -**total** | **Integer** | The total number of elements available. | -**elements** | [**List<Privilege>**](Privilege.md) | The elements of the page. | - - - diff --git a/testing/api-client/docs/ReleasedLocation.md b/testing/api-client/docs/ReleasedLocation.md deleted file mode 100644 index 185d4ef..0000000 --- a/testing/api-client/docs/ReleasedLocation.md +++ /dev/null @@ -1,30 +0,0 @@ - -# ReleasedLocation - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**timestamp** | **Long** | The timestamp of the location. | -**coordinate** | [**Coordinate**](Coordinate.md) | The coordinate of the location. | [optional] -**availability** | [**AvailabilityEnum**](#AvailabilityEnum) | The availability information of the location. | -**version** | **Integer** | The version code of the application. | -**speed** | **Double** | The speed in meter per second or null, if not available. | [optional] -**bearing** | **Double** | The bearing in degree or null, if not available. | [optional] -**altitude** | **Double** | The altitude in meters or null, if not available. | [optional] -**accuracy** | **Double** | The accuracy in meters or null, if not available. | [optional] -**provider** | **String** | The provider name or null, if not available. | [optional] -**sharable** | **Boolean** | A boolean value to mark the update as sharable for research purposes. | -**analyzable** | **Boolean** | A boolean value to mark the update as analyzable to compute places and visits. | - - - -## Enum: AvailabilityEnum -Name | Value ----- | ----- -FRESH | "FRESH" -CACHED | "CACHED" -UNABLE | "UNABLE" -PRIVATE | "PRIVATE" - - - diff --git a/testing/api-client/docs/ServiceApi.md b/testing/api-client/docs/ServiceApi.md deleted file mode 100644 index 560ea15..0000000 --- a/testing/api-client/docs/ServiceApi.md +++ /dev/null @@ -1,576 +0,0 @@ -# ServiceApi - -All URIs are relative to *http://localhost/api* - -Method | HTTP request | Description -------------- | ------------- | ------------- -[**addNotice**](ServiceApi.md#addNotice) | **POST** /notices | Adds a new notice and returns the notice as well as its location. -[**getActiveNotices**](ServiceApi.md#getActiveNotices) | **GET** /notices/active | Returns a page of notices. -[**getBuildVersion**](ServiceApi.md#getBuildVersion) | **GET** /versions/build | Returns the build version. -[**getEntityStatistics**](ServiceApi.md#getEntityStatistics) | **GET** /log/entities | Returns a list of entity statistics. -[**getLoadStatistic**](ServiceApi.md#getLoadStatistic) | **GET** /log/load | Returns the current load statistic. -[**getLogMessages**](ServiceApi.md#getLogMessages) | **GET** /log/messages | Returns a list of log messages starting from a particular id. -[**getNotice**](ServiceApi.md#getNotice) | **GET** /notices/{id} | Returns the notice with the specified id. -[**getNotices**](ServiceApi.md#getNotices) | **GET** /notices | Returns a page of notices. -[**getSystemStatistic**](ServiceApi.md#getSystemStatistic) | **GET** /log/system | Returns the system statistic. -[**getUpdatedNotices**](ServiceApi.md#getUpdatedNotices) | **GET** /notices/updated | Returns all active notices modified after the date. -[**setNotice**](ServiceApi.md#setNotice) | **PUT** /notices/{id} | Updates an existing notice. - - - -# **addNotice** -> Notice addNotice(body) - -Adds a new notice and returns the notice as well as its location. - - - -### Example -```java -// Import classes: -//import io.swagger.client.ApiClient; -//import io.swagger.client.ApiException; -//import io.swagger.client.Configuration; -//import io.swagger.client.auth.*; -//import io.swagger.client.api.ServiceApi; - -ApiClient defaultClient = Configuration.getDefaultApiClient(); - -// Configure HTTP basic authorization: admin -HttpBasicAuth admin = (HttpBasicAuth) defaultClient.getAuthentication("admin"); -admin.setUsername("YOUR USERNAME"); -admin.setPassword("YOUR PASSWORD"); - -ServiceApi apiInstance = new ServiceApi(); -Notice body = new Notice(); // Notice | The new notice to add. -try { - Notice result = apiInstance.addNotice(body); - System.out.println(result); -} catch (ApiException e) { - System.err.println("Exception when calling ServiceApi#addNotice"); - e.printStackTrace(); -} -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **body** | [**Notice**](Notice.md)| The new notice to add. | - -### Return type - -[**Notice**](Notice.md) - -### Authorization - -[admin](../README.md#admin) - -### HTTP request headers - - - **Content-Type**: application/json, application/xml - - **Accept**: application/json, application/xml - - -# **getActiveNotices** -> NoticePage getActiveNotices(pageOffset, pageSize) - -Returns a page of notices. - - - -### Example -```java -// Import classes: -//import io.swagger.client.ApiException; -//import io.swagger.client.api.ServiceApi; - - -ServiceApi apiInstance = new ServiceApi(); -Integer pageOffset = 0; // Integer | The offset in terms of elements. -Integer pageSize = 20; // Integer | The maximum number of elements on the page. -try { - NoticePage result = apiInstance.getActiveNotices(pageOffset, pageSize); - System.out.println(result); -} catch (ApiException e) { - System.err.println("Exception when calling ServiceApi#getActiveNotices"); - e.printStackTrace(); -} -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **pageOffset** | **Integer**| The offset in terms of elements. | [optional] [default to 0] - **pageSize** | **Integer**| The maximum number of elements on the page. | [optional] [default to 20] - -### Return type - -[**NoticePage**](NoticePage.md) - -### Authorization - -No authorization required - -### HTTP request headers - - - **Content-Type**: application/json, application/xml - - **Accept**: application/json, application/xml - - -# **getBuildVersion** -> BuildVersion getBuildVersion() - -Returns the build version. - - - -### Example -```java -// Import classes: -//import io.swagger.client.ApiException; -//import io.swagger.client.api.ServiceApi; - - -ServiceApi apiInstance = new ServiceApi(); -try { - BuildVersion result = apiInstance.getBuildVersion(); - System.out.println(result); -} catch (ApiException e) { - System.err.println("Exception when calling ServiceApi#getBuildVersion"); - e.printStackTrace(); -} -``` - -### Parameters -This endpoint does not need any parameter. - -### Return type - -[**BuildVersion**](BuildVersion.md) - -### Authorization - -No authorization required - -### HTTP request headers - - - **Content-Type**: Not defined - - **Accept**: application/json, application/xml - - -# **getEntityStatistics** -> List<EntityStatistic> getEntityStatistics() - -Returns a list of entity statistics. - - - -### Example -```java -// Import classes: -//import io.swagger.client.ApiClient; -//import io.swagger.client.ApiException; -//import io.swagger.client.Configuration; -//import io.swagger.client.auth.*; -//import io.swagger.client.api.ServiceApi; - -ApiClient defaultClient = Configuration.getDefaultApiClient(); - -// Configure HTTP basic authorization: admin -HttpBasicAuth admin = (HttpBasicAuth) defaultClient.getAuthentication("admin"); -admin.setUsername("YOUR USERNAME"); -admin.setPassword("YOUR PASSWORD"); - -ServiceApi apiInstance = new ServiceApi(); -try { - List result = apiInstance.getEntityStatistics(); - System.out.println(result); -} catch (ApiException e) { - System.err.println("Exception when calling ServiceApi#getEntityStatistics"); - e.printStackTrace(); -} -``` - -### Parameters -This endpoint does not need any parameter. - -### Return type - -[**List<EntityStatistic>**](EntityStatistic.md) - -### Authorization - -[admin](../README.md#admin) - -### HTTP request headers - - - **Content-Type**: Not defined - - **Accept**: application/json, application/xml - - -# **getLoadStatistic** -> LoadStatistic getLoadStatistic() - -Returns the current load statistic. - - - -### Example -```java -// Import classes: -//import io.swagger.client.ApiClient; -//import io.swagger.client.ApiException; -//import io.swagger.client.Configuration; -//import io.swagger.client.auth.*; -//import io.swagger.client.api.ServiceApi; - -ApiClient defaultClient = Configuration.getDefaultApiClient(); - -// Configure HTTP basic authorization: admin -HttpBasicAuth admin = (HttpBasicAuth) defaultClient.getAuthentication("admin"); -admin.setUsername("YOUR USERNAME"); -admin.setPassword("YOUR PASSWORD"); - -ServiceApi apiInstance = new ServiceApi(); -try { - LoadStatistic result = apiInstance.getLoadStatistic(); - System.out.println(result); -} catch (ApiException e) { - System.err.println("Exception when calling ServiceApi#getLoadStatistic"); - e.printStackTrace(); -} -``` - -### Parameters -This endpoint does not need any parameter. - -### Return type - -[**LoadStatistic**](LoadStatistic.md) - -### Authorization - -[admin](../README.md#admin) - -### HTTP request headers - - - **Content-Type**: Not defined - - **Accept**: application/json, application/xml - - -# **getLogMessages** -> List<LogMessage> getLogMessages(from) - -Returns a list of log messages starting from a particular id. - - - -### Example -```java -// Import classes: -//import io.swagger.client.ApiClient; -//import io.swagger.client.ApiException; -//import io.swagger.client.Configuration; -//import io.swagger.client.auth.*; -//import io.swagger.client.api.ServiceApi; - -ApiClient defaultClient = Configuration.getDefaultApiClient(); - -// Configure HTTP basic authorization: admin -HttpBasicAuth admin = (HttpBasicAuth) defaultClient.getAuthentication("admin"); -admin.setUsername("YOUR USERNAME"); -admin.setPassword("YOUR PASSWORD"); - -ServiceApi apiInstance = new ServiceApi(); -Long from = 0L; // Long | The id of the first message to retrieve. -try { - List result = apiInstance.getLogMessages(from); - System.out.println(result); -} catch (ApiException e) { - System.err.println("Exception when calling ServiceApi#getLogMessages"); - e.printStackTrace(); -} -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **from** | **Long**| The id of the first message to retrieve. | [optional] [default to 0] - -### Return type - -[**List<LogMessage>**](LogMessage.md) - -### Authorization - -[admin](../README.md#admin) - -### HTTP request headers - - - **Content-Type**: Not defined - - **Accept**: application/json, application/xml - - -# **getNotice** -> Notice getNotice(id) - -Returns the notice with the specified id. - - - -### Example -```java -// Import classes: -//import io.swagger.client.ApiClient; -//import io.swagger.client.ApiException; -//import io.swagger.client.Configuration; -//import io.swagger.client.auth.*; -//import io.swagger.client.api.ServiceApi; - -ApiClient defaultClient = Configuration.getDefaultApiClient(); - -// Configure HTTP basic authorization: admin -HttpBasicAuth admin = (HttpBasicAuth) defaultClient.getAuthentication("admin"); -admin.setUsername("YOUR USERNAME"); -admin.setPassword("YOUR PASSWORD"); - -ServiceApi apiInstance = new ServiceApi(); -Long id = 789L; // Long | The id of the notice. -try { - Notice result = apiInstance.getNotice(id); - System.out.println(result); -} catch (ApiException e) { - System.err.println("Exception when calling ServiceApi#getNotice"); - e.printStackTrace(); -} -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **id** | **Long**| The id of the notice. | - -### Return type - -[**Notice**](Notice.md) - -### Authorization - -[admin](../README.md#admin) - -### HTTP request headers - - - **Content-Type**: application/json, application/xml - - **Accept**: application/json, application/xml - - -# **getNotices** -> NoticePage getNotices(pageOffset, pageSize) - -Returns a page of notices. - - - -### Example -```java -// Import classes: -//import io.swagger.client.ApiClient; -//import io.swagger.client.ApiException; -//import io.swagger.client.Configuration; -//import io.swagger.client.auth.*; -//import io.swagger.client.api.ServiceApi; - -ApiClient defaultClient = Configuration.getDefaultApiClient(); - -// Configure HTTP basic authorization: admin -HttpBasicAuth admin = (HttpBasicAuth) defaultClient.getAuthentication("admin"); -admin.setUsername("YOUR USERNAME"); -admin.setPassword("YOUR PASSWORD"); - -ServiceApi apiInstance = new ServiceApi(); -Integer pageOffset = 0; // Integer | The offset in terms of elements. -Integer pageSize = 20; // Integer | The maximum number of elements on the page. -try { - NoticePage result = apiInstance.getNotices(pageOffset, pageSize); - System.out.println(result); -} catch (ApiException e) { - System.err.println("Exception when calling ServiceApi#getNotices"); - e.printStackTrace(); -} -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **pageOffset** | **Integer**| The offset in terms of elements. | [optional] [default to 0] - **pageSize** | **Integer**| The maximum number of elements on the page. | [optional] [default to 20] - -### Return type - -[**NoticePage**](NoticePage.md) - -### Authorization - -[admin](../README.md#admin) - -### HTTP request headers - - - **Content-Type**: application/json, application/xml - - **Accept**: application/json, application/xml - - -# **getSystemStatistic** -> LoadStatistic getSystemStatistic() - -Returns the system statistic. - - - -### Example -```java -// Import classes: -//import io.swagger.client.ApiClient; -//import io.swagger.client.ApiException; -//import io.swagger.client.Configuration; -//import io.swagger.client.auth.*; -//import io.swagger.client.api.ServiceApi; - -ApiClient defaultClient = Configuration.getDefaultApiClient(); - -// Configure HTTP basic authorization: admin -HttpBasicAuth admin = (HttpBasicAuth) defaultClient.getAuthentication("admin"); -admin.setUsername("YOUR USERNAME"); -admin.setPassword("YOUR PASSWORD"); - -ServiceApi apiInstance = new ServiceApi(); -try { - LoadStatistic result = apiInstance.getSystemStatistic(); - System.out.println(result); -} catch (ApiException e) { - System.err.println("Exception when calling ServiceApi#getSystemStatistic"); - e.printStackTrace(); -} -``` - -### Parameters -This endpoint does not need any parameter. - -### Return type - -[**LoadStatistic**](LoadStatistic.md) - -### Authorization - -[admin](../README.md#admin) - -### HTTP request headers - - - **Content-Type**: Not defined - - **Accept**: application/json, application/xml - - -# **getUpdatedNotices** -> List<Notice> getUpdatedNotices(since) - -Returns all active notices modified after the date. - - - -### Example -```java -// Import classes: -//import io.swagger.client.ApiException; -//import io.swagger.client.api.ServiceApi; - - -ServiceApi apiInstance = new ServiceApi(); -Long since = 0L; // Long | The earlies time in epoch milliseconds. -try { - List result = apiInstance.getUpdatedNotices(since); - System.out.println(result); -} catch (ApiException e) { - System.err.println("Exception when calling ServiceApi#getUpdatedNotices"); - e.printStackTrace(); -} -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **since** | **Long**| The earlies time in epoch milliseconds. | [optional] [default to 0] - -### Return type - -[**List<Notice>**](Notice.md) - -### Authorization - -No authorization required - -### HTTP request headers - - - **Content-Type**: application/json, application/xml - - **Accept**: application/json, application/xml - - -# **setNotice** -> Notice setNotice(id, body) - -Updates an existing notice. - - - -### Example -```java -// Import classes: -//import io.swagger.client.ApiClient; -//import io.swagger.client.ApiException; -//import io.swagger.client.Configuration; -//import io.swagger.client.auth.*; -//import io.swagger.client.api.ServiceApi; - -ApiClient defaultClient = Configuration.getDefaultApiClient(); - -// Configure HTTP basic authorization: admin -HttpBasicAuth admin = (HttpBasicAuth) defaultClient.getAuthentication("admin"); -admin.setUsername("YOUR USERNAME"); -admin.setPassword("YOUR PASSWORD"); - -ServiceApi apiInstance = new ServiceApi(); -Long id = 789L; // Long | The id of the notice. -Notice body = new Notice(); // Notice | The data of the notice to set. -try { - Notice result = apiInstance.setNotice(id, body); - System.out.println(result); -} catch (ApiException e) { - System.err.println("Exception when calling ServiceApi#setNotice"); - e.printStackTrace(); -} -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **id** | **Long**| The id of the notice. | - **body** | [**Notice**](Notice.md)| The data of the notice to set. | - -### Return type - -[**Notice**](Notice.md) - -### Authorization - -[admin](../README.md#admin) - -### HTTP request headers - - - **Content-Type**: application/json, application/xml - - **Accept**: application/json, application/xml - diff --git a/testing/api-client/docs/Share.md b/testing/api-client/docs/Share.md deleted file mode 100644 index 66fa0cf..0000000 --- a/testing/api-client/docs/Share.md +++ /dev/null @@ -1,19 +0,0 @@ - -# Share - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**id** | **Long** | The unique identifier of the data. | [optional] -**creationTime** | **Long** | The time stamp when the data was created. | [optional] -**modificationTime** | **Long** | The time stamp when the data was created. | [optional] -**deleted** | **Boolean** | A flag to indicate whether the data was deleted. | [optional] -**token** | **String** | The token to forward to other persons to be able to access the share. | -**device** | **Long** | The id of the related device. | [optional] -**message** | **String** | A message to be displayed to the share receiving users. | [optional] -**destination** | **String** | A destination to be displayed to the share receiving users. | [optional] -**expirationTime** | **Long** | The expiration time of the share that should be created. | -**paused** | **Boolean** | A flag to indicate whether the sharing is temporarily paused. | [optional] - - - diff --git a/testing/api-client/docs/ShareApi.md b/testing/api-client/docs/ShareApi.md deleted file mode 100644 index 8b85828..0000000 --- a/testing/api-client/docs/ShareApi.md +++ /dev/null @@ -1,325 +0,0 @@ -# ShareApi - -All URIs are relative to *http://localhost/api* - -Method | HTTP request | Description -------------- | ------------- | ------------- -[**createShare**](ShareApi.md#createShare) | **POST** /shares | Creates a new share. -[**deleteShare**](ShareApi.md#deleteShare) | **DELETE** /shares/{id} | Delete a share. -[**getShare**](ShareApi.md#getShare) | **GET** /shares/{id} | Returns a share. -[**getShareInfo**](ShareApi.md#getShareInfo) | **GET** /shares/{token}/info | Get a share info by its secret token. -[**getShareLocation**](ShareApi.md#getShareLocation) | **GET** /shares/{token}/location | Get a shared location by its secret token. -[**setShare**](ShareApi.md#setShare) | **PUT** /shares/{id} | Updates an existing share. - - - -# **createShare** -> Share createShare(body) - -Creates a new share. - - - -### Example -```java -// Import classes: -//import io.swagger.client.ApiClient; -//import io.swagger.client.ApiException; -//import io.swagger.client.Configuration; -//import io.swagger.client.auth.*; -//import io.swagger.client.api.ShareApi; - -ApiClient defaultClient = Configuration.getDefaultApiClient(); - -// Configure API key authorization: device -ApiKeyAuth device = (ApiKeyAuth) defaultClient.getAuthentication("device"); -device.setApiKey("YOUR API KEY"); -// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null) -//device.setApiKeyPrefix("Token"); - -ShareApi apiInstance = new ShareApi(); -ShareInfo body = new ShareInfo(); // ShareInfo | Necessary data from to create a share. -try { - Share result = apiInstance.createShare(body); - System.out.println(result); -} catch (ApiException e) { - System.err.println("Exception when calling ShareApi#createShare"); - e.printStackTrace(); -} -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **body** | [**ShareInfo**](ShareInfo.md)| Necessary data from to create a share. | - -### Return type - -[**Share**](Share.md) - -### Authorization - -[device](../README.md#device) - -### HTTP request headers - - - **Content-Type**: application/json, application/xml - - **Accept**: application/json, application/xml - - -# **deleteShare** -> deleteShare(id) - -Delete a share. - - - -### Example -```java -// Import classes: -//import io.swagger.client.ApiClient; -//import io.swagger.client.ApiException; -//import io.swagger.client.Configuration; -//import io.swagger.client.auth.*; -//import io.swagger.client.api.ShareApi; - -ApiClient defaultClient = Configuration.getDefaultApiClient(); - -// Configure API key authorization: device -ApiKeyAuth device = (ApiKeyAuth) defaultClient.getAuthentication("device"); -device.setApiKey("YOUR API KEY"); -// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null) -//device.setApiKeyPrefix("Token"); - -ShareApi apiInstance = new ShareApi(); -Long id = 789L; // Long | The share id. -try { - apiInstance.deleteShare(id); -} catch (ApiException e) { - System.err.println("Exception when calling ShareApi#deleteShare"); - e.printStackTrace(); -} -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **id** | **Long**| The share id. | - -### Return type - -null (empty response body) - -### Authorization - -[device](../README.md#device) - -### HTTP request headers - - - **Content-Type**: application/json, application/xml - - **Accept**: application/json, application/xml - - -# **getShare** -> Share getShare(id) - -Returns a share. - - - -### Example -```java -// Import classes: -//import io.swagger.client.ApiClient; -//import io.swagger.client.ApiException; -//import io.swagger.client.Configuration; -//import io.swagger.client.auth.*; -//import io.swagger.client.api.ShareApi; - -ApiClient defaultClient = Configuration.getDefaultApiClient(); - -// Configure API key authorization: device -ApiKeyAuth device = (ApiKeyAuth) defaultClient.getAuthentication("device"); -device.setApiKey("YOUR API KEY"); -// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null) -//device.setApiKeyPrefix("Token"); - -ShareApi apiInstance = new ShareApi(); -Long id = 789L; // Long | The share id. -try { - Share result = apiInstance.getShare(id); - System.out.println(result); -} catch (ApiException e) { - System.err.println("Exception when calling ShareApi#getShare"); - e.printStackTrace(); -} -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **id** | **Long**| The share id. | - -### Return type - -[**Share**](Share.md) - -### Authorization - -[device](../README.md#device) - -### HTTP request headers - - - **Content-Type**: application/json, application/xml - - **Accept**: application/json, application/xml - - -# **getShareInfo** -> ShareInfo getShareInfo(token) - -Get a share info by its secret token. - - - -### Example -```java -// Import classes: -//import io.swagger.client.ApiException; -//import io.swagger.client.api.ShareApi; - - -ShareApi apiInstance = new ShareApi(); -String token = "token_example"; // String | The secret token. -try { - ShareInfo result = apiInstance.getShareInfo(token); - System.out.println(result); -} catch (ApiException e) { - System.err.println("Exception when calling ShareApi#getShareInfo"); - e.printStackTrace(); -} -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **token** | **String**| The secret token. | - -### Return type - -[**ShareInfo**](ShareInfo.md) - -### Authorization - -No authorization required - -### HTTP request headers - - - **Content-Type**: application/json, application/xml - - **Accept**: application/json, application/xml - - -# **getShareLocation** -> Location getShareLocation(token) - -Get a shared location by its secret token. - - - -### Example -```java -// Import classes: -//import io.swagger.client.ApiException; -//import io.swagger.client.api.ShareApi; - - -ShareApi apiInstance = new ShareApi(); -String token = "token_example"; // String | The secret token. -try { - Location result = apiInstance.getShareLocation(token); - System.out.println(result); -} catch (ApiException e) { - System.err.println("Exception when calling ShareApi#getShareLocation"); - e.printStackTrace(); -} -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **token** | **String**| The secret token. | - -### Return type - -[**Location**](Location.md) - -### Authorization - -No authorization required - -### HTTP request headers - - - **Content-Type**: application/json, application/xml - - **Accept**: application/json, application/xml - - -# **setShare** -> Share setShare(id, body) - -Updates an existing share. - - - -### Example -```java -// Import classes: -//import io.swagger.client.ApiClient; -//import io.swagger.client.ApiException; -//import io.swagger.client.Configuration; -//import io.swagger.client.auth.*; -//import io.swagger.client.api.ShareApi; - -ApiClient defaultClient = Configuration.getDefaultApiClient(); - -// Configure API key authorization: device -ApiKeyAuth device = (ApiKeyAuth) defaultClient.getAuthentication("device"); -device.setApiKey("YOUR API KEY"); -// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null) -//device.setApiKeyPrefix("Token"); - -ShareApi apiInstance = new ShareApi(); -Long id = 789L; // Long | The share id. -Share body = new Share(); // Share | The new share to set. -try { - Share result = apiInstance.setShare(id, body); - System.out.println(result); -} catch (ApiException e) { - System.err.println("Exception when calling ShareApi#setShare"); - e.printStackTrace(); -} -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **id** | **Long**| The share id. | - **body** | [**Share**](Share.md)| The new share to set. | [optional] - -### Return type - -[**Share**](Share.md) - -### Authorization - -[device](../README.md#device) - -### HTTP request headers - - - **Content-Type**: application/json, application/xml - - **Accept**: application/json, application/xml - diff --git a/testing/api-client/docs/ShareInfo.md b/testing/api-client/docs/ShareInfo.md deleted file mode 100644 index 073160e..0000000 --- a/testing/api-client/docs/ShareInfo.md +++ /dev/null @@ -1,12 +0,0 @@ - -# ShareInfo - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**message** | **String** | A message to be displayed to the share receiving users. | [optional] -**destination** | **String** | A destination to be displayed to the share receiving users. | [optional] -**expirationTime** | **Long** | The expiration time of the share that should be created. | - - - diff --git a/testing/api-client/docs/User.md b/testing/api-client/docs/User.md deleted file mode 100644 index 05f1013..0000000 --- a/testing/api-client/docs/User.md +++ /dev/null @@ -1,18 +0,0 @@ - -# User - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**id** | **Long** | The unique identifier of the data. | [optional] -**creationTime** | **Long** | The time stamp when the data was created. | [optional] -**modificationTime** | **Long** | The time stamp when the data was created. | [optional] -**deleted** | **Boolean** | A flag to indicate whether the data was deleted. | [optional] -**login** | **String** | The (globally unique) login of the user. | -**name** | **String** | The human name of the user. | -**suspended** | **Boolean** | A flag to indicate that user account is suspended. | -**roles** | **List<String>** | | -**emails** | [**List<Email>**](Email.md) | | - - - diff --git a/testing/api-client/docs/UserApi.md b/testing/api-client/docs/UserApi.md deleted file mode 100644 index 93ffe9e..0000000 --- a/testing/api-client/docs/UserApi.md +++ /dev/null @@ -1,1019 +0,0 @@ -# UserApi - -All URIs are relative to *http://localhost/api* - -Method | HTTP request | Description -------------- | ------------- | ------------- -[**addCurrentUserPrivilege**](UserApi.md#addCurrentUserPrivilege) | **POST** /users/current/privileges | Add a privilege for the specified user. -[**addUser**](UserApi.md#addUser) | **POST** /users | Adds a user account with the specified roles and emails. -[**addUserPrivilege**](UserApi.md#addUserPrivilege) | **POST** /users/{id}/privileges | Returns the privileges for a particular user. -[**getCurrentUser**](UserApi.md#getCurrentUser) | **GET** /users/current | Returns the user currently authorized. -[**getCurrentUserPlaces**](UserApi.md#getCurrentUserPlaces) | **GET** /users/current/places | Returns the places for the current user. -[**getCurrentUserPrivileges**](UserApi.md#getCurrentUserPrivileges) | **GET** /users/current/privileges | Returns the privileges for the current user. -[**getUser**](UserApi.md#getUser) | **GET** /users/{id} | Returns the user account with the specified id. -[**getUserPlaces**](UserApi.md#getUserPlaces) | **GET** /users/{id}/places | Returns the places for a particular user. -[**getUserPrivileges**](UserApi.md#getUserPrivileges) | **GET** /users/{id}/privileges | Returns the privileges for a particular user. -[**getUsers**](UserApi.md#getUsers) | **GET** /users | Returns a list of users. -[**registerUser**](UserApi.md#registerUser) | **POST** /users/register | Registers a new user and sends an email account verification. -[**resetUser**](UserApi.md#resetUser) | **POST** /users/reset | Sends a password reset email to the correspondence email account of a user. -[**resetUserPassword**](UserApi.md#resetUserPassword) | **PUT** /users/password/{token} | Sets the password of a user account using a token received via email. -[**searchUsers**](UserApi.md#searchUsers) | **GET** /users/search | Returns a list of users whose login name or name contains the term. -[**setCurrentPassword**](UserApi.md#setCurrentPassword) | **PUT** /users/current/password | Sets the password of the currently authorized user. -[**setCurrentUser**](UserApi.md#setCurrentUser) | **PUT** /users/current | Updates the currently authorized user. -[**setUser**](UserApi.md#setUser) | **PUT** /users/{id} | Updates the values of a particular user account. -[**setUserPassword**](UserApi.md#setUserPassword) | **PUT** /users/{id}/password | Sets the password of a user. -[**verifyUserEmail**](UserApi.md#verifyUserEmail) | **PUT** /users/verify/{token} | Verifies an email address using a token received via email. - - - -# **addCurrentUserPrivilege** -> Privilege addCurrentUserPrivilege(share) - -Add a privilege for the specified user. - - - -### Example -```java -// Import classes: -//import io.swagger.client.ApiClient; -//import io.swagger.client.ApiException; -//import io.swagger.client.Configuration; -//import io.swagger.client.auth.*; -//import io.swagger.client.api.UserApi; - -ApiClient defaultClient = Configuration.getDefaultApiClient(); - -// Configure HTTP basic authorization: user -HttpBasicAuth user = (HttpBasicAuth) defaultClient.getAuthentication("user"); -user.setUsername("YOUR USERNAME"); -user.setPassword("YOUR PASSWORD"); - -UserApi apiInstance = new UserApi(); -String share = "share_example"; // String | The token of the share. -try { - Privilege result = apiInstance.addCurrentUserPrivilege(share); - System.out.println(result); -} catch (ApiException e) { - System.err.println("Exception when calling UserApi#addCurrentUserPrivilege"); - e.printStackTrace(); -} -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **share** | **String**| The token of the share. | - -### Return type - -[**Privilege**](Privilege.md) - -### Authorization - -[user](../README.md#user) - -### HTTP request headers - - - **Content-Type**: application/json, application/xml - - **Accept**: application/json, application/xml - - -# **addUser** -> User addUser(body) - -Adds a user account with the specified roles and emails. - - - -### Example -```java -// Import classes: -//import io.swagger.client.ApiClient; -//import io.swagger.client.ApiException; -//import io.swagger.client.Configuration; -//import io.swagger.client.auth.*; -//import io.swagger.client.api.UserApi; - -ApiClient defaultClient = Configuration.getDefaultApiClient(); - -// Configure HTTP basic authorization: admin -HttpBasicAuth admin = (HttpBasicAuth) defaultClient.getAuthentication("admin"); -admin.setUsername("YOUR USERNAME"); -admin.setPassword("YOUR PASSWORD"); - -UserApi apiInstance = new UserApi(); -User body = new User(); // User | The data for the new user. -try { - User result = apiInstance.addUser(body); - System.out.println(result); -} catch (ApiException e) { - System.err.println("Exception when calling UserApi#addUser"); - e.printStackTrace(); -} -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **body** | [**User**](User.md)| The data for the new user. | - -### Return type - -[**User**](User.md) - -### Authorization - -[admin](../README.md#admin) - -### HTTP request headers - - - **Content-Type**: application/json, application/xml - - **Accept**: application/json, application/xml - - -# **addUserPrivilege** -> Privilege addUserPrivilege(id, share) - -Returns the privileges for a particular user. - - - -### Example -```java -// Import classes: -//import io.swagger.client.ApiClient; -//import io.swagger.client.ApiException; -//import io.swagger.client.Configuration; -//import io.swagger.client.auth.*; -//import io.swagger.client.api.UserApi; - -ApiClient defaultClient = Configuration.getDefaultApiClient(); - -// Configure HTTP basic authorization: admin -HttpBasicAuth admin = (HttpBasicAuth) defaultClient.getAuthentication("admin"); -admin.setUsername("YOUR USERNAME"); -admin.setPassword("YOUR PASSWORD"); - -UserApi apiInstance = new UserApi(); -Long id = 789L; // Long | The user id. -String share = "share_example"; // String | The token of the share. -try { - Privilege result = apiInstance.addUserPrivilege(id, share); - System.out.println(result); -} catch (ApiException e) { - System.err.println("Exception when calling UserApi#addUserPrivilege"); - e.printStackTrace(); -} -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **id** | **Long**| The user id. | - **share** | **String**| The token of the share. | - -### Return type - -[**Privilege**](Privilege.md) - -### Authorization - -[admin](../README.md#admin) - -### HTTP request headers - - - **Content-Type**: application/json, application/xml - - **Accept**: application/json, application/xml - - -# **getCurrentUser** -> User getCurrentUser() - -Returns the user currently authorized. - - - -### Example -```java -// Import classes: -//import io.swagger.client.ApiClient; -//import io.swagger.client.ApiException; -//import io.swagger.client.Configuration; -//import io.swagger.client.auth.*; -//import io.swagger.client.api.UserApi; - -ApiClient defaultClient = Configuration.getDefaultApiClient(); - -// Configure HTTP basic authorization: user -HttpBasicAuth user = (HttpBasicAuth) defaultClient.getAuthentication("user"); -user.setUsername("YOUR USERNAME"); -user.setPassword("YOUR PASSWORD"); - -UserApi apiInstance = new UserApi(); -try { - User result = apiInstance.getCurrentUser(); - System.out.println(result); -} catch (ApiException e) { - System.err.println("Exception when calling UserApi#getCurrentUser"); - e.printStackTrace(); -} -``` - -### Parameters -This endpoint does not need any parameter. - -### Return type - -[**User**](User.md) - -### Authorization - -[user](../README.md#user) - -### HTTP request headers - - - **Content-Type**: application/json, application/xml - - **Accept**: application/json, application/xml - - -# **getCurrentUserPlaces** -> PlacePage getCurrentUserPlaces(pageOffset, pageSize) - -Returns the places for the current user. - - - -### Example -```java -// Import classes: -//import io.swagger.client.ApiException; -//import io.swagger.client.api.UserApi; - - -UserApi apiInstance = new UserApi(); -Integer pageOffset = 0; // Integer | The offset in terms of elements. -Integer pageSize = 20; // Integer | The maximum number of elements on the page. -try { - PlacePage result = apiInstance.getCurrentUserPlaces(pageOffset, pageSize); - System.out.println(result); -} catch (ApiException e) { - System.err.println("Exception when calling UserApi#getCurrentUserPlaces"); - e.printStackTrace(); -} -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **pageOffset** | **Integer**| The offset in terms of elements. | [optional] [default to 0] - **pageSize** | **Integer**| The maximum number of elements on the page. | [optional] [default to 20] - -### Return type - -[**PlacePage**](PlacePage.md) - -### Authorization - -No authorization required - -### HTTP request headers - - - **Content-Type**: application/json, application/xml - - **Accept**: application/json, application/xml - - -# **getCurrentUserPrivileges** -> PrivilegePage getCurrentUserPrivileges(pageOffset, pageSize) - -Returns the privileges for the current user. - - - -### Example -```java -// Import classes: -//import io.swagger.client.ApiClient; -//import io.swagger.client.ApiException; -//import io.swagger.client.Configuration; -//import io.swagger.client.auth.*; -//import io.swagger.client.api.UserApi; - -ApiClient defaultClient = Configuration.getDefaultApiClient(); - -// Configure HTTP basic authorization: user -HttpBasicAuth user = (HttpBasicAuth) defaultClient.getAuthentication("user"); -user.setUsername("YOUR USERNAME"); -user.setPassword("YOUR PASSWORD"); - -UserApi apiInstance = new UserApi(); -Integer pageOffset = 0; // Integer | The offset in terms of elements. -Integer pageSize = 20; // Integer | The maximum number of elements on the page. -try { - PrivilegePage result = apiInstance.getCurrentUserPrivileges(pageOffset, pageSize); - System.out.println(result); -} catch (ApiException e) { - System.err.println("Exception when calling UserApi#getCurrentUserPrivileges"); - e.printStackTrace(); -} -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **pageOffset** | **Integer**| The offset in terms of elements. | [optional] [default to 0] - **pageSize** | **Integer**| The maximum number of elements on the page. | [optional] [default to 20] - -### Return type - -[**PrivilegePage**](PrivilegePage.md) - -### Authorization - -[user](../README.md#user) - -### HTTP request headers - - - **Content-Type**: application/json, application/xml - - **Accept**: application/json, application/xml - - -# **getUser** -> User getUser(id) - -Returns the user account with the specified id. - - - -### Example -```java -// Import classes: -//import io.swagger.client.ApiClient; -//import io.swagger.client.ApiException; -//import io.swagger.client.Configuration; -//import io.swagger.client.auth.*; -//import io.swagger.client.api.UserApi; - -ApiClient defaultClient = Configuration.getDefaultApiClient(); - -// Configure HTTP basic authorization: admin -HttpBasicAuth admin = (HttpBasicAuth) defaultClient.getAuthentication("admin"); -admin.setUsername("YOUR USERNAME"); -admin.setPassword("YOUR PASSWORD"); - -UserApi apiInstance = new UserApi(); -Long id = 789L; // Long | The id of the user to retrieve. -try { - User result = apiInstance.getUser(id); - System.out.println(result); -} catch (ApiException e) { - System.err.println("Exception when calling UserApi#getUser"); - e.printStackTrace(); -} -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **id** | **Long**| The id of the user to retrieve. | - -### Return type - -[**User**](User.md) - -### Authorization - -[admin](../README.md#admin) - -### HTTP request headers - - - **Content-Type**: application/json, application/xml - - **Accept**: application/json, application/xml - - -# **getUserPlaces** -> PlacePage getUserPlaces(id, pageOffset, pageSize) - -Returns the places for a particular user. - - - -### Example -```java -// Import classes: -//import io.swagger.client.ApiException; -//import io.swagger.client.api.UserApi; - - -UserApi apiInstance = new UserApi(); -Long id = 789L; // Long | The user id. -Integer pageOffset = 0; // Integer | The offset in terms of elements. -Integer pageSize = 20; // Integer | The maximum number of elements on the page. -try { - PlacePage result = apiInstance.getUserPlaces(id, pageOffset, pageSize); - System.out.println(result); -} catch (ApiException e) { - System.err.println("Exception when calling UserApi#getUserPlaces"); - e.printStackTrace(); -} -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **id** | **Long**| The user id. | - **pageOffset** | **Integer**| The offset in terms of elements. | [optional] [default to 0] - **pageSize** | **Integer**| The maximum number of elements on the page. | [optional] [default to 20] - -### Return type - -[**PlacePage**](PlacePage.md) - -### Authorization - -No authorization required - -### HTTP request headers - - - **Content-Type**: application/json, application/xml - - **Accept**: application/json, application/xml - - -# **getUserPrivileges** -> PrivilegePage getUserPrivileges(id, pageOffset, pageSize) - -Returns the privileges for a particular user. - - - -### Example -```java -// Import classes: -//import io.swagger.client.ApiClient; -//import io.swagger.client.ApiException; -//import io.swagger.client.Configuration; -//import io.swagger.client.auth.*; -//import io.swagger.client.api.UserApi; - -ApiClient defaultClient = Configuration.getDefaultApiClient(); - -// Configure HTTP basic authorization: admin -HttpBasicAuth admin = (HttpBasicAuth) defaultClient.getAuthentication("admin"); -admin.setUsername("YOUR USERNAME"); -admin.setPassword("YOUR PASSWORD"); - -UserApi apiInstance = new UserApi(); -Long id = 789L; // Long | The user id. -Integer pageOffset = 0; // Integer | The offset in terms of elements. -Integer pageSize = 20; // Integer | The maximum number of elements on the page. -try { - PrivilegePage result = apiInstance.getUserPrivileges(id, pageOffset, pageSize); - System.out.println(result); -} catch (ApiException e) { - System.err.println("Exception when calling UserApi#getUserPrivileges"); - e.printStackTrace(); -} -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **id** | **Long**| The user id. | - **pageOffset** | **Integer**| The offset in terms of elements. | [optional] [default to 0] - **pageSize** | **Integer**| The maximum number of elements on the page. | [optional] [default to 20] - -### Return type - -[**PrivilegePage**](PrivilegePage.md) - -### Authorization - -[admin](../README.md#admin) - -### HTTP request headers - - - **Content-Type**: application/json, application/xml - - **Accept**: application/json, application/xml - - -# **getUsers** -> UserPage getUsers(pageOffset, pageSize) - -Returns a list of users. - - - -### Example -```java -// Import classes: -//import io.swagger.client.ApiClient; -//import io.swagger.client.ApiException; -//import io.swagger.client.Configuration; -//import io.swagger.client.auth.*; -//import io.swagger.client.api.UserApi; - -ApiClient defaultClient = Configuration.getDefaultApiClient(); - -// Configure HTTP basic authorization: admin -HttpBasicAuth admin = (HttpBasicAuth) defaultClient.getAuthentication("admin"); -admin.setUsername("YOUR USERNAME"); -admin.setPassword("YOUR PASSWORD"); - -UserApi apiInstance = new UserApi(); -Integer pageOffset = 0; // Integer | The offset in terms of elements. -Integer pageSize = 20; // Integer | The maximum number of elements on the page. -try { - UserPage result = apiInstance.getUsers(pageOffset, pageSize); - System.out.println(result); -} catch (ApiException e) { - System.err.println("Exception when calling UserApi#getUsers"); - e.printStackTrace(); -} -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **pageOffset** | **Integer**| The offset in terms of elements. | [optional] [default to 0] - **pageSize** | **Integer**| The maximum number of elements on the page. | [optional] [default to 20] - -### Return type - -[**UserPage**](UserPage.md) - -### Authorization - -[admin](../README.md#admin) - -### HTTP request headers - - - **Content-Type**: application/json, application/xml - - **Accept**: application/json, application/xml - - -# **registerUser** -> User registerUser(body) - -Registers a new user and sends an email account verification. - - - -### Example -```java -// Import classes: -//import io.swagger.client.ApiException; -//import io.swagger.client.api.UserApi; - - -UserApi apiInstance = new UserApi(); -UserRegistration body = new UserRegistration(); // UserRegistration | The data of the new user. -try { - User result = apiInstance.registerUser(body); - System.out.println(result); -} catch (ApiException e) { - System.err.println("Exception when calling UserApi#registerUser"); - e.printStackTrace(); -} -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **body** | [**UserRegistration**](UserRegistration.md)| The data of the new user. | - -### Return type - -[**User**](User.md) - -### Authorization - -No authorization required - -### HTTP request headers - - - **Content-Type**: application/json, application/xml - - **Accept**: application/json, application/xml - - -# **resetUser** -> resetUser(login) - -Sends a password reset email to the correspondence email account of a user. - - - -### Example -```java -// Import classes: -//import io.swagger.client.ApiException; -//import io.swagger.client.api.UserApi; - - -UserApi apiInstance = new UserApi(); -String login = "login_example"; // String | The login of the user to reset. -try { - apiInstance.resetUser(login); -} catch (ApiException e) { - System.err.println("Exception when calling UserApi#resetUser"); - e.printStackTrace(); -} -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **login** | **String**| The login of the user to reset. | - -### Return type - -null (empty response body) - -### Authorization - -No authorization required - -### HTTP request headers - - - **Content-Type**: application/json, application/xml - - **Accept**: application/json, application/xml - - -# **resetUserPassword** -> User resetUserPassword(token, body) - -Sets the password of a user account using a token received via email. - - - -### Example -```java -// Import classes: -//import io.swagger.client.ApiException; -//import io.swagger.client.api.UserApi; - - -UserApi apiInstance = new UserApi(); -String token = "token_example"; // String | The secret token received via email. -UserPassword body = new UserPassword(); // UserPassword | The new user password. -try { - User result = apiInstance.resetUserPassword(token, body); - System.out.println(result); -} catch (ApiException e) { - System.err.println("Exception when calling UserApi#resetUserPassword"); - e.printStackTrace(); -} -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **token** | **String**| The secret token received via email. | - **body** | [**UserPassword**](UserPassword.md)| The new user password. | - -### Return type - -[**User**](User.md) - -### Authorization - -No authorization required - -### HTTP request headers - - - **Content-Type**: application/json, application/xml - - **Accept**: application/json, application/xml - - -# **searchUsers** -> UserPage searchUsers(term, pageOffset, pageSize) - -Returns a list of users whose login name or name contains the term. - - - -### Example -```java -// Import classes: -//import io.swagger.client.ApiClient; -//import io.swagger.client.ApiException; -//import io.swagger.client.Configuration; -//import io.swagger.client.auth.*; -//import io.swagger.client.api.UserApi; - -ApiClient defaultClient = Configuration.getDefaultApiClient(); - -// Configure HTTP basic authorization: admin -HttpBasicAuth admin = (HttpBasicAuth) defaultClient.getAuthentication("admin"); -admin.setUsername("YOUR USERNAME"); -admin.setPassword("YOUR PASSWORD"); - -UserApi apiInstance = new UserApi(); -String term = "term_example"; // String | The search term. -Integer pageOffset = 0; // Integer | The offset in terms of elements. -Integer pageSize = 20; // Integer | The maximum number of elements on the page. -try { - UserPage result = apiInstance.searchUsers(term, pageOffset, pageSize); - System.out.println(result); -} catch (ApiException e) { - System.err.println("Exception when calling UserApi#searchUsers"); - e.printStackTrace(); -} -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **term** | **String**| The search term. | - **pageOffset** | **Integer**| The offset in terms of elements. | [optional] [default to 0] - **pageSize** | **Integer**| The maximum number of elements on the page. | [optional] [default to 20] - -### Return type - -[**UserPage**](UserPage.md) - -### Authorization - -[admin](../README.md#admin) - -### HTTP request headers - - - **Content-Type**: application/json, application/xml - - **Accept**: application/json, application/xml - - -# **setCurrentPassword** -> User setCurrentPassword(body) - -Sets the password of the currently authorized user. - - - -### Example -```java -// Import classes: -//import io.swagger.client.ApiClient; -//import io.swagger.client.ApiException; -//import io.swagger.client.Configuration; -//import io.swagger.client.auth.*; -//import io.swagger.client.api.UserApi; - -ApiClient defaultClient = Configuration.getDefaultApiClient(); - -// Configure HTTP basic authorization: user -HttpBasicAuth user = (HttpBasicAuth) defaultClient.getAuthentication("user"); -user.setUsername("YOUR USERNAME"); -user.setPassword("YOUR PASSWORD"); - -UserApi apiInstance = new UserApi(); -UserPassword body = new UserPassword(); // UserPassword | The new password to set. -try { - User result = apiInstance.setCurrentPassword(body); - System.out.println(result); -} catch (ApiException e) { - System.err.println("Exception when calling UserApi#setCurrentPassword"); - e.printStackTrace(); -} -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **body** | [**UserPassword**](UserPassword.md)| The new password to set. | - -### Return type - -[**User**](User.md) - -### Authorization - -[user](../README.md#user) - -### HTTP request headers - - - **Content-Type**: application/json, application/xml - - **Accept**: application/json, application/xml - - -# **setCurrentUser** -> User setCurrentUser(body) - -Updates the currently authorized user. - - - -### Example -```java -// Import classes: -//import io.swagger.client.ApiClient; -//import io.swagger.client.ApiException; -//import io.swagger.client.Configuration; -//import io.swagger.client.auth.*; -//import io.swagger.client.api.UserApi; - -ApiClient defaultClient = Configuration.getDefaultApiClient(); - -// Configure HTTP basic authorization: user -HttpBasicAuth user = (HttpBasicAuth) defaultClient.getAuthentication("user"); -user.setUsername("YOUR USERNAME"); -user.setPassword("YOUR PASSWORD"); - -UserApi apiInstance = new UserApi(); -User body = new User(); // User | The new user values to set. -try { - User result = apiInstance.setCurrentUser(body); - System.out.println(result); -} catch (ApiException e) { - System.err.println("Exception when calling UserApi#setCurrentUser"); - e.printStackTrace(); -} -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **body** | [**User**](User.md)| The new user values to set. | - -### Return type - -[**User**](User.md) - -### Authorization - -[user](../README.md#user) - -### HTTP request headers - - - **Content-Type**: application/json, application/xml - - **Accept**: application/json, application/xml - - -# **setUser** -> User setUser(id, body) - -Updates the values of a particular user account. - - - -### Example -```java -// Import classes: -//import io.swagger.client.ApiClient; -//import io.swagger.client.ApiException; -//import io.swagger.client.Configuration; -//import io.swagger.client.auth.*; -//import io.swagger.client.api.UserApi; - -ApiClient defaultClient = Configuration.getDefaultApiClient(); - -// Configure HTTP basic authorization: admin -HttpBasicAuth admin = (HttpBasicAuth) defaultClient.getAuthentication("admin"); -admin.setUsername("YOUR USERNAME"); -admin.setPassword("YOUR PASSWORD"); - -UserApi apiInstance = new UserApi(); -Long id = 789L; // Long | The id of the user to set. -User body = new User(); // User | The new user data to set. -try { - User result = apiInstance.setUser(id, body); - System.out.println(result); -} catch (ApiException e) { - System.err.println("Exception when calling UserApi#setUser"); - e.printStackTrace(); -} -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **id** | **Long**| The id of the user to set. | - **body** | [**User**](User.md)| The new user data to set. | - -### Return type - -[**User**](User.md) - -### Authorization - -[admin](../README.md#admin) - -### HTTP request headers - - - **Content-Type**: application/json, application/xml - - **Accept**: application/json, application/xml - - -# **setUserPassword** -> User setUserPassword(id, body) - -Sets the password of a user. - - - -### Example -```java -// Import classes: -//import io.swagger.client.ApiClient; -//import io.swagger.client.ApiException; -//import io.swagger.client.Configuration; -//import io.swagger.client.auth.*; -//import io.swagger.client.api.UserApi; - -ApiClient defaultClient = Configuration.getDefaultApiClient(); - -// Configure HTTP basic authorization: admin -HttpBasicAuth admin = (HttpBasicAuth) defaultClient.getAuthentication("admin"); -admin.setUsername("YOUR USERNAME"); -admin.setPassword("YOUR PASSWORD"); - -UserApi apiInstance = new UserApi(); -Long id = 789L; // Long | The id of the user to change. -UserPassword body = new UserPassword(); // UserPassword | The new password. -try { - User result = apiInstance.setUserPassword(id, body); - System.out.println(result); -} catch (ApiException e) { - System.err.println("Exception when calling UserApi#setUserPassword"); - e.printStackTrace(); -} -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **id** | **Long**| The id of the user to change. | - **body** | [**UserPassword**](UserPassword.md)| The new password. | - -### Return type - -[**User**](User.md) - -### Authorization - -[admin](../README.md#admin) - -### HTTP request headers - - - **Content-Type**: application/json, application/xml - - **Accept**: application/json, application/xml - - -# **verifyUserEmail** -> verifyUserEmail(token) - -Verifies an email address using a token received via email. - - - -### Example -```java -// Import classes: -//import io.swagger.client.ApiException; -//import io.swagger.client.api.UserApi; - - -UserApi apiInstance = new UserApi(); -String token = "token_example"; // String | The secret token received via email. -try { - apiInstance.verifyUserEmail(token); -} catch (ApiException e) { - System.err.println("Exception when calling UserApi#verifyUserEmail"); - e.printStackTrace(); -} -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **token** | **String**| The secret token received via email. | - -### Return type - -null (empty response body) - -### Authorization - -No authorization required - -### HTTP request headers - - - **Content-Type**: application/json, application/xml - - **Accept**: application/json, application/xml - diff --git a/testing/api-client/docs/UserPage.md b/testing/api-client/docs/UserPage.md deleted file mode 100644 index f29caed..0000000 --- a/testing/api-client/docs/UserPage.md +++ /dev/null @@ -1,13 +0,0 @@ - -# UserPage - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**size** | **Integer** | The maximum number of elements on the page. | -**offset** | **Integer** | The page offset (0-based) in number of elements. | -**total** | **Integer** | The total number of elements available. | -**elements** | [**List<User>**](User.md) | The elements of the page. | - - - diff --git a/testing/api-client/docs/UserPassword.md b/testing/api-client/docs/UserPassword.md deleted file mode 100644 index 5198e2f..0000000 --- a/testing/api-client/docs/UserPassword.md +++ /dev/null @@ -1,10 +0,0 @@ - -# UserPassword - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**password** | **String** | The new password. | - - - diff --git a/testing/api-client/docs/UserRegistration.md b/testing/api-client/docs/UserRegistration.md deleted file mode 100644 index c56803d..0000000 --- a/testing/api-client/docs/UserRegistration.md +++ /dev/null @@ -1,13 +0,0 @@ - -# UserRegistration - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**password** | **String** | The new password. | -**login** | **String** | The requested login name. | -**name** | **String** | The human name. | -**email** | **String** | The email address. | - - - diff --git a/testing/api-client/docs/Visit.md b/testing/api-client/docs/Visit.md deleted file mode 100644 index ef15bb1..0000000 --- a/testing/api-client/docs/Visit.md +++ /dev/null @@ -1,17 +0,0 @@ - -# Visit - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**id** | **Long** | The unique identifier of the data. | [optional] -**creationTime** | **Long** | The time stamp when the data was created. | [optional] -**modificationTime** | **Long** | The time stamp when the data was created. | [optional] -**deleted** | **Boolean** | A flag to indicate whether the data was deleted. | [optional] -**place** | **Long** | The id of the place. | [optional] -**device** | **Long** | The id of the device. | [optional] -**beginTime** | **Long** | The beginning of the visit in Epoch milliseconds. | [optional] -**endTime** | **Long** | The end of the visit in Epoch milliseconds. | [optional] - - - diff --git a/testing/api-client/docs/VisitPage.md b/testing/api-client/docs/VisitPage.md deleted file mode 100644 index ecec44a..0000000 --- a/testing/api-client/docs/VisitPage.md +++ /dev/null @@ -1,13 +0,0 @@ - -# VisitPage - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**size** | **Integer** | The maximum number of elements on the page. | -**offset** | **Integer** | The page offset (0-based) in number of elements. | -**total** | **Integer** | The total number of elements available. | -**elements** | [**List<Visit>**](Visit.md) | The elements of the page. | - - - diff --git a/testing/api-client/git_push.sh b/testing/api-client/git_push.sh deleted file mode 100644 index ed37461..0000000 --- a/testing/api-client/git_push.sh +++ /dev/null @@ -1,52 +0,0 @@ -#!/bin/sh -# ref: https://help.github.com/articles/adding-an-existing-project-to-github-using-the-command-line/ -# -# Usage example: /bin/sh ./git_push.sh wing328 swagger-petstore-perl "minor update" - -git_user_id=$1 -git_repo_id=$2 -release_note=$3 - -if [ "$git_user_id" = "" ]; then - git_user_id="GIT_USER_ID" - echo "[INFO] No command line input provided. Set \$git_user_id to $git_user_id" -fi - -if [ "$git_repo_id" = "" ]; then - git_repo_id="GIT_REPO_ID" - echo "[INFO] No command line input provided. Set \$git_repo_id to $git_repo_id" -fi - -if [ "$release_note" = "" ]; then - release_note="Minor update" - echo "[INFO] No command line input provided. Set \$release_note to $release_note" -fi - -# Initialize the local directory as a Git repository -git init - -# Adds the files in the local repository and stages them for commit. -git add . - -# Commits the tracked changes and prepares them to be pushed to a remote repository. -git commit -m "$release_note" - -# Sets the new remote -git_remote=`git remote` -if [ "$git_remote" = "" ]; then # git remote not defined - - if [ "$GIT_TOKEN" = "" ]; then - echo "[INFO] \$GIT_TOKEN (environment variable) is not set. Using the git crediential in your environment." - git remote add origin https://github.com/${git_user_id}/${git_repo_id}.git - else - git remote add origin https://${git_user_id}:${GIT_TOKEN}@github.com/${git_user_id}/${git_repo_id}.git - fi - -fi - -git pull origin master - -# Pushes (Forces) the changes in the local repository up to the remote repository -echo "Git pushing to https://github.com/${git_user_id}/${git_repo_id}.git" -git push origin master 2>&1 | grep -v 'To https' - diff --git a/testing/api-client/gradle.properties b/testing/api-client/gradle.properties deleted file mode 100644 index 05644f0..0000000 --- a/testing/api-client/gradle.properties +++ /dev/null @@ -1,2 +0,0 @@ -# Uncomment to build for Android -#target = android \ No newline at end of file diff --git a/testing/api-client/gradle/wrapper/gradle-wrapper.jar b/testing/api-client/gradle/wrapper/gradle-wrapper.jar deleted file mode 100644 index 2c6137b87896c8f70315ae454e00a969ef5f6019..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 53639 zcmafaW0a=B^559DjdyI@wr$%scWm3Xy<^+Pj_sKpY&N+!|K#4>Bz;ajPk*RBjZ;RV75EK*;qpZCo(BB5~-#>pF^k0$_Qx&3rs}{XFZ)$uJU-ZpbB>L3?|knJ{J+ge{%=bI`#Yn9v&Fxx>fd=_|H)(FY-DO{ z_Wxu>{a02GXCp^PGw1(fh-I*;dGTM?mA^##pNEJ#c-Y%I7@3kW(VN&Bxw!bn$iWOU zB8BZ)vT4(}GX%q~h3EYwbR?$d6|xnvg_e@4>dl5l+%FtPbGqa`;Uk##t$#g&CK4GO zz%my0ZR1Fv@~b2_>T0cBP)ECz-Uc^nW9e+`W4!=mSJPopgoe3A(NMzBd0mR?$&3XA zRL1}bJ2Q%R#bWHrC`j_)tPKMEyHuGSpdJMhT(Ob(e9H+#=Skp%#jzj=BVvc(-RSWB z{_T`UcEeWD{z`!3-y;_N|Ljr4%f;2qPSM%n?_s%GnYsM!d3p)CxmudpyIPqTxjH!i z;}A+!>>N;pko++K5n~I7m4>yco2%Zc$59RohB(l%KcJc9s^nw^?2JGy>O4#x5+CZH zqU~7kA>WE)ngvsdfKhLUX0Lc3r+In0Uyn}LZhm?n){&LHNJws546du%pia=j zyH8CD{^Qx%kFe@kX*$B!DxLa(Y?BO32sm8%#_ynjU-m>PJbabL`~0Ai zeJm<6okftSJUd2!X(>}i#KAh-NR2!Kg%c2JD=G|T%@Q0JQzqKB)Qc4E-{ZF=#PGZg zior4-caRB-Jj;l}Xb_!)TjB`jC}})6z~3AsRE&t~CO&)g{dqM0iK;lvav8?kE1< zmCrHxDZe?&rEK7M4tG-i!`Zk-*IzSk0M0&Ul8+J>*UD(A^;bAFDcz>d&lzAlw}b## zjfu@)rAou-86EN%8_Nv;%bNUmy*<6sbgB9)ZCihdSh_VT2iGFv+T8p&Z&wO02nKtdx?eZh^=*<>SZHSn(Pv)bgn{ zb15>YnVnJ^PO025c~^uK&W1C1XTs1az44L~-9Z-fU3{VvA?T& zdpi&S`mZ|$tMuN{{i|O}fAx#*KkroHe;6z^7c*x`2Rk!a2L~HB$A4@(Rz*hvM+og( zJW+4;S-A$#+Gec-rn8}at+q5gRrNy^iU?Z4Gz_|qzS~sG_EV#m%-VW!jQ>f3jc-Vq zW;~>OqI1Th&*fx#`c^=|A4GGoDp+ZH!n0_fDo-ks3d&GlT=(qzr(?Qw`PHvo3PoU6YJE zu{35)=P`LRm@+=ziAI)7jktM6KHx*v&WHVBYp<~UtR3c?Wv_{a0(k&NF!o#+@|Y6Y z>{||-i0v8N2ntXRrVx~#Z1JMA3C2ki}OkJ4W`WjZIuLByNUEL2HqqKrbi{9a8` zk-w0I$a<6;W6&X<&EbIqul`;nvc+D~{g5al{0oOSp~ zhg;6nG1Bh-XyOBM63jb_z`7apSsta``K{!Q{}mZ!m4rTmWi^<*BN2dh#PLZ)oXIJY zl#I3@$+8Fvi)m<}lK_}7q~VN%BvT^{q~ayRA7mwHO;*r0ePSK*OFv_{`3m+96HKgt z=nD-=Pv90Ae1p)+SPLT&g(Fdqbcc(Vnk5SFyc|Tq08qS;FJ1K4rBmtns%Su=GZchE zR(^9W-y!{QfeVPBeHpaBA{TZpQ*(d$H-*GI)Y}>X2Lk&27aFkqXE7D?G_iGav2r&P zx3V=8GBGi8agj5!H?lDMr`1nYmvKZj!~0{GMPb!tM=VIJXbTk9q8JRoSPD*CH@4I+ zfG-6{Z=Yb->)MIUmXq-#;=lNCyF1G*W+tW6gdD||kQfW$J_@=Y9KmMD!(t#9-fPcJ z>%&KQC-`%E`{y^i!1u=rJP_hhGErM$GYE3Y@ZzzA2a-PC>yaoDziZT#l+y)tfyR}U z5Epq`ACY|VUVISHESM5$BpWC0FpDRK&qi?G-q%Rd8UwIq&`d(Mqa<@(fH!OfNIgFICEG?j_Gj7FS()kY^P(I!zbl`%HB z7Rx=q2vZFjy^XypORT$^NJv_`Vm7-gkJWYsN5xg>snt5%oG?w1K#l_UH<>4@d0G@3 z)r?|yba6;ksyc+5+8YZ?)NZ+ER!4fIzK>>cs^(;ib7M}asT&)+J=J@U^~ffJ>65V# zt_lyUp52t`vT&gcQ%a6Ca)p8u6v}3iJzf?zsx#e9t)-1OtqD$Mky&Lpz6_v?p0|y4 zI{Nq9z89OxQbsqX)UYj z(BGu`28f8C^e9R2jf0Turq;v+fPCWD*z8!8-Q-_s`ILgwo@mtnjpC_D$J zCz7-()9@8rQ{4qy<5;*%bvX3k$grUQ{Bt;B#w))A+7ih631uN?!_~?i^g+zO^lGK$>O1T1$6VdF~%FKR6~Px%M`ibJG*~uQ>o^r9qLo*`@^ry@KX^$LH0>NGPL%MG8|;8 z@_)h2uvB1M!qjGtZgy~7-O=GUa`&;xEFvC zwIt?+O;Fjwgn3aE%`_XfZEw5ayP+JS8x?I|V3ARbQ5@{JAl1E*5a{Ytc(UkoDKtD# zu)K4XIYno7h3)0~5&93}pMJMDr*mcYM|#(FXS@Pj)(2!cl$)R-GwwrpOW!zZ2|wN) zE|B38xr4_NBv|%_Lpnm$We<_~S{F1x42tph3PAS`0saF^PisF6EDtce+9y6jdITmu zqI-CLeTn2%I3t3z_=e=YGzUX6i5SEujY`j|=aqv#(Q=iWPkKhau@g|%#xVC2$6<{2 zAoimy5vLq6rvBo3rv&^VqtaKt_@Vx^gWN{f4^@i6H??!ra^_KC-ShWC(GBNt3o~T^ zudX<0v!;s$rIflR?~Tu4-D=%~E=glv+1|pg*ea30re-2K@8EqQ{8#WY4X-br_!qpq zL;PRCi^e~EClLpGb1MrsXCqfD2m615mt;EyR3W6XKU=4(A^gFCMMWgn#5o1~EYOH* zOlolGlD;B!j%lRFaoc)q_bOH-O!r}g1Bhlhy*dRoTf-bI%`A`kU)Q=HA9HgCKqq&A z2$_rtL-uIA7`PiJfw380j@M4Fff-?(Xe(aR`4>BZyDN2$2E7QQ1}95@X819fnA(}= za=5VF-%;l}aHSRHCfs(#Qf%dPue~fGpy7qPs*eLX2Aa0+@mPxnS4Wm8@kP7KEL)8s z@tNmawLHST-FS4h%20%lVvd zkXpxWa43E`zX{6-{2c+L9C`l(ZRG8`kO9g7t&hx?>j~5_C;y5u*Bvl79)Bq?@T7bN z=G2?QDa0J3VwCfZG0BjOFP>xz4jtv3LS>jz#1x~b9u1*n9>Y6?u8W?I^~;N{GC<1y} zc&Wz{L`kJUSt=oA=5ZHtNj3PSB%w5^=0(U7GC^zUgcdkujo>ruzyBurtTjKuNf1-+ zzn~oZFXCbR&xq&W{ar~T`@fNef5M$u^-C92HMBo=*``D8Q^ktX z(qT{_R=*EI?-R9nNUFNR#{(Qb;27bM14bjI`c#4RiinHbnS445Jy^%krK%kpE zFw%RVQd6kqsNbiBtH*#jiPu3(%}P7Vhs0G9&Dwb4E-hXO!|whZ!O$J-PU@j#;GrzN zwP9o=l~Nv}4OPvv5rVNoFN>Oj0TC%P>ykicmFOx*dyCs@7XBH|w1k2hb`|3|i^GEL zyg7PRl9eV ztQ1z)v~NwH$ebcMSKc-4D=?G^3sKVG47ZWldhR@SHCr}SwWuj5t!W$&HAA*Wo_9tM zw5vs`2clw`z@~R-#W8d4B8!rFtO}+-$-{6f_`O-^-EhGraqg%$D618&<9KG``D|Rb zQJ&TSE3cfgf8i}I^DLu+-z{{;QM>K3I9~3R9!0~=Y`A1=6`CF#XVH@MWO?3@xa6ev zdw08_9L=>3%)iXA(_CE@ipRQ{Tb+@mxoN^3ktgmt^mJ(u#=_Plt?5qMZOA3&I1&NU zOG+0XTsIkbhGsp(ApF2MphRG^)>vqagn!-%pRnppa%`-l@DLS0KUm8*e9jGT0F%0J z*-6E@Z*YyeZ{eP7DGmxQedo}^+w zM~>&E$5&SW6MxP##J56Eo@0P34XG})MLCuhMyDFf**?tziO?_Ad&Jhd z`jok^B{3ff*7cydrxYjdxX`14`S+34kW^$fxDmNn2%fsQ6+Zou0%U{3Y>L}UIbQbw z*E#{Von}~UEAL?vvihW)4?Kr-R?_?JSN?B?QzhUWj==1VNEieTMuTJ#-nl*c@qP+` zGk@aE0oAD5!9_fO=tDQAt9g0rKTr{Z0t~S#oy5?F3&aWm+igqKi| zK9W3KRS|1so|~dx%90o9+FVuN7)O@by^mL=IX_m^M87i&kT1^#9TCpI@diZ_p$uW3 zbA+-ER9vJ{ii?QIZF=cfZT3#vJEKC|BQhNd zGmxBDLEMnuc*AET~k8g-P-K+S~_(+GE9q6jyIMka(dr}(H% z$*z;JDnyI@6BQ7KGcrv03Hn(abJ_-vqS>5~m*;ZJmH$W`@csQ8ejiC8S#sYTB;AoF zXsd!kDTG#3FOo-iJJpd$C~@8}GQJ$b1A85MXp?1#dHWQu@j~i4L*LG40J}+V=&-(g zh~Hzk(l1$_y}PX}Ypluyiib0%vwSqPaJdy9EZ;?+;lFF8%Kb7cwPD17C}@N z2OF;}QCM4;CDx~d;XnunQAx5mQbL#);}H57I+uB9^v|cmZwuXGkoH-cAJ%nIjSO$E z{BpYdC9poyO5pvdL+ZPWFuK}c8WGEq-#I3myONq^BL%uG`RIoSBTEK9sAeU4UBh7f zzM$s|&NtAGN&>`lp5Ruc%qO^oL;VGnzo9A8{fQn@YoORA>qw;^n2pydq>;Ji9(sPH zLGsEeTIH?_6C3uyWoW(gkmM(RhFkiDuQPXmL7Oes(+4)YIHt+B@i`*%0KcgL&A#ua zAjb8l_tO^Ag!ai3f54t?@{aoW%&Hdst}dglRzQlS=M{O!=?l z*xY2vJ?+#!70RO8<&N^R4p+f=z z*&_e}QT%6-R5Wt66moGfvorp$yE|3=-2_(y`FnL0-7A?h%4NMZ#F#Rcb^}971t5ib zw<20w|C?HVv%|)Q)Pef8tGjwQ+!+<{>IVjr@&SRVO*PyC?Efnsq;Eq{r;U2)1+tgp z)@pZ}gJmzf{m=K@7YA_8X#XK+)F465h%z38{V-K8k%&_GF+g^s&9o6^B-&|MDFI)H zj1ofQL>W(MJLOu3xkkJZV@$}GEG~XBz~WvRjxhT0$jKKZKjuKi$rmR-al}Hb3xDL) z^xGG2?5+vUAo4I;$(JgeVQe9+e)vvJ={pO~05f|J={%dsSLVcF>@F9p4|nYK&hMua zWjNvRod}l~WmGo|LX2j#w$r$y?v^H?Gu(_?(WR_%D@1I@$yMTKqD=Ca2) zWBQmx#A$gMrHe^A8kxAgB}c2R5)14G6%HfpDf$(Di|p8ntcN;Hnk)DR1;toC9zo77 zcWb?&&3h65(bLAte%hstI9o%hZ*{y=8t$^!y2E~tz^XUY2N2NChy;EIBmf(Kl zfU~&jf*}p(r;#MP4x5dI>i`vjo`w?`9^5(vfFjmWp`Ch!2Ig}rkpS|T%g@2h-%V~R zg!*o7OZSU-%)M8D>F^|z+2F|!u1mOt?5^zG%;{^CrV^J?diz9AmF!UsO?Pl79DKvD zo-2==yjbcF5oJY!oF?g)BKmC8-v|iL6VT|Gj!Gk5yaXfhs&GeR)OkZ}=q{exBPv)& zV!QTQBMNs>QQ))>(rZOn0PK+-`|7vKvrjky3-Kmuf8uJ`x6&wsA5S(tMf=m;79Hzv za%lZ(OhM&ZUCHtM~FRd#Uk3Iy%oXe^)!Jci39D(a$51WER+%gIZYP)!}nDtDw_FgPL3e>1ilFN=M(j~V` zjOtRhOB8bX8}*FD0oy}+s@r4XQT;OFH__cEn-G#aYHpJDI4&Zo4y2>uJdbPYe zOMGMvbA6#(p00i1{t~^;RaHmgZtE@we39mFaO0r|CJ0zUk$|1Pp60Q&$A;dm>MfP# zkfdw?=^9;jsLEXsccMOi<+0-z|NZb(#wwkcO)nVxJxkF3g(OvW4`m36ytfPx5e-ujFXf($)cVOn|qt9LL zNr!InmcuVkxEg8=_;E)+`>n2Y0eAIDrklnE=T9Pyct>^4h$VDDy>}JiA=W9JE79<6 zv%hpzeJC)TGX|(gP!MGWRhJV}!fa1mcvY%jC^(tbG3QIcQnTy&8UpPPvIekWM!R?R zKQanRv+YZn%s4bqv1LBgQ1PWcEa;-MVeCk`$^FLYR~v%9b-@&M%giqnFHV;5P5_et z@R`%W>@G<6GYa=JZ)JsNMN?47)5Y3@RY`EVOPzxj;z6bn#jZv|D?Fn#$b}F!a}D9{ ztB_roYj%34c-@~ehWM_z;B{G5;udhY`rBH0|+u#!&KLdnw z;!A%tG{%Ua;}OW$BG`B#^8#K$1wX2K$m`OwL-6;hmh{aiuyTz;U|EKES= z9UsxUpT^ZZyWk0;GO;Fe=hC`kPSL&1GWS7kGX0>+votm@V-lg&OR>0*!Iay>_|5OT zF0w~t01mupvy4&HYKnrG?sOsip%=<>nK}Bxth~}g)?=Ax94l_=mC{M@`bqiKtV5vf zIP!>8I;zHdxsaVt9K?{lXCc$%kKfIwh&WM__JhsA?o$!dzxP znoRU4ZdzeN3-W{6h~QQSos{-!W@sIMaM z4o?97?W5*cL~5%q+T@>q%L{Yvw(a2l&68hI0Ra*H=ZjU!-o@3(*7hIKo?I7$gfB(Vlr!62-_R-+T;I0eiE^><*1_t|scfB{r9+a%UxP~CBr zl1!X^l01w8o(|2da~Mca)>Mn}&rF!PhsP_RIU~7)B~VwKIruwlUIlOI5-yd4ci^m{ zBT(H*GvKNt=l7a~GUco)C*2t~7>2t?;V{gJm=WNtIhm4x%KY>Rm(EC^w3uA{0^_>p zM;Na<+I<&KwZOUKM-b0y6;HRov=GeEi&CqEG9^F_GR*0RSM3ukm2c2s{)0<%{+g78 zOyKO%^P(-(U09FO!75Pg@xA{p+1$*cD!3=CgW4NO*p}&H8&K`(HL&$TH2N-bf%?JL zVEWs;@_UDD7IoM&P^(k-U?Gs*sk=bLm+f1p$ggYKeR_7W>Zz|Dl{{o*iYiB1LHq`? ztT)b^6Pgk!Kn~ozynV`O(hsUI52|g{0{cwdQ+=&@$|!y8{pvUC_a5zCemee6?E{;P zVE9;@3w92Nu9m_|x24gtm23{ST8Bp;;iJlhaiH2DVcnYqot`tv>!xiUJXFEIMMP(ZV!_onqyQtB_&x}j9 z?LXw;&z%kyYjyP8CQ6X);-QW^?P1w}&HgM}irG~pOJ()IwwaDp!i2$|_{Ggvw$-%K zp=8N>0Fv-n%W6{A8g-tu7{73N#KzURZl;sb^L*d%leKXp2Ai(ZvO96T#6*!73GqCU z&U-NB*0p@?f;m~1MUN}mfdpBS5Q-dbhZ$$OWW=?t8bT+R5^vMUy$q$xY}ABi60bb_ z9;fj~2T2Ogtg8EDNr4j96{@+9bRP#Li7YDK1Jh8|Mo%NON|bYXi~D(W8oiC2SSE#p z=yQ0EP*}Z)$K$v?MJp8s=xroI@gSp&y!De;aik!U7?>3!sup&HY{6!eElc+?ZW*|3 zjJ;Nx>Kn@)3WP`{R821FpY6p1)yeJPi6yfq=EffesCZjO$#c;p!sc8{$>M-i#@fCt zw?GQV4MTSvDH(NlD2S*g-YnxCDp*%|z9^+|HQ(#XI0Pa8-Io=pz8C&Lp?23Y5JopL z!z_O3s+AY&`HT%KO}EB73{oTar{hg)6J7*KI;_Gy%V%-oO3t+vcyZ?;&%L z3t4A%Ltf=2+f8qITmoRfolL;I__Q8Z&K9*+_f#Sue$2C;xTS@%Z*z-lOAF-+gj1C$ zKEpt`_qg;q^41dggeNsJv#n=5i+6Wyf?4P_a=>s9n(ET_K|*zvh633Mv3Xm3OE!n` zFk^y65tStyk4aamG*+=5V^UePR2e0Fbt7g$({L1SjOel~1^9SmP2zGJ)RZX(>6u4^ zQ78wF_qtS~6b+t&mKM=w&Dt=k(oWMA^e&V#&Y5dFDc>oUn+OU0guB~h3};G1;X=v+ zs_8IR_~Y}&zD^=|P;U_xMA{Ekj+lHN@_n-4)_cHNj0gY4(Lx1*NJ^z9vO>+2_lm4N zo5^}vL2G%7EiPINrH-qX77{y2c*#;|bSa~fRN2)v=)>U@;YF}9H0XR@(+=C+kT5_1 zy?ZhA&_&mTY7O~ad|LX+%+F{GTgE0K8OKaC2@NlC1{j4Co8;2vcUbGpA}+hBiDGCS zl~yxngtG}PI$M*JZYOi{Ta<*0f{3dzV0R}yIV7V>M$aX=TNPo|kS;!!LP3-kbKWj` zR;R%bSf%+AA#LMkG$-o88&k4bF-uIO1_OrXb%uFp((Pkvl@nVyI&^-r5p}XQh`9wL zKWA0SMJ9X|rBICxLwhS6gCTVUGjH&)@nofEcSJ-t4LTj&#NETb#Z;1xu(_?NV@3WH z;c(@t$2zlY@$o5Gy1&pvja&AM`YXr3aFK|wc+u?%JGHLRM$J2vKN~}5@!jdKBlA>;10A(*-o2>n_hIQ7&>E>TKcQoWhx7um zx+JKx)mAsP3Kg{Prb(Z7b};vw&>Tl_WN)E^Ew#Ro{-Otsclp%Ud%bb`8?%r>kLpjh z@2<($JO9+%V+To>{K?m76vT>8qAxhypYw;Yl^JH@v9^QeU01$3lyvRt^C#(Kr#1&2 ziOa@LG9p6O=jO6YCVm-d1OB+_c858dtHm>!h6DUQ zj?dKJvwa2OUJ@qv4!>l1I?bS$Rj zdUU&mofGqgLqZ2jGREYM>;ubg@~XE>T~B)9tM*t-GmFJLO%^tMWh-iWD9tiYqN>eZ zuCTF%GahsUr#3r3I5D*SaA75=3lfE!SpchB~1Xk>a7Ik!R%vTAqhO z#H?Q}PPN8~@>ZQ^rAm^I=*z>a(M4Hxj+BKrRjJcRr42J@DkVoLhUeVWjEI~+)UCRs zja$08$Ff@s9!r47##j1A5^B6br{<%L5uW&8t%_te(t@c|4Fane;UzM{jKhXfC zQa|k^)d*t}!<)K)(nnDxQh+Q?e@YftzoGIIG?V?~$cDY_;kPF>N}C9u7YcZzjzc7t zx3Xi|M5m@PioC>dCO$ia&r=5ZLdGE8PXlgab`D}>z`dy(+;Q%tz^^s*@5D)gll+QL z6@O3@K6&zrhitg~{t*EQ>-YN zy&k{89XF*^mdeRJp{#;EAFi_U<7}|>dl^*QFg**9wzlA#N9!`Qnc68+XRbO-Za=t zy@wz`mi0MmgE?4b>L$q&!%B!6MC7JjyG#Qvwj{d8)bdF`hA`LWSv+lBIs(3~hKSQ^0Se!@QOt;z5`!;Wjy1l8w=(|6%GPeK)b)2&Ula zoJ#7UYiJf>EDwi%YFd4u5wo;2_gb`)QdsyTm-zIX954I&vLMw&_@qLHd?I~=2X}%1 zcd?XuDYM)(2^~9!3z)1@hrW`%-TcpKB1^;IEbz=d0hv4+jtH;wX~%=2q7YW^C67Fk zyxhyP=Au*oC7n_O>l)aQgISa=B$Be8x3eCv5vzC%fSCn|h2H#0`+P1D*PPuPJ!7Hs z{6WlvyS?!zF-KfiP31)E&xYs<)C03BT)N6YQYR*Be?;bPp>h?%RAeQ7@N?;|sEoQ% z4FbO`m}Ae_S79!jErpzDJ)d`-!A8BZ+ASx>I%lITl;$st<;keU6oXJgVi?CJUCotEY>)blbj&;Qh zN*IKSe7UpxWPOCl1!d0I*VjT?k6n3opl8el=lonT&1Xt8T{(7rpV(?%jE~nEAx_mK z2x=-+Sl-h<%IAsBz1ciQ_jr9+nX57O=bO_%VtCzheWyA}*Sw!kN-S9_+tM}G?KEqqx1H036ELVw3Ja0!*Kr-Qo>)t*?aj2$x;CajQ@t`vbVbNp1Oczu@ zIKB+{5l$S;n(ny4#$RSd#g$@+V+qpAU&pBORg2o@QMHYLxS;zGOPnTA`lURgS{%VA zujqnT8gx7vw18%wg2)A>Kn|F{yCToqC2%)srDX&HV#^`^CyAG4XBxu7QNb(Ngc)kN zPoAhkoqR;4KUlU%%|t2D8CYQ2tS2|N#4ya9zsd~cIR=9X1m~a zq1vs3Y@UjgzTk#$YOubL*)YvaAO`Tw+x8GwYPEqbiAH~JNB?Q@9k{nAuAbv)M=kKn zMgOOeEKdf8OTO|`sVCnx_UqR>pFDlXMXG*KdhoM9NRiwYgkFg7%1%0B2UWn_9{BBW zi(Ynp7L|1~Djhg=G&K=N`~Bgoz}Bu0TR6WsI&MC@&)~>7%@S4zHRZxEpO(sp7d)R- zTm)))1Z^NHOYIU?+b2HZL0u1k>{4VGqQJAQ(V6y6+O+>ftKzA`v~wyV{?_@hx>Wy# zE(L|zidSHTux00of7+wJ4YHnk%)G~x)Cq^7ADk{S-wSpBiR2u~n=gpqG~f=6Uc7^N zxd$7)6Cro%?=xyF>PL6z&$ik^I_QIRx<=gRAS8P$G0YnY@PvBt$7&%M`ao@XGWvuE zi5mkN_5kYHJCgC;f_Ho&!s%CF7`#|B`tbUp4>88a8m$kE_O+i@pmEOT*_r0PhCjRvYxN*d5+w5 z<+S)w+1pvfxU6u{0}0sknRj8t^$uf?FCLg<%7SQ-gR~Y6u|f!Abx5U{*KyZ8o(S{G znhQx#Zs_b8jEk`5jd9CUYo>05&e69Ys&-x_*|!PoX$msbdBEGgPSpIl93~>ndH;t5 z?g>S+H^$HtoWcj4>WYo*Gu;Y#8LcoaP!HO?SFS&F9TkZnX`WBhh2jea0Vy%vVx~36 z-!7X*!Tw{Zdsl3qOsK&lf!nnI(lud){Cp$j$@cKrIh@#?+cEyC*m$8tnZIbhG~Zb8 z95)0Fa=3ddJQjW)9W+G{80kq`gZT`XNM=8eTkr^fzdU%d5p>J}v#h&h$)O+oYYaiC z7~hr4Q0PtTg(Xne6E%E@0lhv-CW^o0@EI3>0ZbxAwd2Q zkaU2c{THdFUnut_q0l+0DpJ5KMWNTa^i@v%r`~}fxdmmVFzq6{%vbv?MJ+Q86h6qf zKiGz6Vrb>!7)}8~9}bEy^#HSP)Z^_vqKg2tAfO^GWSN3hV4YzUz)N3m`%I&UEux{a z>>tz9rJBg(&!@S9o5=M@E&|@v2N+w+??UBa3)CDVmgO9(CkCr+a1(#edYE( z7=AAYEV$R1hHyNrAbMnG^0>@S_nLgY&p9vv_XH7|y*X)!GnkY0Fc_(e)0~)Y5B0?S zO)wZqg+nr7PiYMe}!Rb@(l zV=3>ZI(0z_siWqdi(P_*0k&+_l5k``E8WC(s`@v6N3tCfOjJkZ3E2+js++(KEL|!7 z6JZg>9o=$0`A#$_E(Rn7Q78lD1>F}$MhL@|()$cYY`aSA3FK&;&tk3-Fn$m?|G11= z8+AqH86^TNcY64-<)aD>Edj$nbSh>V#yTIi)@m1b2n%j-NCQ51$9C^L6pt|!FCI>S z>LoMC0n<0)p?dWQRLwQC%6wI02x4wAos$QHQ-;4>dBqO9*-d+<429tbfq7d4!Bz~A zw@R_I;~C=vgM@4fK?a|@=Zkm=3H1<#sg`7IM7zB#6JKC*lUC)sA&P)nfwMko15q^^TlLnl5fY75&oPQ4IH{}dT3fc% z!h+Ty;cx9$M$}mW~k$k(($-MeP_DwDJ zXi|*ZdNa$(kiU?}x0*G^XK!i{P4vJzF|aR+T{)yA8LBH!cMjJGpt~YNM$%jK0HK@r z-Au8gN>$8)y;2q-NU&vH`htwS%|ypsMWjg@&jytzR(I|Tx_0(w74iE~aGx%A^s*&- zk#_zHpF8|67{l$Xc;OU^XI`QB5XTUxen~bSmAL6J;tvJSkCU0gM3d#(oWW$IfQXE{ zn3IEWgD|FFf_r2i$iY`bA~B0m zA9y069nq|>2M~U#o)a3V_J?v!I5Y|FZVrj|IbzwDCPTFEP<}#;MDK$4+z+?k5&t!TFS*)Iw)D3Ij}!|C2=Jft4F4=K74tMRar>_~W~mxphIne& zf8?4b?Aez>?UUN5sA$RU7H7n!cG5_tRB*;uY!|bNRwr&)wbrjfH#P{MU;qH>B0Lf_ zQL)-~p>v4Hz#@zh+}jWS`$15LyVn_6_U0`+_<*bI*WTCO+c&>4pO0TIhypN%y(kYy zbpG4O13DpqpSk|q=%UyN5QY2pTAgF@?ck2}gbs*@_?{L>=p77^(s)ltdP1s4hTvR# zbVEL-oMb~j$4?)op8XBJM1hEtuOdwkMwxzOf!Oc63_}v2ZyCOX3D-l+QxJ?adyrSiIJ$W&@WV>oH&K3-1w<073L3DpnPP)xVQVzJG{i)57QSd0e;Nk z4Nk0qcUDTVj@R-&%Z>&u6)a5x3E!|b;-$@ezGJ?J9L zJ#_Lt*u#&vpp2IxBL7fA$a~aJ*1&wKioHc#eC(TR9Q<>9ymdbA?RFnaPsa)iPg7Z; zid$y8`qji`WmJ5nDcKSVb}G$9yOPDUv?h1UiI_S=v%J8%S<83{;qMd0({c8>lc=7V zv$okC+*w{557!ohpAUMyBHhKLAwzs&D11ENhrvr_OtsnS!U{B+CmDH-C=+po+uSqt z+WVVXl8fKe5iCZoP;>}4OVen6_|uw8*ff-r;)O2W+6p7BPT7sT<|Qv=6lgV#3`Ch${(-Wy#6NA$YanDSFV_3aa=PAn%l@^l(XxVdh!TyFFE&->QRkk@GKyy( zC3N%PhyJf^y9iSI;o|)q9U-;Akk>;M>C8E6=3T!vc?1( zyKE(2vV5X_-HDSB2>a6LR9MvCfda}}+bZ>X z+S(fTl)S})HZM`YM`uzRw>!i~X71Kb^FnwAlOM;!g_+l~ri;+f44XrdZb4Lj% zLnTNWm+yi8c7CSidV%@Y+C$j{{Yom*(15277jE z9jJKoT4E%31A+HcljnWqvFsatET*zaYtpHAWtF|1s_}q8!<94D>pAzlt1KT6*zLQF z+QCva$ffV8NM}D4kPEFY+viR{G!wCcp_=a#|l?MwO^f4^EqV7OCWWFn3rmjW=&X+g|Pp(!m2b#9mg zf|*G(z#%g%U^ET)RCAU^ki|7_Do17Ada$cv$~( zHG#hw*H+aJSX`fwUs+fCgF0bc3Yz3eQqR@qIogSt10 znM-VrdE@vOy!0O4tT{+7Ds-+4yp}DT-60aRoqOe@?ZqeW1xR{Vf(S+~+JYGJ&R1-*anVaMt_zSKsob;XbReSb02#(OZ z#D3Aev@!944qL=76Ns-<0PJ;dXn&sw6vB9Wte1{(ah0OPDEDY9J!WVsm`axr_=>uc zQRIf|m;>km2Ivs`a<#Kq@8qn&IeDumS6!2y$8=YgK;QNDcTU}8B zepl6erp@*v{>?ixmx1RS_1rkQC<(hHfN%u_tsNcRo^O<2n71wFlb-^F2vLUoIfB|Hjxm#aY&*+um7eR@%00 zR;6vT(zb2ewr$(CwbHgKRf#X(?%wBgzk8qWw=d@1x>$40h?wIUG2;Jxys__b)vnPF z{VWvLyXGjG4LRo}MH@AP-GOti6rPu^F04vaIukReB|8<7&5cebX<)Zk(VysCOLBuL zW9pEvRa--4vwT?k6P??+#lGMUYE;EsaU~=i_|j!1qCVS_UjMVhKT%CuovR;6*~rP0)s5eX zxVhGZv+qtpZ{_FDf9p{m`ravh=h>mPMVR7J-U@%MaAOU2eY@`s-M3Oi>oRtT?Y&9o({nn~qU4FaEq|l^qnkXer)Cf0IZw;GaBt)}EIen=1lqeg zAHD~nbloktsjFh&*2iYVZ=l1yo%{RK#rgTg8a2WRS8>kl03$CS(p3}E-18`!UpyOg zcH=`UYwn0b@K1`E&aQ%*riO|F-hq;S;kE7UwYd~Ox(u)>VyaE7DA6h_V3_kW2vAR} zBZi_RC*l3!t;JPD;<*z1FiZt;=KK-xuZ`j>?c5oxC^E2R=d`f68!-X=Xw2ONC@;@V zu|Svg4StiAD$#wGarWU~exyzzchb#8=V6F<6*nAca@x}!zXN}k1t78xaOX1yloahl zC4{Ifib;g}#xqD)@Jej<+wsP+JlAn)&WO=qSu>9eKRnm6IOjwOiU=bzd;3R{^cl5* zc9kR~Gd9x`Q$_G^uwc4T9JQhvz3~XG+XpwCgz98Z>Pez=J{DD)((r(!ICFKrmR-;} zL^`7lPsSmZT?p&QpVY&Ps~!n($zaAM8X@%z!}!>;B|CbIl!Y={$prE7WS)cgB{?+| zFnW-KRB-9zM5!L+t{e~B$5lu-N8Yvbu<+|l;OcJH_P;}LdB~2?zAK67?L8YvX})BM zW1=g!&!aNylEkx#95zN~R=D=_+g^bvi(`m0Cxv2EiSJ>&ruObdT4&wfCLa2Vm*a{H z8w@~1h9cs&FqyLbv7}{R)aH=Bo80E3&u_CAxNMrTy_$&cgxR10Gj9c7F~{hm#j+lj z#){r0Qz?MaCV}f2TyRvb=Eh|GNa8M(rqpMPVxnYugYHqe!G`M@x(;>F%H46LGM_cU z{*0k6-F!7r3;j{KOaDxrV16WUIiFAfcx?^t*}ca4B8!-d?R|$UxwV8tyHdKL zhx;7%0Zn#qtx;S)REtEP-meAlV8*1qGFbRJ*eeX&+hsiLF*g9%r0Zl`L^Kn`4I)ul z32#3pg6Mu$LEI@hssUb?T$di_z zHgaB3zw;*0Lnzo$a~T_cFT&y%rdb*kR`|6opI#Pbq~F%t%*KnyUNu|G?-I#~C=i#L zEfu}ckXK+#bWo11e+-E$oobK=nX!q;YZhp}LSm6&Qe-w0XCN{-KL}l?AOUNppM-)A zyTRT@xvO=k&Zj|3XKebEPKZrJDrta?GFKYrlpnSt zA8VzCoU+3vT$%E;kH)pzIV7ZD6MIRB#w`0dViS6g^&rI_mEQjP!m=f>u=Hd04PU^cb>f|JhZ19Vl zkx66rj+G-*9z{b6?PBfYnZ4m6(y*&kN`VB?SiqFiJ#@hegDUqAh4f!+AXW*NgLQGs z>XrzVFqg&m>FT^*5DAgmMCMuFkN4y*!rK^eevG!HFvs7nC672ACBBu5h(+#G@{0J- zPLsJ{ohQEr2N|PmEHw9 znQ`qe-xyv93I;Ym=WnoVU8dau&S^(*Wp=}PSGw;&DtaKz-);y)zjD|@-RT`*6nowj z7B%)h3>Lro-}5THC@BLymuL&3~kh8M}ZrZGtYKAmrT^cym$^O!$eeK$q5X2JF1w5a}4Z6yJ<=8&J?(m6U?;+ z{+*B;P@yGffMz;OSfm7NDhkGR5|7&~FNvel8Yj{F!DWnHG>%?ReZ$1w5I$Bt_u|4v z-ow>!SF!pCGrD&K8=-<;Gp@oB<@9C&%>vPHrp4sQEJj2FdedjC=0FqD>EG?NCf=KQKVd^stDZP7KNCAP-uEO*!?vgwvdp&Dm3h5Cldn!cIOL@u>1!HSfK+~kn-9Ekr|MWNApAJCJ5&5#izmjm z$CI|Boo@;O?Z(Bo9ejP>bbH|jRKn7W3y0L1!O6v$RUtt;%5R#**`+39c$JuO`SMU+ zbzu$7Eu`JQ+ri_ap{w(R_juHcw0X8~e$48TzBX%Yd+HkSSYt2){)+rYm48G^^G#W* zFiC0%tJs0q3%fX_Mt8A=!ODeM?}KLDt@ot6_%aAdLgJ7jCqh_1O`#DT`IGhP2LIMhF* z=l?}r%Tl#)!CpcItYE2!^N8bo`z9X(%0NK9Dgg^cA|rsz?aR+dD6=;#tvNhT5W}1; zFG@_F2cO&7Pdp1;lJ8?TYlI(VI8nbx_FIGRX^Z(d zyWyJi58uPgr>8w$ugIGhX1kr*po@^F>fntO1j&ocjyK za8Z*GGvQt+q~@R@Y=LdQt&v=8-&4WOU^_-YOuT9Fx-H7c;7%(nzWD(B%>dgQ^ zU6~0sR24(ANJ?U>HZ#m8%EmD1X{uL{igUzdbi+JN=G9t`kZMGk!iLCQQiVMhOP&(*~gU(d+&V4$(z=>4zqh(GX+9C&;~g2 z9K2$`gyTRJpG_)fYq=9sG^1I{*I=s%0NX^}8!mJVc?y$OYM^n!x(2jw$$;}n&dh%D;St+FA;eW=+28j#G^YLi@Gdk*H#r-#6u?7sF7#_pv?WS^K7feY1F^;!;$rgU%J zS$lZ(hmo$F>zg$V^`25cS|=QKO1Qj((VZ;&RB*9tS;OXa7 zy(n<$4O;q>q5{{H>n}1-PoFt;=5Ap+$K8LoiaJV7w8Gb%y5icLxGD~6=6hgYQv`ZI z2Opn57nS-1{bJUr(syi^;dv+XcX8?rQRLbhfk1py8M(gkz{TH#=lTd;K=dr!mwk2s z#XnC){9$x)tjD0cUQ90|hE2BkJ9+_tIVobRGD6OQ-uKJ#4fQy!4P;tSC6Az)q?c>E zXt(59YUKD?U}Ssn(3hs&fD$i3I*L_Et-%lx%HDe%#|)*q+ZM-v%Ds3u1LPpPKe-q} zc!9Rt)FvptekA2s+NXxF7I;sH1CNPpN@RT+-*|6h*ZWL{jgu9vth{q)u=E<7D(F06 zN~UUfzhsK)`=W%Z-vr#IIVwmdb(q7k+FX-lciYO%NE!xl25SV53Hwdql-3>8y5X1U zWa3_Qfp2Z;jVX+N+1?`(dx-EJL)%oQsI0G3S=ad&v{dzNal~flHvq(0HjY!v;oE>n z4gQSa2FdJI52Weu$+lED4VYSW;D`5Zn`C#@7Hxa1Ls*#TLBjje(%NYFF+4uOc~dK! zlnyxE4NWVz0c8yx`=sP2t)fHW(PPKZPp{SCwT-on2sEM9tyGO4AW7|R;Iw5|n1KpV zR^S>`h}rxcNv2u+7H6rCvMLMV3p*H#WcN}}t0@Us{w}{20i<-v> zyos+Ev_>@CA**@JrZ6Jzm=pWd6ys`c!7-@jf<~3;!|A_`221MFp-IPg28ABf6kj-Y#eaRcQ!t!|0SRtkQK^pz;YiTC@@lJ4MDpI(++=}nTC zRb4Ak&K16t*d-P(s5zPs+vbqk1u>e5Y&a!;cO(x;E4A4}_Cgp_VoIFwhA z-o^7)=BRYu)zLT8>-5os4@Ss8R&I^?#p?bY1H-c;$NNdXK%RNCJHh)2LhC?B9yL2y z(P-1t9f~NV0_bQ{4zF|-e^9LG9qqevchug76wtFn95+@{PtD)XESnR2u}QuG0jYoh z0df4#&dz_FStgOPG0?LVGW&{znCUzHU%*b1f~F+)7aefg7_j76Vb|2WuG#1oYH_~4 zrzy#g1WMQ#gof`)Ar((3)4m3mARX~3(Ij=>-BC zR@&7dF70|)q>tI$wIr?&;>+!pE`i6CkomA1zEb&JOkmg9!>#z-nB{%!&T@S-2@Q)9 z)ekri>9QUuaHM{bWu&pZ+3|z@e2YjVG^?8F$0qad4oO9UI|R~2)ujGKZiX)9P2;pk z-kPg%FQ23x*$PhgM_1uIBbuz3YC z#9Rz(hzqTU{b28?PeO)PZWzB~VXM5)*}eUt_|uff_A8M4v&@iY{kshk{7dHX1vgHs zC%vd9vD^c;%!7NNz=JX9Q{?$~G@6h!`N>72MR*!Q{xE7IV*?trmw>3qWCP*?>qb01 zqe|3!Y0nv7sp|Md9c z4J5EJA%TD-;emh%|L2kLpA^g>)i56v6HIU8h7M+KSWYw~HHz3`ILj*{==jD(l33>r zmOdINZ8^Jo?ll^~q@{^5l#*3f`ETncJmo?iRLz*=W=o3MJ!K^xjVcw*H}p63#p4XX z1)|C%{Y&)IpRIk5oMVsUi6oyKAFy8MH$@|Zpjr^lxlMX3O{0AZTjc{gso{KRuo30V zUJxq2K=_CwV*Qx_D!hJCBTuQ}5oMNrWUBNVaa8zyMg5lrXgv8Zw@rm5NAcFplYa>P zmUNB>EB|r?#Z!Gq^`(HZl__UJ*K5 z=>`{UTlt0;Y+LmP1Wb19IWK(SIWDrqh=+K81c`t@BCS|2#@K0u5eEwQ7CG92=Axx4 zQ?CPaVE5!XY`2r!Ce@m(tRtB=&+c>a09WzP-Ys!~i;V0hEq}PU8n1a;bVbJ17rYW1 zjz|KkLZoO7-S6oQp_ocIzS43P@CJJxQ$k;$!fS3*V)m|VtBIEgCtU@W`AG9VMU_d znB-Zs3I)I(Wg=xj)Wcx03h}U3i5{D@*udPLg?Jx7dp&KEIwJiW=eh}Ps#FxbsS?F}7z<;<5RP6-UAD+_An$s3y-JAC zh{JlAX3e^CDJl1gJDbH`e=hD88ER_6+Mw8CwK&^|$BnzA|AvDV`#xF^z9b6iWb)0@ z+gir=oSUaVcJi%1k+9!pd`(3|h~4}!NM7NHPNV6rI(W4~Ie5 zl@(Xg2`OSq|HJRUg3qgr-c!}9@W?pEJXKtxP7f(aE2Es33gRSu#~XiCIpV-J;JLM{(@qK2wEvsi@6-9(cyXX!6YS0n7;TK0Ldf*JGmlvrF0 zGQ+Z509rmWa)O}r`z2W3!6u{^ZQrY`KR#VlTRmllG2v$R!7%B~IU@XnNi!E1qM$J8 z%{XFU4vy_*M0tKjDY3E*7N!d%&vnx5qr#=!IKWZfoRo8j=7ji1{xW?g^)A|7 zaaA5Rg6rwCF?y33Kz-90z!ze`@5N916S)(fHPa>{F`UEF8N5PTNjbo)PF5W_YLB*# z?o`qxQTIzokhSdBa1QGmn9b;O#g}y_4d*j*j`cx^bk(=%QwiFxlAhFSNhO0$g|ue> zDh=p|hUow5Knbclx8V;+^H6N_GHwOi!S>Qxv&}FeG-?F7bbOWud`NCE6Tv-~ud&PS6 z;F*l>WT4zvv39&RTmCZQLE67$bwxRykz(UkGzx}(C23?iLR}S-43{WT80c$J*Q`XT zVy-3mu&#j}wp^p0G%NAiIVP2_PN{*!R%t7*IJBVvWVD#wxNRyF9aXsIAl)YpxfQr$d%Rt20U@UE}@w?|8^FMT%k36 zcGi_Mw+vMvA@#}0SfIiy0KEKwQ|`iR++|PF2;LtiH7ea($I{z z32QPp-FlEQ**K_A@OC943z`Qy7wC~&v z*a`z;(`5(e#M|qb4bkN6sWR_|(7W~8<)GnX)cJAt``gu8gqP(AheO-SjJMYlQsGs0 z!;RBZwy>bfw)!(Abmna(pwAh^-;&+#$vChUEXs5QOQi8TZfgQHK$tspm+rc%ee0gy zjTq5y20IJ`i{ogd8l?~8Sbt^R_6Fx*!n6~Jl#rIt@w@qu2eHeyEKhrzqLtEPdFrzy z9*I^6dIZ z)8Gdw1V^@xGue9trS?=(#e5(O#tCJv9fRvP=`a{mnOTboq<-W$-ES7)!Xhi*#}R#6 zS&7hR(QeUetr=$Pt6uV%N&}tC;(iKI>U!y$j6RW&%@8W|29wXe@~{QlQ0OjzS;_>q z(B!=A71r|@CmR7eWdu9n0;OJ zP@VOOo#T+N$s{`3m`3Li+HA4owg&>YqCwsA5|E$b;J&v#6RbT$D!x$Yaflo92wU?A zvgD8g(aY`g7}Y2^2i31ocm&k9Km`NQipEsjU>MuRzD35*Jk7^Q(O;M32!gt1cEB@- zBOHd@@Qo{fQ^7o{FiNdS)_vTiP8toqZ`iNi^1-4(hp+s751}Tf34b z_UYQ1q0~*jIp9pRIpI8ue}$|~uu0#p>-y8t{yEwB(8yAjMXrJ{`{rp7*-wlh8&bso zHV`LnAF7Bw+w}Wm9ii3U@lEvcc-i$0&h+eUmlQuREzg!ao)ZjwThhqIKA})}akyX7 zcbuIw9K}9aUZ;hvAxk~rqpk?bYMWr-@b-pMTR8))ggQa$kBv=IinobKCR0?S&g*+Al2J`VR7he{}0Pu zae7LYa!OoTOk8?ma)M@Ta%NxQacV~KMw&)}fkmF7wvmagnTbWo))`Kofr)`-pNe99 zMnam7vRRs5LTXHWNqTzhfQo90dTdg<=@9teXaX2tyziuRI?UOxKZ5fmd%yNGf%Kis zEDdSxjSP&;Y#smYU$Dk>Sr0J42D)@hAo|7QaAGz(Qp*{d%{I-#UsBYP2*yY8d0&$4 zI^(l62Q-y4>!>S{ zn;iO%>={D42;(0h@P{>EZnIzpFV|^F%-OJADQz(1GpUqqg#t!*i zcK}eD_qV$RmK}-y_}f$Xy7B+hY~f4s{iCD7zq%C|SepGu`+>h6TI}dUGS3%oOYsZ0 z#rWTU&aeMhM%=(r(8kK@3rr|wW^MFE;dK5&^Z!>`JV{CWi^Gq?3jz~C-5hFFwLJ@e zSm3z9mnI+vIcF+RjyOL!VuZP3rJDjPSm4vYolnm)H;BIz!?dLyE0^5(pm)5*>2clW zaI^*Z;p6iGZW~Gr0(Eh+%8Jkz{S9{}=}Ewi6W0wF3|BbVb?CR2x>4xST?woP;Mz8L zDfs+0L9ga3jcM)zCC=`-ah9#oulxt9bZq9zH*fJK$bhT=%(2bPMY~}cPfTyE{_4p+ zc}3pPX`B04z+T>XwRQ4$(`U~037JrmN`)3F8vu_OcBE}M&B;1Vd%|I|1tni?f_b&$ z5wpdJ6F*oif)r=IzB$ytT72GuZi$y>H0p_#amQcJLZ^4KZySOUrRyXy3A2(i=$zB9 znZnGFLC34k?N@s@`)u8aZN({9Hfe}|^@Xk(TmCqNBR*Bter>opM!SGiDU8ShK6FNp zvod~z>Tj!GOXB^#R>6}_D@j67f5cNc#P;yMV}`S*A_OmXk_BIq3I$C}3M~aPU)agY zWC+0JA-)}O@e4XTtjzen&g=J0GIVNjG`_gS6ErXj3cGxeDN*4xEk0PNzfzO@6gb&N zB$S-WV-@efQWs%UX$AVjFN5M@8U>+?Mcqg?@=Z-R`~n~;mQGVJT_vBL|3^fHxZ?#T zE(Sd`8%2WHG)TcNaCHmv_Id%D+K}H3s&c`bxKs(_ScZzyCTpvU zHv~yhtKF9G{s+GC*7>_D@F+qEq@YmXiKTV(j#X7^?WpvIg!Yxi6uBAhh7<91{8vFL zfT?Y~vwmE;(WOL!V5Ag&#@U$mP~T=*#_ ze#QynX>tO#4IJqSj^UB>8ubSEn>Nk!Z?jZE01CJCYuY`1S3 zf%2eyXaWoAQUw)KYO;wi<&+R3_7E%h(7F?xq!8l>!^3Jqj_tNPrG= z+y2S-0j;(AilOo;>SCQu#;Cn?y4Eu za`??!yHz)qFH1Z(3KMqgn+B$&t+5s0zY|}<1kB^Q8FEAumh;^;Yr~amTx1K2%2JUk z@7uIE&0DVch|1R=ro5rjr)w!iU{_09PqfhnGqhAN^$^oz#wVNdTRQ!8^nF};4);Jz#=dTBTMMW7icnZ$dK1E0UEgP4&DNk9MFoKOhtAkVUR`d_vc!x zc|1mY&%{PBxepp^JPHmFDBQ8t@DD-3!C)-ZhGJt)?{)^0MvC%RzI;4}>XoOUF;6~j z{S20Ra%PaiGvM$pFbH;N6)b1J(N;{+Gp^^Qk34JAuPKH}Ap}fen!WlC5vrQ0$pnyq z5poi8VG>>PnGw2^-CY3XdG3<;|0xU}#WBPqn{mO=z0RwL=MXn3=;oA(1C@V^6F;ogwB4EBUpltu=)(MC@To2kSPbL zDdGz|C<@`&!MmQ*e>H>2Qkwa~K%;yZw;SnM<=qwNHu-Dh$r(}-d}T}u!=UOAkzvEOiZ6>{)t$$# zlAmjO$1)&1Zh^zdh8uhmZ>OBA1T4%s9Jex_y4|ifY_=XoX6UzpP;MuC5su(6%;)NI z4d#4aW<*)L6o7w?MY2+jRx6-3S4i zC(~)A`|)5(s?)pBvTfYjwvr@Z-Dx-F7uq}z#WJB6&}0TIi6sGXFWOxD!As%cUg)_A zI)sRCf-5kPBU|rVm0A{!s=W2){AJwvShr6Tsvbg|NrXi!7zoMde_n>-+XFX0fiQy~ zjRp|;6~pR()0a>ETtC7mZD|i$Emj!r-gq!yhAFdV1uR*M<4O?t83N1JRT~8Cy8Vha z+STlcw&CoCJt$k^#ar+~DBmvtC5tr{(>|W6wHq*NSE!^#8*rs>!oYj%fl9~Nu*d4t zdk!|mGJehKW8xJE5ZOcHRfp4plI+l1Pct;rK={=P`YH8&1hNW*YE)4yF2@wa7JFaL zLHJH6ZWc1j|nQ55Znh#>tV`!~N7lY_05Cq%|8I-yN}yf@EzDG zBL z(b0sjh+ui^*s(rg)=l8fU<%cPfba<7y?>}j3R83$2KHzWbVF*`!x^V8JY`D0itC?ZSTYH|w3lUD#$5G$@!v(Lphex2O1;%>w;Qh$t7YF3EjFuySPC$>~%EspW}@Ctn1Bghd5*HVJ=tZK~8oMiZ@9IxfFLSk~>p9cT9gOSPLyP!^bOah`U-6{}C_ zmyhS7S_-tYDm|9C6(Wu2Qe=*g5@{**z@#Ekz3Y{o7fw!^4z$yi z&=a^zmtOpsRO0lFr&c=khr)cL2v9LFKXRDdE}tWlOgpR%}oWHCeJ4;(9U_HeJYl! zwz$p|t6?#eCju@0{IF0gbk>So3C{Ror~JTpuOW!G@^?lBVrf zf?%rDK2E3x=xGC)J_lEk{(ESh-Uw*#k-n4l42f3oC3BJX0-2NMZo?P)-6y1v+?|+< zfFHX8(bw;H@;6K!?=!B#eZrkowcdn7)roPT=WM@MK?>T-cUa$oQdYp&3YRdWu~rhA z@rZKmqj8Ftz-*@`&iH|) zC(H;QiqYx4{Mz@rm`qs~*Ue~4EHM^J7i{QnL~t)O)tnwIQC;23p}TBoc=9rcuS!cQ zQgl)_F@t9{c)ESLtAcg1AbCXqVS%i1ZZRiy$*?Bu=r2ad13e|ZeWV=3pSL>YAk>X& zQZAY4kJD`CYrK-nNti&;uJ*e{cRILOFk@z?B@fNO(exjUhf!b=yuC`@(RS#ko1HA+ zOwsym7?F)}ufcD5&IV+qr+i7Mo3)6M2oI)*3?@-%ah^0rL#0PIn}XmOTP9Xsg5C;t zqkFe6yT##_ZG5KuhVQY)89LfWOeXpXVNWX2PmiRqq<$C!<^WlyO~Q=pk${$DsWY-7 zZ->4<+c@KPgKzKosGPF+&Q*>L>WaN6_FC~SP~3gH7bvg6>QgPzp`&QTpf3W>HjxDxj!y zZb`O;&XZzI2YJ4!^Mq5~Vz7lLv`StN|TSP@jdF}@9;ql?u*#Q+_E}~hak(3B%AQNq)t7PKgAWTYp>EJz^VIj67KcZ3^vvZ7{b;; zcOOArcAw2$T+$UwIib|pt3i#NAuP#3?Z@Oaz?Mt(H&u7HZu!03kV7`t5IRcf7hwck zf{Ujp*YsH;dvcW0q|=o$;z#Cg52;n5t1phY44To!sQ99h`iVzXd+v(L%?A$Ks|Ne; z7fby7IVUXqN8gzsnL-s?uIv>=Qh!qAxoe{fRaI&EcSGCTdggq-Qq?DU%SBOummO5cRa9NW}V>A0IH#pxch)!$2p8=^-XYjsB%$S$U5nI zlJEMBb!BZ_O4@87cEYUBH7}Y_MF$+(~gdf-!7)D-D)+O{*18TC{HGZFF+`%IPcmK{O{YxR> zSfJHSeQCChuPUAWe_x~gy*f!!wvt_tL-Dp=nUm+juu;4L6N1IIG4dsVMat#T^p7p1n*Tx2a!YaivBTqLsSJAF=kJej?@QWf)Y-8Ks>WkC456{B#hW-ML zI+f23(}F=MeSdbWQ>R98TOzv#Haw}ua+17H=P5|~#BDmoEPkzl#lBTvCoyj`XU|IS zHn?dXbq>rqUW8^kQN01zL~6!Vxn4!$Pu|F&#XbiF{{>T z)&khW&2Y?d8^jC|phWKQ4!CM9b66+l*HTdPm+)M|e5yT)I32Q~2ENVJ*ZH;JF^Y907{XNHLoQ+85J~!w@3h_5d04o=~|1 zCBAvjnXMn`S#qMkPZE}9#RX`%al{`J=oFKk(aJYT&Ss`4iBrXa_pQ=3lS1IUFA|Rr zgnh;c8nkGH)|*yyoUZ?tE1XKwkF$n6`sdkf^7)(wZ52xtm86N>o&&jG_@#ue(B`xPM|8oGz94>*kl17-|d^y0`D=&hScq6gGQ%Z6|LU zG@<~h-R{xW)y7k1x7XFw!TWW~HPC^bCO_;xG#A4he?=xkLjS=~U!uR+q>vqJxCN~J z+I}|P5RTv*qRT{k2N^Kz8OX*mz$hYR!aYq-f5bN4R4=omUVP19L|)EZq?O0#B9 z<3G&oAZ`UeIqZWlujz8UNNSK#{=_c`*(&TwlIr3ZpC0sfS5Jy?;t+&wb1g4Q91rRNiEt1|L zisgH;)V()S&(TSB|1yAxZLH%BY`nnhUw_6sz~zdKCCc!ZV*Ws6`U4u|CBpv4pYIX1 z5*)5C*N#D}gj<@pdZxtw!`5aFVQ^Jj?1W z+EsBx6>WV`%wnP@Fp{XlqFkbHf%LfCgIi_|w?uPPjHAgOF+lDnAb+WEB+i_53PFmu zj!=umx@ez9mVxC&jA_RtKRfQG>Cz`A77S2SpOt7%Rt*}fG|yO+2t7CMuK$^}D#i}k zZmO9yUwK6%!LbRsULVnxUxfxso5KFES=!WCm>y&YSR@0CS|iON0v59pkQ7dVA{j*+ zmcRtD@lxXuFq@#$DKKSal#ApSJLw58m_NIJ?z;eD3Z8u*-#}EaK zyG~L>-7laE`Y}{g#FPs9YA-wT4>X>xRNtTHp8_rhvWA|eJH(!o-G~C&tvHB9$UEJI{ngD>QjBz=wl~x-j1MB z4)L_#jZSvaQkbmVbN)4{#^r&ZmfhhV%?tet3`xJ;#jI}DsS94qc&s)#2kXv5pkt;K zaY6emqzF1JWMxI(7h}mk*MQ5C8WLAol60!DPj|u0jMrLTkU7G?ud**S@bYx-vp$+r zMVXWc4H}2=yF+YML9!k~LT(|<#By?F2bS~weMi9dD@DA&k#0e&MM1YT!qoQDeNLwB zA;{KvwSzP?-K(>@_b@4vTkIX7xwj}ckrusCw!k=#;Krt6;}3q4d*)?c{>I|C2I^4p zR(o48TqHbw?4Z`c`>?P{`cT;FpJoFW1wJ3IVO#5Q`wsB>o>zsRDDATmct`aaYQbTL zJVlHeok9_?w83#Z*J(_BMs-;N;mNeq{;f3S zSy{i5hNY5s`c#)~KhQZ{0_hNmrMD2b7CLC2+x#EmLcNa8V1Q=jz@e~VV)Yq!Z|$nv$TEG3j6K4opW+mH z3~z?*H$qobb652kQ}ZHFHUVj$%JAwS-Ie=Vh&Iivx3hjMCZ1k)4dRjdhxRb17P;Gz zZCsB4J=l1S8`O|(g!8c$aOMaYeUoCJj&n#kbDxe(^GQ)E)$Rq+i-wbPKeaQvL!`Y- zcL=QOLcWBdDq_`HLow9P5BG2EMY$v;w9cR$C{ zMv)5zrmYv!uzHFAxDI>aftAp&ad>GYoPt!d;A*$s)^6E5l5ct#&O7A0p^8J1ceXa) znIq{NgKbbOSC`6E_af2bCoI(gD@(krDr^mDVw>cRz3zJ^&9kbuf6)J@Cd#zbnko5m zdyD^j^!9J7`oH!u{~wlOl7jYM(OcdI^#*5Y>BjUumq_g&tx<#_pkzQL3{!g?50d=#eCov*uIw$N*glXJe1F{FuUF_wCElS)Z2X= z8&w0?WkCX%HfL)#n-m1tiLy!jDMqH$LikJF=#lu@k5%&vN zOEmQQ^n*t^76E;JhHPzQqbY0+m8GQ9;~dJLLZ@*sqVX0ui5yz%8Hyn87vqUisY_0- zDtUu5haWdOvDBOX9Y;=s;7ul^_xLxfU(?k(HStRfk0Ab!pY(scal?Nz{Qu?etFHNA ztD=60Y>dte)hUle1IUyYIFgMxgGpvx%Odv4q;WPV?Zj<0pph+zWMfSd=SIUcB_#7^ zgNlm4(v!WIBm4?kpvZnCvp?TXW7~Azs3LT8Gh<0Ew=&W*e+4X_xQ{(e+UCESTaWwz zd1ly>%|#A|W%fgeL_3gAwxjeb?Wi3rAR3U#9Rie*)dfz7YxUK;ex+a4F>@qyQAL0^ zZncndzG56R$F&?R4SOX>&%UDdBid6 zIn=GRfcto+s-%gMB)Wx7!_Z+SS)f3IG!&s%P2eNfHI6~E*=>e`^RpvJQY?T95IOKL zeX-_BCdRE#f06_QAoDyMH;#IIBnT#PWSOtks+PCo`04X-brsea32I~@X(Bwl*Q`$c z{Al@04k=Mmd0}}ts=u%dCO;qn-;qh>Hr7bB6!NOVxy@Yi#GK2vusj7iU9757HTqN~ zNMoKeZY}o)nA*{CqTTPKnWi*JgZFZj&EjD$V;O9zqHV#tB#r5Ur$V3To8iP-bO*Gl_d%qc2$SoU`Hu-6*hWbuWzAn(83_jZ%>P{PY3XVV!q$~ALE^GC( zdIGgR(HnV8Rn*P^7b8#AzONo*U_W}{Ne!=#*qNJIRZzapu_fOkvki(|8NDg>&D=OZ zL3G)1WS*8CFh`-sb*#8*hIN7WDjw6<$D&T|B>JPi`K!*5DF(O*^A+r*Jfnt))c8|M zQKtgEytAqpy@~XZGnVYMJmZSG0U~uvP?i*?DhgDOSYtx6s%6u*vL$SW87`&xJ9cmDLrPHI@G7Pb*cizPGf|!5th41a2ijel>Xfk3i?7Bd*{|)@>|ZBi zH6gO9a2Yd&_ZeKmNQC^e&S$cl!3D2oBCX)C;Ve{0qc|4+*fwK!x{=QYtb#3QD1|Yi z%r?t<$-Mjbli1fF(C?V&w#;Gq3-**PgsGPPsXN(0fb?pIDc{s6b<9{t%6D*47A9ZHlc4rEGU<}u;tiom3^lA-&)1i=j z|I#)cctK)AH-b2*a3Wm%Gt*;#GWjNF6q0q^Evid`6G2yhMg_4TaMUK&x*D*5+KtlF#!)86A7pn~&yvD-Rh%`@(o!Wc#9t=t;(9_y*(MWS;4cPU&cJcE+h} z6fZHrjH@7{6~n40#qgL(yA-oVrt;Kcu=fV1WQ0QY`_I8lVds$PYR7KDvhsTbkC8q6 zct`{-n;z2!($SBZ?;(ZMu1sY(VY)KJ@%p)!LEBL+M{ck-$kHEx=3N+%$#msc!LKD> z?(7`Owu6Iuf-Nb|5wFxCm}U)Du@JO|nHV?%8lk(y3x-=F_d}u8>#AU~iWtSD6|VuV&YM=#_v-HDjZ4mS|L2%K2K}Mhz zVb)f#Q>%4Du>|ea6cbNYrpi<6A!rSmbeh7+xGZ{-TPG);DG9qg=>9!44ScDdh49-_ z;|KUp*RQ-So$jyV%Ss5FnJa^|LYAl%8niBhd%(W!x$Rpq@pcp6(XF^fHFRF2KQP>$ zo@`Qi&QlkFxp%0@2)7RlN4+NzCWo{?_x}5$E?kh!!UM3Vg9R+=xPLWty|S}5Gt_qg z+-v~8k*0?Bf0^Q+IZS56Ny~Q$pap&c2NUt&f7P9P+zEz*>bOO!5J8(uhIJ#%lgMNl z3;y^@Yht z_Dko1D=J@nc@`zIXz6dWsr`Kdt!m8`gGlx59A(t5ZjDVmrsjl#0wT@It~$j=uGRM! z@XJK@Q})NA_sQpEZkNduP-h{cP|l+Qqwr{g--LeHY2&||4dJFD34ZCj7@+4ZH4}La zjfr1gHXr8j#ppOa+gkiuHYf$a+VGA${f!~LtdO!~|X+>{b zY8=`^(0d9`z1f!nNzD`;4&65cNlg)@h5m5oOj&gG%mslXlc+jou#n#`d_l6}hwB+CG5k*Sr36Yrz zP2B)Pq#G?*Iwb)FJiXU@lTvTrdR&WRpV8sUz(Sx3C%f;BHSLY@I$!TqSg!%IetroG zD$gu&K<>-imH@Bh&}f!zwO-`w8Dt>MMZ>8V@{X1g?!2BS0S;GtXTW(%@{L=6uC*fB znj>TvA9Cj80~Hn`A5GSVpyqA$*6rlEa`u=Z!{-DRtCo0{jnK|3KxpDEi3&^DwWNg4 z%|~wf=EtEq^ku$fbX{@*EYr&TP@j@?OyLdVKVk*&H23K=xzmgV8p0Y|jK+@cNaPE1 zovLSR73MssgV04G7S-h7L}ID!!8|-X7U6-7?t~caWg)yk6*s=m)9us~kZ7pC6I1+@ zd&wXWPx{8Z>47wN=yJJ;BgQ&`z)H7hxm}Jq_9GiAq)9R- z7(@1=H+oqdJ(YFEq(LiJW=s}h(Yx~}5%_cQ&3xV0VUT%{sXE!% zVMqItDE@pLL%E2I2<48s8InBVbnt|shpL|$wrvbdWe!LJMr$c+e86OWy77OJ6k_2&3KMqL9=QFd2QUVwwR8X*sgj}5OpiFWK zkiv)DX__mAlH9kRszqfgqLLvBrDbP&mL;Amd=_UXSF4&!?$+*0ZswW?9oH!-BQgjS z*IQf1yzUikvx`UPXLZi2UvHaGMOee-cPA0C5fni_Q zcj2Hhbit;RZ5t^!?2;o_*D4W$VcsfIc+m?Z?b!Uv2;-s&XYSCUiczc2-b0I0g-hNj z@xi1}g6j<*=Dr7UMa-%w&YN`cBbWT>BQ~p;QyS!^#eQ>q9dy!?Nrh+?bfo*_kEe;nyR%9=3OTAD90?RT8#Bk}X#Pkr(TqBF2&!V=` z^iWLr%Yk96POnG@bEb?cv#Uk)5}bP0=~;%g>Sm{t#hoNp#yeFj7UxuD?en)EXw2%= zTS`>YY)#O023TqIXj@8o2KAM29NQM4QH=;sYP$pcqtRoxg?ZK@CWy{=P7(uI7%TOp; zP-^!0wmMVv-f2E>6tEj7ZTG#-KaZMuUUgl1|nl&p%3Dc8tZ4 zW{0iAY38oin5YwiQlKRrH8RP-h95fX$>v!l2*6R~)3vTQ7V(gjstAxGVc>U<8Jwb) zPTqZIfoIV>X`vA2EuAW0Ghj||3;hwn0w`nHnL~5Xr-xuSDNmuyhoZWBBa|hf3)-7$ z6nhe93c?Vv(WT4=mKowy$9Fu8Y)h5yEW6z&zzB7;Yf(a|ei#jb>!ayFWo?MkgWxQK z47{-ws_k4#8xv#$x229MEUK#x*X1k=2QLLnaWhYREFj!ta9&)3I+w+wuB-hQ0SFLZ zlvuP9c*O0k+Bm_8bPyfY2o>Ts&0yRSIg4c@Rv71IVHGS{L3?%!54(HvY;tru5FCHC z9_ER%i7@?-Tq&gCLBVg_3g3?9Gu6P$T^70*)YqUQTN$IHtc4g5UG7WN_J&c!4-lZ& z0a=#~p%2D>Wvx?z(9bP0Z<&FgpEnI^CYsg{+)}t}Teb>kj&)7NNmPz4Zv@MJA2cA4 zE{uQ3IbdMxWrxK|%90Rdmx)yBJ3FI$YLuF4DF~35POQtBilKK{44PuvYIHjt?~mW& zzNwc$LazTnX6dO-hE|>Wu0KO)5xDdvCq>WTfkeI85j!LDvSNHy0&TTnCpr_Y@_=eYt;}dhqY5=4^QRl&pzt9Bed!EmviR=h>B6ynC7MGc`x^9c*)$$|imA)E z9KmcfaDlPY6j0i|;UW8=8oO5$aRyZaYTM*qBd?3;u=u(KdjqYJ_fLd`tRoym(-gX) zqoT2Ua$jR%Ibg0>jte$VWiyOhLaYcnGe^pQ(V0O%I}YnENL$+J%d>ulP(v~JZtnH_wYk$}A_OsQn5BbzOkG2(!baa2N({4d%BrLdzn_qpUhmGmod2kf3s)xrh|=VU=smdZ ze#hs3hAI5A(;4e45x>FbZjXU=hACbM{;p^HFvP31DFz6_lHCVuZC63Xv9`wzN@Y6rcuoPF<~3V<@&m2~m3D5&4GW7GA+XXs{sPo!wDK z85d-&4Og)(j6Q8x3f?Ooxm7VJf?Nw>3_s3fV9y_1xSDfCy31yBhkr2LI_&)xUpcLxXfuNl6z9z^w)MF}E8U)#3YWS4&8 z{-CVR?>0{F?ccm>oP#mMTY-&w90y~vwccFmV3Wd60@~aufc|xzwLI_AA^-goYhcMf z>+D@$bjnFLRX|X?6oMyaW_}(z!Ys&@5~HmlWUY|}!wJnBP8YPsWvf1%(iPjQZ2#s7 zd=-ANqy%pCwL5&H8Tzs{Ux(<1et1ny> z?C%$W*FgAI%!nl0a{QuH&7L*cr$DOVP-67{8fQkKPfPD$L+Lv zSnj#tSMG<%-tcmKzH8dSPFO)VC^+Dw0|si;bY^#=`Ilum3dEF5!JrA9J z^7-aQuXu7vwaQBlnT>)~G|scmodeOzMFBpiJ_`6WePZh+=vMX276uFz4Vd%}>sndc z95j(>Uq_*mC-r*$6iUb)5mCYRy8>n-Y?K==}9iFFRN zB_u(i5p)JpS@Is*ArpnM&nOOwsI6t6IAmTNaVm+)*gWI?2fN{+=&1n$oGYcUGS!0y znn-1azfTgI zyHQk7RQGW=l@WF&jO?B1KXJa9;4BdKcfcpq35}=O+x=GE;TGw}Ub3M+AbPW8_LG;zZ%{IenPEAQ0yCE`_ z5medk+}GQkcA+x*kGZgwAC&01r6-zspCxwld`4~iEZGot%8<4p%sS7d>FR_YB` z1Ifjyuvj`fc|U|FGJ>_SBP*e_IMD*V%9fftjgs&{b6*4#VT3Vun6n`CvL$#d*2ygL z)7eoDSMZ1NGifW#;&EW?%%%0BG5R6&cx8T(iz?c$ah{_eCRo%Dp%dN0c9w$xeo))f z!{R2?4ug`a98BH;1&H}cNC!iP7dTNKFKcpxcOl6#wP-SCOy% z!JYwOsHXEGr4S3cKrNjJ=%MF4T z@!bVaWe=0&6`nIQ;)FZc{l;u(ho}|4c%t0S8wEmM$g~?uCNTxxtk^R4o;IIHXg4Nb zZhIyY?230y#03^WP!{XWxKemhpfBjbwIDOpx8d|`8Pt~dI`s(SzLBSax8yVhRmu9{ zw$*00x8`h$)GaBWP=7&dA{3Isa5b890UcZ}9{lKpxjTOUjiBd@0mQR5q$sBg0u@Iy zwll8RkI|Pv!)|-}!4Q;*3w)M>CtQ|YfuY*dE7B89}m%)-8C#3~yUl6@M z@$xCS^_0V!62E%u6hMI}Baijc^H8CqqH=??%n$8DrN(@_lxx_H?j+3I+s>0uS4W-> zq0;-tBt+ZUCJDUZPCC#K`72}xS)J822;Tq5LaYD!CkRo6su~3oN zg&ag$fC3ZxSR5uvsAWN7eFh2^)f87O^;9TTDscs|OpfUC5ghp1K49VjDrt>4fKO=L zLxxhlumLD^ZNtMYZExK9PV1gvZsMjXa&<%d^2M4I|F-IW|5xsB0rGy*D60s$dYsg6 zMdyH$$qnp@ADG-=TiGN!GTMc$NnfrNngX>@GClAFT;EKG&5U1Bb*)IV83-ppR>OmP z;mE%>wS^m>hiH7_YYVSpTmR5U_95QXcNL(22X&|AmEtABFNSh^r+yF3YBOQc4!O80 zW_5fFeqSWTBALo%V#({BIC-%Lq^vp1z-V;gLfX5Rua>+TgW*Re+49!T|9sLVQu&ivPtDwn<# zB=%%^7~>Vd1WyRru7m;?SybRpuTdTkp!CqN?qy2_^y(`WSe9uYa9qE|o zcGg`Ff;qg;-$@F&9QY~YAiHAU+kZCb9ucTo{Gb6k#xmH@V2*O=2$V9hv3N!FG!${7 zTp-rnDN>xcgi;~=_Mxb*sFFSwD6?;CdR1Cbi8F3{DehvaW-t1+1l`nx@J2Uuss#I} z7YEQopO?lmS-vrY<18fFZQj;RUYHV1%R8M@0Tkd>SU5a}8CH-r{t1(N7NT#$sq)^w zmVCLx`_@z>k8uq?b|oJ{kgpSC_o3O$%4V2RH#rTN1lnS2uTuJCihJod=< zbK*bD&;BL?vnWrN{SD(*)sBR6Em-F63?LK}2oSl&aN^HYHdZan2q(BF z)D7uS5-tMDl2IECM|7gx%2> zc};Ho`i;kR%Dy)GUpF~6W1Ki*Wd%6#FMi5xBe)PX;SaussO4z3-v?U!u2?q%8AwgJaANO0!?)r6)*$^idCj}7^=gi;C5G{41QB@Q*c8MR zn@7|~dhs0<3%J0Tf=dI8%-XKKYj#sRI^D}q0b6V;M(o(HwO9@8wBzAG+cAYdGz_#F+444xshfBlAac=NZ;*fOTY9TtZ05z^pR5AEUigsEZVK|3P%EN69l9T#rt ztMj^w%zcjN9ADJ>WP_UYuZX&jZR@ji&u>=*IXGQau?w2zE-No+$nTgu_GgZsa&$M# zZYvI)dh>Bd=#L)dh+N*aEL{^5`qD^U_KpbEKUE%6$K7WS@R1G!nIcLmnv5J+Ack3a z2%04+f%{()h=i%kj`tsqCkKKoh%KE`ZGs_5p$zYHg~mcPi@d*l{hE-c6mFY*IgBX* zL6~^BD26Gh26+p)EPJ2IL;Sue$6HLwX#VB^s1h4Q+Hww|5(zlpA&M+;`=Svm=S+;v zJkHERRBWx#%q|GpK%F+Rc$V1Q(oO+`kKp_?Haa3}B9gaq1r)nI#4!25hPe^VDlLJ6 z5!=XtON&dC5`5o5js^}ccFq*%Q{E2ZcqcfHG;3~hzIV1Smr2JnUrzA}qvJS0pHByD zCj6^D|3`QKV-Mkn7l`7C+;{KiDa87OI_;q(s#HJaMS4T(P0Ely98^+ZR5*wy_!G56 z3+J?z-u?HtV2|%ah$ea4I0FGlLpsR$NLzoiQt?zYqY;)WuKzk zX&zj^7gwX#;?y|AsCmpgmqu;LL}sQV%xExYp;~&@;1uwbc*ZH@^yP4QVY8iniz)@m z`NT(X?G-$aA(h8Yb5{k|ODM1t4fD*k+EhMk&aPsfdgTiZ`crm;aE@iffH$0xl)xzk zP;cf1mo~EIT*L1pFr>c)6bMypnY#=C1chd$F z%xSI__^fdrclZD!Ywh;nrQKS)Gv4n`Ga?-lrHjRFhZVaU8$}1Fr&DC&0+5EHg+pD* z&pKO@6Taone5>3KFT+$B7Il<7`8grSj`|R;58(C6d48Z%;pV6 zj;G<~o22D(mZ@K0+17Z31aLV+Ib~<-!z5SSzQzTB0}{rh&2duz%ly zaG}^#dJ9k$#eoF^;`w!0|1(z1zu5!@L z@tL*vL%QefR>d1{NE>i|3C`dpl0@?KUi{TkiN6mGNRUDey67%i8-Y4@?C?4BK3S) zfr7HErec}l`_~GWBpfXk`;cTxqhQ@?lDsP1%O4g~b66sRNmD#`1VWS0+t5BO78E2& zICkZ`iPxc*m11BQxRt7dE1Ik0(P7<}s}!ezaiQ@+*Mlw==xGFmqi$4i>jy2&9mUsA z*j>?_P%uwoz{pMh_#KrelvNTR1Opo6mb0SRdK0M!Onk`Fp z=ys4!Z0vaFCTK~5b`EdIQS#2A*Qxqp3-@B7aA|=0WBE1wz(P~(nkuXl$tH%v&|#9R zeLm0olbua(?JgZv2G?R6yz3gVQMwP#Y?)mq-k6@gOK|{k8!R#T#dqf~3JgcyYV_!1 zp9v$!CMgIg^wGUhsG`m7QN0#1VZJ^W5m6TdZ-x>ULth(W{8-URkIild7h~&lW-x6# zkamVW=Fm$^>gUSsTS%jcc8$w;GJ85Mm6ERkFl=0h8YO#a*X7vZdhL(NZ^$yXf-l)ch{DbY`+M4q6{fN>WVq;uQz|Q)ZP2YT2wh+vZ+$wOqNyK`2r(RlH>uebaK2avbVcg z{@;W^5h;qUc)ExRI?u}9`&={vL4h#9%kfVg8oSDKpXrtx)=Dkv95RS`c6_Ya%CPQC zTS5MSS`B|Ys|SBOr^kwpi#7i^XAT5X7Z2tT*1m^K5{>uKVM+tlmjz}bI(8LGIh*ms zsMRF~)Z zhf64Z9SiFjJH1?Ww#3?_{~Ehqr&!d1@{PteLg{| z77qv)uM`QvK+3m{7!R~TPcnJ&7Vd@$JSpSW?&Q|)()t24_zF+GMe1DJe9u=JL((pz z4@A;xoiw;3?LGCEciG5$Z{N|`rA>OUUZZTmgJoTfSjMXtou~^{@2Gdt3#}aVPkp&$ z;<#mYqWv~IR4PWq6R@TK>G(xHnxscc2G>Kz zna3IzOUIMP6YyJPT55w=uM}j6{e%$j8MAVCg2K`y>GEQHGW+Q1C~P&o&OS8KcHC@N z=WVu!LBgQ8k675M3KmokUnj4A2`EwxIHITBFM{dT(;41?F>3Zo@~au76RvQJs*KoS z&L@-VLeWtdWPLNQgrr$_l(4LdjNv_DW?{dFzQj%)S2oXPWW_8#V2>5y%Hx-?Of->d(WT$~az&0U;asF!k=o??sn0dY zP~Sai?n7|WSX9ty2<<9(n`Ys=AX@RNRjzxYcMjsFZ?*klo(9`Xy0pz%+dO3^(+0== zbA1P2Ogj6>A;Xc#xtnp7B~iZ?OK=h>aDmEqi5QqA&V7UYaQwbvoMw%fid2k?v=$&W zU9LC1N7!8#Q-WfmkA|V1){F$W1nSN@5^O7TnxTnpys|30Y$U>gDEnU0u7`$EzCUgxKF=SKK zc(M!e{m6AkXWHEu3NF(2SA@7<23J^(Jg^;%h5KGp(c)gN$N7PNs6sUOs-M(%hY-0? z|B;LE-P5z_yS}s1J{j;76a!AP{;PNwe>?_)&boGne>lMWCEi7uGGMK$fW+GXaJzP@ zLeKG9htxxEMuTA+D1<>_B7;wzX8q{haH4_P(6W0v8!dhg{dEgbRwR;)&j-;kT{BT* zGF5alYiw*J#lFCK_w@1W)i+2V*HX%u9(Z`}>My23@3YcyD46nzA%%NuA6 z$lONl=$>A5cNf{XGkwN zKJmz+b(iE7?Za|mYx@aj!F+AgUP^!_!U^+IR_LR7^Wd6_?3V!V5M8Vknv-+Y*0=VB z3RDkWb~q(Xg>VWlaH=;l$s&6kowW8sh+In-9=`2&@$jt{s5oin8d<4-abf1&S1-yY z4Xll-Q5$CpVd1vYSL)4;BBv`+o2Uw73krO-6KUK|T~D`hx1+))!2)*!D_zF}$3nUF z@+Bco^6H5c!eU*o;#dsv6N7QlCIKiGMYk#s&zjCk;|@N&6P?8zHiT>2<9Z~6OW+dy z1;en?LH?maVakQZ=w<717oPTVD5{odQy#~CajBt5Rs?}0C1?oiNK3OWSt#y7$R%ayCbDQ7oAH<-&`Wp2>)fn@T+)hdW? zvE+)d2_$+7ALBDazH-i|WSMsT%KI8p;uxa*y6SzABt(4(r{>`#y^}+@uNBzb65Cdz zz%0=Yndh4^T4e5FymIOP2e;OLU$IhxNx)$Py!MR08zX)l`2XVJ z^~^~xQbAU_TL8%u;DbF~QB3)XgcU}tLY7)W0SyEOdbQ!8*+P<|dL`kJ9q|#!JE2iF z2P|F)Gcm)p=B!P3ckkv1x081a-vK`zC7nzWwj4fZ4YttY{*0j83 z`PT;>OuT#X3hZf2Y|#0OO*KdOdF<`w8GXTMqD!jidZDjP_B-7vFClC@%wCpeyiVBR z-jHXmyT>GNns9^GS}Ruz7(N+Gs|YythV2@4+Vsb`i=eGpP)ZXpdFz-;FN8{;cCt`v zc+QT8%U1bDX*pG@Uj@NNt;c*Ds=wF$3*_JHS9k(r_YmL_=>d2n_*Y@vV3A``LM;>6=Nn|z zre+N07A%UrbNF+fy2fh#6N|1jjqmfH-t*^9**oh)QB;1kEqHS}+ypo@-}EWd{rd6h z%$flx&-P89`bb8uk&YOaJsvhT3Wg!wx(1MRS$J~<4L!=WM+XbG8e#Rw9dqM9!@ z+#_6QHns5>W898fQL8nHugDl&2EBr0Q&x_YDt@cktT5=HQP5iCd`p4gHB$_A!2NZi zfd&6%=r+PKcF zcD>}A2!}ZrljP{g7lSURAIQNm87b5}hmrWXJFAsVr&+soJYUbIW<3f`8Rn&64AN|n zSdEEN^c|s2!F}}qI+8?SVwkqY15P7FqL;E!ycf$J%{gv!1HO@T*!_;91hNgu4&Yv_ zLVv=T^B%)U-s|Imj%(pjRp^!<7P~u*P@4{oI(<@|8!tD9aMICh#2eS4$eGG3v%|!D z3A9hb5HtqpqehMMa#N!Ts_sj&kZ`-;{^vSa$2KvUzQTu(^Rn+6Ub!urJ5;1XyfGF+ zPk&ug5Jz{R?Xt?FQ>0Rd;JiS)`RxM2aDHoU{Tt$KM~`fJ4=u@MHp~=H1h{{0>(l^Z z)`#oM8@Fg94%5>@ozPzIKn4u?Z9^Kdq zb>z6+;*Il{_Z$%8;%)VaMOgBcyqA`}UcP78_o$yfdftM9!cK-_c98twa zHqXs$;lCQr75r$Jq!!*D1TBMN$&{KKiwJy76aO*8aAD0)##01^2jiQZ=S6PyL9z`dPCX(PcIvRFR%Q%oq&J*9@-?yiy6KV#!b`ri50d zRQ+HHJA+XuO_7QOd(_ieE+CfY<*sY!`#?Q6B zy5398or>DtM&>Pt;fqQzX%#y7TO~D@!Q8N`jsznSaHVV@QII_GY`mUV{igy`NP(A}J%X}?5&&wsZWPQiBz zc?)>svRp9m2Q!__B)myK^VmyYTJ!dL1hE0?7sFX%XPzI+HQT~=qMN2?g-TJ)yv&^o zP-?RkV&wTaPG0K7dqAKQ@lbwGb9HunYmN}@dk%i*Y6CgtG26<8lS=_zY90qI7DfB}ire6El{#mc z;nEwoLQ&~Dc`v!lIOL$!8Cqc^q1h(sj5ncZeba?%Dy69??%`Jp?ZZZ>TN*R4Ep}sI zw{?js2HG>`K26%gY%2}$aMg~J`MfG&2;w$5vc%2GLM?tmm92FD7>Lt&#@luqnUb7n zMTH2f?x*aH%6_dW3+wKB{N5x-bY8Q7_w;nlC+dFhl!&BN&Ff1*S?}lyRicHzJ65=f zO#y?AA+n$PMh7kEH#NpfC>Lnwc{{Z)Vlk`VfVXgIAuJw^YU76nsxsw4)XG69SOl3M zXsToc7Sjz)_Km2o@OS4l8Pk|X#8Bcodlqp{eX(rt5%t!Csf6D|iO(IUR*jxn8u2KO zQ2ElC42(){N+?>x3X&7oo+mgooiaS zIvzb95Qu_Akw-&VCsEKR{6ZwE1sQ^Dq&q8pmb6%CggTRbctH9@U2Nq8LLNW}pd=Wl z)2ye3h=#^9CL^`Tj0Z|w$>T;#V)NRoh|No=l@&1z-e+UkRuibQ&9wG2&Ky}hRs@pk z&{u^6Votln-4}O_cY$AM;?jnlE9nfz_he1h*m+5^E44Gg@Gffy)%TbyGEpeMe`{2) z5*7nD8Bstj#>{{T1EU_vd5^`35WIP5gh(GPDeFoGC)=FJWY{fZomyNDEx}y7*y@Q+ zE!*X`kfss8HWb@hx{mGnzB$zNE*{{roGJ) z74vfpFx-*xmyL|>aP{5|H_RRB2nK&RUyU)Q5Nyxk0h)N4isUHfG~i4EXs`76b>R{p zaTE$B^0yjYa0Dz4T!#L-BNMU4i_Hbr=KTo*#^mn;q#H-@)7~#Sw!WzJVyR2QRWHPVe)!r_j!+mZ)-gCwne;e2sekE2s#u zBB@|AlL)>RmIfI%!jyQ9yJ=36Y=kjt3Ss$!7>SBfYIXZ3iz10mkjP@voHl-|)^tIh z#IY2OH0SyP1y$O`Gex+}Lv)?dR?e$O)x$1IK~cET zQ>(H{FhP9X=x~9~8;=t1n2V;CyWI65+}B__iGq-W+!Er~oYCPvy%Po`*xl&OqhjBD zAY4Ky{Ib^XLF8{~54CQ6@9!S7KA#DyA;cCC4>(OU)A_lDLI*%?VKI zVF7!a^&(NWCGBf}7T177CBQTaEqJ;4=I>8sWt6@0_tP^XfDa+y^Fs#!aMb<(TLYk) zx#~9>06Tw+{0|I*1`1Fvhk^oP1X%b0y#E*V9xyumxR8KO1iyck6;%?Xmy{C&9Mu1N zvW7l2DgnShC<8udfX|;-p6~a!#s5ntD<~%^CaS3PLRRdr2;|R*0khqY3km3(U>e}N zwVm0c5a{ypIj35H*oP5cau-UI%12Jj*Mk^K9u z))ybJ{`#KRAIyIO{HY7|XQcJ#IqF>voJ9l7^EQBze{cRjuUcPVz+e9f@cF6^u)cF~ z6?Akk0mQyF)&CjT`8ng>v6_7`fMyBsA^DRIaIf`s2IS#4jFNwr;g6Th=XhX6ZYx@V zyea@v)Bg=m7ho&?4W782u7QQ2G9diCgteuijJ377qs{N3@iw)WdI2E!fL{82L-^0D z))&xce+LbS`D@{54>(sQW@=$5sIPBmZ!fEBrEC1B(!%q+kHG7QeUG4h2e9Y;J?{hn zQPbb#UG)!X4uGk{$kf;o5I!3aO8)nGSMbC)-2qeyHX!eee`XwTul2o0`YrVH_LKmK zMOgf|jOV*DHmd+K4g{#3?<2;aSFJBS#&6MOtd0L`EsWV6g`ordOsoK9{(da#&#TtA z6CeWen_Bpr?A`B+&$(K^f(v-Wjsc?p(Vu{Td#x`v;OB2J0fzz|bS*4?kG9e&6WRl) z%y)o+>F@1i2j~~SK@+mJcK9y4VI!++Y6Y;l{uJAI-UTFP8_1>rZA1zv>UYV6Kd)L} zU(Vk`|L6juE{6J!{}(;|Icfk-UP(0oRS1Ae^Cu+WUhA7G{9DvN9*Q5>-!uLDig>QM z`zLg*ZvsF><~J4bqgwyl@bg^b@F$)FU_k#3-rt)3zbPI*uZ`#Wc|TdaRDa9z&m+!r z*_@wnvv2-y^87IX|8@fXYyQ4(ZatU1`3Y$J_P>kZJV*JS>iZ-4{rWB&^T+jl9<$W_ zTPeSXuz8;Nxrof4$!mSne@*(7j@&*7g7gZzZ2H25WNe}Vn+a>?{-Z~R_w z&m}m1qM{o93)FuQ46!nEyV!!gHSIhx~u?BuD(h^XuU8ua5jb=X`!t`zNPZ^#A7k{c!c% zr}ii2dCvdF{Edh0^GrW?VEjq2llLzO{yIwiz68(R$9@tF6#hc+=PdDW48PAy^4#6y zCy{UIFGRm|*MEB4o^PT5L=LX_1^L&`^au3sH`JdO;`!F)Pb#&ybLsOPyPvR& zHU9+rW5D=_{k!J{cy8DK$wbij3)A!WhriU_|0vLNTk}tv^QK>D{sQ}>K!4o+VeETu zbo_}g(fTj&|GNqDd3`;%qx>XV1sDeYcrynq2!C%?c_j@FcnkclF2e+b1PDE++xh+1 F{{tUq7iIte diff --git a/testing/api-client/pom.xml b/testing/api-client/pom.xml deleted file mode 100644 index 5e33d55..0000000 --- a/testing/api-client/pom.xml +++ /dev/null @@ -1,117 +0,0 @@ - - - - testing - com.maptology - 0.0.1-SNAPSHOT - - 4.0.0 - - api-client - Maptology Java API Client - jar - - - 1.7 - ${java.version} - ${java.version} - 1.5.15 - 2.7.5 - 2.8.1 - 1.3.5 - 1.0.0 - 4.12 - 2.9.9 - UTF-8 - - - - - - maven-dependency-plugin - - - - copy - - generate-sources - - - - com.maptology - api - ${project.version} - swagger - maptology.json - ${project.basedir}/src/main/resources/api/ - - - - - - - - io.swagger - swagger-codegen-maven-plugin - 2.2.3 - - - - generate - - - ${project.basedir}/src/main/resources/api/maptology.json - java - ${project.basedir} - - - - - - - - - - io.swagger - swagger-annotations - ${swagger-core-version} - - - com.squareup.okhttp - okhttp - ${okhttp-version} - - - com.squareup.okhttp - logging-interceptor - ${okhttp-version} - - - com.google.code.gson - gson - ${gson-version} - - - org.threeten - threetenbp - ${threetenbp-version} - - - joda-time - joda-time - ${joda-version} - - - - - - junit - junit - ${junit-version} - test - - - - \ No newline at end of file diff --git a/testing/api-client/settings.gradle b/testing/api-client/settings.gradle deleted file mode 100644 index 55640f7..0000000 --- a/testing/api-client/settings.gradle +++ /dev/null @@ -1 +0,0 @@ -rootProject.name = "swagger-java-client" \ No newline at end of file diff --git a/testing/api-client/src/main/AndroidManifest.xml b/testing/api-client/src/main/AndroidManifest.xml deleted file mode 100644 index 465dcb5..0000000 --- a/testing/api-client/src/main/AndroidManifest.xml +++ /dev/null @@ -1,3 +0,0 @@ - - - diff --git a/testing/api-client/src/main/java/io/swagger/client/ApiCallback.java b/testing/api-client/src/main/java/io/swagger/client/ApiCallback.java deleted file mode 100644 index cf0d325..0000000 --- a/testing/api-client/src/main/java/io/swagger/client/ApiCallback.java +++ /dev/null @@ -1,62 +0,0 @@ -/* - * Maptology Service - * Maptology Service - * - * OpenAPI spec version: 0.0.1-SNAPSHOT - * Contact: nes-admin@uni-due.de - * - * NOTE: This class is auto generated by the swagger code generator program. - * https://github.com/swagger-api/swagger-codegen.git - * Do not edit the class manually. - */ - - -package io.swagger.client; - -import java.io.IOException; - -import java.util.Map; -import java.util.List; - -/** - * Callback for asynchronous API call. - * - * @param The return type - */ -public interface ApiCallback { - /** - * This is called when the API call fails. - * - * @param e The exception causing the failure - * @param statusCode Status code of the response if available, otherwise it would be 0 - * @param responseHeaders Headers of the response if available, otherwise it would be null - */ - void onFailure(ApiException e, int statusCode, Map> responseHeaders); - - /** - * This is called when the API call succeeded. - * - * @param result The result deserialized from response - * @param statusCode Status code of the response - * @param responseHeaders Headers of the response - */ - void onSuccess(T result, int statusCode, Map> responseHeaders); - - /** - * This is called when the API upload processing. - * - * @param bytesWritten bytes Written - * @param contentLength content length of request body - * @param done write end - */ - void onUploadProgress(long bytesWritten, long contentLength, boolean done); - - /** - * This is called when the API downlond processing. - * - * @param bytesRead bytes Read - * @param contentLength content lenngth of the response - * @param done Read end - */ - void onDownloadProgress(long bytesRead, long contentLength, boolean done); -} diff --git a/testing/api-client/src/main/java/io/swagger/client/ApiClient.java b/testing/api-client/src/main/java/io/swagger/client/ApiClient.java deleted file mode 100644 index 8bef545..0000000 --- a/testing/api-client/src/main/java/io/swagger/client/ApiClient.java +++ /dev/null @@ -1,1361 +0,0 @@ -/* - * Maptology Service - * Maptology Service - * - * OpenAPI spec version: 0.0.1-SNAPSHOT - * Contact: nes-admin@uni-due.de - * - * NOTE: This class is auto generated by the swagger code generator program. - * https://github.com/swagger-api/swagger-codegen.git - * Do not edit the class manually. - */ - - -package io.swagger.client; - -import com.squareup.okhttp.Call; -import com.squareup.okhttp.Callback; -import com.squareup.okhttp.OkHttpClient; -import com.squareup.okhttp.Request; -import com.squareup.okhttp.Response; -import com.squareup.okhttp.RequestBody; -import com.squareup.okhttp.FormEncodingBuilder; -import com.squareup.okhttp.MultipartBuilder; -import com.squareup.okhttp.MediaType; -import com.squareup.okhttp.Headers; -import com.squareup.okhttp.internal.http.HttpMethod; -import com.squareup.okhttp.logging.HttpLoggingInterceptor; -import com.squareup.okhttp.logging.HttpLoggingInterceptor.Level; - -import java.lang.reflect.Type; - -import java.util.Collection; -import java.util.Collections; -import java.util.Map; -import java.util.Map.Entry; -import java.util.HashMap; -import java.util.List; -import java.util.ArrayList; -import java.util.Date; -import java.util.TimeZone; -import java.util.concurrent.TimeUnit; -import java.util.regex.Matcher; -import java.util.regex.Pattern; - -import java.net.URLEncoder; -import java.net.URLConnection; - -import java.io.File; -import java.io.InputStream; -import java.io.IOException; -import java.io.UnsupportedEncodingException; - -import java.security.GeneralSecurityException; -import java.security.KeyStore; -import java.security.SecureRandom; -import java.security.cert.Certificate; -import java.security.cert.CertificateException; -import java.security.cert.CertificateFactory; -import java.security.cert.X509Certificate; - -import java.text.DateFormat; -import java.text.SimpleDateFormat; -import java.text.ParseException; - -import javax.net.ssl.HostnameVerifier; -import javax.net.ssl.KeyManager; -import javax.net.ssl.KeyManagerFactory; -import javax.net.ssl.SSLContext; -import javax.net.ssl.SSLSession; -import javax.net.ssl.TrustManager; -import javax.net.ssl.TrustManagerFactory; -import javax.net.ssl.X509TrustManager; - -import okio.BufferedSink; -import okio.Okio; - -import io.swagger.client.auth.Authentication; -import io.swagger.client.auth.HttpBasicAuth; -import io.swagger.client.auth.ApiKeyAuth; -import io.swagger.client.auth.OAuth; - -public class ApiClient { - public static final double JAVA_VERSION; - public static final boolean IS_ANDROID; - public static final int ANDROID_SDK_VERSION; - - static { - JAVA_VERSION = Double.parseDouble(System.getProperty("java.specification.version")); - boolean isAndroid; - try { - Class.forName("android.app.Activity"); - isAndroid = true; - } catch (ClassNotFoundException e) { - isAndroid = false; - } - IS_ANDROID = isAndroid; - int sdkVersion = 0; - if (IS_ANDROID) { - try { - sdkVersion = Class.forName("android.os.Build$VERSION").getField("SDK_INT").getInt(null); - } catch (Exception e) { - try { - sdkVersion = Integer.parseInt((String) Class.forName("android.os.Build$VERSION").getField("SDK").get(null)); - } catch (Exception e2) { } - } - } - ANDROID_SDK_VERSION = sdkVersion; - } - - /** - * The datetime format to be used when lenientDatetimeFormat is enabled. - */ - public static final String LENIENT_DATETIME_FORMAT = "yyyy-MM-dd'T'HH:mm:ss.SSSZ"; - - private String basePath = "http://localhost/api"; - private boolean lenientOnJson = false; - private boolean debugging = false; - private Map defaultHeaderMap = new HashMap(); - private String tempFolderPath = null; - - private Map authentications; - - private DateFormat dateFormat; - private DateFormat datetimeFormat; - private boolean lenientDatetimeFormat; - private int dateLength; - - private InputStream sslCaCert; - private boolean verifyingSsl; - private KeyManager[] keyManagers; - - private OkHttpClient httpClient; - private JSON json; - - private HttpLoggingInterceptor loggingInterceptor; - - /* - * Constructor for ApiClient - */ - public ApiClient() { - httpClient = new OkHttpClient(); - - - verifyingSsl = true; - - json = new JSON(this); - - /* - * Use RFC3339 format for date and datetime. - * See http://xml2rfc.ietf.org/public/rfc/html/rfc3339.html#anchor14 - */ - this.dateFormat = new SimpleDateFormat("yyyy-MM-dd"); - // Always use UTC as the default time zone when dealing with date (without time). - this.dateFormat.setTimeZone(TimeZone.getTimeZone("UTC")); - initDatetimeFormat(); - - // Be lenient on datetime formats when parsing datetime from string. - // See parseDatetime. - this.lenientDatetimeFormat = true; - - // Set default User-Agent. - setUserAgent("Swagger-Codegen/1.0.0/java"); - - // Setup authentications (key: authentication name, value: authentication). - authentications = new HashMap(); - authentications.put("admin", new HttpBasicAuth()); - authentications.put("device", new ApiKeyAuth("header", "Authorization")); - authentications.put("user", new HttpBasicAuth()); - // Prevent the authentications from being modified. - authentications = Collections.unmodifiableMap(authentications); - } - - /** - * Get base path - * - * @return Baes path - */ - public String getBasePath() { - return basePath; - } - - /** - * Set base path - * - * @param basePath Base path of the URL (e.g http://localhost/api - * @return An instance of OkHttpClient - */ - public ApiClient setBasePath(String basePath) { - this.basePath = basePath; - return this; - } - - /** - * Get HTTP client - * - * @return An instance of OkHttpClient - */ - public OkHttpClient getHttpClient() { - return httpClient; - } - - /** - * Set HTTP client - * - * @param httpClient An instance of OkHttpClient - * @return Api Client - */ - public ApiClient setHttpClient(OkHttpClient httpClient) { - this.httpClient = httpClient; - return this; - } - - /** - * Get JSON - * - * @return JSON object - */ - public JSON getJSON() { - return json; - } - - /** - * Set JSON - * - * @param json JSON object - * @return Api client - */ - public ApiClient setJSON(JSON json) { - this.json = json; - return this; - } - - /** - * True if isVerifyingSsl flag is on - * - * @return True if isVerifySsl flag is on - */ - public boolean isVerifyingSsl() { - return verifyingSsl; - } - - /** - * Configure whether to verify certificate and hostname when making https requests. - * Default to true. - * NOTE: Do NOT set to false in production code, otherwise you would face multiple types of cryptographic attacks. - * - * @param verifyingSsl True to verify TLS/SSL connection - * @return ApiClient - */ - public ApiClient setVerifyingSsl(boolean verifyingSsl) { - this.verifyingSsl = verifyingSsl; - applySslSettings(); - return this; - } - - /** - * Get SSL CA cert. - * - * @return Input stream to the SSL CA cert - */ - public InputStream getSslCaCert() { - return sslCaCert; - } - - /** - * Configure the CA certificate to be trusted when making https requests. - * Use null to reset to default. - * - * @param sslCaCert input stream for SSL CA cert - * @return ApiClient - */ - public ApiClient setSslCaCert(InputStream sslCaCert) { - this.sslCaCert = sslCaCert; - applySslSettings(); - return this; - } - - public KeyManager[] getKeyManagers() { - return keyManagers; - } - - /** - * Configure client keys to use for authorization in an SSL session. - * Use null to reset to default. - * - * @param managers The KeyManagers to use - * @return ApiClient - */ - public ApiClient setKeyManagers(KeyManager[] managers) { - this.keyManagers = managers; - applySslSettings(); - return this; - } - - public DateFormat getDateFormat() { - return dateFormat; - } - - public ApiClient setDateFormat(DateFormat dateFormat) { - this.dateFormat = dateFormat; - this.dateLength = this.dateFormat.format(new Date()).length(); - return this; - } - - public DateFormat getDatetimeFormat() { - return datetimeFormat; - } - - public ApiClient setDatetimeFormat(DateFormat datetimeFormat) { - this.datetimeFormat = datetimeFormat; - return this; - } - - /** - * Whether to allow various ISO 8601 datetime formats when parsing a datetime string. - * @see #parseDatetime(String) - * @return True if lenientDatetimeFormat flag is set to true - */ - public boolean isLenientDatetimeFormat() { - return lenientDatetimeFormat; - } - - public ApiClient setLenientDatetimeFormat(boolean lenientDatetimeFormat) { - this.lenientDatetimeFormat = lenientDatetimeFormat; - return this; - } - - /** - * Parse the given date string into Date object. - * The default dateFormat supports these ISO 8601 date formats: - * 2015-08-16 - * 2015-8-16 - * @param str String to be parsed - * @return Date - */ - public Date parseDate(String str) { - if (str == null) - return null; - try { - return dateFormat.parse(str); - } catch (ParseException e) { - throw new RuntimeException(e); - } - } - - /** - * Parse the given datetime string into Date object. - * When lenientDatetimeFormat is enabled, the following ISO 8601 datetime formats are supported: - * 2015-08-16T08:20:05Z - * 2015-8-16T8:20:05Z - * 2015-08-16T08:20:05+00:00 - * 2015-08-16T08:20:05+0000 - * 2015-08-16T08:20:05.376Z - * 2015-08-16T08:20:05.376+00:00 - * 2015-08-16T08:20:05.376+00 - * Note: The 3-digit milli-seconds is optional. Time zone is required and can be in one of - * these formats: - * Z (same with +0000) - * +08:00 (same with +0800) - * -02 (same with -0200) - * -0200 - * @see ISO 8601 - * @param str Date time string to be parsed - * @return Date representation of the string - */ - public Date parseDatetime(String str) { - if (str == null) - return null; - - DateFormat format; - if (lenientDatetimeFormat) { - /* - * When lenientDatetimeFormat is enabled, normalize the date string - * into LENIENT_DATETIME_FORMAT to support various formats - * defined by ISO 8601. - */ - // normalize time zone - // trailing "Z": 2015-08-16T08:20:05Z => 2015-08-16T08:20:05+0000 - str = str.replaceAll("[zZ]\\z", "+0000"); - // remove colon in time zone: 2015-08-16T08:20:05+00:00 => 2015-08-16T08:20:05+0000 - str = str.replaceAll("([+-]\\d{2}):(\\d{2})\\z", "$1$2"); - // expand time zone: 2015-08-16T08:20:05+00 => 2015-08-16T08:20:05+0000 - str = str.replaceAll("([+-]\\d{2})\\z", "$100"); - // add milliseconds when missing - // 2015-08-16T08:20:05+0000 => 2015-08-16T08:20:05.000+0000 - str = str.replaceAll("(:\\d{1,2})([+-]\\d{4})\\z", "$1.000$2"); - format = new SimpleDateFormat(LENIENT_DATETIME_FORMAT); - } else { - format = this.datetimeFormat; - } - - try { - return format.parse(str); - } catch (ParseException e) { - throw new RuntimeException(e); - } - } - - /* - * Parse date or date time in string format into Date object. - * - * @param str Date time string to be parsed - * @return Date representation of the string - */ - public Date parseDateOrDatetime(String str) { - if (str == null) - return null; - else if (str.length() <= dateLength) - return parseDate(str); - else - return parseDatetime(str); - } - - /** - * Format the given Date object into string (Date format). - * - * @param date Date object - * @return Formatted date in string representation - */ - public String formatDate(Date date) { - return dateFormat.format(date); - } - - /** - * Format the given Date object into string (Datetime format). - * - * @param date Date object - * @return Formatted datetime in string representation - */ - public String formatDatetime(Date date) { - return datetimeFormat.format(date); - } - - /** - * Get authentications (key: authentication name, value: authentication). - * - * @return Map of authentication objects - */ - public Map getAuthentications() { - return authentications; - } - - /** - * Get authentication for the given name. - * - * @param authName The authentication name - * @return The authentication, null if not found - */ - public Authentication getAuthentication(String authName) { - return authentications.get(authName); - } - - /** - * Helper method to set username for the first HTTP basic authentication. - * - * @param username Username - */ - public void setUsername(String username) { - for (Authentication auth : authentications.values()) { - if (auth instanceof HttpBasicAuth) { - ((HttpBasicAuth) auth).setUsername(username); - return; - } - } - throw new RuntimeException("No HTTP basic authentication configured!"); - } - - /** - * Helper method to set password for the first HTTP basic authentication. - * - * @param password Password - */ - public void setPassword(String password) { - for (Authentication auth : authentications.values()) { - if (auth instanceof HttpBasicAuth) { - ((HttpBasicAuth) auth).setPassword(password); - return; - } - } - throw new RuntimeException("No HTTP basic authentication configured!"); - } - - /** - * Helper method to set API key value for the first API key authentication. - * - * @param apiKey API key - */ - public void setApiKey(String apiKey) { - for (Authentication auth : authentications.values()) { - if (auth instanceof ApiKeyAuth) { - ((ApiKeyAuth) auth).setApiKey(apiKey); - return; - } - } - throw new RuntimeException("No API key authentication configured!"); - } - - /** - * Helper method to set API key prefix for the first API key authentication. - * - * @param apiKeyPrefix API key prefix - */ - public void setApiKeyPrefix(String apiKeyPrefix) { - for (Authentication auth : authentications.values()) { - if (auth instanceof ApiKeyAuth) { - ((ApiKeyAuth) auth).setApiKeyPrefix(apiKeyPrefix); - return; - } - } - throw new RuntimeException("No API key authentication configured!"); - } - - /** - * Helper method to set access token for the first OAuth2 authentication. - * - * @param accessToken Access token - */ - public void setAccessToken(String accessToken) { - for (Authentication auth : authentications.values()) { - if (auth instanceof OAuth) { - ((OAuth) auth).setAccessToken(accessToken); - return; - } - } - throw new RuntimeException("No OAuth2 authentication configured!"); - } - - /** - * Set the User-Agent header's value (by adding to the default header map). - * - * @param userAgent HTTP request's user agent - * @return ApiClient - */ - public ApiClient setUserAgent(String userAgent) { - addDefaultHeader("User-Agent", userAgent); - return this; - } - - /** - * Add a default header. - * - * @param key The header's key - * @param value The header's value - * @return ApiClient - */ - public ApiClient addDefaultHeader(String key, String value) { - defaultHeaderMap.put(key, value); - return this; - } - - /** - * @see setLenient - * - * @return True if lenientOnJson is enabled, false otherwise. - */ - public boolean isLenientOnJson() { - return lenientOnJson; - } - - /** - * Set LenientOnJson - * - * @param lenient True to enable lenientOnJson - * @return ApiClient - */ - public ApiClient setLenientOnJson(boolean lenient) { - this.lenientOnJson = lenient; - return this; - } - - /** - * Check that whether debugging is enabled for this API client. - * - * @return True if debugging is enabled, false otherwise. - */ - public boolean isDebugging() { - return debugging; - } - - /** - * Enable/disable debugging for this API client. - * - * @param debugging To enable (true) or disable (false) debugging - * @return ApiClient - */ - public ApiClient setDebugging(boolean debugging) { - if (debugging != this.debugging) { - if (debugging) { - loggingInterceptor = new HttpLoggingInterceptor(); - loggingInterceptor.setLevel(Level.BODY); - httpClient.interceptors().add(loggingInterceptor); - } else { - httpClient.interceptors().remove(loggingInterceptor); - loggingInterceptor = null; - } - } - this.debugging = debugging; - return this; - } - - /** - * The path of temporary folder used to store downloaded files from endpoints - * with file response. The default value is null, i.e. using - * the system's default tempopary folder. - * - * @see createTempFile - * @return Temporary folder path - */ - public String getTempFolderPath() { - return tempFolderPath; - } - - /** - * Set the tempoaray folder path (for downloading files) - * - * @param tempFolderPath Temporary folder path - * @return ApiClient - */ - public ApiClient setTempFolderPath(String tempFolderPath) { - this.tempFolderPath = tempFolderPath; - return this; - } - - /** - * Get connection timeout (in milliseconds). - * - * @return Timeout in milliseconds - */ - public int getConnectTimeout() { - return httpClient.getConnectTimeout(); - } - - /** - * Sets the connect timeout (in milliseconds). - * A value of 0 means no timeout, otherwise values must be between 1 and - * - * @param connectionTimeout connection timeout in milliseconds - * @return Api client - */ - public ApiClient setConnectTimeout(int connectionTimeout) { - httpClient.setConnectTimeout(connectionTimeout, TimeUnit.MILLISECONDS); - return this; - } - - /** - * Format the given parameter object into string. - * - * @param param Parameter - * @return String representation of the parameter - */ - public String parameterToString(Object param) { - if (param == null) { - return ""; - } else if (param instanceof Date) { - return formatDatetime((Date) param); - } else if (param instanceof Collection) { - StringBuilder b = new StringBuilder(); - for (Object o : (Collection)param) { - if (b.length() > 0) { - b.append(","); - } - b.append(String.valueOf(o)); - } - return b.toString(); - } else { - return String.valueOf(param); - } - } - - /** - * Format to {@code Pair} objects. - * - * @param collectionFormat collection format (e.g. csv, tsv) - * @param name Name - * @param value Value - * @return A list of Pair objects - */ - public List parameterToPairs(String collectionFormat, String name, Object value){ - List params = new ArrayList(); - - // preconditions - if (name == null || name.isEmpty() || value == null) return params; - - Collection valueCollection = null; - if (value instanceof Collection) { - valueCollection = (Collection) value; - } else { - params.add(new Pair(name, parameterToString(value))); - return params; - } - - if (valueCollection.isEmpty()){ - return params; - } - - // get the collection format - collectionFormat = (collectionFormat == null || collectionFormat.isEmpty() ? "csv" : collectionFormat); // default: csv - - // create the params based on the collection format - if (collectionFormat.equals("multi")) { - for (Object item : valueCollection) { - params.add(new Pair(name, parameterToString(item))); - } - - return params; - } - - String delimiter = ","; - - if (collectionFormat.equals("csv")) { - delimiter = ","; - } else if (collectionFormat.equals("ssv")) { - delimiter = " "; - } else if (collectionFormat.equals("tsv")) { - delimiter = "\t"; - } else if (collectionFormat.equals("pipes")) { - delimiter = "|"; - } - - StringBuilder sb = new StringBuilder() ; - for (Object item : valueCollection) { - sb.append(delimiter); - sb.append(parameterToString(item)); - } - - params.add(new Pair(name, sb.substring(1))); - - return params; - } - - /** - * Sanitize filename by removing path. - * e.g. ../../sun.gif becomes sun.gif - * - * @param filename The filename to be sanitized - * @return The sanitized filename - */ - public String sanitizeFilename(String filename) { - return filename.replaceAll(".*[/\\\\]", ""); - } - - /** - * Check if the given MIME is a JSON MIME. - * JSON MIME examples: - * application/json - * application/json; charset=UTF8 - * APPLICATION/JSON - * application/vnd.company+json - * @param mime MIME (Multipurpose Internet Mail Extensions) - * @return True if the given MIME is JSON, false otherwise. - */ - public boolean isJsonMime(String mime) { - String jsonMime = "(?i)^(application/json|[^;/ \t]+/[^;/ \t]+[+]json)[ \t]*(;.*)?$"; - return mime != null && (mime.matches(jsonMime) || mime.equalsIgnoreCase("application/json-patch+json")); - } - - /** - * Select the Accept header's value from the given accepts array: - * if JSON exists in the given array, use it; - * otherwise use all of them (joining into a string) - * - * @param accepts The accepts array to select from - * @return The Accept header to use. If the given array is empty, - * null will be returned (not to set the Accept header explicitly). - */ - public String selectHeaderAccept(String[] accepts) { - if (accepts.length == 0) { - return null; - } - for (String accept : accepts) { - if (isJsonMime(accept)) { - return accept; - } - } - return StringUtil.join(accepts, ","); - } - - /** - * Select the Content-Type header's value from the given array: - * if JSON exists in the given array, use it; - * otherwise use the first one of the array. - * - * @param contentTypes The Content-Type array to select from - * @return The Content-Type header to use. If the given array is empty, - * JSON will be used. - */ - public String selectHeaderContentType(String[] contentTypes) { - if (contentTypes.length == 0) { - return "application/json"; - } - for (String contentType : contentTypes) { - if (isJsonMime(contentType)) { - return contentType; - } - } - return contentTypes[0]; - } - - /** - * Escape the given string to be used as URL query value. - * - * @param str String to be escaped - * @return Escaped string - */ - public String escapeString(String str) { - try { - return URLEncoder.encode(str, "utf8").replaceAll("\\+", "%20"); - } catch (UnsupportedEncodingException e) { - return str; - } - } - - /** - * Deserialize response body to Java object, according to the return type and - * the Content-Type response header. - * - * @param Type - * @param response HTTP response - * @param returnType The type of the Java object - * @return The deserialized Java object - * @throws ApiException If fail to deserialize response body, i.e. cannot read response body - * or the Content-Type of the response is not supported. - */ - @SuppressWarnings("unchecked") - public T deserialize(Response response, Type returnType) throws ApiException { - if (response == null || returnType == null) { - return null; - } - - if ("byte[]".equals(returnType.toString())) { - // Handle binary response (byte array). - try { - return (T) response.body().bytes(); - } catch (IOException e) { - throw new ApiException(e); - } - } else if (returnType.equals(File.class)) { - // Handle file downloading. - return (T) downloadFileFromResponse(response); - } - - String respBody; - try { - if (response.body() != null) - respBody = response.body().string(); - else - respBody = null; - } catch (IOException e) { - throw new ApiException(e); - } - - if (respBody == null || "".equals(respBody)) { - return null; - } - - String contentType = response.headers().get("Content-Type"); - if (contentType == null) { - // ensuring a default content type - contentType = "application/json"; - } - if (isJsonMime(contentType)) { - return json.deserialize(respBody, returnType); - } else if (returnType.equals(String.class)) { - // Expecting string, return the raw response body. - return (T) respBody; - } else { - throw new ApiException( - "Content type \"" + contentType + "\" is not supported for type: " + returnType, - response.code(), - response.headers().toMultimap(), - respBody); - } - } - - /** - * Serialize the given Java object into request body according to the object's - * class and the request Content-Type. - * - * @param obj The Java object - * @param contentType The request Content-Type - * @return The serialized request body - * @throws ApiException If fail to serialize the given object - */ - public RequestBody serialize(Object obj, String contentType) throws ApiException { - if (obj instanceof byte[]) { - // Binary (byte array) body parameter support. - return RequestBody.create(MediaType.parse(contentType), (byte[]) obj); - } else if (obj instanceof File) { - // File body parameter support. - return RequestBody.create(MediaType.parse(contentType), (File) obj); - } else if (isJsonMime(contentType)) { - String content; - if (obj != null) { - content = json.serialize(obj); - } else { - content = null; - } - return RequestBody.create(MediaType.parse(contentType), content); - } else { - throw new ApiException("Content type \"" + contentType + "\" is not supported"); - } - } - - /** - * Download file from the given response. - * - * @param response An instance of the Response object - * @throws ApiException If fail to read file content from response and write to disk - * @return Downloaded file - */ - public File downloadFileFromResponse(Response response) throws ApiException { - try { - File file = prepareDownloadFile(response); - BufferedSink sink = Okio.buffer(Okio.sink(file)); - sink.writeAll(response.body().source()); - sink.close(); - return file; - } catch (IOException e) { - throw new ApiException(e); - } - } - - /** - * Prepare file for download - * - * @param response An instance of the Response object - * @throws IOException If fail to prepare file for download - * @return Prepared file for the download - */ - public File prepareDownloadFile(Response response) throws IOException { - String filename = null; - String contentDisposition = response.header("Content-Disposition"); - if (contentDisposition != null && !"".equals(contentDisposition)) { - // Get filename from the Content-Disposition header. - Pattern pattern = Pattern.compile("filename=['\"]?([^'\"\\s]+)['\"]?"); - Matcher matcher = pattern.matcher(contentDisposition); - if (matcher.find()) { - filename = sanitizeFilename(matcher.group(1)); - } - } - - String prefix = null; - String suffix = null; - if (filename == null) { - prefix = "download-"; - suffix = ""; - } else { - int pos = filename.lastIndexOf("."); - if (pos == -1) { - prefix = filename + "-"; - } else { - prefix = filename.substring(0, pos) + "-"; - suffix = filename.substring(pos); - } - // File.createTempFile requires the prefix to be at least three characters long - if (prefix.length() < 3) - prefix = "download-"; - } - - if (tempFolderPath == null) - return File.createTempFile(prefix, suffix); - else - return File.createTempFile(prefix, suffix, new File(tempFolderPath)); - } - - /** - * {@link #execute(Call, Type)} - * - * @param Type - * @param call An instance of the Call object - * @throws ApiException If fail to execute the call - * @return ApiResponse<T> - */ - public ApiResponse execute(Call call) throws ApiException { - return execute(call, null); - } - - /** - * Execute HTTP call and deserialize the HTTP response body into the given return type. - * - * @param returnType The return type used to deserialize HTTP response body - * @param The return type corresponding to (same with) returnType - * @param call Call - * @return ApiResponse object containing response status, headers and - * data, which is a Java object deserialized from response body and would be null - * when returnType is null. - * @throws ApiException If fail to execute the call - */ - public ApiResponse execute(Call call, Type returnType) throws ApiException { - try { - Response response = call.execute(); - T data = handleResponse(response, returnType); - return new ApiResponse(response.code(), response.headers().toMultimap(), data); - } catch (IOException e) { - throw new ApiException(e); - } - } - - /** - * {@link #executeAsync(Call, Type, ApiCallback)} - * - * @param Type - * @param call An instance of the Call object - * @param callback ApiCallback<T> - */ - public void executeAsync(Call call, ApiCallback callback) { - executeAsync(call, null, callback); - } - - /** - * Execute HTTP call asynchronously. - * - * @see #execute(Call, Type) - * @param Type - * @param call The callback to be executed when the API call finishes - * @param returnType Return type - * @param callback ApiCallback - */ - @SuppressWarnings("unchecked") - public void executeAsync(Call call, final Type returnType, final ApiCallback callback) { - call.enqueue(new Callback() { - @Override - public void onFailure(Request request, IOException e) { - callback.onFailure(new ApiException(e), 0, null); - } - - @Override - public void onResponse(Response response) throws IOException { - T result; - try { - result = (T) handleResponse(response, returnType); - } catch (ApiException e) { - callback.onFailure(e, response.code(), response.headers().toMultimap()); - return; - } - callback.onSuccess(result, response.code(), response.headers().toMultimap()); - } - }); - } - - /** - * Handle the given response, return the deserialized object when the response is successful. - * - * @param Type - * @param response Response - * @param returnType Return type - * @throws ApiException If the response has a unsuccessful status code or - * fail to deserialize the response body - * @return Type - */ - public T handleResponse(Response response, Type returnType) throws ApiException { - if (response.isSuccessful()) { - if (returnType == null || response.code() == 204) { - // returning null if the returnType is not defined, - // or the status code is 204 (No Content) - if (response.body() != null) { - try { - response.body().close(); - } catch (IOException e) { - throw new ApiException(response.message(), e, response.code(), response.headers().toMultimap()); - } - } - return null; - } else { - return deserialize(response, returnType); - } - } else { - String respBody = null; - if (response.body() != null) { - try { - respBody = response.body().string(); - } catch (IOException e) { - throw new ApiException(response.message(), e, response.code(), response.headers().toMultimap()); - } - } - throw new ApiException(response.message(), response.code(), response.headers().toMultimap(), respBody); - } - } - - /** - * Build HTTP call with the given options. - * - * @param path The sub-path of the HTTP URL - * @param method The request method, one of "GET", "HEAD", "OPTIONS", "POST", "PUT", "PATCH" and "DELETE" - * @param queryParams The query parameters - * @param body The request body object - * @param headerParams The header parameters - * @param formParams The form parameters - * @param authNames The authentications to apply - * @param progressRequestListener Progress request listener - * @return The HTTP call - * @throws ApiException If fail to serialize the request body object - */ - public Call buildCall(String path, String method, List queryParams, Object body, Map headerParams, Map formParams, String[] authNames, ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - Request request = buildRequest(path, method, queryParams, body, headerParams, formParams, authNames, progressRequestListener); - - return httpClient.newCall(request); - } - - /** - * Build an HTTP request with the given options. - * - * @param path The sub-path of the HTTP URL - * @param method The request method, one of "GET", "HEAD", "OPTIONS", "POST", "PUT", "PATCH" and "DELETE" - * @param queryParams The query parameters - * @param body The request body object - * @param headerParams The header parameters - * @param formParams The form parameters - * @param authNames The authentications to apply - * @param progressRequestListener Progress request listener - * @return The HTTP request - * @throws ApiException If fail to serialize the request body object - */ - public Request buildRequest(String path, String method, List queryParams, Object body, Map headerParams, Map formParams, String[] authNames, ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - updateParamsForAuth(authNames, queryParams, headerParams); - - final String url = buildUrl(path, queryParams); - final Request.Builder reqBuilder = new Request.Builder().url(url); - processHeaderParams(headerParams, reqBuilder); - - String contentType = (String) headerParams.get("Content-Type"); - // ensuring a default content type - if (contentType == null) { - contentType = "application/json"; - } - - RequestBody reqBody; - if (!HttpMethod.permitsRequestBody(method)) { - reqBody = null; - } else if ("application/x-www-form-urlencoded".equals(contentType)) { - reqBody = buildRequestBodyFormEncoding(formParams); - } else if ("multipart/form-data".equals(contentType)) { - reqBody = buildRequestBodyMultipart(formParams); - } else if (body == null) { - if ("DELETE".equals(method)) { - // allow calling DELETE without sending a request body - reqBody = null; - } else { - // use an empty request body (for POST, PUT and PATCH) - reqBody = RequestBody.create(MediaType.parse(contentType), ""); - } - } else { - reqBody = serialize(body, contentType); - } - - Request request = null; - - if(progressRequestListener != null && reqBody != null) { - ProgressRequestBody progressRequestBody = new ProgressRequestBody(reqBody, progressRequestListener); - request = reqBuilder.method(method, progressRequestBody).build(); - } else { - request = reqBuilder.method(method, reqBody).build(); - } - - return request; - } - - /** - * Build full URL by concatenating base path, the given sub path and query parameters. - * - * @param path The sub path - * @param queryParams The query parameters - * @return The full URL - */ - public String buildUrl(String path, List queryParams) { - final StringBuilder url = new StringBuilder(); - url.append(basePath).append(path); - - if (queryParams != null && !queryParams.isEmpty()) { - // support (constant) query string in `path`, e.g. "/posts?draft=1" - String prefix = path.contains("?") ? "&" : "?"; - for (Pair param : queryParams) { - if (param.getValue() != null) { - if (prefix != null) { - url.append(prefix); - prefix = null; - } else { - url.append("&"); - } - String value = parameterToString(param.getValue()); - url.append(escapeString(param.getName())).append("=").append(escapeString(value)); - } - } - } - - return url.toString(); - } - - /** - * Set header parameters to the request builder, including default headers. - * - * @param headerParams Header parameters in the ofrm of Map - * @param reqBuilder Reqeust.Builder - */ - public void processHeaderParams(Map headerParams, Request.Builder reqBuilder) { - for (Entry param : headerParams.entrySet()) { - reqBuilder.header(param.getKey(), parameterToString(param.getValue())); - } - for (Entry header : defaultHeaderMap.entrySet()) { - if (!headerParams.containsKey(header.getKey())) { - reqBuilder.header(header.getKey(), parameterToString(header.getValue())); - } - } - } - - /** - * Update query and header parameters based on authentication settings. - * - * @param authNames The authentications to apply - * @param queryParams List of query parameters - * @param headerParams Map of header parameters - */ - public void updateParamsForAuth(String[] authNames, List queryParams, Map headerParams) { - for (String authName : authNames) { - Authentication auth = authentications.get(authName); - if (auth == null) throw new RuntimeException("Authentication undefined: " + authName); - auth.applyToParams(queryParams, headerParams); - } - } - - /** - * Build a form-encoding request body with the given form parameters. - * - * @param formParams Form parameters in the form of Map - * @return RequestBody - */ - public RequestBody buildRequestBodyFormEncoding(Map formParams) { - FormEncodingBuilder formBuilder = new FormEncodingBuilder(); - for (Entry param : formParams.entrySet()) { - formBuilder.add(param.getKey(), parameterToString(param.getValue())); - } - return formBuilder.build(); - } - - /** - * Build a multipart (file uploading) request body with the given form parameters, - * which could contain text fields and file fields. - * - * @param formParams Form parameters in the form of Map - * @return RequestBody - */ - public RequestBody buildRequestBodyMultipart(Map formParams) { - MultipartBuilder mpBuilder = new MultipartBuilder().type(MultipartBuilder.FORM); - for (Entry param : formParams.entrySet()) { - if (param.getValue() instanceof File) { - File file = (File) param.getValue(); - Headers partHeaders = Headers.of("Content-Disposition", "form-data; name=\"" + param.getKey() + "\"; filename=\"" + file.getName() + "\""); - MediaType mediaType = MediaType.parse(guessContentTypeFromFile(file)); - mpBuilder.addPart(partHeaders, RequestBody.create(mediaType, file)); - } else { - Headers partHeaders = Headers.of("Content-Disposition", "form-data; name=\"" + param.getKey() + "\""); - mpBuilder.addPart(partHeaders, RequestBody.create(null, parameterToString(param.getValue()))); - } - } - return mpBuilder.build(); - } - - /** - * Guess Content-Type header from the given file (defaults to "application/octet-stream"). - * - * @param file The given file - * @return The guessed Content-Type - */ - public String guessContentTypeFromFile(File file) { - String contentType = URLConnection.guessContentTypeFromName(file.getName()); - if (contentType == null) { - return "application/octet-stream"; - } else { - return contentType; - } - } - - /** - * Initialize datetime format according to the current environment, e.g. Java 1.7 and Android. - */ - private void initDatetimeFormat() { - String formatWithTimeZone = null; - if (IS_ANDROID) { - if (ANDROID_SDK_VERSION >= 18) { - // The time zone format "ZZZZZ" is available since Android 4.3 (SDK version 18) - formatWithTimeZone = "yyyy-MM-dd'T'HH:mm:ss.SSSZZZZZ"; - } - } else if (JAVA_VERSION >= 1.7) { - // The time zone format "XXX" is available since Java 1.7 - formatWithTimeZone = "yyyy-MM-dd'T'HH:mm:ss.SSSXXX"; - } - if (formatWithTimeZone != null) { - this.datetimeFormat = new SimpleDateFormat(formatWithTimeZone); - // NOTE: Use the system's default time zone (mainly for datetime formatting). - } else { - // Use a common format that works across all systems. - this.datetimeFormat = new SimpleDateFormat("yyyy-MM-dd'T'HH:mm:ss.SSS'Z'"); - // Always use the UTC time zone as we are using a constant trailing "Z" here. - this.datetimeFormat.setTimeZone(TimeZone.getTimeZone("UTC")); - } - } - - /** - * Apply SSL related settings to httpClient according to the current values of - * verifyingSsl and sslCaCert. - */ - private void applySslSettings() { - try { - TrustManager[] trustManagers = null; - HostnameVerifier hostnameVerifier = null; - if (!verifyingSsl) { - TrustManager trustAll = new X509TrustManager() { - @Override - public void checkClientTrusted(X509Certificate[] chain, String authType) throws CertificateException {} - @Override - public void checkServerTrusted(X509Certificate[] chain, String authType) throws CertificateException {} - @Override - public X509Certificate[] getAcceptedIssuers() { return null; } - }; - SSLContext sslContext = SSLContext.getInstance("TLS"); - trustManagers = new TrustManager[]{ trustAll }; - hostnameVerifier = new HostnameVerifier() { - @Override - public boolean verify(String hostname, SSLSession session) { return true; } - }; - } else if (sslCaCert != null) { - char[] password = null; // Any password will work. - CertificateFactory certificateFactory = CertificateFactory.getInstance("X.509"); - Collection certificates = certificateFactory.generateCertificates(sslCaCert); - if (certificates.isEmpty()) { - throw new IllegalArgumentException("expected non-empty set of trusted certificates"); - } - KeyStore caKeyStore = newEmptyKeyStore(password); - int index = 0; - for (Certificate certificate : certificates) { - String certificateAlias = "ca" + Integer.toString(index++); - caKeyStore.setCertificateEntry(certificateAlias, certificate); - } - TrustManagerFactory trustManagerFactory = TrustManagerFactory.getInstance(TrustManagerFactory.getDefaultAlgorithm()); - trustManagerFactory.init(caKeyStore); - trustManagers = trustManagerFactory.getTrustManagers(); - } - - if (keyManagers != null || trustManagers != null) { - SSLContext sslContext = SSLContext.getInstance("TLS"); - sslContext.init(keyManagers, trustManagers, new SecureRandom()); - httpClient.setSslSocketFactory(sslContext.getSocketFactory()); - } else { - httpClient.setSslSocketFactory(null); - } - httpClient.setHostnameVerifier(hostnameVerifier); - } catch (GeneralSecurityException e) { - throw new RuntimeException(e); - } - } - - private KeyStore newEmptyKeyStore(char[] password) throws GeneralSecurityException { - try { - KeyStore keyStore = KeyStore.getInstance(KeyStore.getDefaultType()); - keyStore.load(null, password); - return keyStore; - } catch (IOException e) { - throw new AssertionError(e); - } - } -} diff --git a/testing/api-client/src/main/java/io/swagger/client/ApiException.java b/testing/api-client/src/main/java/io/swagger/client/ApiException.java deleted file mode 100644 index c3eac68..0000000 --- a/testing/api-client/src/main/java/io/swagger/client/ApiException.java +++ /dev/null @@ -1,91 +0,0 @@ -/* - * Maptology Service - * Maptology Service - * - * OpenAPI spec version: 0.0.1-SNAPSHOT - * Contact: nes-admin@uni-due.de - * - * NOTE: This class is auto generated by the swagger code generator program. - * https://github.com/swagger-api/swagger-codegen.git - * Do not edit the class manually. - */ - - -package io.swagger.client; - -import java.util.Map; -import java.util.List; - -@javax.annotation.Generated(value = "io.swagger.codegen.languages.JavaClientCodegen", date = "2018-01-25T01:26:31.138+01:00") -public class ApiException extends Exception { - private int code = 0; - private Map> responseHeaders = null; - private String responseBody = null; - - public ApiException() {} - - public ApiException(Throwable throwable) { - super(throwable); - } - - public ApiException(String message) { - super(message); - } - - public ApiException(String message, Throwable throwable, int code, Map> responseHeaders, String responseBody) { - super(message, throwable); - this.code = code; - this.responseHeaders = responseHeaders; - this.responseBody = responseBody; - } - - public ApiException(String message, int code, Map> responseHeaders, String responseBody) { - this(message, (Throwable) null, code, responseHeaders, responseBody); - } - - public ApiException(String message, Throwable throwable, int code, Map> responseHeaders) { - this(message, throwable, code, responseHeaders, null); - } - - public ApiException(int code, Map> responseHeaders, String responseBody) { - this((String) null, (Throwable) null, code, responseHeaders, responseBody); - } - - public ApiException(int code, String message) { - super(message); - this.code = code; - } - - public ApiException(int code, String message, Map> responseHeaders, String responseBody) { - this(code, message); - this.responseHeaders = responseHeaders; - this.responseBody = responseBody; - } - - /** - * Get the HTTP status code. - * - * @return HTTP status code - */ - public int getCode() { - return code; - } - - /** - * Get the HTTP response headers. - * - * @return A map of list of string - */ - public Map> getResponseHeaders() { - return responseHeaders; - } - - /** - * Get the HTTP response body. - * - * @return Response body in the form of string - */ - public String getResponseBody() { - return responseBody; - } -} diff --git a/testing/api-client/src/main/java/io/swagger/client/ApiResponse.java b/testing/api-client/src/main/java/io/swagger/client/ApiResponse.java deleted file mode 100644 index 80bfbe5..0000000 --- a/testing/api-client/src/main/java/io/swagger/client/ApiResponse.java +++ /dev/null @@ -1,59 +0,0 @@ -/* - * Maptology Service - * Maptology Service - * - * OpenAPI spec version: 0.0.1-SNAPSHOT - * Contact: nes-admin@uni-due.de - * - * NOTE: This class is auto generated by the swagger code generator program. - * https://github.com/swagger-api/swagger-codegen.git - * Do not edit the class manually. - */ - - -package io.swagger.client; - -import java.util.List; -import java.util.Map; - -/** - * API response returned by API call. - * - * @param The type of data that is deserialized from response body - */ -public class ApiResponse { - final private int statusCode; - final private Map> headers; - final private T data; - - /** - * @param statusCode The status code of HTTP response - * @param headers The headers of HTTP response - */ - public ApiResponse(int statusCode, Map> headers) { - this(statusCode, headers, null); - } - - /** - * @param statusCode The status code of HTTP response - * @param headers The headers of HTTP response - * @param data The object deserialized from response bod - */ - public ApiResponse(int statusCode, Map> headers, T data) { - this.statusCode = statusCode; - this.headers = headers; - this.data = data; - } - - public int getStatusCode() { - return statusCode; - } - - public Map> getHeaders() { - return headers; - } - - public T getData() { - return data; - } -} diff --git a/testing/api-client/src/main/java/io/swagger/client/Configuration.java b/testing/api-client/src/main/java/io/swagger/client/Configuration.java deleted file mode 100644 index a69a75a..0000000 --- a/testing/api-client/src/main/java/io/swagger/client/Configuration.java +++ /dev/null @@ -1,39 +0,0 @@ -/* - * Maptology Service - * Maptology Service - * - * OpenAPI spec version: 0.0.1-SNAPSHOT - * Contact: nes-admin@uni-due.de - * - * NOTE: This class is auto generated by the swagger code generator program. - * https://github.com/swagger-api/swagger-codegen.git - * Do not edit the class manually. - */ - - -package io.swagger.client; - -@javax.annotation.Generated(value = "io.swagger.codegen.languages.JavaClientCodegen", date = "2018-01-25T01:26:31.138+01:00") -public class Configuration { - private static ApiClient defaultApiClient = new ApiClient(); - - /** - * Get the default API client, which would be used when creating API - * instances without providing an API client. - * - * @return Default API client - */ - public static ApiClient getDefaultApiClient() { - return defaultApiClient; - } - - /** - * Set the default API client, which would be used when creating API - * instances without providing an API client. - * - * @param apiClient API client - */ - public static void setDefaultApiClient(ApiClient apiClient) { - defaultApiClient = apiClient; - } -} diff --git a/testing/api-client/src/main/java/io/swagger/client/GzipRequestInterceptor.java b/testing/api-client/src/main/java/io/swagger/client/GzipRequestInterceptor.java deleted file mode 100644 index ae20268..0000000 --- a/testing/api-client/src/main/java/io/swagger/client/GzipRequestInterceptor.java +++ /dev/null @@ -1,81 +0,0 @@ -/* - * Maptology Service - * Maptology Service - * - * OpenAPI spec version: 0.0.1-SNAPSHOT - * Contact: nes-admin@uni-due.de - * - * NOTE: This class is auto generated by the swagger code generator program. - * https://github.com/swagger-api/swagger-codegen.git - * Do not edit the class manually. - */ - - -package io.swagger.client; - -import com.squareup.okhttp.*; -import okio.Buffer; -import okio.BufferedSink; -import okio.GzipSink; -import okio.Okio; - -import java.io.IOException; - -/** - * Encodes request bodies using gzip. - * - * Taken from https://github.com/square/okhttp/issues/350 - */ -class GzipRequestInterceptor implements Interceptor { - @Override public Response intercept(Chain chain) throws IOException { - Request originalRequest = chain.request(); - if (originalRequest.body() == null || originalRequest.header("Content-Encoding") != null) { - return chain.proceed(originalRequest); - } - - Request compressedRequest = originalRequest.newBuilder() - .header("Content-Encoding", "gzip") - .method(originalRequest.method(), forceContentLength(gzip(originalRequest.body()))) - .build(); - return chain.proceed(compressedRequest); - } - - private RequestBody forceContentLength(final RequestBody requestBody) throws IOException { - final Buffer buffer = new Buffer(); - requestBody.writeTo(buffer); - return new RequestBody() { - @Override - public MediaType contentType() { - return requestBody.contentType(); - } - - @Override - public long contentLength() { - return buffer.size(); - } - - @Override - public void writeTo(BufferedSink sink) throws IOException { - sink.write(buffer.snapshot()); - } - }; - } - - private RequestBody gzip(final RequestBody body) { - return new RequestBody() { - @Override public MediaType contentType() { - return body.contentType(); - } - - @Override public long contentLength() { - return -1; // We don't know the compressed length in advance! - } - - @Override public void writeTo(BufferedSink sink) throws IOException { - BufferedSink gzipSink = Okio.buffer(new GzipSink(sink)); - body.writeTo(gzipSink); - gzipSink.close(); - } - }; - } -} \ No newline at end of file diff --git a/testing/api-client/src/main/java/io/swagger/client/JSON.java b/testing/api-client/src/main/java/io/swagger/client/JSON.java deleted file mode 100644 index 3731fa3..0000000 --- a/testing/api-client/src/main/java/io/swagger/client/JSON.java +++ /dev/null @@ -1,225 +0,0 @@ -/* - * Maptology Service - * Maptology Service - * - * OpenAPI spec version: 0.0.1-SNAPSHOT - * Contact: nes-admin@uni-due.de - * - * NOTE: This class is auto generated by the swagger code generator program. - * https://github.com/swagger-api/swagger-codegen.git - * Do not edit the class manually. - */ - - -package io.swagger.client; - -import com.google.gson.Gson; -import com.google.gson.GsonBuilder; -import com.google.gson.JsonDeserializationContext; -import com.google.gson.JsonDeserializer; -import com.google.gson.JsonElement; -import com.google.gson.JsonNull; -import com.google.gson.JsonParseException; -import com.google.gson.JsonPrimitive; -import com.google.gson.JsonSerializationContext; -import com.google.gson.JsonSerializer; -import com.google.gson.TypeAdapter; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; - -import java.io.IOException; -import java.io.StringReader; -import java.lang.reflect.Type; -import java.util.Date; - -import org.joda.time.DateTime; -import org.joda.time.LocalDate; -import org.joda.time.format.DateTimeFormatter; -import org.joda.time.format.ISODateTimeFormat; - -public class JSON { - private ApiClient apiClient; - private Gson gson; - - /** - * JSON constructor. - * - * @param apiClient An instance of ApiClient - */ - public JSON(ApiClient apiClient) { - this.apiClient = apiClient; - gson = new GsonBuilder() - .registerTypeAdapter(Date.class, new DateAdapter(apiClient)) - .registerTypeAdapter(DateTime.class, new DateTimeTypeAdapter()) - .registerTypeAdapter(LocalDate.class, new LocalDateTypeAdapter()) - .create(); - } - - /** - * Get Gson. - * - * @return Gson - */ - public Gson getGson() { - return gson; - } - - /** - * Set Gson. - * - * @param gson Gson - */ - public void setGson(Gson gson) { - this.gson = gson; - } - - /** - * Serialize the given Java object into JSON string. - * - * @param obj Object - * @return String representation of the JSON - */ - public String serialize(Object obj) { - return gson.toJson(obj); - } - - /** - * Deserialize the given JSON string to Java object. - * - * @param Type - * @param body The JSON string - * @param returnType The type to deserialize into - * @return The deserialized Java object - */ - @SuppressWarnings("unchecked") - public T deserialize(String body, Type returnType) { - try { - if (apiClient.isLenientOnJson()) { - JsonReader jsonReader = new JsonReader(new StringReader(body)); - // see https://google-gson.googlecode.com/svn/trunk/gson/docs/javadocs/com/google/gson/stream/JsonReader.html#setLenient(boolean) - jsonReader.setLenient(true); - return gson.fromJson(jsonReader, returnType); - } else { - return gson.fromJson(body, returnType); - } - } catch (JsonParseException e) { - // Fallback processing when failed to parse JSON form response body: - // return the response body string directly for the String return type; - // parse response body into date or datetime for the Date return type. - if (returnType.equals(String.class)) - return (T) body; - else if (returnType.equals(Date.class)) - return (T) apiClient.parseDateOrDatetime(body); - else throw(e); - } - } -} - -class DateAdapter implements JsonSerializer, JsonDeserializer { - private final ApiClient apiClient; - - /** - * Constructor for DateAdapter - * - * @param apiClient Api client - */ - public DateAdapter(ApiClient apiClient) { - super(); - this.apiClient = apiClient; - } - - /** - * Serialize - * - * @param src Date - * @param typeOfSrc Type - * @param context Json Serialization Context - * @return Json Element - */ - @Override - public JsonElement serialize(Date src, Type typeOfSrc, JsonSerializationContext context) { - if (src == null) { - return JsonNull.INSTANCE; - } else { - return new JsonPrimitive(apiClient.formatDatetime(src)); - } - } - - /** - * Deserialize - * - * @param json Json element - * @param date Type - * @param context Json Serialization Context - * @return Date - * @throws JsonParseException if fail to parse - */ - @Override - public Date deserialize(JsonElement json, Type date, JsonDeserializationContext context) throws JsonParseException { - String str = json.getAsJsonPrimitive().getAsString(); - try { - return apiClient.parseDateOrDatetime(str); - } catch (RuntimeException e) { - throw new JsonParseException(e); - } - } -} - -/** - * Gson TypeAdapter for Joda DateTime type - */ -class DateTimeTypeAdapter extends TypeAdapter { - - private final DateTimeFormatter parseFormatter = ISODateTimeFormat.dateOptionalTimeParser(); - private final DateTimeFormatter printFormatter = ISODateTimeFormat.dateTime(); - - @Override - public void write(JsonWriter out, DateTime date) throws IOException { - if (date == null) { - out.nullValue(); - } else { - out.value(printFormatter.print(date)); - } - } - - @Override - public DateTime read(JsonReader in) throws IOException { - switch (in.peek()) { - case NULL: - in.nextNull(); - return null; - default: - String date = in.nextString(); - return parseFormatter.parseDateTime(date); - } - } -} - -/** - * Gson TypeAdapter for Joda LocalDate type - */ -class LocalDateTypeAdapter extends TypeAdapter { - - private final DateTimeFormatter formatter = ISODateTimeFormat.date(); - - @Override - public void write(JsonWriter out, LocalDate date) throws IOException { - if (date == null) { - out.nullValue(); - } else { - out.value(formatter.print(date)); - } - } - - @Override - public LocalDate read(JsonReader in) throws IOException { - switch (in.peek()) { - case NULL: - in.nextNull(); - return null; - default: - String date = in.nextString(); - return formatter.parseLocalDate(date); - } - } -} diff --git a/testing/api-client/src/main/java/io/swagger/client/Pair.java b/testing/api-client/src/main/java/io/swagger/client/Pair.java deleted file mode 100644 index ad3e683..0000000 --- a/testing/api-client/src/main/java/io/swagger/client/Pair.java +++ /dev/null @@ -1,52 +0,0 @@ -/* - * Maptology Service - * Maptology Service - * - * OpenAPI spec version: 0.0.1-SNAPSHOT - * Contact: nes-admin@uni-due.de - * - * NOTE: This class is auto generated by the swagger code generator program. - * https://github.com/swagger-api/swagger-codegen.git - * Do not edit the class manually. - */ - - -package io.swagger.client; - -@javax.annotation.Generated(value = "io.swagger.codegen.languages.JavaClientCodegen", date = "2018-01-25T01:26:31.138+01:00") -public class Pair { - private String name = ""; - private String value = ""; - - public Pair (String name, String value) { - setName(name); - setValue(value); - } - - private void setName(String name) { - if (!isValidString(name)) return; - - this.name = name; - } - - private void setValue(String value) { - if (!isValidString(value)) return; - - this.value = value; - } - - public String getName() { - return this.name; - } - - public String getValue() { - return this.value; - } - - private boolean isValidString(String arg) { - if (arg == null) return false; - if (arg.trim().isEmpty()) return false; - - return true; - } -} diff --git a/testing/api-client/src/main/java/io/swagger/client/ProgressRequestBody.java b/testing/api-client/src/main/java/io/swagger/client/ProgressRequestBody.java deleted file mode 100644 index f393b2d..0000000 --- a/testing/api-client/src/main/java/io/swagger/client/ProgressRequestBody.java +++ /dev/null @@ -1,77 +0,0 @@ -/* - * Maptology Service - * Maptology Service - * - * OpenAPI spec version: 0.0.1-SNAPSHOT - * Contact: nes-admin@uni-due.de - * - * NOTE: This class is auto generated by the swagger code generator program. - * https://github.com/swagger-api/swagger-codegen.git - * Do not edit the class manually. - */ - - -package io.swagger.client; - -import com.squareup.okhttp.MediaType; -import com.squareup.okhttp.RequestBody; - -import java.io.IOException; - -import okio.Buffer; -import okio.BufferedSink; -import okio.ForwardingSink; -import okio.Okio; -import okio.Sink; - -public class ProgressRequestBody extends RequestBody { - - public interface ProgressRequestListener { - void onRequestProgress(long bytesWritten, long contentLength, boolean done); - } - - private final RequestBody requestBody; - - private final ProgressRequestListener progressListener; - - public ProgressRequestBody(RequestBody requestBody, ProgressRequestListener progressListener) { - this.requestBody = requestBody; - this.progressListener = progressListener; - } - - @Override - public MediaType contentType() { - return requestBody.contentType(); - } - - @Override - public long contentLength() throws IOException { - return requestBody.contentLength(); - } - - @Override - public void writeTo(BufferedSink sink) throws IOException { - BufferedSink bufferedSink = Okio.buffer(sink(sink)); - requestBody.writeTo(bufferedSink); - bufferedSink.flush(); - } - - private Sink sink(Sink sink) { - return new ForwardingSink(sink) { - - long bytesWritten = 0L; - long contentLength = 0L; - - @Override - public void write(Buffer source, long byteCount) throws IOException { - super.write(source, byteCount); - if (contentLength == 0) { - contentLength = contentLength(); - } - - bytesWritten += byteCount; - progressListener.onRequestProgress(bytesWritten, contentLength, bytesWritten == contentLength); - } - }; - } -} diff --git a/testing/api-client/src/main/java/io/swagger/client/ProgressResponseBody.java b/testing/api-client/src/main/java/io/swagger/client/ProgressResponseBody.java deleted file mode 100644 index c5b20db..0000000 --- a/testing/api-client/src/main/java/io/swagger/client/ProgressResponseBody.java +++ /dev/null @@ -1,76 +0,0 @@ -/* - * Maptology Service - * Maptology Service - * - * OpenAPI spec version: 0.0.1-SNAPSHOT - * Contact: nes-admin@uni-due.de - * - * NOTE: This class is auto generated by the swagger code generator program. - * https://github.com/swagger-api/swagger-codegen.git - * Do not edit the class manually. - */ - - -package io.swagger.client; - -import com.squareup.okhttp.MediaType; -import com.squareup.okhttp.ResponseBody; - -import java.io.IOException; - -import okio.Buffer; -import okio.BufferedSource; -import okio.ForwardingSource; -import okio.Okio; -import okio.Source; - -public class ProgressResponseBody extends ResponseBody { - - public interface ProgressListener { - void update(long bytesRead, long contentLength, boolean done); - } - - private final ResponseBody responseBody; - private final ProgressListener progressListener; - private BufferedSource bufferedSource; - - public ProgressResponseBody(ResponseBody responseBody, ProgressListener progressListener) { - this.responseBody = responseBody; - this.progressListener = progressListener; - } - - @Override - public MediaType contentType() { - return responseBody.contentType(); - } - - @Override - public long contentLength() throws IOException { - return responseBody.contentLength(); - } - - @Override - public BufferedSource source() throws IOException { - if (bufferedSource == null) { - bufferedSource = Okio.buffer(source(responseBody.source())); - } - return bufferedSource; - } - - private Source source(Source source) { - return new ForwardingSource(source) { - long totalBytesRead = 0L; - - @Override - public long read(Buffer sink, long byteCount) throws IOException { - long bytesRead = super.read(sink, byteCount); - // read() returns the number of bytes read, or -1 if this source is exhausted. - totalBytesRead += bytesRead != -1 ? bytesRead : 0; - progressListener.update(totalBytesRead, responseBody.contentLength(), bytesRead == -1); - return bytesRead; - } - }; - } -} - - diff --git a/testing/api-client/src/main/java/io/swagger/client/StringUtil.java b/testing/api-client/src/main/java/io/swagger/client/StringUtil.java deleted file mode 100644 index 0871651..0000000 --- a/testing/api-client/src/main/java/io/swagger/client/StringUtil.java +++ /dev/null @@ -1,55 +0,0 @@ -/* - * Maptology Service - * Maptology Service - * - * OpenAPI spec version: 0.0.1-SNAPSHOT - * Contact: nes-admin@uni-due.de - * - * NOTE: This class is auto generated by the swagger code generator program. - * https://github.com/swagger-api/swagger-codegen.git - * Do not edit the class manually. - */ - - -package io.swagger.client; - -@javax.annotation.Generated(value = "io.swagger.codegen.languages.JavaClientCodegen", date = "2018-01-25T01:26:31.138+01:00") -public class StringUtil { - /** - * Check if the given array contains the given value (with case-insensitive comparison). - * - * @param array The array - * @param value The value to search - * @return true if the array contains the value - */ - public static boolean containsIgnoreCase(String[] array, String value) { - for (String str : array) { - if (value == null && str == null) return true; - if (value != null && value.equalsIgnoreCase(str)) return true; - } - return false; - } - - /** - * Join an array of strings with the given separator. - *

- * Note: This might be replaced by utility method from commons-lang or guava someday - * if one of those libraries is added as dependency. - *

- * - * @param array The array of strings - * @param separator The separator - * @return the resulting string - */ - public static String join(String[] array, String separator) { - int len = array.length; - if (len == 0) return ""; - - StringBuilder out = new StringBuilder(); - out.append(array[0]); - for (int i = 1; i < len; i++) { - out.append(separator).append(array[i]); - } - return out.toString(); - } -} diff --git a/testing/api-client/src/main/java/io/swagger/client/api/DefaultApi.java b/testing/api-client/src/main/java/io/swagger/client/api/DefaultApi.java deleted file mode 100644 index 0062e11..0000000 --- a/testing/api-client/src/main/java/io/swagger/client/api/DefaultApi.java +++ /dev/null @@ -1,6793 +0,0 @@ -/* - * Maptology Service - * Maptology Service - * - * OpenAPI spec version: 0.0.1-SNAPSHOT - * Contact: nes-admin@uni-due.de - * - * NOTE: This class is auto generated by the swagger code generator program. - * https://github.com/swagger-api/swagger-codegen.git - * Do not edit the class manually. - */ - - -package io.swagger.client.api; - -import io.swagger.client.ApiCallback; -import io.swagger.client.ApiClient; -import io.swagger.client.ApiException; -import io.swagger.client.ApiResponse; -import io.swagger.client.Configuration; -import io.swagger.client.Pair; -import io.swagger.client.ProgressRequestBody; -import io.swagger.client.ProgressResponseBody; - -import com.google.gson.reflect.TypeToken; - -import java.io.IOException; - - -import io.swagger.client.model.BuildVersion; -import io.swagger.client.model.Device; -import io.swagger.client.model.DeviceHandle; -import io.swagger.client.model.DeviceInfo; -import io.swagger.client.model.DevicePage; -import io.swagger.client.model.EntityStatistic; -import io.swagger.client.model.LoadStatistic; -import io.swagger.client.model.Location; -import io.swagger.client.model.LocationUpdate; -import io.swagger.client.model.LogMessage; -import io.swagger.client.model.Notice; -import io.swagger.client.model.NoticePage; -import io.swagger.client.model.Place; -import io.swagger.client.model.PlacePage; -import io.swagger.client.model.Privilege; -import io.swagger.client.model.PrivilegePage; -import io.swagger.client.model.Share; -import io.swagger.client.model.ShareInfo; -import io.swagger.client.model.User; -import io.swagger.client.model.UserPage; -import io.swagger.client.model.UserPassword; -import io.swagger.client.model.UserRegistration; -import io.swagger.client.model.Visit; -import io.swagger.client.model.VisitPage; - -import java.lang.reflect.Type; -import java.util.ArrayList; -import java.util.HashMap; -import java.util.List; -import java.util.Map; - -public class DefaultApi { - private ApiClient apiClient; - - public DefaultApi() { - this(Configuration.getDefaultApiClient()); - } - - public DefaultApi(ApiClient apiClient) { - this.apiClient = apiClient; - } - - public ApiClient getApiClient() { - return apiClient; - } - - public void setApiClient(ApiClient apiClient) { - this.apiClient = apiClient; - } - - /** - * Build call for addCurrentUserPrivilege - * @param share The token of the share. (required) - * @param progressListener Progress listener - * @param progressRequestListener Progress request listener - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - */ - public com.squareup.okhttp.Call addCurrentUserPrivilegeCall(String share, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - Object localVarPostBody = null; - - // create path and map variables - String localVarPath = "/users/current/privileges"; - - List localVarQueryParams = new ArrayList(); - if (share != null) - localVarQueryParams.addAll(apiClient.parameterToPairs("", "share", share)); - - Map localVarHeaderParams = new HashMap(); - - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json", "application/xml" - }; - final String localVarAccept = apiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) localVarHeaderParams.put("Accept", localVarAccept); - - final String[] localVarContentTypes = { - "application/json", "application/xml" - }; - final String localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); - - if(progressListener != null) { - apiClient.getHttpClient().networkInterceptors().add(new com.squareup.okhttp.Interceptor() { - @Override - public com.squareup.okhttp.Response intercept(com.squareup.okhttp.Interceptor.Chain chain) throws IOException { - com.squareup.okhttp.Response originalResponse = chain.proceed(chain.request()); - return originalResponse.newBuilder() - .body(new ProgressResponseBody(originalResponse.body(), progressListener)) - .build(); - } - }); - } - - String[] localVarAuthNames = new String[] { "user" }; - return apiClient.buildCall(localVarPath, "POST", localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, progressRequestListener); - } - - @SuppressWarnings("rawtypes") - private com.squareup.okhttp.Call addCurrentUserPrivilegeValidateBeforeCall(String share, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - - // verify the required parameter 'share' is set - if (share == null) { - throw new ApiException("Missing the required parameter 'share' when calling addCurrentUserPrivilege(Async)"); - } - - - com.squareup.okhttp.Call call = addCurrentUserPrivilegeCall(share, progressListener, progressRequestListener); - return call; - - - - - - } - - /** - * Add a privilege for the specified user. - * - * @param share The token of the share. (required) - * @return Privilege - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public Privilege addCurrentUserPrivilege(String share) throws ApiException { - ApiResponse resp = addCurrentUserPrivilegeWithHttpInfo(share); - return resp.getData(); - } - - /** - * Add a privilege for the specified user. - * - * @param share The token of the share. (required) - * @return ApiResponse<Privilege> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public ApiResponse addCurrentUserPrivilegeWithHttpInfo(String share) throws ApiException { - com.squareup.okhttp.Call call = addCurrentUserPrivilegeValidateBeforeCall(share, null, null); - Type localVarReturnType = new TypeToken(){}.getType(); - return apiClient.execute(call, localVarReturnType); - } - - /** - * Add a privilege for the specified user. (asynchronously) - * - * @param share The token of the share. (required) - * @param callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - */ - public com.squareup.okhttp.Call addCurrentUserPrivilegeAsync(String share, final ApiCallback callback) throws ApiException { - - ProgressResponseBody.ProgressListener progressListener = null; - ProgressRequestBody.ProgressRequestListener progressRequestListener = null; - - if (callback != null) { - progressListener = new ProgressResponseBody.ProgressListener() { - @Override - public void update(long bytesRead, long contentLength, boolean done) { - callback.onDownloadProgress(bytesRead, contentLength, done); - } - }; - - progressRequestListener = new ProgressRequestBody.ProgressRequestListener() { - @Override - public void onRequestProgress(long bytesWritten, long contentLength, boolean done) { - callback.onUploadProgress(bytesWritten, contentLength, done); - } - }; - } - - com.squareup.okhttp.Call call = addCurrentUserPrivilegeValidateBeforeCall(share, progressListener, progressRequestListener); - Type localVarReturnType = new TypeToken(){}.getType(); - apiClient.executeAsync(call, localVarReturnType, callback); - return call; - } - /** - * Build call for addLocations - * @param body The location update with the locations to add. (required) - * @param progressListener Progress listener - * @param progressRequestListener Progress request listener - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - */ - public com.squareup.okhttp.Call addLocationsCall(LocationUpdate body, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - Object localVarPostBody = body; - - // create path and map variables - String localVarPath = "/devices/current/locations"; - - List localVarQueryParams = new ArrayList(); - - Map localVarHeaderParams = new HashMap(); - - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json", "application/xml" - }; - final String localVarAccept = apiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) localVarHeaderParams.put("Accept", localVarAccept); - - final String[] localVarContentTypes = { - "application/json", "application/xml" - }; - final String localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); - - if(progressListener != null) { - apiClient.getHttpClient().networkInterceptors().add(new com.squareup.okhttp.Interceptor() { - @Override - public com.squareup.okhttp.Response intercept(com.squareup.okhttp.Interceptor.Chain chain) throws IOException { - com.squareup.okhttp.Response originalResponse = chain.proceed(chain.request()); - return originalResponse.newBuilder() - .body(new ProgressResponseBody(originalResponse.body(), progressListener)) - .build(); - } - }); - } - - String[] localVarAuthNames = new String[] { "device" }; - return apiClient.buildCall(localVarPath, "POST", localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, progressRequestListener); - } - - @SuppressWarnings("rawtypes") - private com.squareup.okhttp.Call addLocationsValidateBeforeCall(LocationUpdate body, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - - // verify the required parameter 'body' is set - if (body == null) { - throw new ApiException("Missing the required parameter 'body' when calling addLocations(Async)"); - } - - - com.squareup.okhttp.Call call = addLocationsCall(body, progressListener, progressRequestListener); - return call; - - - - - - } - - /** - * Updates the locations of the current device. - * - * @param body The location update with the locations to add. (required) - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public void addLocations(LocationUpdate body) throws ApiException { - addLocationsWithHttpInfo(body); - } - - /** - * Updates the locations of the current device. - * - * @param body The location update with the locations to add. (required) - * @return ApiResponse<Void> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public ApiResponse addLocationsWithHttpInfo(LocationUpdate body) throws ApiException { - com.squareup.okhttp.Call call = addLocationsValidateBeforeCall(body, null, null); - return apiClient.execute(call); - } - - /** - * Updates the locations of the current device. (asynchronously) - * - * @param body The location update with the locations to add. (required) - * @param callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - */ - public com.squareup.okhttp.Call addLocationsAsync(LocationUpdate body, final ApiCallback callback) throws ApiException { - - ProgressResponseBody.ProgressListener progressListener = null; - ProgressRequestBody.ProgressRequestListener progressRequestListener = null; - - if (callback != null) { - progressListener = new ProgressResponseBody.ProgressListener() { - @Override - public void update(long bytesRead, long contentLength, boolean done) { - callback.onDownloadProgress(bytesRead, contentLength, done); - } - }; - - progressRequestListener = new ProgressRequestBody.ProgressRequestListener() { - @Override - public void onRequestProgress(long bytesWritten, long contentLength, boolean done) { - callback.onUploadProgress(bytesWritten, contentLength, done); - } - }; - } - - com.squareup.okhttp.Call call = addLocationsValidateBeforeCall(body, progressListener, progressRequestListener); - apiClient.executeAsync(call, callback); - return call; - } - /** - * Build call for addNotice - * @param body The new notice to add. (required) - * @param progressListener Progress listener - * @param progressRequestListener Progress request listener - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - */ - public com.squareup.okhttp.Call addNoticeCall(Notice body, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - Object localVarPostBody = body; - - // create path and map variables - String localVarPath = "/notices"; - - List localVarQueryParams = new ArrayList(); - - Map localVarHeaderParams = new HashMap(); - - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json", "application/xml" - }; - final String localVarAccept = apiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) localVarHeaderParams.put("Accept", localVarAccept); - - final String[] localVarContentTypes = { - "application/json", "application/xml" - }; - final String localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); - - if(progressListener != null) { - apiClient.getHttpClient().networkInterceptors().add(new com.squareup.okhttp.Interceptor() { - @Override - public com.squareup.okhttp.Response intercept(com.squareup.okhttp.Interceptor.Chain chain) throws IOException { - com.squareup.okhttp.Response originalResponse = chain.proceed(chain.request()); - return originalResponse.newBuilder() - .body(new ProgressResponseBody(originalResponse.body(), progressListener)) - .build(); - } - }); - } - - String[] localVarAuthNames = new String[] { "admin" }; - return apiClient.buildCall(localVarPath, "POST", localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, progressRequestListener); - } - - @SuppressWarnings("rawtypes") - private com.squareup.okhttp.Call addNoticeValidateBeforeCall(Notice body, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - - // verify the required parameter 'body' is set - if (body == null) { - throw new ApiException("Missing the required parameter 'body' when calling addNotice(Async)"); - } - - - com.squareup.okhttp.Call call = addNoticeCall(body, progressListener, progressRequestListener); - return call; - - - - - - } - - /** - * Adds a new notice and returns the notice as well as its location. - * - * @param body The new notice to add. (required) - * @return Notice - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public Notice addNotice(Notice body) throws ApiException { - ApiResponse resp = addNoticeWithHttpInfo(body); - return resp.getData(); - } - - /** - * Adds a new notice and returns the notice as well as its location. - * - * @param body The new notice to add. (required) - * @return ApiResponse<Notice> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public ApiResponse addNoticeWithHttpInfo(Notice body) throws ApiException { - com.squareup.okhttp.Call call = addNoticeValidateBeforeCall(body, null, null); - Type localVarReturnType = new TypeToken(){}.getType(); - return apiClient.execute(call, localVarReturnType); - } - - /** - * Adds a new notice and returns the notice as well as its location. (asynchronously) - * - * @param body The new notice to add. (required) - * @param callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - */ - public com.squareup.okhttp.Call addNoticeAsync(Notice body, final ApiCallback callback) throws ApiException { - - ProgressResponseBody.ProgressListener progressListener = null; - ProgressRequestBody.ProgressRequestListener progressRequestListener = null; - - if (callback != null) { - progressListener = new ProgressResponseBody.ProgressListener() { - @Override - public void update(long bytesRead, long contentLength, boolean done) { - callback.onDownloadProgress(bytesRead, contentLength, done); - } - }; - - progressRequestListener = new ProgressRequestBody.ProgressRequestListener() { - @Override - public void onRequestProgress(long bytesWritten, long contentLength, boolean done) { - callback.onUploadProgress(bytesWritten, contentLength, done); - } - }; - } - - com.squareup.okhttp.Call call = addNoticeValidateBeforeCall(body, progressListener, progressRequestListener); - Type localVarReturnType = new TypeToken(){}.getType(); - apiClient.executeAsync(call, localVarReturnType, callback); - return call; - } - /** - * Build call for addUser - * @param body The data for the new user. (required) - * @param progressListener Progress listener - * @param progressRequestListener Progress request listener - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - */ - public com.squareup.okhttp.Call addUserCall(User body, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - Object localVarPostBody = body; - - // create path and map variables - String localVarPath = "/users"; - - List localVarQueryParams = new ArrayList(); - - Map localVarHeaderParams = new HashMap(); - - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json", "application/xml" - }; - final String localVarAccept = apiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) localVarHeaderParams.put("Accept", localVarAccept); - - final String[] localVarContentTypes = { - "application/json", "application/xml" - }; - final String localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); - - if(progressListener != null) { - apiClient.getHttpClient().networkInterceptors().add(new com.squareup.okhttp.Interceptor() { - @Override - public com.squareup.okhttp.Response intercept(com.squareup.okhttp.Interceptor.Chain chain) throws IOException { - com.squareup.okhttp.Response originalResponse = chain.proceed(chain.request()); - return originalResponse.newBuilder() - .body(new ProgressResponseBody(originalResponse.body(), progressListener)) - .build(); - } - }); - } - - String[] localVarAuthNames = new String[] { "admin" }; - return apiClient.buildCall(localVarPath, "POST", localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, progressRequestListener); - } - - @SuppressWarnings("rawtypes") - private com.squareup.okhttp.Call addUserValidateBeforeCall(User body, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - - // verify the required parameter 'body' is set - if (body == null) { - throw new ApiException("Missing the required parameter 'body' when calling addUser(Async)"); - } - - - com.squareup.okhttp.Call call = addUserCall(body, progressListener, progressRequestListener); - return call; - - - - - - } - - /** - * Adds a user account with the specified roles and emails. - * - * @param body The data for the new user. (required) - * @return User - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public User addUser(User body) throws ApiException { - ApiResponse resp = addUserWithHttpInfo(body); - return resp.getData(); - } - - /** - * Adds a user account with the specified roles and emails. - * - * @param body The data for the new user. (required) - * @return ApiResponse<User> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public ApiResponse addUserWithHttpInfo(User body) throws ApiException { - com.squareup.okhttp.Call call = addUserValidateBeforeCall(body, null, null); - Type localVarReturnType = new TypeToken(){}.getType(); - return apiClient.execute(call, localVarReturnType); - } - - /** - * Adds a user account with the specified roles and emails. (asynchronously) - * - * @param body The data for the new user. (required) - * @param callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - */ - public com.squareup.okhttp.Call addUserAsync(User body, final ApiCallback callback) throws ApiException { - - ProgressResponseBody.ProgressListener progressListener = null; - ProgressRequestBody.ProgressRequestListener progressRequestListener = null; - - if (callback != null) { - progressListener = new ProgressResponseBody.ProgressListener() { - @Override - public void update(long bytesRead, long contentLength, boolean done) { - callback.onDownloadProgress(bytesRead, contentLength, done); - } - }; - - progressRequestListener = new ProgressRequestBody.ProgressRequestListener() { - @Override - public void onRequestProgress(long bytesWritten, long contentLength, boolean done) { - callback.onUploadProgress(bytesWritten, contentLength, done); - } - }; - } - - com.squareup.okhttp.Call call = addUserValidateBeforeCall(body, progressListener, progressRequestListener); - Type localVarReturnType = new TypeToken(){}.getType(); - apiClient.executeAsync(call, localVarReturnType, callback); - return call; - } - /** - * Build call for addUserPrivilege - * @param id The user id. (required) - * @param share The token of the share. (required) - * @param progressListener Progress listener - * @param progressRequestListener Progress request listener - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - */ - public com.squareup.okhttp.Call addUserPrivilegeCall(Long id, String share, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - Object localVarPostBody = null; - - // create path and map variables - String localVarPath = "/users/{id}/privileges" - .replaceAll("\\{" + "id" + "\\}", apiClient.escapeString(id.toString())); - - List localVarQueryParams = new ArrayList(); - if (share != null) - localVarQueryParams.addAll(apiClient.parameterToPairs("", "share", share)); - - Map localVarHeaderParams = new HashMap(); - - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json", "application/xml" - }; - final String localVarAccept = apiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) localVarHeaderParams.put("Accept", localVarAccept); - - final String[] localVarContentTypes = { - "application/json", "application/xml" - }; - final String localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); - - if(progressListener != null) { - apiClient.getHttpClient().networkInterceptors().add(new com.squareup.okhttp.Interceptor() { - @Override - public com.squareup.okhttp.Response intercept(com.squareup.okhttp.Interceptor.Chain chain) throws IOException { - com.squareup.okhttp.Response originalResponse = chain.proceed(chain.request()); - return originalResponse.newBuilder() - .body(new ProgressResponseBody(originalResponse.body(), progressListener)) - .build(); - } - }); - } - - String[] localVarAuthNames = new String[] { "admin" }; - return apiClient.buildCall(localVarPath, "POST", localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, progressRequestListener); - } - - @SuppressWarnings("rawtypes") - private com.squareup.okhttp.Call addUserPrivilegeValidateBeforeCall(Long id, String share, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - - // verify the required parameter 'id' is set - if (id == null) { - throw new ApiException("Missing the required parameter 'id' when calling addUserPrivilege(Async)"); - } - - // verify the required parameter 'share' is set - if (share == null) { - throw new ApiException("Missing the required parameter 'share' when calling addUserPrivilege(Async)"); - } - - - com.squareup.okhttp.Call call = addUserPrivilegeCall(id, share, progressListener, progressRequestListener); - return call; - - - - - - } - - /** - * Returns the privileges for a particular user. - * - * @param id The user id. (required) - * @param share The token of the share. (required) - * @return Privilege - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public Privilege addUserPrivilege(Long id, String share) throws ApiException { - ApiResponse resp = addUserPrivilegeWithHttpInfo(id, share); - return resp.getData(); - } - - /** - * Returns the privileges for a particular user. - * - * @param id The user id. (required) - * @param share The token of the share. (required) - * @return ApiResponse<Privilege> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public ApiResponse addUserPrivilegeWithHttpInfo(Long id, String share) throws ApiException { - com.squareup.okhttp.Call call = addUserPrivilegeValidateBeforeCall(id, share, null, null); - Type localVarReturnType = new TypeToken(){}.getType(); - return apiClient.execute(call, localVarReturnType); - } - - /** - * Returns the privileges for a particular user. (asynchronously) - * - * @param id The user id. (required) - * @param share The token of the share. (required) - * @param callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - */ - public com.squareup.okhttp.Call addUserPrivilegeAsync(Long id, String share, final ApiCallback callback) throws ApiException { - - ProgressResponseBody.ProgressListener progressListener = null; - ProgressRequestBody.ProgressRequestListener progressRequestListener = null; - - if (callback != null) { - progressListener = new ProgressResponseBody.ProgressListener() { - @Override - public void update(long bytesRead, long contentLength, boolean done) { - callback.onDownloadProgress(bytesRead, contentLength, done); - } - }; - - progressRequestListener = new ProgressRequestBody.ProgressRequestListener() { - @Override - public void onRequestProgress(long bytesWritten, long contentLength, boolean done) { - callback.onUploadProgress(bytesWritten, contentLength, done); - } - }; - } - - com.squareup.okhttp.Call call = addUserPrivilegeValidateBeforeCall(id, share, progressListener, progressRequestListener); - Type localVarReturnType = new TypeToken(){}.getType(); - apiClient.executeAsync(call, localVarReturnType, callback); - return call; - } - /** - * Build call for createDevice - * @param body Necessary data from to create a device. (required) - * @param progressListener Progress listener - * @param progressRequestListener Progress request listener - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - */ - public com.squareup.okhttp.Call createDeviceCall(DeviceInfo body, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - Object localVarPostBody = body; - - // create path and map variables - String localVarPath = "/devices"; - - List localVarQueryParams = new ArrayList(); - - Map localVarHeaderParams = new HashMap(); - - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json", "application/xml" - }; - final String localVarAccept = apiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) localVarHeaderParams.put("Accept", localVarAccept); - - final String[] localVarContentTypes = { - "application/json", "application/xml" - }; - final String localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); - - if(progressListener != null) { - apiClient.getHttpClient().networkInterceptors().add(new com.squareup.okhttp.Interceptor() { - @Override - public com.squareup.okhttp.Response intercept(com.squareup.okhttp.Interceptor.Chain chain) throws IOException { - com.squareup.okhttp.Response originalResponse = chain.proceed(chain.request()); - return originalResponse.newBuilder() - .body(new ProgressResponseBody(originalResponse.body(), progressListener)) - .build(); - } - }); - } - - String[] localVarAuthNames = new String[] { }; - return apiClient.buildCall(localVarPath, "POST", localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, progressRequestListener); - } - - @SuppressWarnings("rawtypes") - private com.squareup.okhttp.Call createDeviceValidateBeforeCall(DeviceInfo body, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - - // verify the required parameter 'body' is set - if (body == null) { - throw new ApiException("Missing the required parameter 'body' when calling createDevice(Async)"); - } - - - com.squareup.okhttp.Call call = createDeviceCall(body, progressListener, progressRequestListener); - return call; - - - - - - } - - /** - * Creates a new device and returns its handle. - * The response will include the auth token to be stored on the device and supplied as authentication on all subsequent api calls. Note that the auth token can not be requested after creation, so when losing the auth token you may lose access to the device data. - * @param body Necessary data from to create a device. (required) - * @return DeviceHandle - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public DeviceHandle createDevice(DeviceInfo body) throws ApiException { - ApiResponse resp = createDeviceWithHttpInfo(body); - return resp.getData(); - } - - /** - * Creates a new device and returns its handle. - * The response will include the auth token to be stored on the device and supplied as authentication on all subsequent api calls. Note that the auth token can not be requested after creation, so when losing the auth token you may lose access to the device data. - * @param body Necessary data from to create a device. (required) - * @return ApiResponse<DeviceHandle> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public ApiResponse createDeviceWithHttpInfo(DeviceInfo body) throws ApiException { - com.squareup.okhttp.Call call = createDeviceValidateBeforeCall(body, null, null); - Type localVarReturnType = new TypeToken(){}.getType(); - return apiClient.execute(call, localVarReturnType); - } - - /** - * Creates a new device and returns its handle. (asynchronously) - * The response will include the auth token to be stored on the device and supplied as authentication on all subsequent api calls. Note that the auth token can not be requested after creation, so when losing the auth token you may lose access to the device data. - * @param body Necessary data from to create a device. (required) - * @param callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - */ - public com.squareup.okhttp.Call createDeviceAsync(DeviceInfo body, final ApiCallback callback) throws ApiException { - - ProgressResponseBody.ProgressListener progressListener = null; - ProgressRequestBody.ProgressRequestListener progressRequestListener = null; - - if (callback != null) { - progressListener = new ProgressResponseBody.ProgressListener() { - @Override - public void update(long bytesRead, long contentLength, boolean done) { - callback.onDownloadProgress(bytesRead, contentLength, done); - } - }; - - progressRequestListener = new ProgressRequestBody.ProgressRequestListener() { - @Override - public void onRequestProgress(long bytesWritten, long contentLength, boolean done) { - callback.onUploadProgress(bytesWritten, contentLength, done); - } - }; - } - - com.squareup.okhttp.Call call = createDeviceValidateBeforeCall(body, progressListener, progressRequestListener); - Type localVarReturnType = new TypeToken(){}.getType(); - apiClient.executeAsync(call, localVarReturnType, callback); - return call; - } - /** - * Build call for createShare - * @param body Necessary data from to create a share. (required) - * @param progressListener Progress listener - * @param progressRequestListener Progress request listener - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - */ - public com.squareup.okhttp.Call createShareCall(ShareInfo body, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - Object localVarPostBody = body; - - // create path and map variables - String localVarPath = "/shares"; - - List localVarQueryParams = new ArrayList(); - - Map localVarHeaderParams = new HashMap(); - - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json", "application/xml" - }; - final String localVarAccept = apiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) localVarHeaderParams.put("Accept", localVarAccept); - - final String[] localVarContentTypes = { - "application/json", "application/xml" - }; - final String localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); - - if(progressListener != null) { - apiClient.getHttpClient().networkInterceptors().add(new com.squareup.okhttp.Interceptor() { - @Override - public com.squareup.okhttp.Response intercept(com.squareup.okhttp.Interceptor.Chain chain) throws IOException { - com.squareup.okhttp.Response originalResponse = chain.proceed(chain.request()); - return originalResponse.newBuilder() - .body(new ProgressResponseBody(originalResponse.body(), progressListener)) - .build(); - } - }); - } - - String[] localVarAuthNames = new String[] { "device" }; - return apiClient.buildCall(localVarPath, "POST", localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, progressRequestListener); - } - - @SuppressWarnings("rawtypes") - private com.squareup.okhttp.Call createShareValidateBeforeCall(ShareInfo body, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - - // verify the required parameter 'body' is set - if (body == null) { - throw new ApiException("Missing the required parameter 'body' when calling createShare(Async)"); - } - - - com.squareup.okhttp.Call call = createShareCall(body, progressListener, progressRequestListener); - return call; - - - - - - } - - /** - * Creates a new share. - * - * @param body Necessary data from to create a share. (required) - * @return Share - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public Share createShare(ShareInfo body) throws ApiException { - ApiResponse resp = createShareWithHttpInfo(body); - return resp.getData(); - } - - /** - * Creates a new share. - * - * @param body Necessary data from to create a share. (required) - * @return ApiResponse<Share> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public ApiResponse createShareWithHttpInfo(ShareInfo body) throws ApiException { - com.squareup.okhttp.Call call = createShareValidateBeforeCall(body, null, null); - Type localVarReturnType = new TypeToken(){}.getType(); - return apiClient.execute(call, localVarReturnType); - } - - /** - * Creates a new share. (asynchronously) - * - * @param body Necessary data from to create a share. (required) - * @param callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - */ - public com.squareup.okhttp.Call createShareAsync(ShareInfo body, final ApiCallback callback) throws ApiException { - - ProgressResponseBody.ProgressListener progressListener = null; - ProgressRequestBody.ProgressRequestListener progressRequestListener = null; - - if (callback != null) { - progressListener = new ProgressResponseBody.ProgressListener() { - @Override - public void update(long bytesRead, long contentLength, boolean done) { - callback.onDownloadProgress(bytesRead, contentLength, done); - } - }; - - progressRequestListener = new ProgressRequestBody.ProgressRequestListener() { - @Override - public void onRequestProgress(long bytesWritten, long contentLength, boolean done) { - callback.onUploadProgress(bytesWritten, contentLength, done); - } - }; - } - - com.squareup.okhttp.Call call = createShareValidateBeforeCall(body, progressListener, progressRequestListener); - Type localVarReturnType = new TypeToken(){}.getType(); - apiClient.executeAsync(call, localVarReturnType, callback); - return call; - } - /** - * Build call for deleteCurrentDevice - * @param progressListener Progress listener - * @param progressRequestListener Progress request listener - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - */ - public com.squareup.okhttp.Call deleteCurrentDeviceCall(final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - Object localVarPostBody = null; - - // create path and map variables - String localVarPath = "/devices/current"; - - List localVarQueryParams = new ArrayList(); - - Map localVarHeaderParams = new HashMap(); - - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json", "application/xml" - }; - final String localVarAccept = apiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) localVarHeaderParams.put("Accept", localVarAccept); - - final String[] localVarContentTypes = { - "application/json", "application/xml" - }; - final String localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); - - if(progressListener != null) { - apiClient.getHttpClient().networkInterceptors().add(new com.squareup.okhttp.Interceptor() { - @Override - public com.squareup.okhttp.Response intercept(com.squareup.okhttp.Interceptor.Chain chain) throws IOException { - com.squareup.okhttp.Response originalResponse = chain.proceed(chain.request()); - return originalResponse.newBuilder() - .body(new ProgressResponseBody(originalResponse.body(), progressListener)) - .build(); - } - }); - } - - String[] localVarAuthNames = new String[] { "device" }; - return apiClient.buildCall(localVarPath, "DELETE", localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, progressRequestListener); - } - - @SuppressWarnings("rawtypes") - private com.squareup.okhttp.Call deleteCurrentDeviceValidateBeforeCall(final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - - - com.squareup.okhttp.Call call = deleteCurrentDeviceCall(progressListener, progressRequestListener); - return call; - - - - - - } - - /** - * Deletes the current device. - * - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public void deleteCurrentDevice() throws ApiException { - deleteCurrentDeviceWithHttpInfo(); - } - - /** - * Deletes the current device. - * - * @return ApiResponse<Void> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public ApiResponse deleteCurrentDeviceWithHttpInfo() throws ApiException { - com.squareup.okhttp.Call call = deleteCurrentDeviceValidateBeforeCall(null, null); - return apiClient.execute(call); - } - - /** - * Deletes the current device. (asynchronously) - * - * @param callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - */ - public com.squareup.okhttp.Call deleteCurrentDeviceAsync(final ApiCallback callback) throws ApiException { - - ProgressResponseBody.ProgressListener progressListener = null; - ProgressRequestBody.ProgressRequestListener progressRequestListener = null; - - if (callback != null) { - progressListener = new ProgressResponseBody.ProgressListener() { - @Override - public void update(long bytesRead, long contentLength, boolean done) { - callback.onDownloadProgress(bytesRead, contentLength, done); - } - }; - - progressRequestListener = new ProgressRequestBody.ProgressRequestListener() { - @Override - public void onRequestProgress(long bytesWritten, long contentLength, boolean done) { - callback.onUploadProgress(bytesWritten, contentLength, done); - } - }; - } - - com.squareup.okhttp.Call call = deleteCurrentDeviceValidateBeforeCall(progressListener, progressRequestListener); - apiClient.executeAsync(call, callback); - return call; - } - /** - * Build call for deleteDevice - * @param id The device id. (required) - * @param progressListener Progress listener - * @param progressRequestListener Progress request listener - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - */ - public com.squareup.okhttp.Call deleteDeviceCall(Long id, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - Object localVarPostBody = null; - - // create path and map variables - String localVarPath = "/devices/{id}" - .replaceAll("\\{" + "id" + "\\}", apiClient.escapeString(id.toString())); - - List localVarQueryParams = new ArrayList(); - - Map localVarHeaderParams = new HashMap(); - - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json", "application/xml" - }; - final String localVarAccept = apiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) localVarHeaderParams.put("Accept", localVarAccept); - - final String[] localVarContentTypes = { - "application/json", "application/xml" - }; - final String localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); - - if(progressListener != null) { - apiClient.getHttpClient().networkInterceptors().add(new com.squareup.okhttp.Interceptor() { - @Override - public com.squareup.okhttp.Response intercept(com.squareup.okhttp.Interceptor.Chain chain) throws IOException { - com.squareup.okhttp.Response originalResponse = chain.proceed(chain.request()); - return originalResponse.newBuilder() - .body(new ProgressResponseBody(originalResponse.body(), progressListener)) - .build(); - } - }); - } - - String[] localVarAuthNames = new String[] { "admin", "user" }; - return apiClient.buildCall(localVarPath, "DELETE", localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, progressRequestListener); - } - - @SuppressWarnings("rawtypes") - private com.squareup.okhttp.Call deleteDeviceValidateBeforeCall(Long id, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - - // verify the required parameter 'id' is set - if (id == null) { - throw new ApiException("Missing the required parameter 'id' when calling deleteDevice(Async)"); - } - - - com.squareup.okhttp.Call call = deleteDeviceCall(id, progressListener, progressRequestListener); - return call; - - - - - - } - - /** - * Deletes a device. - * - * @param id The device id. (required) - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public void deleteDevice(Long id) throws ApiException { - deleteDeviceWithHttpInfo(id); - } - - /** - * Deletes a device. - * - * @param id The device id. (required) - * @return ApiResponse<Void> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public ApiResponse deleteDeviceWithHttpInfo(Long id) throws ApiException { - com.squareup.okhttp.Call call = deleteDeviceValidateBeforeCall(id, null, null); - return apiClient.execute(call); - } - - /** - * Deletes a device. (asynchronously) - * - * @param id The device id. (required) - * @param callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - */ - public com.squareup.okhttp.Call deleteDeviceAsync(Long id, final ApiCallback callback) throws ApiException { - - ProgressResponseBody.ProgressListener progressListener = null; - ProgressRequestBody.ProgressRequestListener progressRequestListener = null; - - if (callback != null) { - progressListener = new ProgressResponseBody.ProgressListener() { - @Override - public void update(long bytesRead, long contentLength, boolean done) { - callback.onDownloadProgress(bytesRead, contentLength, done); - } - }; - - progressRequestListener = new ProgressRequestBody.ProgressRequestListener() { - @Override - public void onRequestProgress(long bytesWritten, long contentLength, boolean done) { - callback.onUploadProgress(bytesWritten, contentLength, done); - } - }; - } - - com.squareup.okhttp.Call call = deleteDeviceValidateBeforeCall(id, progressListener, progressRequestListener); - apiClient.executeAsync(call, callback); - return call; - } - /** - * Build call for deletePrivilege - * @param id The privilege id. (required) - * @param progressListener Progress listener - * @param progressRequestListener Progress request listener - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - */ - public com.squareup.okhttp.Call deletePrivilegeCall(Long id, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - Object localVarPostBody = null; - - // create path and map variables - String localVarPath = "/privileges/{id}" - .replaceAll("\\{" + "id" + "\\}", apiClient.escapeString(id.toString())); - - List localVarQueryParams = new ArrayList(); - - Map localVarHeaderParams = new HashMap(); - - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json", "application/xml" - }; - final String localVarAccept = apiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) localVarHeaderParams.put("Accept", localVarAccept); - - final String[] localVarContentTypes = { - "application/json", "application/xml" - }; - final String localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); - - if(progressListener != null) { - apiClient.getHttpClient().networkInterceptors().add(new com.squareup.okhttp.Interceptor() { - @Override - public com.squareup.okhttp.Response intercept(com.squareup.okhttp.Interceptor.Chain chain) throws IOException { - com.squareup.okhttp.Response originalResponse = chain.proceed(chain.request()); - return originalResponse.newBuilder() - .body(new ProgressResponseBody(originalResponse.body(), progressListener)) - .build(); - } - }); - } - - String[] localVarAuthNames = new String[] { "admin", "user" }; - return apiClient.buildCall(localVarPath, "DELETE", localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, progressRequestListener); - } - - @SuppressWarnings("rawtypes") - private com.squareup.okhttp.Call deletePrivilegeValidateBeforeCall(Long id, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - - // verify the required parameter 'id' is set - if (id == null) { - throw new ApiException("Missing the required parameter 'id' when calling deletePrivilege(Async)"); - } - - - com.squareup.okhttp.Call call = deletePrivilegeCall(id, progressListener, progressRequestListener); - return call; - - - - - - } - - /** - * Deletes a particular privilege. - * - * @param id The privilege id. (required) - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public void deletePrivilege(Long id) throws ApiException { - deletePrivilegeWithHttpInfo(id); - } - - /** - * Deletes a particular privilege. - * - * @param id The privilege id. (required) - * @return ApiResponse<Void> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public ApiResponse deletePrivilegeWithHttpInfo(Long id) throws ApiException { - com.squareup.okhttp.Call call = deletePrivilegeValidateBeforeCall(id, null, null); - return apiClient.execute(call); - } - - /** - * Deletes a particular privilege. (asynchronously) - * - * @param id The privilege id. (required) - * @param callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - */ - public com.squareup.okhttp.Call deletePrivilegeAsync(Long id, final ApiCallback callback) throws ApiException { - - ProgressResponseBody.ProgressListener progressListener = null; - ProgressRequestBody.ProgressRequestListener progressRequestListener = null; - - if (callback != null) { - progressListener = new ProgressResponseBody.ProgressListener() { - @Override - public void update(long bytesRead, long contentLength, boolean done) { - callback.onDownloadProgress(bytesRead, contentLength, done); - } - }; - - progressRequestListener = new ProgressRequestBody.ProgressRequestListener() { - @Override - public void onRequestProgress(long bytesWritten, long contentLength, boolean done) { - callback.onUploadProgress(bytesWritten, contentLength, done); - } - }; - } - - com.squareup.okhttp.Call call = deletePrivilegeValidateBeforeCall(id, progressListener, progressRequestListener); - apiClient.executeAsync(call, callback); - return call; - } - /** - * Build call for deleteShare - * @param id The share id. (required) - * @param progressListener Progress listener - * @param progressRequestListener Progress request listener - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - */ - public com.squareup.okhttp.Call deleteShareCall(Long id, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - Object localVarPostBody = null; - - // create path and map variables - String localVarPath = "/shares/{id}" - .replaceAll("\\{" + "id" + "\\}", apiClient.escapeString(id.toString())); - - List localVarQueryParams = new ArrayList(); - - Map localVarHeaderParams = new HashMap(); - - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json", "application/xml" - }; - final String localVarAccept = apiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) localVarHeaderParams.put("Accept", localVarAccept); - - final String[] localVarContentTypes = { - "application/json", "application/xml" - }; - final String localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); - - if(progressListener != null) { - apiClient.getHttpClient().networkInterceptors().add(new com.squareup.okhttp.Interceptor() { - @Override - public com.squareup.okhttp.Response intercept(com.squareup.okhttp.Interceptor.Chain chain) throws IOException { - com.squareup.okhttp.Response originalResponse = chain.proceed(chain.request()); - return originalResponse.newBuilder() - .body(new ProgressResponseBody(originalResponse.body(), progressListener)) - .build(); - } - }); - } - - String[] localVarAuthNames = new String[] { "device" }; - return apiClient.buildCall(localVarPath, "DELETE", localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, progressRequestListener); - } - - @SuppressWarnings("rawtypes") - private com.squareup.okhttp.Call deleteShareValidateBeforeCall(Long id, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - - // verify the required parameter 'id' is set - if (id == null) { - throw new ApiException("Missing the required parameter 'id' when calling deleteShare(Async)"); - } - - - com.squareup.okhttp.Call call = deleteShareCall(id, progressListener, progressRequestListener); - return call; - - - - - - } - - /** - * Delete a share. - * - * @param id The share id. (required) - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public void deleteShare(Long id) throws ApiException { - deleteShareWithHttpInfo(id); - } - - /** - * Delete a share. - * - * @param id The share id. (required) - * @return ApiResponse<Void> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public ApiResponse deleteShareWithHttpInfo(Long id) throws ApiException { - com.squareup.okhttp.Call call = deleteShareValidateBeforeCall(id, null, null); - return apiClient.execute(call); - } - - /** - * Delete a share. (asynchronously) - * - * @param id The share id. (required) - * @param callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - */ - public com.squareup.okhttp.Call deleteShareAsync(Long id, final ApiCallback callback) throws ApiException { - - ProgressResponseBody.ProgressListener progressListener = null; - ProgressRequestBody.ProgressRequestListener progressRequestListener = null; - - if (callback != null) { - progressListener = new ProgressResponseBody.ProgressListener() { - @Override - public void update(long bytesRead, long contentLength, boolean done) { - callback.onDownloadProgress(bytesRead, contentLength, done); - } - }; - - progressRequestListener = new ProgressRequestBody.ProgressRequestListener() { - @Override - public void onRequestProgress(long bytesWritten, long contentLength, boolean done) { - callback.onUploadProgress(bytesWritten, contentLength, done); - } - }; - } - - com.squareup.okhttp.Call call = deleteShareValidateBeforeCall(id, progressListener, progressRequestListener); - apiClient.executeAsync(call, callback); - return call; - } - /** - * Build call for getActiveNotices - * @param pageOffset The offset in terms of elements. (optional, default to 0) - * @param pageSize The maximum number of elements on the page. (optional, default to 20) - * @param progressListener Progress listener - * @param progressRequestListener Progress request listener - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - */ - public com.squareup.okhttp.Call getActiveNoticesCall(Integer pageOffset, Integer pageSize, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - Object localVarPostBody = null; - - // create path and map variables - String localVarPath = "/notices/active"; - - List localVarQueryParams = new ArrayList(); - if (pageOffset != null) - localVarQueryParams.addAll(apiClient.parameterToPairs("", "pageOffset", pageOffset)); - if (pageSize != null) - localVarQueryParams.addAll(apiClient.parameterToPairs("", "pageSize", pageSize)); - - Map localVarHeaderParams = new HashMap(); - - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json", "application/xml" - }; - final String localVarAccept = apiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) localVarHeaderParams.put("Accept", localVarAccept); - - final String[] localVarContentTypes = { - "application/json", "application/xml" - }; - final String localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); - - if(progressListener != null) { - apiClient.getHttpClient().networkInterceptors().add(new com.squareup.okhttp.Interceptor() { - @Override - public com.squareup.okhttp.Response intercept(com.squareup.okhttp.Interceptor.Chain chain) throws IOException { - com.squareup.okhttp.Response originalResponse = chain.proceed(chain.request()); - return originalResponse.newBuilder() - .body(new ProgressResponseBody(originalResponse.body(), progressListener)) - .build(); - } - }); - } - - String[] localVarAuthNames = new String[] { }; - return apiClient.buildCall(localVarPath, "GET", localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, progressRequestListener); - } - - @SuppressWarnings("rawtypes") - private com.squareup.okhttp.Call getActiveNoticesValidateBeforeCall(Integer pageOffset, Integer pageSize, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - - - com.squareup.okhttp.Call call = getActiveNoticesCall(pageOffset, pageSize, progressListener, progressRequestListener); - return call; - - - - - - } - - /** - * Returns a page of notices. - * - * @param pageOffset The offset in terms of elements. (optional, default to 0) - * @param pageSize The maximum number of elements on the page. (optional, default to 20) - * @return NoticePage - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public NoticePage getActiveNotices(Integer pageOffset, Integer pageSize) throws ApiException { - ApiResponse resp = getActiveNoticesWithHttpInfo(pageOffset, pageSize); - return resp.getData(); - } - - /** - * Returns a page of notices. - * - * @param pageOffset The offset in terms of elements. (optional, default to 0) - * @param pageSize The maximum number of elements on the page. (optional, default to 20) - * @return ApiResponse<NoticePage> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public ApiResponse getActiveNoticesWithHttpInfo(Integer pageOffset, Integer pageSize) throws ApiException { - com.squareup.okhttp.Call call = getActiveNoticesValidateBeforeCall(pageOffset, pageSize, null, null); - Type localVarReturnType = new TypeToken(){}.getType(); - return apiClient.execute(call, localVarReturnType); - } - - /** - * Returns a page of notices. (asynchronously) - * - * @param pageOffset The offset in terms of elements. (optional, default to 0) - * @param pageSize The maximum number of elements on the page. (optional, default to 20) - * @param callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - */ - public com.squareup.okhttp.Call getActiveNoticesAsync(Integer pageOffset, Integer pageSize, final ApiCallback callback) throws ApiException { - - ProgressResponseBody.ProgressListener progressListener = null; - ProgressRequestBody.ProgressRequestListener progressRequestListener = null; - - if (callback != null) { - progressListener = new ProgressResponseBody.ProgressListener() { - @Override - public void update(long bytesRead, long contentLength, boolean done) { - callback.onDownloadProgress(bytesRead, contentLength, done); - } - }; - - progressRequestListener = new ProgressRequestBody.ProgressRequestListener() { - @Override - public void onRequestProgress(long bytesWritten, long contentLength, boolean done) { - callback.onUploadProgress(bytesWritten, contentLength, done); - } - }; - } - - com.squareup.okhttp.Call call = getActiveNoticesValidateBeforeCall(pageOffset, pageSize, progressListener, progressRequestListener); - Type localVarReturnType = new TypeToken(){}.getType(); - apiClient.executeAsync(call, localVarReturnType, callback); - return call; - } - /** - * Build call for getBuildVersion - * @param progressListener Progress listener - * @param progressRequestListener Progress request listener - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - */ - public com.squareup.okhttp.Call getBuildVersionCall(final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - Object localVarPostBody = null; - - // create path and map variables - String localVarPath = "/versions/build"; - - List localVarQueryParams = new ArrayList(); - - Map localVarHeaderParams = new HashMap(); - - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json", "application/xml" - }; - final String localVarAccept = apiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) localVarHeaderParams.put("Accept", localVarAccept); - - final String[] localVarContentTypes = { - - }; - final String localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); - - if(progressListener != null) { - apiClient.getHttpClient().networkInterceptors().add(new com.squareup.okhttp.Interceptor() { - @Override - public com.squareup.okhttp.Response intercept(com.squareup.okhttp.Interceptor.Chain chain) throws IOException { - com.squareup.okhttp.Response originalResponse = chain.proceed(chain.request()); - return originalResponse.newBuilder() - .body(new ProgressResponseBody(originalResponse.body(), progressListener)) - .build(); - } - }); - } - - String[] localVarAuthNames = new String[] { }; - return apiClient.buildCall(localVarPath, "GET", localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, progressRequestListener); - } - - @SuppressWarnings("rawtypes") - private com.squareup.okhttp.Call getBuildVersionValidateBeforeCall(final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - - - com.squareup.okhttp.Call call = getBuildVersionCall(progressListener, progressRequestListener); - return call; - - - - - - } - - /** - * Returns the build version. - * - * @return BuildVersion - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public BuildVersion getBuildVersion() throws ApiException { - ApiResponse resp = getBuildVersionWithHttpInfo(); - return resp.getData(); - } - - /** - * Returns the build version. - * - * @return ApiResponse<BuildVersion> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public ApiResponse getBuildVersionWithHttpInfo() throws ApiException { - com.squareup.okhttp.Call call = getBuildVersionValidateBeforeCall(null, null); - Type localVarReturnType = new TypeToken(){}.getType(); - return apiClient.execute(call, localVarReturnType); - } - - /** - * Returns the build version. (asynchronously) - * - * @param callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - */ - public com.squareup.okhttp.Call getBuildVersionAsync(final ApiCallback callback) throws ApiException { - - ProgressResponseBody.ProgressListener progressListener = null; - ProgressRequestBody.ProgressRequestListener progressRequestListener = null; - - if (callback != null) { - progressListener = new ProgressResponseBody.ProgressListener() { - @Override - public void update(long bytesRead, long contentLength, boolean done) { - callback.onDownloadProgress(bytesRead, contentLength, done); - } - }; - - progressRequestListener = new ProgressRequestBody.ProgressRequestListener() { - @Override - public void onRequestProgress(long bytesWritten, long contentLength, boolean done) { - callback.onUploadProgress(bytesWritten, contentLength, done); - } - }; - } - - com.squareup.okhttp.Call call = getBuildVersionValidateBeforeCall(progressListener, progressRequestListener); - Type localVarReturnType = new TypeToken(){}.getType(); - apiClient.executeAsync(call, localVarReturnType, callback); - return call; - } - /** - * Build call for getCurrentDevice - * @param progressListener Progress listener - * @param progressRequestListener Progress request listener - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - */ - public com.squareup.okhttp.Call getCurrentDeviceCall(final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - Object localVarPostBody = null; - - // create path and map variables - String localVarPath = "/devices/current"; - - List localVarQueryParams = new ArrayList(); - - Map localVarHeaderParams = new HashMap(); - - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json", "application/xml" - }; - final String localVarAccept = apiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) localVarHeaderParams.put("Accept", localVarAccept); - - final String[] localVarContentTypes = { - "application/json", "application/xml" - }; - final String localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); - - if(progressListener != null) { - apiClient.getHttpClient().networkInterceptors().add(new com.squareup.okhttp.Interceptor() { - @Override - public com.squareup.okhttp.Response intercept(com.squareup.okhttp.Interceptor.Chain chain) throws IOException { - com.squareup.okhttp.Response originalResponse = chain.proceed(chain.request()); - return originalResponse.newBuilder() - .body(new ProgressResponseBody(originalResponse.body(), progressListener)) - .build(); - } - }); - } - - String[] localVarAuthNames = new String[] { "device" }; - return apiClient.buildCall(localVarPath, "GET", localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, progressRequestListener); - } - - @SuppressWarnings("rawtypes") - private com.squareup.okhttp.Call getCurrentDeviceValidateBeforeCall(final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - - - com.squareup.okhttp.Call call = getCurrentDeviceCall(progressListener, progressRequestListener); - return call; - - - - - - } - - /** - * Returns the current device. - * - * @return Device - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public Device getCurrentDevice() throws ApiException { - ApiResponse resp = getCurrentDeviceWithHttpInfo(); - return resp.getData(); - } - - /** - * Returns the current device. - * - * @return ApiResponse<Device> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public ApiResponse getCurrentDeviceWithHttpInfo() throws ApiException { - com.squareup.okhttp.Call call = getCurrentDeviceValidateBeforeCall(null, null); - Type localVarReturnType = new TypeToken(){}.getType(); - return apiClient.execute(call, localVarReturnType); - } - - /** - * Returns the current device. (asynchronously) - * - * @param callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - */ - public com.squareup.okhttp.Call getCurrentDeviceAsync(final ApiCallback callback) throws ApiException { - - ProgressResponseBody.ProgressListener progressListener = null; - ProgressRequestBody.ProgressRequestListener progressRequestListener = null; - - if (callback != null) { - progressListener = new ProgressResponseBody.ProgressListener() { - @Override - public void update(long bytesRead, long contentLength, boolean done) { - callback.onDownloadProgress(bytesRead, contentLength, done); - } - }; - - progressRequestListener = new ProgressRequestBody.ProgressRequestListener() { - @Override - public void onRequestProgress(long bytesWritten, long contentLength, boolean done) { - callback.onUploadProgress(bytesWritten, contentLength, done); - } - }; - } - - com.squareup.okhttp.Call call = getCurrentDeviceValidateBeforeCall(progressListener, progressRequestListener); - Type localVarReturnType = new TypeToken(){}.getType(); - apiClient.executeAsync(call, localVarReturnType, callback); - return call; - } - /** - * Build call for getCurrentUser - * @param progressListener Progress listener - * @param progressRequestListener Progress request listener - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - */ - public com.squareup.okhttp.Call getCurrentUserCall(final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - Object localVarPostBody = null; - - // create path and map variables - String localVarPath = "/users/current"; - - List localVarQueryParams = new ArrayList(); - - Map localVarHeaderParams = new HashMap(); - - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json", "application/xml" - }; - final String localVarAccept = apiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) localVarHeaderParams.put("Accept", localVarAccept); - - final String[] localVarContentTypes = { - "application/json", "application/xml" - }; - final String localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); - - if(progressListener != null) { - apiClient.getHttpClient().networkInterceptors().add(new com.squareup.okhttp.Interceptor() { - @Override - public com.squareup.okhttp.Response intercept(com.squareup.okhttp.Interceptor.Chain chain) throws IOException { - com.squareup.okhttp.Response originalResponse = chain.proceed(chain.request()); - return originalResponse.newBuilder() - .body(new ProgressResponseBody(originalResponse.body(), progressListener)) - .build(); - } - }); - } - - String[] localVarAuthNames = new String[] { "user" }; - return apiClient.buildCall(localVarPath, "GET", localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, progressRequestListener); - } - - @SuppressWarnings("rawtypes") - private com.squareup.okhttp.Call getCurrentUserValidateBeforeCall(final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - - - com.squareup.okhttp.Call call = getCurrentUserCall(progressListener, progressRequestListener); - return call; - - - - - - } - - /** - * Returns the user currently authorized. - * - * @return User - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public User getCurrentUser() throws ApiException { - ApiResponse resp = getCurrentUserWithHttpInfo(); - return resp.getData(); - } - - /** - * Returns the user currently authorized. - * - * @return ApiResponse<User> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public ApiResponse getCurrentUserWithHttpInfo() throws ApiException { - com.squareup.okhttp.Call call = getCurrentUserValidateBeforeCall(null, null); - Type localVarReturnType = new TypeToken(){}.getType(); - return apiClient.execute(call, localVarReturnType); - } - - /** - * Returns the user currently authorized. (asynchronously) - * - * @param callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - */ - public com.squareup.okhttp.Call getCurrentUserAsync(final ApiCallback callback) throws ApiException { - - ProgressResponseBody.ProgressListener progressListener = null; - ProgressRequestBody.ProgressRequestListener progressRequestListener = null; - - if (callback != null) { - progressListener = new ProgressResponseBody.ProgressListener() { - @Override - public void update(long bytesRead, long contentLength, boolean done) { - callback.onDownloadProgress(bytesRead, contentLength, done); - } - }; - - progressRequestListener = new ProgressRequestBody.ProgressRequestListener() { - @Override - public void onRequestProgress(long bytesWritten, long contentLength, boolean done) { - callback.onUploadProgress(bytesWritten, contentLength, done); - } - }; - } - - com.squareup.okhttp.Call call = getCurrentUserValidateBeforeCall(progressListener, progressRequestListener); - Type localVarReturnType = new TypeToken(){}.getType(); - apiClient.executeAsync(call, localVarReturnType, callback); - return call; - } - /** - * Build call for getCurrentUserDevices - * @param pageOffset The offset in terms of elements. (optional, default to 0) - * @param pageSize The maximum number of elements on the page. (optional, default to 20) - * @param progressListener Progress listener - * @param progressRequestListener Progress request listener - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - */ - public com.squareup.okhttp.Call getCurrentUserDevicesCall(Integer pageOffset, Integer pageSize, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - Object localVarPostBody = null; - - // create path and map variables - String localVarPath = "/users/current/devices"; - - List localVarQueryParams = new ArrayList(); - if (pageOffset != null) - localVarQueryParams.addAll(apiClient.parameterToPairs("", "pageOffset", pageOffset)); - if (pageSize != null) - localVarQueryParams.addAll(apiClient.parameterToPairs("", "pageSize", pageSize)); - - Map localVarHeaderParams = new HashMap(); - - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json", "application/xml" - }; - final String localVarAccept = apiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) localVarHeaderParams.put("Accept", localVarAccept); - - final String[] localVarContentTypes = { - "application/json", "application/xml" - }; - final String localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); - - if(progressListener != null) { - apiClient.getHttpClient().networkInterceptors().add(new com.squareup.okhttp.Interceptor() { - @Override - public com.squareup.okhttp.Response intercept(com.squareup.okhttp.Interceptor.Chain chain) throws IOException { - com.squareup.okhttp.Response originalResponse = chain.proceed(chain.request()); - return originalResponse.newBuilder() - .body(new ProgressResponseBody(originalResponse.body(), progressListener)) - .build(); - } - }); - } - - String[] localVarAuthNames = new String[] { "user" }; - return apiClient.buildCall(localVarPath, "GET", localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, progressRequestListener); - } - - @SuppressWarnings("rawtypes") - private com.squareup.okhttp.Call getCurrentUserDevicesValidateBeforeCall(Integer pageOffset, Integer pageSize, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - - - com.squareup.okhttp.Call call = getCurrentUserDevicesCall(pageOffset, pageSize, progressListener, progressRequestListener); - return call; - - - - - - } - - /** - * Returns the list of devices for the current user. - * - * @param pageOffset The offset in terms of elements. (optional, default to 0) - * @param pageSize The maximum number of elements on the page. (optional, default to 20) - * @return DevicePage - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public DevicePage getCurrentUserDevices(Integer pageOffset, Integer pageSize) throws ApiException { - ApiResponse resp = getCurrentUserDevicesWithHttpInfo(pageOffset, pageSize); - return resp.getData(); - } - - /** - * Returns the list of devices for the current user. - * - * @param pageOffset The offset in terms of elements. (optional, default to 0) - * @param pageSize The maximum number of elements on the page. (optional, default to 20) - * @return ApiResponse<DevicePage> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public ApiResponse getCurrentUserDevicesWithHttpInfo(Integer pageOffset, Integer pageSize) throws ApiException { - com.squareup.okhttp.Call call = getCurrentUserDevicesValidateBeforeCall(pageOffset, pageSize, null, null); - Type localVarReturnType = new TypeToken(){}.getType(); - return apiClient.execute(call, localVarReturnType); - } - - /** - * Returns the list of devices for the current user. (asynchronously) - * - * @param pageOffset The offset in terms of elements. (optional, default to 0) - * @param pageSize The maximum number of elements on the page. (optional, default to 20) - * @param callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - */ - public com.squareup.okhttp.Call getCurrentUserDevicesAsync(Integer pageOffset, Integer pageSize, final ApiCallback callback) throws ApiException { - - ProgressResponseBody.ProgressListener progressListener = null; - ProgressRequestBody.ProgressRequestListener progressRequestListener = null; - - if (callback != null) { - progressListener = new ProgressResponseBody.ProgressListener() { - @Override - public void update(long bytesRead, long contentLength, boolean done) { - callback.onDownloadProgress(bytesRead, contentLength, done); - } - }; - - progressRequestListener = new ProgressRequestBody.ProgressRequestListener() { - @Override - public void onRequestProgress(long bytesWritten, long contentLength, boolean done) { - callback.onUploadProgress(bytesWritten, contentLength, done); - } - }; - } - - com.squareup.okhttp.Call call = getCurrentUserDevicesValidateBeforeCall(pageOffset, pageSize, progressListener, progressRequestListener); - Type localVarReturnType = new TypeToken(){}.getType(); - apiClient.executeAsync(call, localVarReturnType, callback); - return call; - } - /** - * Build call for getCurrentUserPlaces - * @param pageOffset The offset in terms of elements. (optional, default to 0) - * @param pageSize The maximum number of elements on the page. (optional, default to 20) - * @param progressListener Progress listener - * @param progressRequestListener Progress request listener - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - */ - public com.squareup.okhttp.Call getCurrentUserPlacesCall(Integer pageOffset, Integer pageSize, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - Object localVarPostBody = null; - - // create path and map variables - String localVarPath = "/users/current/places"; - - List localVarQueryParams = new ArrayList(); - if (pageOffset != null) - localVarQueryParams.addAll(apiClient.parameterToPairs("", "pageOffset", pageOffset)); - if (pageSize != null) - localVarQueryParams.addAll(apiClient.parameterToPairs("", "pageSize", pageSize)); - - Map localVarHeaderParams = new HashMap(); - - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json", "application/xml" - }; - final String localVarAccept = apiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) localVarHeaderParams.put("Accept", localVarAccept); - - final String[] localVarContentTypes = { - "application/json", "application/xml" - }; - final String localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); - - if(progressListener != null) { - apiClient.getHttpClient().networkInterceptors().add(new com.squareup.okhttp.Interceptor() { - @Override - public com.squareup.okhttp.Response intercept(com.squareup.okhttp.Interceptor.Chain chain) throws IOException { - com.squareup.okhttp.Response originalResponse = chain.proceed(chain.request()); - return originalResponse.newBuilder() - .body(new ProgressResponseBody(originalResponse.body(), progressListener)) - .build(); - } - }); - } - - String[] localVarAuthNames = new String[] { }; - return apiClient.buildCall(localVarPath, "GET", localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, progressRequestListener); - } - - @SuppressWarnings("rawtypes") - private com.squareup.okhttp.Call getCurrentUserPlacesValidateBeforeCall(Integer pageOffset, Integer pageSize, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - - - com.squareup.okhttp.Call call = getCurrentUserPlacesCall(pageOffset, pageSize, progressListener, progressRequestListener); - return call; - - - - - - } - - /** - * Returns the places for the current user. - * - * @param pageOffset The offset in terms of elements. (optional, default to 0) - * @param pageSize The maximum number of elements on the page. (optional, default to 20) - * @return PlacePage - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public PlacePage getCurrentUserPlaces(Integer pageOffset, Integer pageSize) throws ApiException { - ApiResponse resp = getCurrentUserPlacesWithHttpInfo(pageOffset, pageSize); - return resp.getData(); - } - - /** - * Returns the places for the current user. - * - * @param pageOffset The offset in terms of elements. (optional, default to 0) - * @param pageSize The maximum number of elements on the page. (optional, default to 20) - * @return ApiResponse<PlacePage> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public ApiResponse getCurrentUserPlacesWithHttpInfo(Integer pageOffset, Integer pageSize) throws ApiException { - com.squareup.okhttp.Call call = getCurrentUserPlacesValidateBeforeCall(pageOffset, pageSize, null, null); - Type localVarReturnType = new TypeToken(){}.getType(); - return apiClient.execute(call, localVarReturnType); - } - - /** - * Returns the places for the current user. (asynchronously) - * - * @param pageOffset The offset in terms of elements. (optional, default to 0) - * @param pageSize The maximum number of elements on the page. (optional, default to 20) - * @param callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - */ - public com.squareup.okhttp.Call getCurrentUserPlacesAsync(Integer pageOffset, Integer pageSize, final ApiCallback callback) throws ApiException { - - ProgressResponseBody.ProgressListener progressListener = null; - ProgressRequestBody.ProgressRequestListener progressRequestListener = null; - - if (callback != null) { - progressListener = new ProgressResponseBody.ProgressListener() { - @Override - public void update(long bytesRead, long contentLength, boolean done) { - callback.onDownloadProgress(bytesRead, contentLength, done); - } - }; - - progressRequestListener = new ProgressRequestBody.ProgressRequestListener() { - @Override - public void onRequestProgress(long bytesWritten, long contentLength, boolean done) { - callback.onUploadProgress(bytesWritten, contentLength, done); - } - }; - } - - com.squareup.okhttp.Call call = getCurrentUserPlacesValidateBeforeCall(pageOffset, pageSize, progressListener, progressRequestListener); - Type localVarReturnType = new TypeToken(){}.getType(); - apiClient.executeAsync(call, localVarReturnType, callback); - return call; - } - /** - * Build call for getCurrentUserPrivileges - * @param pageOffset The offset in terms of elements. (optional, default to 0) - * @param pageSize The maximum number of elements on the page. (optional, default to 20) - * @param progressListener Progress listener - * @param progressRequestListener Progress request listener - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - */ - public com.squareup.okhttp.Call getCurrentUserPrivilegesCall(Integer pageOffset, Integer pageSize, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - Object localVarPostBody = null; - - // create path and map variables - String localVarPath = "/users/current/privileges"; - - List localVarQueryParams = new ArrayList(); - if (pageOffset != null) - localVarQueryParams.addAll(apiClient.parameterToPairs("", "pageOffset", pageOffset)); - if (pageSize != null) - localVarQueryParams.addAll(apiClient.parameterToPairs("", "pageSize", pageSize)); - - Map localVarHeaderParams = new HashMap(); - - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json", "application/xml" - }; - final String localVarAccept = apiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) localVarHeaderParams.put("Accept", localVarAccept); - - final String[] localVarContentTypes = { - "application/json", "application/xml" - }; - final String localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); - - if(progressListener != null) { - apiClient.getHttpClient().networkInterceptors().add(new com.squareup.okhttp.Interceptor() { - @Override - public com.squareup.okhttp.Response intercept(com.squareup.okhttp.Interceptor.Chain chain) throws IOException { - com.squareup.okhttp.Response originalResponse = chain.proceed(chain.request()); - return originalResponse.newBuilder() - .body(new ProgressResponseBody(originalResponse.body(), progressListener)) - .build(); - } - }); - } - - String[] localVarAuthNames = new String[] { "user" }; - return apiClient.buildCall(localVarPath, "GET", localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, progressRequestListener); - } - - @SuppressWarnings("rawtypes") - private com.squareup.okhttp.Call getCurrentUserPrivilegesValidateBeforeCall(Integer pageOffset, Integer pageSize, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - - - com.squareup.okhttp.Call call = getCurrentUserPrivilegesCall(pageOffset, pageSize, progressListener, progressRequestListener); - return call; - - - - - - } - - /** - * Returns the privileges for the current user. - * - * @param pageOffset The offset in terms of elements. (optional, default to 0) - * @param pageSize The maximum number of elements on the page. (optional, default to 20) - * @return PrivilegePage - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public PrivilegePage getCurrentUserPrivileges(Integer pageOffset, Integer pageSize) throws ApiException { - ApiResponse resp = getCurrentUserPrivilegesWithHttpInfo(pageOffset, pageSize); - return resp.getData(); - } - - /** - * Returns the privileges for the current user. - * - * @param pageOffset The offset in terms of elements. (optional, default to 0) - * @param pageSize The maximum number of elements on the page. (optional, default to 20) - * @return ApiResponse<PrivilegePage> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public ApiResponse getCurrentUserPrivilegesWithHttpInfo(Integer pageOffset, Integer pageSize) throws ApiException { - com.squareup.okhttp.Call call = getCurrentUserPrivilegesValidateBeforeCall(pageOffset, pageSize, null, null); - Type localVarReturnType = new TypeToken(){}.getType(); - return apiClient.execute(call, localVarReturnType); - } - - /** - * Returns the privileges for the current user. (asynchronously) - * - * @param pageOffset The offset in terms of elements. (optional, default to 0) - * @param pageSize The maximum number of elements on the page. (optional, default to 20) - * @param callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - */ - public com.squareup.okhttp.Call getCurrentUserPrivilegesAsync(Integer pageOffset, Integer pageSize, final ApiCallback callback) throws ApiException { - - ProgressResponseBody.ProgressListener progressListener = null; - ProgressRequestBody.ProgressRequestListener progressRequestListener = null; - - if (callback != null) { - progressListener = new ProgressResponseBody.ProgressListener() { - @Override - public void update(long bytesRead, long contentLength, boolean done) { - callback.onDownloadProgress(bytesRead, contentLength, done); - } - }; - - progressRequestListener = new ProgressRequestBody.ProgressRequestListener() { - @Override - public void onRequestProgress(long bytesWritten, long contentLength, boolean done) { - callback.onUploadProgress(bytesWritten, contentLength, done); - } - }; - } - - com.squareup.okhttp.Call call = getCurrentUserPrivilegesValidateBeforeCall(pageOffset, pageSize, progressListener, progressRequestListener); - Type localVarReturnType = new TypeToken(){}.getType(); - apiClient.executeAsync(call, localVarReturnType, callback); - return call; - } - /** - * Build call for getDevice - * @param id The device id. (required) - * @param progressListener Progress listener - * @param progressRequestListener Progress request listener - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - */ - public com.squareup.okhttp.Call getDeviceCall(Long id, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - Object localVarPostBody = null; - - // create path and map variables - String localVarPath = "/devices/{id}" - .replaceAll("\\{" + "id" + "\\}", apiClient.escapeString(id.toString())); - - List localVarQueryParams = new ArrayList(); - - Map localVarHeaderParams = new HashMap(); - - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json", "application/xml" - }; - final String localVarAccept = apiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) localVarHeaderParams.put("Accept", localVarAccept); - - final String[] localVarContentTypes = { - "application/json", "application/xml" - }; - final String localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); - - if(progressListener != null) { - apiClient.getHttpClient().networkInterceptors().add(new com.squareup.okhttp.Interceptor() { - @Override - public com.squareup.okhttp.Response intercept(com.squareup.okhttp.Interceptor.Chain chain) throws IOException { - com.squareup.okhttp.Response originalResponse = chain.proceed(chain.request()); - return originalResponse.newBuilder() - .body(new ProgressResponseBody(originalResponse.body(), progressListener)) - .build(); - } - }); - } - - String[] localVarAuthNames = new String[] { "admin", "user" }; - return apiClient.buildCall(localVarPath, "GET", localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, progressRequestListener); - } - - @SuppressWarnings("rawtypes") - private com.squareup.okhttp.Call getDeviceValidateBeforeCall(Long id, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - - // verify the required parameter 'id' is set - if (id == null) { - throw new ApiException("Missing the required parameter 'id' when calling getDevice(Async)"); - } - - - com.squareup.okhttp.Call call = getDeviceCall(id, progressListener, progressRequestListener); - return call; - - - - - - } - - /** - * Gets a device. - * - * @param id The device id. (required) - * @return Device - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public Device getDevice(Long id) throws ApiException { - ApiResponse resp = getDeviceWithHttpInfo(id); - return resp.getData(); - } - - /** - * Gets a device. - * - * @param id The device id. (required) - * @return ApiResponse<Device> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public ApiResponse getDeviceWithHttpInfo(Long id) throws ApiException { - com.squareup.okhttp.Call call = getDeviceValidateBeforeCall(id, null, null); - Type localVarReturnType = new TypeToken(){}.getType(); - return apiClient.execute(call, localVarReturnType); - } - - /** - * Gets a device. (asynchronously) - * - * @param id The device id. (required) - * @param callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - */ - public com.squareup.okhttp.Call getDeviceAsync(Long id, final ApiCallback callback) throws ApiException { - - ProgressResponseBody.ProgressListener progressListener = null; - ProgressRequestBody.ProgressRequestListener progressRequestListener = null; - - if (callback != null) { - progressListener = new ProgressResponseBody.ProgressListener() { - @Override - public void update(long bytesRead, long contentLength, boolean done) { - callback.onDownloadProgress(bytesRead, contentLength, done); - } - }; - - progressRequestListener = new ProgressRequestBody.ProgressRequestListener() { - @Override - public void onRequestProgress(long bytesWritten, long contentLength, boolean done) { - callback.onUploadProgress(bytesWritten, contentLength, done); - } - }; - } - - com.squareup.okhttp.Call call = getDeviceValidateBeforeCall(id, progressListener, progressRequestListener); - Type localVarReturnType = new TypeToken(){}.getType(); - apiClient.executeAsync(call, localVarReturnType, callback); - return call; - } - /** - * Build call for getDeviceLocation - * @param id The device id. (required) - * @param progressListener Progress listener - * @param progressRequestListener Progress request listener - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - */ - public com.squareup.okhttp.Call getDeviceLocationCall(Long id, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - Object localVarPostBody = null; - - // create path and map variables - String localVarPath = "/devices/{id}/location" - .replaceAll("\\{" + "id" + "\\}", apiClient.escapeString(id.toString())); - - List localVarQueryParams = new ArrayList(); - - Map localVarHeaderParams = new HashMap(); - - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json", "application/xml" - }; - final String localVarAccept = apiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) localVarHeaderParams.put("Accept", localVarAccept); - - final String[] localVarContentTypes = { - "application/json", "application/xml" - }; - final String localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); - - if(progressListener != null) { - apiClient.getHttpClient().networkInterceptors().add(new com.squareup.okhttp.Interceptor() { - @Override - public com.squareup.okhttp.Response intercept(com.squareup.okhttp.Interceptor.Chain chain) throws IOException { - com.squareup.okhttp.Response originalResponse = chain.proceed(chain.request()); - return originalResponse.newBuilder() - .body(new ProgressResponseBody(originalResponse.body(), progressListener)) - .build(); - } - }); - } - - String[] localVarAuthNames = new String[] { "admin", "user" }; - return apiClient.buildCall(localVarPath, "GET", localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, progressRequestListener); - } - - @SuppressWarnings("rawtypes") - private com.squareup.okhttp.Call getDeviceLocationValidateBeforeCall(Long id, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - - // verify the required parameter 'id' is set - if (id == null) { - throw new ApiException("Missing the required parameter 'id' when calling getDeviceLocation(Async)"); - } - - - com.squareup.okhttp.Call call = getDeviceLocationCall(id, progressListener, progressRequestListener); - return call; - - - - - - } - - /** - * Gets the last device location. - * - * @param id The device id. (required) - * @return Location - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public Location getDeviceLocation(Long id) throws ApiException { - ApiResponse resp = getDeviceLocationWithHttpInfo(id); - return resp.getData(); - } - - /** - * Gets the last device location. - * - * @param id The device id. (required) - * @return ApiResponse<Location> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public ApiResponse getDeviceLocationWithHttpInfo(Long id) throws ApiException { - com.squareup.okhttp.Call call = getDeviceLocationValidateBeforeCall(id, null, null); - Type localVarReturnType = new TypeToken(){}.getType(); - return apiClient.execute(call, localVarReturnType); - } - - /** - * Gets the last device location. (asynchronously) - * - * @param id The device id. (required) - * @param callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - */ - public com.squareup.okhttp.Call getDeviceLocationAsync(Long id, final ApiCallback callback) throws ApiException { - - ProgressResponseBody.ProgressListener progressListener = null; - ProgressRequestBody.ProgressRequestListener progressRequestListener = null; - - if (callback != null) { - progressListener = new ProgressResponseBody.ProgressListener() { - @Override - public void update(long bytesRead, long contentLength, boolean done) { - callback.onDownloadProgress(bytesRead, contentLength, done); - } - }; - - progressRequestListener = new ProgressRequestBody.ProgressRequestListener() { - @Override - public void onRequestProgress(long bytesWritten, long contentLength, boolean done) { - callback.onUploadProgress(bytesWritten, contentLength, done); - } - }; - } - - com.squareup.okhttp.Call call = getDeviceLocationValidateBeforeCall(id, progressListener, progressRequestListener); - Type localVarReturnType = new TypeToken(){}.getType(); - apiClient.executeAsync(call, localVarReturnType, callback); - return call; - } - /** - * Build call for getDeviceVisits - * @param id The device id. (required) - * @param start The start time in Epoch milliseconds. (required) - * @param duration The duration in milliseconds. (required) - * @param progressListener Progress listener - * @param progressRequestListener Progress request listener - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - */ - public com.squareup.okhttp.Call getDeviceVisitsCall(Long id, Long start, Long duration, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - Object localVarPostBody = null; - - // create path and map variables - String localVarPath = "/devices/{id}/visits" - .replaceAll("\\{" + "id" + "\\}", apiClient.escapeString(id.toString())) - .replaceAll("\\{" + "start" + "\\}", apiClient.escapeString(start.toString())) - .replaceAll("\\{" + "duration" + "\\}", apiClient.escapeString(duration.toString())); - - List localVarQueryParams = new ArrayList(); - - Map localVarHeaderParams = new HashMap(); - - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json", "application/xml" - }; - final String localVarAccept = apiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) localVarHeaderParams.put("Accept", localVarAccept); - - final String[] localVarContentTypes = { - "application/json", "application/xml" - }; - final String localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); - - if(progressListener != null) { - apiClient.getHttpClient().networkInterceptors().add(new com.squareup.okhttp.Interceptor() { - @Override - public com.squareup.okhttp.Response intercept(com.squareup.okhttp.Interceptor.Chain chain) throws IOException { - com.squareup.okhttp.Response originalResponse = chain.proceed(chain.request()); - return originalResponse.newBuilder() - .body(new ProgressResponseBody(originalResponse.body(), progressListener)) - .build(); - } - }); - } - - String[] localVarAuthNames = new String[] { "admin", "user" }; - return apiClient.buildCall(localVarPath, "GET", localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, progressRequestListener); - } - - @SuppressWarnings("rawtypes") - private com.squareup.okhttp.Call getDeviceVisitsValidateBeforeCall(Long id, Long start, Long duration, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - - // verify the required parameter 'id' is set - if (id == null) { - throw new ApiException("Missing the required parameter 'id' when calling getDeviceVisits(Async)"); - } - - // verify the required parameter 'start' is set - if (start == null) { - throw new ApiException("Missing the required parameter 'start' when calling getDeviceVisits(Async)"); - } - - // verify the required parameter 'duration' is set - if (duration == null) { - throw new ApiException("Missing the required parameter 'duration' when calling getDeviceVisits(Async)"); - } - - - com.squareup.okhttp.Call call = getDeviceVisitsCall(id, start, duration, progressListener, progressRequestListener); - return call; - - - - - - } - - /** - * Gets the last device location. - * - * @param id The device id. (required) - * @param start The start time in Epoch milliseconds. (required) - * @param duration The duration in milliseconds. (required) - * @return List<Visit> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public List getDeviceVisits(Long id, Long start, Long duration) throws ApiException { - ApiResponse> resp = getDeviceVisitsWithHttpInfo(id, start, duration); - return resp.getData(); - } - - /** - * Gets the last device location. - * - * @param id The device id. (required) - * @param start The start time in Epoch milliseconds. (required) - * @param duration The duration in milliseconds. (required) - * @return ApiResponse<List<Visit>> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public ApiResponse> getDeviceVisitsWithHttpInfo(Long id, Long start, Long duration) throws ApiException { - com.squareup.okhttp.Call call = getDeviceVisitsValidateBeforeCall(id, start, duration, null, null); - Type localVarReturnType = new TypeToken>(){}.getType(); - return apiClient.execute(call, localVarReturnType); - } - - /** - * Gets the last device location. (asynchronously) - * - * @param id The device id. (required) - * @param start The start time in Epoch milliseconds. (required) - * @param duration The duration in milliseconds. (required) - * @param callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - */ - public com.squareup.okhttp.Call getDeviceVisitsAsync(Long id, Long start, Long duration, final ApiCallback> callback) throws ApiException { - - ProgressResponseBody.ProgressListener progressListener = null; - ProgressRequestBody.ProgressRequestListener progressRequestListener = null; - - if (callback != null) { - progressListener = new ProgressResponseBody.ProgressListener() { - @Override - public void update(long bytesRead, long contentLength, boolean done) { - callback.onDownloadProgress(bytesRead, contentLength, done); - } - }; - - progressRequestListener = new ProgressRequestBody.ProgressRequestListener() { - @Override - public void onRequestProgress(long bytesWritten, long contentLength, boolean done) { - callback.onUploadProgress(bytesWritten, contentLength, done); - } - }; - } - - com.squareup.okhttp.Call call = getDeviceVisitsValidateBeforeCall(id, start, duration, progressListener, progressRequestListener); - Type localVarReturnType = new TypeToken>(){}.getType(); - apiClient.executeAsync(call, localVarReturnType, callback); - return call; - } - /** - * Build call for getDevices - * @param pageOffset The offset in terms of elements. (optional, default to 0) - * @param pageSize The maximum number of elements on the page. (optional, default to 20) - * @param progressListener Progress listener - * @param progressRequestListener Progress request listener - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - */ - public com.squareup.okhttp.Call getDevicesCall(Integer pageOffset, Integer pageSize, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - Object localVarPostBody = null; - - // create path and map variables - String localVarPath = "/devices"; - - List localVarQueryParams = new ArrayList(); - if (pageOffset != null) - localVarQueryParams.addAll(apiClient.parameterToPairs("", "pageOffset", pageOffset)); - if (pageSize != null) - localVarQueryParams.addAll(apiClient.parameterToPairs("", "pageSize", pageSize)); - - Map localVarHeaderParams = new HashMap(); - - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json", "application/xml" - }; - final String localVarAccept = apiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) localVarHeaderParams.put("Accept", localVarAccept); - - final String[] localVarContentTypes = { - "application/json", "application/xml" - }; - final String localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); - - if(progressListener != null) { - apiClient.getHttpClient().networkInterceptors().add(new com.squareup.okhttp.Interceptor() { - @Override - public com.squareup.okhttp.Response intercept(com.squareup.okhttp.Interceptor.Chain chain) throws IOException { - com.squareup.okhttp.Response originalResponse = chain.proceed(chain.request()); - return originalResponse.newBuilder() - .body(new ProgressResponseBody(originalResponse.body(), progressListener)) - .build(); - } - }); - } - - String[] localVarAuthNames = new String[] { "admin" }; - return apiClient.buildCall(localVarPath, "GET", localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, progressRequestListener); - } - - @SuppressWarnings("rawtypes") - private com.squareup.okhttp.Call getDevicesValidateBeforeCall(Integer pageOffset, Integer pageSize, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - - - com.squareup.okhttp.Call call = getDevicesCall(pageOffset, pageSize, progressListener, progressRequestListener); - return call; - - - - - - } - - /** - * Returns all devices. - * - * @param pageOffset The offset in terms of elements. (optional, default to 0) - * @param pageSize The maximum number of elements on the page. (optional, default to 20) - * @return DevicePage - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public DevicePage getDevices(Integer pageOffset, Integer pageSize) throws ApiException { - ApiResponse resp = getDevicesWithHttpInfo(pageOffset, pageSize); - return resp.getData(); - } - - /** - * Returns all devices. - * - * @param pageOffset The offset in terms of elements. (optional, default to 0) - * @param pageSize The maximum number of elements on the page. (optional, default to 20) - * @return ApiResponse<DevicePage> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public ApiResponse getDevicesWithHttpInfo(Integer pageOffset, Integer pageSize) throws ApiException { - com.squareup.okhttp.Call call = getDevicesValidateBeforeCall(pageOffset, pageSize, null, null); - Type localVarReturnType = new TypeToken(){}.getType(); - return apiClient.execute(call, localVarReturnType); - } - - /** - * Returns all devices. (asynchronously) - * - * @param pageOffset The offset in terms of elements. (optional, default to 0) - * @param pageSize The maximum number of elements on the page. (optional, default to 20) - * @param callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - */ - public com.squareup.okhttp.Call getDevicesAsync(Integer pageOffset, Integer pageSize, final ApiCallback callback) throws ApiException { - - ProgressResponseBody.ProgressListener progressListener = null; - ProgressRequestBody.ProgressRequestListener progressRequestListener = null; - - if (callback != null) { - progressListener = new ProgressResponseBody.ProgressListener() { - @Override - public void update(long bytesRead, long contentLength, boolean done) { - callback.onDownloadProgress(bytesRead, contentLength, done); - } - }; - - progressRequestListener = new ProgressRequestBody.ProgressRequestListener() { - @Override - public void onRequestProgress(long bytesWritten, long contentLength, boolean done) { - callback.onUploadProgress(bytesWritten, contentLength, done); - } - }; - } - - com.squareup.okhttp.Call call = getDevicesValidateBeforeCall(pageOffset, pageSize, progressListener, progressRequestListener); - Type localVarReturnType = new TypeToken(){}.getType(); - apiClient.executeAsync(call, localVarReturnType, callback); - return call; - } - /** - * Build call for getEntityStatistics - * @param progressListener Progress listener - * @param progressRequestListener Progress request listener - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - */ - public com.squareup.okhttp.Call getEntityStatisticsCall(final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - Object localVarPostBody = null; - - // create path and map variables - String localVarPath = "/log/entities"; - - List localVarQueryParams = new ArrayList(); - - Map localVarHeaderParams = new HashMap(); - - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json", "application/xml" - }; - final String localVarAccept = apiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) localVarHeaderParams.put("Accept", localVarAccept); - - final String[] localVarContentTypes = { - - }; - final String localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); - - if(progressListener != null) { - apiClient.getHttpClient().networkInterceptors().add(new com.squareup.okhttp.Interceptor() { - @Override - public com.squareup.okhttp.Response intercept(com.squareup.okhttp.Interceptor.Chain chain) throws IOException { - com.squareup.okhttp.Response originalResponse = chain.proceed(chain.request()); - return originalResponse.newBuilder() - .body(new ProgressResponseBody(originalResponse.body(), progressListener)) - .build(); - } - }); - } - - String[] localVarAuthNames = new String[] { "admin" }; - return apiClient.buildCall(localVarPath, "GET", localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, progressRequestListener); - } - - @SuppressWarnings("rawtypes") - private com.squareup.okhttp.Call getEntityStatisticsValidateBeforeCall(final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - - - com.squareup.okhttp.Call call = getEntityStatisticsCall(progressListener, progressRequestListener); - return call; - - - - - - } - - /** - * Returns a list of entity statistics. - * - * @return List<EntityStatistic> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public List getEntityStatistics() throws ApiException { - ApiResponse> resp = getEntityStatisticsWithHttpInfo(); - return resp.getData(); - } - - /** - * Returns a list of entity statistics. - * - * @return ApiResponse<List<EntityStatistic>> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public ApiResponse> getEntityStatisticsWithHttpInfo() throws ApiException { - com.squareup.okhttp.Call call = getEntityStatisticsValidateBeforeCall(null, null); - Type localVarReturnType = new TypeToken>(){}.getType(); - return apiClient.execute(call, localVarReturnType); - } - - /** - * Returns a list of entity statistics. (asynchronously) - * - * @param callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - */ - public com.squareup.okhttp.Call getEntityStatisticsAsync(final ApiCallback> callback) throws ApiException { - - ProgressResponseBody.ProgressListener progressListener = null; - ProgressRequestBody.ProgressRequestListener progressRequestListener = null; - - if (callback != null) { - progressListener = new ProgressResponseBody.ProgressListener() { - @Override - public void update(long bytesRead, long contentLength, boolean done) { - callback.onDownloadProgress(bytesRead, contentLength, done); - } - }; - - progressRequestListener = new ProgressRequestBody.ProgressRequestListener() { - @Override - public void onRequestProgress(long bytesWritten, long contentLength, boolean done) { - callback.onUploadProgress(bytesWritten, contentLength, done); - } - }; - } - - com.squareup.okhttp.Call call = getEntityStatisticsValidateBeforeCall(progressListener, progressRequestListener); - Type localVarReturnType = new TypeToken>(){}.getType(); - apiClient.executeAsync(call, localVarReturnType, callback); - return call; - } - /** - * Build call for getLoadStatistic - * @param progressListener Progress listener - * @param progressRequestListener Progress request listener - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - */ - public com.squareup.okhttp.Call getLoadStatisticCall(final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - Object localVarPostBody = null; - - // create path and map variables - String localVarPath = "/log/load"; - - List localVarQueryParams = new ArrayList(); - - Map localVarHeaderParams = new HashMap(); - - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json", "application/xml" - }; - final String localVarAccept = apiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) localVarHeaderParams.put("Accept", localVarAccept); - - final String[] localVarContentTypes = { - - }; - final String localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); - - if(progressListener != null) { - apiClient.getHttpClient().networkInterceptors().add(new com.squareup.okhttp.Interceptor() { - @Override - public com.squareup.okhttp.Response intercept(com.squareup.okhttp.Interceptor.Chain chain) throws IOException { - com.squareup.okhttp.Response originalResponse = chain.proceed(chain.request()); - return originalResponse.newBuilder() - .body(new ProgressResponseBody(originalResponse.body(), progressListener)) - .build(); - } - }); - } - - String[] localVarAuthNames = new String[] { "admin" }; - return apiClient.buildCall(localVarPath, "GET", localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, progressRequestListener); - } - - @SuppressWarnings("rawtypes") - private com.squareup.okhttp.Call getLoadStatisticValidateBeforeCall(final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - - - com.squareup.okhttp.Call call = getLoadStatisticCall(progressListener, progressRequestListener); - return call; - - - - - - } - - /** - * Returns the current load statistic. - * - * @return LoadStatistic - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public LoadStatistic getLoadStatistic() throws ApiException { - ApiResponse resp = getLoadStatisticWithHttpInfo(); - return resp.getData(); - } - - /** - * Returns the current load statistic. - * - * @return ApiResponse<LoadStatistic> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public ApiResponse getLoadStatisticWithHttpInfo() throws ApiException { - com.squareup.okhttp.Call call = getLoadStatisticValidateBeforeCall(null, null); - Type localVarReturnType = new TypeToken(){}.getType(); - return apiClient.execute(call, localVarReturnType); - } - - /** - * Returns the current load statistic. (asynchronously) - * - * @param callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - */ - public com.squareup.okhttp.Call getLoadStatisticAsync(final ApiCallback callback) throws ApiException { - - ProgressResponseBody.ProgressListener progressListener = null; - ProgressRequestBody.ProgressRequestListener progressRequestListener = null; - - if (callback != null) { - progressListener = new ProgressResponseBody.ProgressListener() { - @Override - public void update(long bytesRead, long contentLength, boolean done) { - callback.onDownloadProgress(bytesRead, contentLength, done); - } - }; - - progressRequestListener = new ProgressRequestBody.ProgressRequestListener() { - @Override - public void onRequestProgress(long bytesWritten, long contentLength, boolean done) { - callback.onUploadProgress(bytesWritten, contentLength, done); - } - }; - } - - com.squareup.okhttp.Call call = getLoadStatisticValidateBeforeCall(progressListener, progressRequestListener); - Type localVarReturnType = new TypeToken(){}.getType(); - apiClient.executeAsync(call, localVarReturnType, callback); - return call; - } - /** - * Build call for getLogMessages - * @param from The id of the first message to retrieve. (optional, default to 0) - * @param progressListener Progress listener - * @param progressRequestListener Progress request listener - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - */ - public com.squareup.okhttp.Call getLogMessagesCall(Long from, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - Object localVarPostBody = null; - - // create path and map variables - String localVarPath = "/log/messages"; - - List localVarQueryParams = new ArrayList(); - if (from != null) - localVarQueryParams.addAll(apiClient.parameterToPairs("", "from", from)); - - Map localVarHeaderParams = new HashMap(); - - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json", "application/xml" - }; - final String localVarAccept = apiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) localVarHeaderParams.put("Accept", localVarAccept); - - final String[] localVarContentTypes = { - - }; - final String localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); - - if(progressListener != null) { - apiClient.getHttpClient().networkInterceptors().add(new com.squareup.okhttp.Interceptor() { - @Override - public com.squareup.okhttp.Response intercept(com.squareup.okhttp.Interceptor.Chain chain) throws IOException { - com.squareup.okhttp.Response originalResponse = chain.proceed(chain.request()); - return originalResponse.newBuilder() - .body(new ProgressResponseBody(originalResponse.body(), progressListener)) - .build(); - } - }); - } - - String[] localVarAuthNames = new String[] { "admin" }; - return apiClient.buildCall(localVarPath, "GET", localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, progressRequestListener); - } - - @SuppressWarnings("rawtypes") - private com.squareup.okhttp.Call getLogMessagesValidateBeforeCall(Long from, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - - - com.squareup.okhttp.Call call = getLogMessagesCall(from, progressListener, progressRequestListener); - return call; - - - - - - } - - /** - * Returns a list of log messages starting from a particular id. - * - * @param from The id of the first message to retrieve. (optional, default to 0) - * @return List<LogMessage> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public List getLogMessages(Long from) throws ApiException { - ApiResponse> resp = getLogMessagesWithHttpInfo(from); - return resp.getData(); - } - - /** - * Returns a list of log messages starting from a particular id. - * - * @param from The id of the first message to retrieve. (optional, default to 0) - * @return ApiResponse<List<LogMessage>> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public ApiResponse> getLogMessagesWithHttpInfo(Long from) throws ApiException { - com.squareup.okhttp.Call call = getLogMessagesValidateBeforeCall(from, null, null); - Type localVarReturnType = new TypeToken>(){}.getType(); - return apiClient.execute(call, localVarReturnType); - } - - /** - * Returns a list of log messages starting from a particular id. (asynchronously) - * - * @param from The id of the first message to retrieve. (optional, default to 0) - * @param callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - */ - public com.squareup.okhttp.Call getLogMessagesAsync(Long from, final ApiCallback> callback) throws ApiException { - - ProgressResponseBody.ProgressListener progressListener = null; - ProgressRequestBody.ProgressRequestListener progressRequestListener = null; - - if (callback != null) { - progressListener = new ProgressResponseBody.ProgressListener() { - @Override - public void update(long bytesRead, long contentLength, boolean done) { - callback.onDownloadProgress(bytesRead, contentLength, done); - } - }; - - progressRequestListener = new ProgressRequestBody.ProgressRequestListener() { - @Override - public void onRequestProgress(long bytesWritten, long contentLength, boolean done) { - callback.onUploadProgress(bytesWritten, contentLength, done); - } - }; - } - - com.squareup.okhttp.Call call = getLogMessagesValidateBeforeCall(from, progressListener, progressRequestListener); - Type localVarReturnType = new TypeToken>(){}.getType(); - apiClient.executeAsync(call, localVarReturnType, callback); - return call; - } - /** - * Build call for getNotice - * @param id The id of the notice. (required) - * @param progressListener Progress listener - * @param progressRequestListener Progress request listener - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - */ - public com.squareup.okhttp.Call getNoticeCall(Long id, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - Object localVarPostBody = null; - - // create path and map variables - String localVarPath = "/notices/{id}" - .replaceAll("\\{" + "id" + "\\}", apiClient.escapeString(id.toString())); - - List localVarQueryParams = new ArrayList(); - - Map localVarHeaderParams = new HashMap(); - - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json", "application/xml" - }; - final String localVarAccept = apiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) localVarHeaderParams.put("Accept", localVarAccept); - - final String[] localVarContentTypes = { - "application/json", "application/xml" - }; - final String localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); - - if(progressListener != null) { - apiClient.getHttpClient().networkInterceptors().add(new com.squareup.okhttp.Interceptor() { - @Override - public com.squareup.okhttp.Response intercept(com.squareup.okhttp.Interceptor.Chain chain) throws IOException { - com.squareup.okhttp.Response originalResponse = chain.proceed(chain.request()); - return originalResponse.newBuilder() - .body(new ProgressResponseBody(originalResponse.body(), progressListener)) - .build(); - } - }); - } - - String[] localVarAuthNames = new String[] { "admin" }; - return apiClient.buildCall(localVarPath, "GET", localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, progressRequestListener); - } - - @SuppressWarnings("rawtypes") - private com.squareup.okhttp.Call getNoticeValidateBeforeCall(Long id, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - - // verify the required parameter 'id' is set - if (id == null) { - throw new ApiException("Missing the required parameter 'id' when calling getNotice(Async)"); - } - - - com.squareup.okhttp.Call call = getNoticeCall(id, progressListener, progressRequestListener); - return call; - - - - - - } - - /** - * Returns the notice with the specified id. - * - * @param id The id of the notice. (required) - * @return Notice - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public Notice getNotice(Long id) throws ApiException { - ApiResponse resp = getNoticeWithHttpInfo(id); - return resp.getData(); - } - - /** - * Returns the notice with the specified id. - * - * @param id The id of the notice. (required) - * @return ApiResponse<Notice> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public ApiResponse getNoticeWithHttpInfo(Long id) throws ApiException { - com.squareup.okhttp.Call call = getNoticeValidateBeforeCall(id, null, null); - Type localVarReturnType = new TypeToken(){}.getType(); - return apiClient.execute(call, localVarReturnType); - } - - /** - * Returns the notice with the specified id. (asynchronously) - * - * @param id The id of the notice. (required) - * @param callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - */ - public com.squareup.okhttp.Call getNoticeAsync(Long id, final ApiCallback callback) throws ApiException { - - ProgressResponseBody.ProgressListener progressListener = null; - ProgressRequestBody.ProgressRequestListener progressRequestListener = null; - - if (callback != null) { - progressListener = new ProgressResponseBody.ProgressListener() { - @Override - public void update(long bytesRead, long contentLength, boolean done) { - callback.onDownloadProgress(bytesRead, contentLength, done); - } - }; - - progressRequestListener = new ProgressRequestBody.ProgressRequestListener() { - @Override - public void onRequestProgress(long bytesWritten, long contentLength, boolean done) { - callback.onUploadProgress(bytesWritten, contentLength, done); - } - }; - } - - com.squareup.okhttp.Call call = getNoticeValidateBeforeCall(id, progressListener, progressRequestListener); - Type localVarReturnType = new TypeToken(){}.getType(); - apiClient.executeAsync(call, localVarReturnType, callback); - return call; - } - /** - * Build call for getNotices - * @param pageOffset The offset in terms of elements. (optional, default to 0) - * @param pageSize The maximum number of elements on the page. (optional, default to 20) - * @param progressListener Progress listener - * @param progressRequestListener Progress request listener - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - */ - public com.squareup.okhttp.Call getNoticesCall(Integer pageOffset, Integer pageSize, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - Object localVarPostBody = null; - - // create path and map variables - String localVarPath = "/notices"; - - List localVarQueryParams = new ArrayList(); - if (pageOffset != null) - localVarQueryParams.addAll(apiClient.parameterToPairs("", "pageOffset", pageOffset)); - if (pageSize != null) - localVarQueryParams.addAll(apiClient.parameterToPairs("", "pageSize", pageSize)); - - Map localVarHeaderParams = new HashMap(); - - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json", "application/xml" - }; - final String localVarAccept = apiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) localVarHeaderParams.put("Accept", localVarAccept); - - final String[] localVarContentTypes = { - "application/json", "application/xml" - }; - final String localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); - - if(progressListener != null) { - apiClient.getHttpClient().networkInterceptors().add(new com.squareup.okhttp.Interceptor() { - @Override - public com.squareup.okhttp.Response intercept(com.squareup.okhttp.Interceptor.Chain chain) throws IOException { - com.squareup.okhttp.Response originalResponse = chain.proceed(chain.request()); - return originalResponse.newBuilder() - .body(new ProgressResponseBody(originalResponse.body(), progressListener)) - .build(); - } - }); - } - - String[] localVarAuthNames = new String[] { "admin" }; - return apiClient.buildCall(localVarPath, "GET", localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, progressRequestListener); - } - - @SuppressWarnings("rawtypes") - private com.squareup.okhttp.Call getNoticesValidateBeforeCall(Integer pageOffset, Integer pageSize, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - - - com.squareup.okhttp.Call call = getNoticesCall(pageOffset, pageSize, progressListener, progressRequestListener); - return call; - - - - - - } - - /** - * Returns a page of notices. - * - * @param pageOffset The offset in terms of elements. (optional, default to 0) - * @param pageSize The maximum number of elements on the page. (optional, default to 20) - * @return NoticePage - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public NoticePage getNotices(Integer pageOffset, Integer pageSize) throws ApiException { - ApiResponse resp = getNoticesWithHttpInfo(pageOffset, pageSize); - return resp.getData(); - } - - /** - * Returns a page of notices. - * - * @param pageOffset The offset in terms of elements. (optional, default to 0) - * @param pageSize The maximum number of elements on the page. (optional, default to 20) - * @return ApiResponse<NoticePage> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public ApiResponse getNoticesWithHttpInfo(Integer pageOffset, Integer pageSize) throws ApiException { - com.squareup.okhttp.Call call = getNoticesValidateBeforeCall(pageOffset, pageSize, null, null); - Type localVarReturnType = new TypeToken(){}.getType(); - return apiClient.execute(call, localVarReturnType); - } - - /** - * Returns a page of notices. (asynchronously) - * - * @param pageOffset The offset in terms of elements. (optional, default to 0) - * @param pageSize The maximum number of elements on the page. (optional, default to 20) - * @param callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - */ - public com.squareup.okhttp.Call getNoticesAsync(Integer pageOffset, Integer pageSize, final ApiCallback callback) throws ApiException { - - ProgressResponseBody.ProgressListener progressListener = null; - ProgressRequestBody.ProgressRequestListener progressRequestListener = null; - - if (callback != null) { - progressListener = new ProgressResponseBody.ProgressListener() { - @Override - public void update(long bytesRead, long contentLength, boolean done) { - callback.onDownloadProgress(bytesRead, contentLength, done); - } - }; - - progressRequestListener = new ProgressRequestBody.ProgressRequestListener() { - @Override - public void onRequestProgress(long bytesWritten, long contentLength, boolean done) { - callback.onUploadProgress(bytesWritten, contentLength, done); - } - }; - } - - com.squareup.okhttp.Call call = getNoticesValidateBeforeCall(pageOffset, pageSize, progressListener, progressRequestListener); - Type localVarReturnType = new TypeToken(){}.getType(); - apiClient.executeAsync(call, localVarReturnType, callback); - return call; - } - /** - * Build call for getPlace - * @param id The place id. (required) - * @param progressListener Progress listener - * @param progressRequestListener Progress request listener - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - */ - public com.squareup.okhttp.Call getPlaceCall(Long id, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - Object localVarPostBody = null; - - // create path and map variables - String localVarPath = "/places/{id}" - .replaceAll("\\{" + "id" + "\\}", apiClient.escapeString(id.toString())); - - List localVarQueryParams = new ArrayList(); - - Map localVarHeaderParams = new HashMap(); - - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json", "application/xml" - }; - final String localVarAccept = apiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) localVarHeaderParams.put("Accept", localVarAccept); - - final String[] localVarContentTypes = { - "application/json", "application/xml" - }; - final String localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); - - if(progressListener != null) { - apiClient.getHttpClient().networkInterceptors().add(new com.squareup.okhttp.Interceptor() { - @Override - public com.squareup.okhttp.Response intercept(com.squareup.okhttp.Interceptor.Chain chain) throws IOException { - com.squareup.okhttp.Response originalResponse = chain.proceed(chain.request()); - return originalResponse.newBuilder() - .body(new ProgressResponseBody(originalResponse.body(), progressListener)) - .build(); - } - }); - } - - String[] localVarAuthNames = new String[] { }; - return apiClient.buildCall(localVarPath, "GET", localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, progressRequestListener); - } - - @SuppressWarnings("rawtypes") - private com.squareup.okhttp.Call getPlaceValidateBeforeCall(Long id, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - - // verify the required parameter 'id' is set - if (id == null) { - throw new ApiException("Missing the required parameter 'id' when calling getPlace(Async)"); - } - - - com.squareup.okhttp.Call call = getPlaceCall(id, progressListener, progressRequestListener); - return call; - - - - - - } - - /** - * Returns the place with the specified id. - * - * @param id The place id. (required) - * @return Place - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public Place getPlace(Long id) throws ApiException { - ApiResponse resp = getPlaceWithHttpInfo(id); - return resp.getData(); - } - - /** - * Returns the place with the specified id. - * - * @param id The place id. (required) - * @return ApiResponse<Place> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public ApiResponse getPlaceWithHttpInfo(Long id) throws ApiException { - com.squareup.okhttp.Call call = getPlaceValidateBeforeCall(id, null, null); - Type localVarReturnType = new TypeToken(){}.getType(); - return apiClient.execute(call, localVarReturnType); - } - - /** - * Returns the place with the specified id. (asynchronously) - * - * @param id The place id. (required) - * @param callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - */ - public com.squareup.okhttp.Call getPlaceAsync(Long id, final ApiCallback callback) throws ApiException { - - ProgressResponseBody.ProgressListener progressListener = null; - ProgressRequestBody.ProgressRequestListener progressRequestListener = null; - - if (callback != null) { - progressListener = new ProgressResponseBody.ProgressListener() { - @Override - public void update(long bytesRead, long contentLength, boolean done) { - callback.onDownloadProgress(bytesRead, contentLength, done); - } - }; - - progressRequestListener = new ProgressRequestBody.ProgressRequestListener() { - @Override - public void onRequestProgress(long bytesWritten, long contentLength, boolean done) { - callback.onUploadProgress(bytesWritten, contentLength, done); - } - }; - } - - com.squareup.okhttp.Call call = getPlaceValidateBeforeCall(id, progressListener, progressRequestListener); - Type localVarReturnType = new TypeToken(){}.getType(); - apiClient.executeAsync(call, localVarReturnType, callback); - return call; - } - /** - * Build call for getPlaceVisits - * @param id The place id. (required) - * @param pageOffset The offset in terms of elements. (optional, default to 0) - * @param pageSize The maximum number of elements on the page. (optional, default to 20) - * @param progressListener Progress listener - * @param progressRequestListener Progress request listener - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - */ - public com.squareup.okhttp.Call getPlaceVisitsCall(Long id, Integer pageOffset, Integer pageSize, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - Object localVarPostBody = null; - - // create path and map variables - String localVarPath = "/places/{id}/visits" - .replaceAll("\\{" + "id" + "\\}", apiClient.escapeString(id.toString())); - - List localVarQueryParams = new ArrayList(); - if (pageOffset != null) - localVarQueryParams.addAll(apiClient.parameterToPairs("", "pageOffset", pageOffset)); - if (pageSize != null) - localVarQueryParams.addAll(apiClient.parameterToPairs("", "pageSize", pageSize)); - - Map localVarHeaderParams = new HashMap(); - - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json", "application/xml" - }; - final String localVarAccept = apiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) localVarHeaderParams.put("Accept", localVarAccept); - - final String[] localVarContentTypes = { - "application/json", "application/xml" - }; - final String localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); - - if(progressListener != null) { - apiClient.getHttpClient().networkInterceptors().add(new com.squareup.okhttp.Interceptor() { - @Override - public com.squareup.okhttp.Response intercept(com.squareup.okhttp.Interceptor.Chain chain) throws IOException { - com.squareup.okhttp.Response originalResponse = chain.proceed(chain.request()); - return originalResponse.newBuilder() - .body(new ProgressResponseBody(originalResponse.body(), progressListener)) - .build(); - } - }); - } - - String[] localVarAuthNames = new String[] { }; - return apiClient.buildCall(localVarPath, "GET", localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, progressRequestListener); - } - - @SuppressWarnings("rawtypes") - private com.squareup.okhttp.Call getPlaceVisitsValidateBeforeCall(Long id, Integer pageOffset, Integer pageSize, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - - // verify the required parameter 'id' is set - if (id == null) { - throw new ApiException("Missing the required parameter 'id' when calling getPlaceVisits(Async)"); - } - - - com.squareup.okhttp.Call call = getPlaceVisitsCall(id, pageOffset, pageSize, progressListener, progressRequestListener); - return call; - - - - - - } - - /** - * Returns the visits for a particular place. - * - * @param id The place id. (required) - * @param pageOffset The offset in terms of elements. (optional, default to 0) - * @param pageSize The maximum number of elements on the page. (optional, default to 20) - * @return VisitPage - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public VisitPage getPlaceVisits(Long id, Integer pageOffset, Integer pageSize) throws ApiException { - ApiResponse resp = getPlaceVisitsWithHttpInfo(id, pageOffset, pageSize); - return resp.getData(); - } - - /** - * Returns the visits for a particular place. - * - * @param id The place id. (required) - * @param pageOffset The offset in terms of elements. (optional, default to 0) - * @param pageSize The maximum number of elements on the page. (optional, default to 20) - * @return ApiResponse<VisitPage> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public ApiResponse getPlaceVisitsWithHttpInfo(Long id, Integer pageOffset, Integer pageSize) throws ApiException { - com.squareup.okhttp.Call call = getPlaceVisitsValidateBeforeCall(id, pageOffset, pageSize, null, null); - Type localVarReturnType = new TypeToken(){}.getType(); - return apiClient.execute(call, localVarReturnType); - } - - /** - * Returns the visits for a particular place. (asynchronously) - * - * @param id The place id. (required) - * @param pageOffset The offset in terms of elements. (optional, default to 0) - * @param pageSize The maximum number of elements on the page. (optional, default to 20) - * @param callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - */ - public com.squareup.okhttp.Call getPlaceVisitsAsync(Long id, Integer pageOffset, Integer pageSize, final ApiCallback callback) throws ApiException { - - ProgressResponseBody.ProgressListener progressListener = null; - ProgressRequestBody.ProgressRequestListener progressRequestListener = null; - - if (callback != null) { - progressListener = new ProgressResponseBody.ProgressListener() { - @Override - public void update(long bytesRead, long contentLength, boolean done) { - callback.onDownloadProgress(bytesRead, contentLength, done); - } - }; - - progressRequestListener = new ProgressRequestBody.ProgressRequestListener() { - @Override - public void onRequestProgress(long bytesWritten, long contentLength, boolean done) { - callback.onUploadProgress(bytesWritten, contentLength, done); - } - }; - } - - com.squareup.okhttp.Call call = getPlaceVisitsValidateBeforeCall(id, pageOffset, pageSize, progressListener, progressRequestListener); - Type localVarReturnType = new TypeToken(){}.getType(); - apiClient.executeAsync(call, localVarReturnType, callback); - return call; - } - /** - * Build call for getPrivilege - * @param id The privilege id. (required) - * @param progressListener Progress listener - * @param progressRequestListener Progress request listener - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - */ - public com.squareup.okhttp.Call getPrivilegeCall(Long id, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - Object localVarPostBody = null; - - // create path and map variables - String localVarPath = "/privileges/{id}" - .replaceAll("\\{" + "id" + "\\}", apiClient.escapeString(id.toString())); - - List localVarQueryParams = new ArrayList(); - - Map localVarHeaderParams = new HashMap(); - - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json", "application/xml" - }; - final String localVarAccept = apiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) localVarHeaderParams.put("Accept", localVarAccept); - - final String[] localVarContentTypes = { - "application/json", "application/xml" - }; - final String localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); - - if(progressListener != null) { - apiClient.getHttpClient().networkInterceptors().add(new com.squareup.okhttp.Interceptor() { - @Override - public com.squareup.okhttp.Response intercept(com.squareup.okhttp.Interceptor.Chain chain) throws IOException { - com.squareup.okhttp.Response originalResponse = chain.proceed(chain.request()); - return originalResponse.newBuilder() - .body(new ProgressResponseBody(originalResponse.body(), progressListener)) - .build(); - } - }); - } - - String[] localVarAuthNames = new String[] { "admin", "user" }; - return apiClient.buildCall(localVarPath, "GET", localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, progressRequestListener); - } - - @SuppressWarnings("rawtypes") - private com.squareup.okhttp.Call getPrivilegeValidateBeforeCall(Long id, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - - // verify the required parameter 'id' is set - if (id == null) { - throw new ApiException("Missing the required parameter 'id' when calling getPrivilege(Async)"); - } - - - com.squareup.okhttp.Call call = getPrivilegeCall(id, progressListener, progressRequestListener); - return call; - - - - - - } - - /** - * Returns the privileges for a particular user. - * - * @param id The privilege id. (required) - * @return Privilege - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public Privilege getPrivilege(Long id) throws ApiException { - ApiResponse resp = getPrivilegeWithHttpInfo(id); - return resp.getData(); - } - - /** - * Returns the privileges for a particular user. - * - * @param id The privilege id. (required) - * @return ApiResponse<Privilege> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public ApiResponse getPrivilegeWithHttpInfo(Long id) throws ApiException { - com.squareup.okhttp.Call call = getPrivilegeValidateBeforeCall(id, null, null); - Type localVarReturnType = new TypeToken(){}.getType(); - return apiClient.execute(call, localVarReturnType); - } - - /** - * Returns the privileges for a particular user. (asynchronously) - * - * @param id The privilege id. (required) - * @param callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - */ - public com.squareup.okhttp.Call getPrivilegeAsync(Long id, final ApiCallback callback) throws ApiException { - - ProgressResponseBody.ProgressListener progressListener = null; - ProgressRequestBody.ProgressRequestListener progressRequestListener = null; - - if (callback != null) { - progressListener = new ProgressResponseBody.ProgressListener() { - @Override - public void update(long bytesRead, long contentLength, boolean done) { - callback.onDownloadProgress(bytesRead, contentLength, done); - } - }; - - progressRequestListener = new ProgressRequestBody.ProgressRequestListener() { - @Override - public void onRequestProgress(long bytesWritten, long contentLength, boolean done) { - callback.onUploadProgress(bytesWritten, contentLength, done); - } - }; - } - - com.squareup.okhttp.Call call = getPrivilegeValidateBeforeCall(id, progressListener, progressRequestListener); - Type localVarReturnType = new TypeToken(){}.getType(); - apiClient.executeAsync(call, localVarReturnType, callback); - return call; - } - /** - * Build call for getPrivilegeLocation - * @param id The privilege id. (required) - * @param progressListener Progress listener - * @param progressRequestListener Progress request listener - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - */ - public com.squareup.okhttp.Call getPrivilegeLocationCall(Long id, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - Object localVarPostBody = null; - - // create path and map variables - String localVarPath = "/privileges/{id}/location" - .replaceAll("\\{" + "id" + "\\}", apiClient.escapeString(id.toString())); - - List localVarQueryParams = new ArrayList(); - - Map localVarHeaderParams = new HashMap(); - - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json", "application/xml" - }; - final String localVarAccept = apiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) localVarHeaderParams.put("Accept", localVarAccept); - - final String[] localVarContentTypes = { - "application/json", "application/xml" - }; - final String localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); - - if(progressListener != null) { - apiClient.getHttpClient().networkInterceptors().add(new com.squareup.okhttp.Interceptor() { - @Override - public com.squareup.okhttp.Response intercept(com.squareup.okhttp.Interceptor.Chain chain) throws IOException { - com.squareup.okhttp.Response originalResponse = chain.proceed(chain.request()); - return originalResponse.newBuilder() - .body(new ProgressResponseBody(originalResponse.body(), progressListener)) - .build(); - } - }); - } - - String[] localVarAuthNames = new String[] { "admin", "user" }; - return apiClient.buildCall(localVarPath, "GET", localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, progressRequestListener); - } - - @SuppressWarnings("rawtypes") - private com.squareup.okhttp.Call getPrivilegeLocationValidateBeforeCall(Long id, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - - // verify the required parameter 'id' is set - if (id == null) { - throw new ApiException("Missing the required parameter 'id' when calling getPrivilegeLocation(Async)"); - } - - - com.squareup.okhttp.Call call = getPrivilegeLocationCall(id, progressListener, progressRequestListener); - return call; - - - - - - } - - /** - * Returns the location for a particular privilege. - * - * @param id The privilege id. (required) - * @return Location - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public Location getPrivilegeLocation(Long id) throws ApiException { - ApiResponse resp = getPrivilegeLocationWithHttpInfo(id); - return resp.getData(); - } - - /** - * Returns the location for a particular privilege. - * - * @param id The privilege id. (required) - * @return ApiResponse<Location> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public ApiResponse getPrivilegeLocationWithHttpInfo(Long id) throws ApiException { - com.squareup.okhttp.Call call = getPrivilegeLocationValidateBeforeCall(id, null, null); - Type localVarReturnType = new TypeToken(){}.getType(); - return apiClient.execute(call, localVarReturnType); - } - - /** - * Returns the location for a particular privilege. (asynchronously) - * - * @param id The privilege id. (required) - * @param callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - */ - public com.squareup.okhttp.Call getPrivilegeLocationAsync(Long id, final ApiCallback callback) throws ApiException { - - ProgressResponseBody.ProgressListener progressListener = null; - ProgressRequestBody.ProgressRequestListener progressRequestListener = null; - - if (callback != null) { - progressListener = new ProgressResponseBody.ProgressListener() { - @Override - public void update(long bytesRead, long contentLength, boolean done) { - callback.onDownloadProgress(bytesRead, contentLength, done); - } - }; - - progressRequestListener = new ProgressRequestBody.ProgressRequestListener() { - @Override - public void onRequestProgress(long bytesWritten, long contentLength, boolean done) { - callback.onUploadProgress(bytesWritten, contentLength, done); - } - }; - } - - com.squareup.okhttp.Call call = getPrivilegeLocationValidateBeforeCall(id, progressListener, progressRequestListener); - Type localVarReturnType = new TypeToken(){}.getType(); - apiClient.executeAsync(call, localVarReturnType, callback); - return call; - } - /** - * Build call for getShare - * @param id The share id. (required) - * @param progressListener Progress listener - * @param progressRequestListener Progress request listener - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - */ - public com.squareup.okhttp.Call getShareCall(Long id, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - Object localVarPostBody = null; - - // create path and map variables - String localVarPath = "/shares/{id}" - .replaceAll("\\{" + "id" + "\\}", apiClient.escapeString(id.toString())); - - List localVarQueryParams = new ArrayList(); - - Map localVarHeaderParams = new HashMap(); - - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json", "application/xml" - }; - final String localVarAccept = apiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) localVarHeaderParams.put("Accept", localVarAccept); - - final String[] localVarContentTypes = { - "application/json", "application/xml" - }; - final String localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); - - if(progressListener != null) { - apiClient.getHttpClient().networkInterceptors().add(new com.squareup.okhttp.Interceptor() { - @Override - public com.squareup.okhttp.Response intercept(com.squareup.okhttp.Interceptor.Chain chain) throws IOException { - com.squareup.okhttp.Response originalResponse = chain.proceed(chain.request()); - return originalResponse.newBuilder() - .body(new ProgressResponseBody(originalResponse.body(), progressListener)) - .build(); - } - }); - } - - String[] localVarAuthNames = new String[] { "device" }; - return apiClient.buildCall(localVarPath, "GET", localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, progressRequestListener); - } - - @SuppressWarnings("rawtypes") - private com.squareup.okhttp.Call getShareValidateBeforeCall(Long id, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - - // verify the required parameter 'id' is set - if (id == null) { - throw new ApiException("Missing the required parameter 'id' when calling getShare(Async)"); - } - - - com.squareup.okhttp.Call call = getShareCall(id, progressListener, progressRequestListener); - return call; - - - - - - } - - /** - * Returns a share. - * - * @param id The share id. (required) - * @return Share - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public Share getShare(Long id) throws ApiException { - ApiResponse resp = getShareWithHttpInfo(id); - return resp.getData(); - } - - /** - * Returns a share. - * - * @param id The share id. (required) - * @return ApiResponse<Share> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public ApiResponse getShareWithHttpInfo(Long id) throws ApiException { - com.squareup.okhttp.Call call = getShareValidateBeforeCall(id, null, null); - Type localVarReturnType = new TypeToken(){}.getType(); - return apiClient.execute(call, localVarReturnType); - } - - /** - * Returns a share. (asynchronously) - * - * @param id The share id. (required) - * @param callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - */ - public com.squareup.okhttp.Call getShareAsync(Long id, final ApiCallback callback) throws ApiException { - - ProgressResponseBody.ProgressListener progressListener = null; - ProgressRequestBody.ProgressRequestListener progressRequestListener = null; - - if (callback != null) { - progressListener = new ProgressResponseBody.ProgressListener() { - @Override - public void update(long bytesRead, long contentLength, boolean done) { - callback.onDownloadProgress(bytesRead, contentLength, done); - } - }; - - progressRequestListener = new ProgressRequestBody.ProgressRequestListener() { - @Override - public void onRequestProgress(long bytesWritten, long contentLength, boolean done) { - callback.onUploadProgress(bytesWritten, contentLength, done); - } - }; - } - - com.squareup.okhttp.Call call = getShareValidateBeforeCall(id, progressListener, progressRequestListener); - Type localVarReturnType = new TypeToken(){}.getType(); - apiClient.executeAsync(call, localVarReturnType, callback); - return call; - } - /** - * Build call for getShareInfo - * @param token The secret token. (required) - * @param progressListener Progress listener - * @param progressRequestListener Progress request listener - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - */ - public com.squareup.okhttp.Call getShareInfoCall(String token, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - Object localVarPostBody = null; - - // create path and map variables - String localVarPath = "/shares/{token}/info" - .replaceAll("\\{" + "token" + "\\}", apiClient.escapeString(token.toString())); - - List localVarQueryParams = new ArrayList(); - - Map localVarHeaderParams = new HashMap(); - - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json", "application/xml" - }; - final String localVarAccept = apiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) localVarHeaderParams.put("Accept", localVarAccept); - - final String[] localVarContentTypes = { - "application/json", "application/xml" - }; - final String localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); - - if(progressListener != null) { - apiClient.getHttpClient().networkInterceptors().add(new com.squareup.okhttp.Interceptor() { - @Override - public com.squareup.okhttp.Response intercept(com.squareup.okhttp.Interceptor.Chain chain) throws IOException { - com.squareup.okhttp.Response originalResponse = chain.proceed(chain.request()); - return originalResponse.newBuilder() - .body(new ProgressResponseBody(originalResponse.body(), progressListener)) - .build(); - } - }); - } - - String[] localVarAuthNames = new String[] { }; - return apiClient.buildCall(localVarPath, "GET", localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, progressRequestListener); - } - - @SuppressWarnings("rawtypes") - private com.squareup.okhttp.Call getShareInfoValidateBeforeCall(String token, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - - // verify the required parameter 'token' is set - if (token == null) { - throw new ApiException("Missing the required parameter 'token' when calling getShareInfo(Async)"); - } - - - com.squareup.okhttp.Call call = getShareInfoCall(token, progressListener, progressRequestListener); - return call; - - - - - - } - - /** - * Get a share info by its secret token. - * - * @param token The secret token. (required) - * @return ShareInfo - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public ShareInfo getShareInfo(String token) throws ApiException { - ApiResponse resp = getShareInfoWithHttpInfo(token); - return resp.getData(); - } - - /** - * Get a share info by its secret token. - * - * @param token The secret token. (required) - * @return ApiResponse<ShareInfo> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public ApiResponse getShareInfoWithHttpInfo(String token) throws ApiException { - com.squareup.okhttp.Call call = getShareInfoValidateBeforeCall(token, null, null); - Type localVarReturnType = new TypeToken(){}.getType(); - return apiClient.execute(call, localVarReturnType); - } - - /** - * Get a share info by its secret token. (asynchronously) - * - * @param token The secret token. (required) - * @param callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - */ - public com.squareup.okhttp.Call getShareInfoAsync(String token, final ApiCallback callback) throws ApiException { - - ProgressResponseBody.ProgressListener progressListener = null; - ProgressRequestBody.ProgressRequestListener progressRequestListener = null; - - if (callback != null) { - progressListener = new ProgressResponseBody.ProgressListener() { - @Override - public void update(long bytesRead, long contentLength, boolean done) { - callback.onDownloadProgress(bytesRead, contentLength, done); - } - }; - - progressRequestListener = new ProgressRequestBody.ProgressRequestListener() { - @Override - public void onRequestProgress(long bytesWritten, long contentLength, boolean done) { - callback.onUploadProgress(bytesWritten, contentLength, done); - } - }; - } - - com.squareup.okhttp.Call call = getShareInfoValidateBeforeCall(token, progressListener, progressRequestListener); - Type localVarReturnType = new TypeToken(){}.getType(); - apiClient.executeAsync(call, localVarReturnType, callback); - return call; - } - /** - * Build call for getShareLocation - * @param token The secret token. (required) - * @param progressListener Progress listener - * @param progressRequestListener Progress request listener - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - */ - public com.squareup.okhttp.Call getShareLocationCall(String token, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - Object localVarPostBody = null; - - // create path and map variables - String localVarPath = "/shares/{token}/location" - .replaceAll("\\{" + "token" + "\\}", apiClient.escapeString(token.toString())); - - List localVarQueryParams = new ArrayList(); - - Map localVarHeaderParams = new HashMap(); - - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json", "application/xml" - }; - final String localVarAccept = apiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) localVarHeaderParams.put("Accept", localVarAccept); - - final String[] localVarContentTypes = { - "application/json", "application/xml" - }; - final String localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); - - if(progressListener != null) { - apiClient.getHttpClient().networkInterceptors().add(new com.squareup.okhttp.Interceptor() { - @Override - public com.squareup.okhttp.Response intercept(com.squareup.okhttp.Interceptor.Chain chain) throws IOException { - com.squareup.okhttp.Response originalResponse = chain.proceed(chain.request()); - return originalResponse.newBuilder() - .body(new ProgressResponseBody(originalResponse.body(), progressListener)) - .build(); - } - }); - } - - String[] localVarAuthNames = new String[] { }; - return apiClient.buildCall(localVarPath, "GET", localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, progressRequestListener); - } - - @SuppressWarnings("rawtypes") - private com.squareup.okhttp.Call getShareLocationValidateBeforeCall(String token, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - - // verify the required parameter 'token' is set - if (token == null) { - throw new ApiException("Missing the required parameter 'token' when calling getShareLocation(Async)"); - } - - - com.squareup.okhttp.Call call = getShareLocationCall(token, progressListener, progressRequestListener); - return call; - - - - - - } - - /** - * Get a shared location by its secret token. - * - * @param token The secret token. (required) - * @return Location - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public Location getShareLocation(String token) throws ApiException { - ApiResponse resp = getShareLocationWithHttpInfo(token); - return resp.getData(); - } - - /** - * Get a shared location by its secret token. - * - * @param token The secret token. (required) - * @return ApiResponse<Location> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public ApiResponse getShareLocationWithHttpInfo(String token) throws ApiException { - com.squareup.okhttp.Call call = getShareLocationValidateBeforeCall(token, null, null); - Type localVarReturnType = new TypeToken(){}.getType(); - return apiClient.execute(call, localVarReturnType); - } - - /** - * Get a shared location by its secret token. (asynchronously) - * - * @param token The secret token. (required) - * @param callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - */ - public com.squareup.okhttp.Call getShareLocationAsync(String token, final ApiCallback callback) throws ApiException { - - ProgressResponseBody.ProgressListener progressListener = null; - ProgressRequestBody.ProgressRequestListener progressRequestListener = null; - - if (callback != null) { - progressListener = new ProgressResponseBody.ProgressListener() { - @Override - public void update(long bytesRead, long contentLength, boolean done) { - callback.onDownloadProgress(bytesRead, contentLength, done); - } - }; - - progressRequestListener = new ProgressRequestBody.ProgressRequestListener() { - @Override - public void onRequestProgress(long bytesWritten, long contentLength, boolean done) { - callback.onUploadProgress(bytesWritten, contentLength, done); - } - }; - } - - com.squareup.okhttp.Call call = getShareLocationValidateBeforeCall(token, progressListener, progressRequestListener); - Type localVarReturnType = new TypeToken(){}.getType(); - apiClient.executeAsync(call, localVarReturnType, callback); - return call; - } - /** - * Build call for getSystemStatistic - * @param progressListener Progress listener - * @param progressRequestListener Progress request listener - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - */ - public com.squareup.okhttp.Call getSystemStatisticCall(final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - Object localVarPostBody = null; - - // create path and map variables - String localVarPath = "/log/system"; - - List localVarQueryParams = new ArrayList(); - - Map localVarHeaderParams = new HashMap(); - - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json", "application/xml" - }; - final String localVarAccept = apiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) localVarHeaderParams.put("Accept", localVarAccept); - - final String[] localVarContentTypes = { - - }; - final String localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); - - if(progressListener != null) { - apiClient.getHttpClient().networkInterceptors().add(new com.squareup.okhttp.Interceptor() { - @Override - public com.squareup.okhttp.Response intercept(com.squareup.okhttp.Interceptor.Chain chain) throws IOException { - com.squareup.okhttp.Response originalResponse = chain.proceed(chain.request()); - return originalResponse.newBuilder() - .body(new ProgressResponseBody(originalResponse.body(), progressListener)) - .build(); - } - }); - } - - String[] localVarAuthNames = new String[] { "admin" }; - return apiClient.buildCall(localVarPath, "GET", localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, progressRequestListener); - } - - @SuppressWarnings("rawtypes") - private com.squareup.okhttp.Call getSystemStatisticValidateBeforeCall(final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - - - com.squareup.okhttp.Call call = getSystemStatisticCall(progressListener, progressRequestListener); - return call; - - - - - - } - - /** - * Returns the system statistic. - * - * @return LoadStatistic - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public LoadStatistic getSystemStatistic() throws ApiException { - ApiResponse resp = getSystemStatisticWithHttpInfo(); - return resp.getData(); - } - - /** - * Returns the system statistic. - * - * @return ApiResponse<LoadStatistic> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public ApiResponse getSystemStatisticWithHttpInfo() throws ApiException { - com.squareup.okhttp.Call call = getSystemStatisticValidateBeforeCall(null, null); - Type localVarReturnType = new TypeToken(){}.getType(); - return apiClient.execute(call, localVarReturnType); - } - - /** - * Returns the system statistic. (asynchronously) - * - * @param callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - */ - public com.squareup.okhttp.Call getSystemStatisticAsync(final ApiCallback callback) throws ApiException { - - ProgressResponseBody.ProgressListener progressListener = null; - ProgressRequestBody.ProgressRequestListener progressRequestListener = null; - - if (callback != null) { - progressListener = new ProgressResponseBody.ProgressListener() { - @Override - public void update(long bytesRead, long contentLength, boolean done) { - callback.onDownloadProgress(bytesRead, contentLength, done); - } - }; - - progressRequestListener = new ProgressRequestBody.ProgressRequestListener() { - @Override - public void onRequestProgress(long bytesWritten, long contentLength, boolean done) { - callback.onUploadProgress(bytesWritten, contentLength, done); - } - }; - } - - com.squareup.okhttp.Call call = getSystemStatisticValidateBeforeCall(progressListener, progressRequestListener); - Type localVarReturnType = new TypeToken(){}.getType(); - apiClient.executeAsync(call, localVarReturnType, callback); - return call; - } - /** - * Build call for getUpdatedNotices - * @param since The earlies time in epoch milliseconds. (optional, default to 0) - * @param progressListener Progress listener - * @param progressRequestListener Progress request listener - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - */ - public com.squareup.okhttp.Call getUpdatedNoticesCall(Long since, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - Object localVarPostBody = null; - - // create path and map variables - String localVarPath = "/notices/updated"; - - List localVarQueryParams = new ArrayList(); - if (since != null) - localVarQueryParams.addAll(apiClient.parameterToPairs("", "since", since)); - - Map localVarHeaderParams = new HashMap(); - - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json", "application/xml" - }; - final String localVarAccept = apiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) localVarHeaderParams.put("Accept", localVarAccept); - - final String[] localVarContentTypes = { - "application/json", "application/xml" - }; - final String localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); - - if(progressListener != null) { - apiClient.getHttpClient().networkInterceptors().add(new com.squareup.okhttp.Interceptor() { - @Override - public com.squareup.okhttp.Response intercept(com.squareup.okhttp.Interceptor.Chain chain) throws IOException { - com.squareup.okhttp.Response originalResponse = chain.proceed(chain.request()); - return originalResponse.newBuilder() - .body(new ProgressResponseBody(originalResponse.body(), progressListener)) - .build(); - } - }); - } - - String[] localVarAuthNames = new String[] { }; - return apiClient.buildCall(localVarPath, "GET", localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, progressRequestListener); - } - - @SuppressWarnings("rawtypes") - private com.squareup.okhttp.Call getUpdatedNoticesValidateBeforeCall(Long since, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - - - com.squareup.okhttp.Call call = getUpdatedNoticesCall(since, progressListener, progressRequestListener); - return call; - - - - - - } - - /** - * Returns all active notices modified after the date. - * - * @param since The earlies time in epoch milliseconds. (optional, default to 0) - * @return List<Notice> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public List getUpdatedNotices(Long since) throws ApiException { - ApiResponse> resp = getUpdatedNoticesWithHttpInfo(since); - return resp.getData(); - } - - /** - * Returns all active notices modified after the date. - * - * @param since The earlies time in epoch milliseconds. (optional, default to 0) - * @return ApiResponse<List<Notice>> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public ApiResponse> getUpdatedNoticesWithHttpInfo(Long since) throws ApiException { - com.squareup.okhttp.Call call = getUpdatedNoticesValidateBeforeCall(since, null, null); - Type localVarReturnType = new TypeToken>(){}.getType(); - return apiClient.execute(call, localVarReturnType); - } - - /** - * Returns all active notices modified after the date. (asynchronously) - * - * @param since The earlies time in epoch milliseconds. (optional, default to 0) - * @param callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - */ - public com.squareup.okhttp.Call getUpdatedNoticesAsync(Long since, final ApiCallback> callback) throws ApiException { - - ProgressResponseBody.ProgressListener progressListener = null; - ProgressRequestBody.ProgressRequestListener progressRequestListener = null; - - if (callback != null) { - progressListener = new ProgressResponseBody.ProgressListener() { - @Override - public void update(long bytesRead, long contentLength, boolean done) { - callback.onDownloadProgress(bytesRead, contentLength, done); - } - }; - - progressRequestListener = new ProgressRequestBody.ProgressRequestListener() { - @Override - public void onRequestProgress(long bytesWritten, long contentLength, boolean done) { - callback.onUploadProgress(bytesWritten, contentLength, done); - } - }; - } - - com.squareup.okhttp.Call call = getUpdatedNoticesValidateBeforeCall(since, progressListener, progressRequestListener); - Type localVarReturnType = new TypeToken>(){}.getType(); - apiClient.executeAsync(call, localVarReturnType, callback); - return call; - } - /** - * Build call for getUser - * @param id The id of the user to retrieve. (required) - * @param progressListener Progress listener - * @param progressRequestListener Progress request listener - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - */ - public com.squareup.okhttp.Call getUserCall(Long id, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - Object localVarPostBody = null; - - // create path and map variables - String localVarPath = "/users/{id}" - .replaceAll("\\{" + "id" + "\\}", apiClient.escapeString(id.toString())); - - List localVarQueryParams = new ArrayList(); - - Map localVarHeaderParams = new HashMap(); - - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json", "application/xml" - }; - final String localVarAccept = apiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) localVarHeaderParams.put("Accept", localVarAccept); - - final String[] localVarContentTypes = { - "application/json", "application/xml" - }; - final String localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); - - if(progressListener != null) { - apiClient.getHttpClient().networkInterceptors().add(new com.squareup.okhttp.Interceptor() { - @Override - public com.squareup.okhttp.Response intercept(com.squareup.okhttp.Interceptor.Chain chain) throws IOException { - com.squareup.okhttp.Response originalResponse = chain.proceed(chain.request()); - return originalResponse.newBuilder() - .body(new ProgressResponseBody(originalResponse.body(), progressListener)) - .build(); - } - }); - } - - String[] localVarAuthNames = new String[] { "admin" }; - return apiClient.buildCall(localVarPath, "GET", localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, progressRequestListener); - } - - @SuppressWarnings("rawtypes") - private com.squareup.okhttp.Call getUserValidateBeforeCall(Long id, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - - // verify the required parameter 'id' is set - if (id == null) { - throw new ApiException("Missing the required parameter 'id' when calling getUser(Async)"); - } - - - com.squareup.okhttp.Call call = getUserCall(id, progressListener, progressRequestListener); - return call; - - - - - - } - - /** - * Returns the user account with the specified id. - * - * @param id The id of the user to retrieve. (required) - * @return User - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public User getUser(Long id) throws ApiException { - ApiResponse resp = getUserWithHttpInfo(id); - return resp.getData(); - } - - /** - * Returns the user account with the specified id. - * - * @param id The id of the user to retrieve. (required) - * @return ApiResponse<User> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public ApiResponse getUserWithHttpInfo(Long id) throws ApiException { - com.squareup.okhttp.Call call = getUserValidateBeforeCall(id, null, null); - Type localVarReturnType = new TypeToken(){}.getType(); - return apiClient.execute(call, localVarReturnType); - } - - /** - * Returns the user account with the specified id. (asynchronously) - * - * @param id The id of the user to retrieve. (required) - * @param callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - */ - public com.squareup.okhttp.Call getUserAsync(Long id, final ApiCallback callback) throws ApiException { - - ProgressResponseBody.ProgressListener progressListener = null; - ProgressRequestBody.ProgressRequestListener progressRequestListener = null; - - if (callback != null) { - progressListener = new ProgressResponseBody.ProgressListener() { - @Override - public void update(long bytesRead, long contentLength, boolean done) { - callback.onDownloadProgress(bytesRead, contentLength, done); - } - }; - - progressRequestListener = new ProgressRequestBody.ProgressRequestListener() { - @Override - public void onRequestProgress(long bytesWritten, long contentLength, boolean done) { - callback.onUploadProgress(bytesWritten, contentLength, done); - } - }; - } - - com.squareup.okhttp.Call call = getUserValidateBeforeCall(id, progressListener, progressRequestListener); - Type localVarReturnType = new TypeToken(){}.getType(); - apiClient.executeAsync(call, localVarReturnType, callback); - return call; - } - /** - * Build call for getUserPlaces - * @param id The user id. (required) - * @param pageOffset The offset in terms of elements. (optional, default to 0) - * @param pageSize The maximum number of elements on the page. (optional, default to 20) - * @param progressListener Progress listener - * @param progressRequestListener Progress request listener - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - */ - public com.squareup.okhttp.Call getUserPlacesCall(Long id, Integer pageOffset, Integer pageSize, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - Object localVarPostBody = null; - - // create path and map variables - String localVarPath = "/users/{id}/places" - .replaceAll("\\{" + "id" + "\\}", apiClient.escapeString(id.toString())); - - List localVarQueryParams = new ArrayList(); - if (pageOffset != null) - localVarQueryParams.addAll(apiClient.parameterToPairs("", "pageOffset", pageOffset)); - if (pageSize != null) - localVarQueryParams.addAll(apiClient.parameterToPairs("", "pageSize", pageSize)); - - Map localVarHeaderParams = new HashMap(); - - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json", "application/xml" - }; - final String localVarAccept = apiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) localVarHeaderParams.put("Accept", localVarAccept); - - final String[] localVarContentTypes = { - "application/json", "application/xml" - }; - final String localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); - - if(progressListener != null) { - apiClient.getHttpClient().networkInterceptors().add(new com.squareup.okhttp.Interceptor() { - @Override - public com.squareup.okhttp.Response intercept(com.squareup.okhttp.Interceptor.Chain chain) throws IOException { - com.squareup.okhttp.Response originalResponse = chain.proceed(chain.request()); - return originalResponse.newBuilder() - .body(new ProgressResponseBody(originalResponse.body(), progressListener)) - .build(); - } - }); - } - - String[] localVarAuthNames = new String[] { }; - return apiClient.buildCall(localVarPath, "GET", localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, progressRequestListener); - } - - @SuppressWarnings("rawtypes") - private com.squareup.okhttp.Call getUserPlacesValidateBeforeCall(Long id, Integer pageOffset, Integer pageSize, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - - // verify the required parameter 'id' is set - if (id == null) { - throw new ApiException("Missing the required parameter 'id' when calling getUserPlaces(Async)"); - } - - - com.squareup.okhttp.Call call = getUserPlacesCall(id, pageOffset, pageSize, progressListener, progressRequestListener); - return call; - - - - - - } - - /** - * Returns the places for a particular user. - * - * @param id The user id. (required) - * @param pageOffset The offset in terms of elements. (optional, default to 0) - * @param pageSize The maximum number of elements on the page. (optional, default to 20) - * @return PlacePage - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public PlacePage getUserPlaces(Long id, Integer pageOffset, Integer pageSize) throws ApiException { - ApiResponse resp = getUserPlacesWithHttpInfo(id, pageOffset, pageSize); - return resp.getData(); - } - - /** - * Returns the places for a particular user. - * - * @param id The user id. (required) - * @param pageOffset The offset in terms of elements. (optional, default to 0) - * @param pageSize The maximum number of elements on the page. (optional, default to 20) - * @return ApiResponse<PlacePage> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public ApiResponse getUserPlacesWithHttpInfo(Long id, Integer pageOffset, Integer pageSize) throws ApiException { - com.squareup.okhttp.Call call = getUserPlacesValidateBeforeCall(id, pageOffset, pageSize, null, null); - Type localVarReturnType = new TypeToken(){}.getType(); - return apiClient.execute(call, localVarReturnType); - } - - /** - * Returns the places for a particular user. (asynchronously) - * - * @param id The user id. (required) - * @param pageOffset The offset in terms of elements. (optional, default to 0) - * @param pageSize The maximum number of elements on the page. (optional, default to 20) - * @param callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - */ - public com.squareup.okhttp.Call getUserPlacesAsync(Long id, Integer pageOffset, Integer pageSize, final ApiCallback callback) throws ApiException { - - ProgressResponseBody.ProgressListener progressListener = null; - ProgressRequestBody.ProgressRequestListener progressRequestListener = null; - - if (callback != null) { - progressListener = new ProgressResponseBody.ProgressListener() { - @Override - public void update(long bytesRead, long contentLength, boolean done) { - callback.onDownloadProgress(bytesRead, contentLength, done); - } - }; - - progressRequestListener = new ProgressRequestBody.ProgressRequestListener() { - @Override - public void onRequestProgress(long bytesWritten, long contentLength, boolean done) { - callback.onUploadProgress(bytesWritten, contentLength, done); - } - }; - } - - com.squareup.okhttp.Call call = getUserPlacesValidateBeforeCall(id, pageOffset, pageSize, progressListener, progressRequestListener); - Type localVarReturnType = new TypeToken(){}.getType(); - apiClient.executeAsync(call, localVarReturnType, callback); - return call; - } - /** - * Build call for getUserPrivileges - * @param id The user id. (required) - * @param pageOffset The offset in terms of elements. (optional, default to 0) - * @param pageSize The maximum number of elements on the page. (optional, default to 20) - * @param progressListener Progress listener - * @param progressRequestListener Progress request listener - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - */ - public com.squareup.okhttp.Call getUserPrivilegesCall(Long id, Integer pageOffset, Integer pageSize, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - Object localVarPostBody = null; - - // create path and map variables - String localVarPath = "/users/{id}/privileges" - .replaceAll("\\{" + "id" + "\\}", apiClient.escapeString(id.toString())); - - List localVarQueryParams = new ArrayList(); - if (pageOffset != null) - localVarQueryParams.addAll(apiClient.parameterToPairs("", "pageOffset", pageOffset)); - if (pageSize != null) - localVarQueryParams.addAll(apiClient.parameterToPairs("", "pageSize", pageSize)); - - Map localVarHeaderParams = new HashMap(); - - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json", "application/xml" - }; - final String localVarAccept = apiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) localVarHeaderParams.put("Accept", localVarAccept); - - final String[] localVarContentTypes = { - "application/json", "application/xml" - }; - final String localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); - - if(progressListener != null) { - apiClient.getHttpClient().networkInterceptors().add(new com.squareup.okhttp.Interceptor() { - @Override - public com.squareup.okhttp.Response intercept(com.squareup.okhttp.Interceptor.Chain chain) throws IOException { - com.squareup.okhttp.Response originalResponse = chain.proceed(chain.request()); - return originalResponse.newBuilder() - .body(new ProgressResponseBody(originalResponse.body(), progressListener)) - .build(); - } - }); - } - - String[] localVarAuthNames = new String[] { "admin" }; - return apiClient.buildCall(localVarPath, "GET", localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, progressRequestListener); - } - - @SuppressWarnings("rawtypes") - private com.squareup.okhttp.Call getUserPrivilegesValidateBeforeCall(Long id, Integer pageOffset, Integer pageSize, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - - // verify the required parameter 'id' is set - if (id == null) { - throw new ApiException("Missing the required parameter 'id' when calling getUserPrivileges(Async)"); - } - - - com.squareup.okhttp.Call call = getUserPrivilegesCall(id, pageOffset, pageSize, progressListener, progressRequestListener); - return call; - - - - - - } - - /** - * Returns the privileges for a particular user. - * - * @param id The user id. (required) - * @param pageOffset The offset in terms of elements. (optional, default to 0) - * @param pageSize The maximum number of elements on the page. (optional, default to 20) - * @return PrivilegePage - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public PrivilegePage getUserPrivileges(Long id, Integer pageOffset, Integer pageSize) throws ApiException { - ApiResponse resp = getUserPrivilegesWithHttpInfo(id, pageOffset, pageSize); - return resp.getData(); - } - - /** - * Returns the privileges for a particular user. - * - * @param id The user id. (required) - * @param pageOffset The offset in terms of elements. (optional, default to 0) - * @param pageSize The maximum number of elements on the page. (optional, default to 20) - * @return ApiResponse<PrivilegePage> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public ApiResponse getUserPrivilegesWithHttpInfo(Long id, Integer pageOffset, Integer pageSize) throws ApiException { - com.squareup.okhttp.Call call = getUserPrivilegesValidateBeforeCall(id, pageOffset, pageSize, null, null); - Type localVarReturnType = new TypeToken(){}.getType(); - return apiClient.execute(call, localVarReturnType); - } - - /** - * Returns the privileges for a particular user. (asynchronously) - * - * @param id The user id. (required) - * @param pageOffset The offset in terms of elements. (optional, default to 0) - * @param pageSize The maximum number of elements on the page. (optional, default to 20) - * @param callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - */ - public com.squareup.okhttp.Call getUserPrivilegesAsync(Long id, Integer pageOffset, Integer pageSize, final ApiCallback callback) throws ApiException { - - ProgressResponseBody.ProgressListener progressListener = null; - ProgressRequestBody.ProgressRequestListener progressRequestListener = null; - - if (callback != null) { - progressListener = new ProgressResponseBody.ProgressListener() { - @Override - public void update(long bytesRead, long contentLength, boolean done) { - callback.onDownloadProgress(bytesRead, contentLength, done); - } - }; - - progressRequestListener = new ProgressRequestBody.ProgressRequestListener() { - @Override - public void onRequestProgress(long bytesWritten, long contentLength, boolean done) { - callback.onUploadProgress(bytesWritten, contentLength, done); - } - }; - } - - com.squareup.okhttp.Call call = getUserPrivilegesValidateBeforeCall(id, pageOffset, pageSize, progressListener, progressRequestListener); - Type localVarReturnType = new TypeToken(){}.getType(); - apiClient.executeAsync(call, localVarReturnType, callback); - return call; - } - /** - * Build call for getUsers - * @param pageOffset The offset in terms of elements. (optional, default to 0) - * @param pageSize The maximum number of elements on the page. (optional, default to 20) - * @param progressListener Progress listener - * @param progressRequestListener Progress request listener - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - */ - public com.squareup.okhttp.Call getUsersCall(Integer pageOffset, Integer pageSize, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - Object localVarPostBody = null; - - // create path and map variables - String localVarPath = "/users"; - - List localVarQueryParams = new ArrayList(); - if (pageOffset != null) - localVarQueryParams.addAll(apiClient.parameterToPairs("", "pageOffset", pageOffset)); - if (pageSize != null) - localVarQueryParams.addAll(apiClient.parameterToPairs("", "pageSize", pageSize)); - - Map localVarHeaderParams = new HashMap(); - - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json", "application/xml" - }; - final String localVarAccept = apiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) localVarHeaderParams.put("Accept", localVarAccept); - - final String[] localVarContentTypes = { - "application/json", "application/xml" - }; - final String localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); - - if(progressListener != null) { - apiClient.getHttpClient().networkInterceptors().add(new com.squareup.okhttp.Interceptor() { - @Override - public com.squareup.okhttp.Response intercept(com.squareup.okhttp.Interceptor.Chain chain) throws IOException { - com.squareup.okhttp.Response originalResponse = chain.proceed(chain.request()); - return originalResponse.newBuilder() - .body(new ProgressResponseBody(originalResponse.body(), progressListener)) - .build(); - } - }); - } - - String[] localVarAuthNames = new String[] { "admin" }; - return apiClient.buildCall(localVarPath, "GET", localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, progressRequestListener); - } - - @SuppressWarnings("rawtypes") - private com.squareup.okhttp.Call getUsersValidateBeforeCall(Integer pageOffset, Integer pageSize, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - - - com.squareup.okhttp.Call call = getUsersCall(pageOffset, pageSize, progressListener, progressRequestListener); - return call; - - - - - - } - - /** - * Returns a list of users. - * - * @param pageOffset The offset in terms of elements. (optional, default to 0) - * @param pageSize The maximum number of elements on the page. (optional, default to 20) - * @return UserPage - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public UserPage getUsers(Integer pageOffset, Integer pageSize) throws ApiException { - ApiResponse resp = getUsersWithHttpInfo(pageOffset, pageSize); - return resp.getData(); - } - - /** - * Returns a list of users. - * - * @param pageOffset The offset in terms of elements. (optional, default to 0) - * @param pageSize The maximum number of elements on the page. (optional, default to 20) - * @return ApiResponse<UserPage> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public ApiResponse getUsersWithHttpInfo(Integer pageOffset, Integer pageSize) throws ApiException { - com.squareup.okhttp.Call call = getUsersValidateBeforeCall(pageOffset, pageSize, null, null); - Type localVarReturnType = new TypeToken(){}.getType(); - return apiClient.execute(call, localVarReturnType); - } - - /** - * Returns a list of users. (asynchronously) - * - * @param pageOffset The offset in terms of elements. (optional, default to 0) - * @param pageSize The maximum number of elements on the page. (optional, default to 20) - * @param callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - */ - public com.squareup.okhttp.Call getUsersAsync(Integer pageOffset, Integer pageSize, final ApiCallback callback) throws ApiException { - - ProgressResponseBody.ProgressListener progressListener = null; - ProgressRequestBody.ProgressRequestListener progressRequestListener = null; - - if (callback != null) { - progressListener = new ProgressResponseBody.ProgressListener() { - @Override - public void update(long bytesRead, long contentLength, boolean done) { - callback.onDownloadProgress(bytesRead, contentLength, done); - } - }; - - progressRequestListener = new ProgressRequestBody.ProgressRequestListener() { - @Override - public void onRequestProgress(long bytesWritten, long contentLength, boolean done) { - callback.onUploadProgress(bytesWritten, contentLength, done); - } - }; - } - - com.squareup.okhttp.Call call = getUsersValidateBeforeCall(pageOffset, pageSize, progressListener, progressRequestListener); - Type localVarReturnType = new TypeToken(){}.getType(); - apiClient.executeAsync(call, localVarReturnType, callback); - return call; - } - /** - * Build call for registerUser - * @param body The data of the new user. (required) - * @param progressListener Progress listener - * @param progressRequestListener Progress request listener - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - */ - public com.squareup.okhttp.Call registerUserCall(UserRegistration body, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - Object localVarPostBody = body; - - // create path and map variables - String localVarPath = "/users/register"; - - List localVarQueryParams = new ArrayList(); - - Map localVarHeaderParams = new HashMap(); - - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json", "application/xml" - }; - final String localVarAccept = apiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) localVarHeaderParams.put("Accept", localVarAccept); - - final String[] localVarContentTypes = { - "application/json", "application/xml" - }; - final String localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); - - if(progressListener != null) { - apiClient.getHttpClient().networkInterceptors().add(new com.squareup.okhttp.Interceptor() { - @Override - public com.squareup.okhttp.Response intercept(com.squareup.okhttp.Interceptor.Chain chain) throws IOException { - com.squareup.okhttp.Response originalResponse = chain.proceed(chain.request()); - return originalResponse.newBuilder() - .body(new ProgressResponseBody(originalResponse.body(), progressListener)) - .build(); - } - }); - } - - String[] localVarAuthNames = new String[] { }; - return apiClient.buildCall(localVarPath, "POST", localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, progressRequestListener); - } - - @SuppressWarnings("rawtypes") - private com.squareup.okhttp.Call registerUserValidateBeforeCall(UserRegistration body, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - - // verify the required parameter 'body' is set - if (body == null) { - throw new ApiException("Missing the required parameter 'body' when calling registerUser(Async)"); - } - - - com.squareup.okhttp.Call call = registerUserCall(body, progressListener, progressRequestListener); - return call; - - - - - - } - - /** - * Registers a new user and sends an email account verification. - * - * @param body The data of the new user. (required) - * @return User - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public User registerUser(UserRegistration body) throws ApiException { - ApiResponse resp = registerUserWithHttpInfo(body); - return resp.getData(); - } - - /** - * Registers a new user and sends an email account verification. - * - * @param body The data of the new user. (required) - * @return ApiResponse<User> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public ApiResponse registerUserWithHttpInfo(UserRegistration body) throws ApiException { - com.squareup.okhttp.Call call = registerUserValidateBeforeCall(body, null, null); - Type localVarReturnType = new TypeToken(){}.getType(); - return apiClient.execute(call, localVarReturnType); - } - - /** - * Registers a new user and sends an email account verification. (asynchronously) - * - * @param body The data of the new user. (required) - * @param callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - */ - public com.squareup.okhttp.Call registerUserAsync(UserRegistration body, final ApiCallback callback) throws ApiException { - - ProgressResponseBody.ProgressListener progressListener = null; - ProgressRequestBody.ProgressRequestListener progressRequestListener = null; - - if (callback != null) { - progressListener = new ProgressResponseBody.ProgressListener() { - @Override - public void update(long bytesRead, long contentLength, boolean done) { - callback.onDownloadProgress(bytesRead, contentLength, done); - } - }; - - progressRequestListener = new ProgressRequestBody.ProgressRequestListener() { - @Override - public void onRequestProgress(long bytesWritten, long contentLength, boolean done) { - callback.onUploadProgress(bytesWritten, contentLength, done); - } - }; - } - - com.squareup.okhttp.Call call = registerUserValidateBeforeCall(body, progressListener, progressRequestListener); - Type localVarReturnType = new TypeToken(){}.getType(); - apiClient.executeAsync(call, localVarReturnType, callback); - return call; - } - /** - * Build call for resetUser - * @param login The login of the user to reset. (required) - * @param progressListener Progress listener - * @param progressRequestListener Progress request listener - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - */ - public com.squareup.okhttp.Call resetUserCall(String login, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - Object localVarPostBody = null; - - // create path and map variables - String localVarPath = "/users/reset"; - - List localVarQueryParams = new ArrayList(); - if (login != null) - localVarQueryParams.addAll(apiClient.parameterToPairs("", "login", login)); - - Map localVarHeaderParams = new HashMap(); - - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json", "application/xml" - }; - final String localVarAccept = apiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) localVarHeaderParams.put("Accept", localVarAccept); - - final String[] localVarContentTypes = { - "application/json", "application/xml" - }; - final String localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); - - if(progressListener != null) { - apiClient.getHttpClient().networkInterceptors().add(new com.squareup.okhttp.Interceptor() { - @Override - public com.squareup.okhttp.Response intercept(com.squareup.okhttp.Interceptor.Chain chain) throws IOException { - com.squareup.okhttp.Response originalResponse = chain.proceed(chain.request()); - return originalResponse.newBuilder() - .body(new ProgressResponseBody(originalResponse.body(), progressListener)) - .build(); - } - }); - } - - String[] localVarAuthNames = new String[] { }; - return apiClient.buildCall(localVarPath, "POST", localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, progressRequestListener); - } - - @SuppressWarnings("rawtypes") - private com.squareup.okhttp.Call resetUserValidateBeforeCall(String login, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - - // verify the required parameter 'login' is set - if (login == null) { - throw new ApiException("Missing the required parameter 'login' when calling resetUser(Async)"); - } - - - com.squareup.okhttp.Call call = resetUserCall(login, progressListener, progressRequestListener); - return call; - - - - - - } - - /** - * Sends a password reset email to the correspondence email account of a user. - * - * @param login The login of the user to reset. (required) - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public void resetUser(String login) throws ApiException { - resetUserWithHttpInfo(login); - } - - /** - * Sends a password reset email to the correspondence email account of a user. - * - * @param login The login of the user to reset. (required) - * @return ApiResponse<Void> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public ApiResponse resetUserWithHttpInfo(String login) throws ApiException { - com.squareup.okhttp.Call call = resetUserValidateBeforeCall(login, null, null); - return apiClient.execute(call); - } - - /** - * Sends a password reset email to the correspondence email account of a user. (asynchronously) - * - * @param login The login of the user to reset. (required) - * @param callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - */ - public com.squareup.okhttp.Call resetUserAsync(String login, final ApiCallback callback) throws ApiException { - - ProgressResponseBody.ProgressListener progressListener = null; - ProgressRequestBody.ProgressRequestListener progressRequestListener = null; - - if (callback != null) { - progressListener = new ProgressResponseBody.ProgressListener() { - @Override - public void update(long bytesRead, long contentLength, boolean done) { - callback.onDownloadProgress(bytesRead, contentLength, done); - } - }; - - progressRequestListener = new ProgressRequestBody.ProgressRequestListener() { - @Override - public void onRequestProgress(long bytesWritten, long contentLength, boolean done) { - callback.onUploadProgress(bytesWritten, contentLength, done); - } - }; - } - - com.squareup.okhttp.Call call = resetUserValidateBeforeCall(login, progressListener, progressRequestListener); - apiClient.executeAsync(call, callback); - return call; - } - /** - * Build call for resetUserPassword - * @param token The secret token received via email. (required) - * @param body The new user password. (required) - * @param progressListener Progress listener - * @param progressRequestListener Progress request listener - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - */ - public com.squareup.okhttp.Call resetUserPasswordCall(String token, UserPassword body, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - Object localVarPostBody = body; - - // create path and map variables - String localVarPath = "/users/password/{token}" - .replaceAll("\\{" + "token" + "\\}", apiClient.escapeString(token.toString())); - - List localVarQueryParams = new ArrayList(); - - Map localVarHeaderParams = new HashMap(); - - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json", "application/xml" - }; - final String localVarAccept = apiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) localVarHeaderParams.put("Accept", localVarAccept); - - final String[] localVarContentTypes = { - "application/json", "application/xml" - }; - final String localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); - - if(progressListener != null) { - apiClient.getHttpClient().networkInterceptors().add(new com.squareup.okhttp.Interceptor() { - @Override - public com.squareup.okhttp.Response intercept(com.squareup.okhttp.Interceptor.Chain chain) throws IOException { - com.squareup.okhttp.Response originalResponse = chain.proceed(chain.request()); - return originalResponse.newBuilder() - .body(new ProgressResponseBody(originalResponse.body(), progressListener)) - .build(); - } - }); - } - - String[] localVarAuthNames = new String[] { }; - return apiClient.buildCall(localVarPath, "PUT", localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, progressRequestListener); - } - - @SuppressWarnings("rawtypes") - private com.squareup.okhttp.Call resetUserPasswordValidateBeforeCall(String token, UserPassword body, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - - // verify the required parameter 'token' is set - if (token == null) { - throw new ApiException("Missing the required parameter 'token' when calling resetUserPassword(Async)"); - } - - // verify the required parameter 'body' is set - if (body == null) { - throw new ApiException("Missing the required parameter 'body' when calling resetUserPassword(Async)"); - } - - - com.squareup.okhttp.Call call = resetUserPasswordCall(token, body, progressListener, progressRequestListener); - return call; - - - - - - } - - /** - * Sets the password of a user account using a token received via email. - * - * @param token The secret token received via email. (required) - * @param body The new user password. (required) - * @return User - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public User resetUserPassword(String token, UserPassword body) throws ApiException { - ApiResponse resp = resetUserPasswordWithHttpInfo(token, body); - return resp.getData(); - } - - /** - * Sets the password of a user account using a token received via email. - * - * @param token The secret token received via email. (required) - * @param body The new user password. (required) - * @return ApiResponse<User> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public ApiResponse resetUserPasswordWithHttpInfo(String token, UserPassword body) throws ApiException { - com.squareup.okhttp.Call call = resetUserPasswordValidateBeforeCall(token, body, null, null); - Type localVarReturnType = new TypeToken(){}.getType(); - return apiClient.execute(call, localVarReturnType); - } - - /** - * Sets the password of a user account using a token received via email. (asynchronously) - * - * @param token The secret token received via email. (required) - * @param body The new user password. (required) - * @param callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - */ - public com.squareup.okhttp.Call resetUserPasswordAsync(String token, UserPassword body, final ApiCallback callback) throws ApiException { - - ProgressResponseBody.ProgressListener progressListener = null; - ProgressRequestBody.ProgressRequestListener progressRequestListener = null; - - if (callback != null) { - progressListener = new ProgressResponseBody.ProgressListener() { - @Override - public void update(long bytesRead, long contentLength, boolean done) { - callback.onDownloadProgress(bytesRead, contentLength, done); - } - }; - - progressRequestListener = new ProgressRequestBody.ProgressRequestListener() { - @Override - public void onRequestProgress(long bytesWritten, long contentLength, boolean done) { - callback.onUploadProgress(bytesWritten, contentLength, done); - } - }; - } - - com.squareup.okhttp.Call call = resetUserPasswordValidateBeforeCall(token, body, progressListener, progressRequestListener); - Type localVarReturnType = new TypeToken(){}.getType(); - apiClient.executeAsync(call, localVarReturnType, callback); - return call; - } - /** - * Build call for searchUsers - * @param term The search term. (required) - * @param pageOffset The offset in terms of elements. (optional, default to 0) - * @param pageSize The maximum number of elements on the page. (optional, default to 20) - * @param progressListener Progress listener - * @param progressRequestListener Progress request listener - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - */ - public com.squareup.okhttp.Call searchUsersCall(String term, Integer pageOffset, Integer pageSize, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - Object localVarPostBody = null; - - // create path and map variables - String localVarPath = "/users/search"; - - List localVarQueryParams = new ArrayList(); - if (pageOffset != null) - localVarQueryParams.addAll(apiClient.parameterToPairs("", "pageOffset", pageOffset)); - if (pageSize != null) - localVarQueryParams.addAll(apiClient.parameterToPairs("", "pageSize", pageSize)); - if (term != null) - localVarQueryParams.addAll(apiClient.parameterToPairs("", "term", term)); - - Map localVarHeaderParams = new HashMap(); - - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json", "application/xml" - }; - final String localVarAccept = apiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) localVarHeaderParams.put("Accept", localVarAccept); - - final String[] localVarContentTypes = { - "application/json", "application/xml" - }; - final String localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); - - if(progressListener != null) { - apiClient.getHttpClient().networkInterceptors().add(new com.squareup.okhttp.Interceptor() { - @Override - public com.squareup.okhttp.Response intercept(com.squareup.okhttp.Interceptor.Chain chain) throws IOException { - com.squareup.okhttp.Response originalResponse = chain.proceed(chain.request()); - return originalResponse.newBuilder() - .body(new ProgressResponseBody(originalResponse.body(), progressListener)) - .build(); - } - }); - } - - String[] localVarAuthNames = new String[] { "admin" }; - return apiClient.buildCall(localVarPath, "GET", localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, progressRequestListener); - } - - @SuppressWarnings("rawtypes") - private com.squareup.okhttp.Call searchUsersValidateBeforeCall(String term, Integer pageOffset, Integer pageSize, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - - // verify the required parameter 'term' is set - if (term == null) { - throw new ApiException("Missing the required parameter 'term' when calling searchUsers(Async)"); - } - - - com.squareup.okhttp.Call call = searchUsersCall(term, pageOffset, pageSize, progressListener, progressRequestListener); - return call; - - - - - - } - - /** - * Returns a list of users whose login name or name contains the term. - * - * @param term The search term. (required) - * @param pageOffset The offset in terms of elements. (optional, default to 0) - * @param pageSize The maximum number of elements on the page. (optional, default to 20) - * @return UserPage - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public UserPage searchUsers(String term, Integer pageOffset, Integer pageSize) throws ApiException { - ApiResponse resp = searchUsersWithHttpInfo(term, pageOffset, pageSize); - return resp.getData(); - } - - /** - * Returns a list of users whose login name or name contains the term. - * - * @param term The search term. (required) - * @param pageOffset The offset in terms of elements. (optional, default to 0) - * @param pageSize The maximum number of elements on the page. (optional, default to 20) - * @return ApiResponse<UserPage> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public ApiResponse searchUsersWithHttpInfo(String term, Integer pageOffset, Integer pageSize) throws ApiException { - com.squareup.okhttp.Call call = searchUsersValidateBeforeCall(term, pageOffset, pageSize, null, null); - Type localVarReturnType = new TypeToken(){}.getType(); - return apiClient.execute(call, localVarReturnType); - } - - /** - * Returns a list of users whose login name or name contains the term. (asynchronously) - * - * @param term The search term. (required) - * @param pageOffset The offset in terms of elements. (optional, default to 0) - * @param pageSize The maximum number of elements on the page. (optional, default to 20) - * @param callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - */ - public com.squareup.okhttp.Call searchUsersAsync(String term, Integer pageOffset, Integer pageSize, final ApiCallback callback) throws ApiException { - - ProgressResponseBody.ProgressListener progressListener = null; - ProgressRequestBody.ProgressRequestListener progressRequestListener = null; - - if (callback != null) { - progressListener = new ProgressResponseBody.ProgressListener() { - @Override - public void update(long bytesRead, long contentLength, boolean done) { - callback.onDownloadProgress(bytesRead, contentLength, done); - } - }; - - progressRequestListener = new ProgressRequestBody.ProgressRequestListener() { - @Override - public void onRequestProgress(long bytesWritten, long contentLength, boolean done) { - callback.onUploadProgress(bytesWritten, contentLength, done); - } - }; - } - - com.squareup.okhttp.Call call = searchUsersValidateBeforeCall(term, pageOffset, pageSize, progressListener, progressRequestListener); - Type localVarReturnType = new TypeToken(){}.getType(); - apiClient.executeAsync(call, localVarReturnType, callback); - return call; - } - /** - * Build call for setCurrentPassword - * @param body The new password to set. (required) - * @param progressListener Progress listener - * @param progressRequestListener Progress request listener - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - */ - public com.squareup.okhttp.Call setCurrentPasswordCall(UserPassword body, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - Object localVarPostBody = body; - - // create path and map variables - String localVarPath = "/users/current/password"; - - List localVarQueryParams = new ArrayList(); - - Map localVarHeaderParams = new HashMap(); - - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json", "application/xml" - }; - final String localVarAccept = apiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) localVarHeaderParams.put("Accept", localVarAccept); - - final String[] localVarContentTypes = { - "application/json", "application/xml" - }; - final String localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); - - if(progressListener != null) { - apiClient.getHttpClient().networkInterceptors().add(new com.squareup.okhttp.Interceptor() { - @Override - public com.squareup.okhttp.Response intercept(com.squareup.okhttp.Interceptor.Chain chain) throws IOException { - com.squareup.okhttp.Response originalResponse = chain.proceed(chain.request()); - return originalResponse.newBuilder() - .body(new ProgressResponseBody(originalResponse.body(), progressListener)) - .build(); - } - }); - } - - String[] localVarAuthNames = new String[] { "user" }; - return apiClient.buildCall(localVarPath, "PUT", localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, progressRequestListener); - } - - @SuppressWarnings("rawtypes") - private com.squareup.okhttp.Call setCurrentPasswordValidateBeforeCall(UserPassword body, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - - // verify the required parameter 'body' is set - if (body == null) { - throw new ApiException("Missing the required parameter 'body' when calling setCurrentPassword(Async)"); - } - - - com.squareup.okhttp.Call call = setCurrentPasswordCall(body, progressListener, progressRequestListener); - return call; - - - - - - } - - /** - * Sets the password of the currently authorized user. - * - * @param body The new password to set. (required) - * @return User - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public User setCurrentPassword(UserPassword body) throws ApiException { - ApiResponse resp = setCurrentPasswordWithHttpInfo(body); - return resp.getData(); - } - - /** - * Sets the password of the currently authorized user. - * - * @param body The new password to set. (required) - * @return ApiResponse<User> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public ApiResponse setCurrentPasswordWithHttpInfo(UserPassword body) throws ApiException { - com.squareup.okhttp.Call call = setCurrentPasswordValidateBeforeCall(body, null, null); - Type localVarReturnType = new TypeToken(){}.getType(); - return apiClient.execute(call, localVarReturnType); - } - - /** - * Sets the password of the currently authorized user. (asynchronously) - * - * @param body The new password to set. (required) - * @param callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - */ - public com.squareup.okhttp.Call setCurrentPasswordAsync(UserPassword body, final ApiCallback callback) throws ApiException { - - ProgressResponseBody.ProgressListener progressListener = null; - ProgressRequestBody.ProgressRequestListener progressRequestListener = null; - - if (callback != null) { - progressListener = new ProgressResponseBody.ProgressListener() { - @Override - public void update(long bytesRead, long contentLength, boolean done) { - callback.onDownloadProgress(bytesRead, contentLength, done); - } - }; - - progressRequestListener = new ProgressRequestBody.ProgressRequestListener() { - @Override - public void onRequestProgress(long bytesWritten, long contentLength, boolean done) { - callback.onUploadProgress(bytesWritten, contentLength, done); - } - }; - } - - com.squareup.okhttp.Call call = setCurrentPasswordValidateBeforeCall(body, progressListener, progressRequestListener); - Type localVarReturnType = new TypeToken(){}.getType(); - apiClient.executeAsync(call, localVarReturnType, callback); - return call; - } - /** - * Build call for setCurrentUser - * @param body The new user values to set. (required) - * @param progressListener Progress listener - * @param progressRequestListener Progress request listener - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - */ - public com.squareup.okhttp.Call setCurrentUserCall(User body, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - Object localVarPostBody = body; - - // create path and map variables - String localVarPath = "/users/current"; - - List localVarQueryParams = new ArrayList(); - - Map localVarHeaderParams = new HashMap(); - - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json", "application/xml" - }; - final String localVarAccept = apiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) localVarHeaderParams.put("Accept", localVarAccept); - - final String[] localVarContentTypes = { - "application/json", "application/xml" - }; - final String localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); - - if(progressListener != null) { - apiClient.getHttpClient().networkInterceptors().add(new com.squareup.okhttp.Interceptor() { - @Override - public com.squareup.okhttp.Response intercept(com.squareup.okhttp.Interceptor.Chain chain) throws IOException { - com.squareup.okhttp.Response originalResponse = chain.proceed(chain.request()); - return originalResponse.newBuilder() - .body(new ProgressResponseBody(originalResponse.body(), progressListener)) - .build(); - } - }); - } - - String[] localVarAuthNames = new String[] { "user" }; - return apiClient.buildCall(localVarPath, "PUT", localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, progressRequestListener); - } - - @SuppressWarnings("rawtypes") - private com.squareup.okhttp.Call setCurrentUserValidateBeforeCall(User body, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - - // verify the required parameter 'body' is set - if (body == null) { - throw new ApiException("Missing the required parameter 'body' when calling setCurrentUser(Async)"); - } - - - com.squareup.okhttp.Call call = setCurrentUserCall(body, progressListener, progressRequestListener); - return call; - - - - - - } - - /** - * Updates the currently authorized user. - * - * @param body The new user values to set. (required) - * @return User - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public User setCurrentUser(User body) throws ApiException { - ApiResponse resp = setCurrentUserWithHttpInfo(body); - return resp.getData(); - } - - /** - * Updates the currently authorized user. - * - * @param body The new user values to set. (required) - * @return ApiResponse<User> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public ApiResponse setCurrentUserWithHttpInfo(User body) throws ApiException { - com.squareup.okhttp.Call call = setCurrentUserValidateBeforeCall(body, null, null); - Type localVarReturnType = new TypeToken(){}.getType(); - return apiClient.execute(call, localVarReturnType); - } - - /** - * Updates the currently authorized user. (asynchronously) - * - * @param body The new user values to set. (required) - * @param callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - */ - public com.squareup.okhttp.Call setCurrentUserAsync(User body, final ApiCallback callback) throws ApiException { - - ProgressResponseBody.ProgressListener progressListener = null; - ProgressRequestBody.ProgressRequestListener progressRequestListener = null; - - if (callback != null) { - progressListener = new ProgressResponseBody.ProgressListener() { - @Override - public void update(long bytesRead, long contentLength, boolean done) { - callback.onDownloadProgress(bytesRead, contentLength, done); - } - }; - - progressRequestListener = new ProgressRequestBody.ProgressRequestListener() { - @Override - public void onRequestProgress(long bytesWritten, long contentLength, boolean done) { - callback.onUploadProgress(bytesWritten, contentLength, done); - } - }; - } - - com.squareup.okhttp.Call call = setCurrentUserValidateBeforeCall(body, progressListener, progressRequestListener); - Type localVarReturnType = new TypeToken(){}.getType(); - apiClient.executeAsync(call, localVarReturnType, callback); - return call; - } - /** - * Build call for setDevice - * @param id The device id. (required) - * @param body The device values. (optional) - * @param progressListener Progress listener - * @param progressRequestListener Progress request listener - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - */ - public com.squareup.okhttp.Call setDeviceCall(Long id, Device body, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - Object localVarPostBody = body; - - // create path and map variables - String localVarPath = "/devices/{id}" - .replaceAll("\\{" + "id" + "\\}", apiClient.escapeString(id.toString())); - - List localVarQueryParams = new ArrayList(); - - Map localVarHeaderParams = new HashMap(); - - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json", "application/xml" - }; - final String localVarAccept = apiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) localVarHeaderParams.put("Accept", localVarAccept); - - final String[] localVarContentTypes = { - "application/json", "application/xml" - }; - final String localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); - - if(progressListener != null) { - apiClient.getHttpClient().networkInterceptors().add(new com.squareup.okhttp.Interceptor() { - @Override - public com.squareup.okhttp.Response intercept(com.squareup.okhttp.Interceptor.Chain chain) throws IOException { - com.squareup.okhttp.Response originalResponse = chain.proceed(chain.request()); - return originalResponse.newBuilder() - .body(new ProgressResponseBody(originalResponse.body(), progressListener)) - .build(); - } - }); - } - - String[] localVarAuthNames = new String[] { "admin" }; - return apiClient.buildCall(localVarPath, "PUT", localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, progressRequestListener); - } - - @SuppressWarnings("rawtypes") - private com.squareup.okhttp.Call setDeviceValidateBeforeCall(Long id, Device body, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - - // verify the required parameter 'id' is set - if (id == null) { - throw new ApiException("Missing the required parameter 'id' when calling setDevice(Async)"); - } - - - com.squareup.okhttp.Call call = setDeviceCall(id, body, progressListener, progressRequestListener); - return call; - - - - - - } - - /** - * Sets the values of a device. - * - * @param id The device id. (required) - * @param body The device values. (optional) - * @return Device - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public Device setDevice(Long id, Device body) throws ApiException { - ApiResponse resp = setDeviceWithHttpInfo(id, body); - return resp.getData(); - } - - /** - * Sets the values of a device. - * - * @param id The device id. (required) - * @param body The device values. (optional) - * @return ApiResponse<Device> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public ApiResponse setDeviceWithHttpInfo(Long id, Device body) throws ApiException { - com.squareup.okhttp.Call call = setDeviceValidateBeforeCall(id, body, null, null); - Type localVarReturnType = new TypeToken(){}.getType(); - return apiClient.execute(call, localVarReturnType); - } - - /** - * Sets the values of a device. (asynchronously) - * - * @param id The device id. (required) - * @param body The device values. (optional) - * @param callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - */ - public com.squareup.okhttp.Call setDeviceAsync(Long id, Device body, final ApiCallback callback) throws ApiException { - - ProgressResponseBody.ProgressListener progressListener = null; - ProgressRequestBody.ProgressRequestListener progressRequestListener = null; - - if (callback != null) { - progressListener = new ProgressResponseBody.ProgressListener() { - @Override - public void update(long bytesRead, long contentLength, boolean done) { - callback.onDownloadProgress(bytesRead, contentLength, done); - } - }; - - progressRequestListener = new ProgressRequestBody.ProgressRequestListener() { - @Override - public void onRequestProgress(long bytesWritten, long contentLength, boolean done) { - callback.onUploadProgress(bytesWritten, contentLength, done); - } - }; - } - - com.squareup.okhttp.Call call = setDeviceValidateBeforeCall(id, body, progressListener, progressRequestListener); - Type localVarReturnType = new TypeToken(){}.getType(); - apiClient.executeAsync(call, localVarReturnType, callback); - return call; - } - /** - * Build call for setNotice - * @param id The id of the notice. (required) - * @param body The data of the notice to set. (required) - * @param progressListener Progress listener - * @param progressRequestListener Progress request listener - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - */ - public com.squareup.okhttp.Call setNoticeCall(Long id, Notice body, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - Object localVarPostBody = body; - - // create path and map variables - String localVarPath = "/notices/{id}" - .replaceAll("\\{" + "id" + "\\}", apiClient.escapeString(id.toString())); - - List localVarQueryParams = new ArrayList(); - - Map localVarHeaderParams = new HashMap(); - - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json", "application/xml" - }; - final String localVarAccept = apiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) localVarHeaderParams.put("Accept", localVarAccept); - - final String[] localVarContentTypes = { - "application/json", "application/xml" - }; - final String localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); - - if(progressListener != null) { - apiClient.getHttpClient().networkInterceptors().add(new com.squareup.okhttp.Interceptor() { - @Override - public com.squareup.okhttp.Response intercept(com.squareup.okhttp.Interceptor.Chain chain) throws IOException { - com.squareup.okhttp.Response originalResponse = chain.proceed(chain.request()); - return originalResponse.newBuilder() - .body(new ProgressResponseBody(originalResponse.body(), progressListener)) - .build(); - } - }); - } - - String[] localVarAuthNames = new String[] { "admin" }; - return apiClient.buildCall(localVarPath, "PUT", localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, progressRequestListener); - } - - @SuppressWarnings("rawtypes") - private com.squareup.okhttp.Call setNoticeValidateBeforeCall(Long id, Notice body, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - - // verify the required parameter 'id' is set - if (id == null) { - throw new ApiException("Missing the required parameter 'id' when calling setNotice(Async)"); - } - - // verify the required parameter 'body' is set - if (body == null) { - throw new ApiException("Missing the required parameter 'body' when calling setNotice(Async)"); - } - - - com.squareup.okhttp.Call call = setNoticeCall(id, body, progressListener, progressRequestListener); - return call; - - - - - - } - - /** - * Updates an existing notice. - * - * @param id The id of the notice. (required) - * @param body The data of the notice to set. (required) - * @return Notice - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public Notice setNotice(Long id, Notice body) throws ApiException { - ApiResponse resp = setNoticeWithHttpInfo(id, body); - return resp.getData(); - } - - /** - * Updates an existing notice. - * - * @param id The id of the notice. (required) - * @param body The data of the notice to set. (required) - * @return ApiResponse<Notice> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public ApiResponse setNoticeWithHttpInfo(Long id, Notice body) throws ApiException { - com.squareup.okhttp.Call call = setNoticeValidateBeforeCall(id, body, null, null); - Type localVarReturnType = new TypeToken(){}.getType(); - return apiClient.execute(call, localVarReturnType); - } - - /** - * Updates an existing notice. (asynchronously) - * - * @param id The id of the notice. (required) - * @param body The data of the notice to set. (required) - * @param callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - */ - public com.squareup.okhttp.Call setNoticeAsync(Long id, Notice body, final ApiCallback callback) throws ApiException { - - ProgressResponseBody.ProgressListener progressListener = null; - ProgressRequestBody.ProgressRequestListener progressRequestListener = null; - - if (callback != null) { - progressListener = new ProgressResponseBody.ProgressListener() { - @Override - public void update(long bytesRead, long contentLength, boolean done) { - callback.onDownloadProgress(bytesRead, contentLength, done); - } - }; - - progressRequestListener = new ProgressRequestBody.ProgressRequestListener() { - @Override - public void onRequestProgress(long bytesWritten, long contentLength, boolean done) { - callback.onUploadProgress(bytesWritten, contentLength, done); - } - }; - } - - com.squareup.okhttp.Call call = setNoticeValidateBeforeCall(id, body, progressListener, progressRequestListener); - Type localVarReturnType = new TypeToken(){}.getType(); - apiClient.executeAsync(call, localVarReturnType, callback); - return call; - } - /** - * Build call for setPlace - * @param id The place id. (required) - * @param body The place to set. (required) - * @param progressListener Progress listener - * @param progressRequestListener Progress request listener - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - */ - public com.squareup.okhttp.Call setPlaceCall(Long id, Place body, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - Object localVarPostBody = body; - - // create path and map variables - String localVarPath = "/places/{id}" - .replaceAll("\\{" + "id" + "\\}", apiClient.escapeString(id.toString())); - - List localVarQueryParams = new ArrayList(); - - Map localVarHeaderParams = new HashMap(); - - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json", "application/xml" - }; - final String localVarAccept = apiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) localVarHeaderParams.put("Accept", localVarAccept); - - final String[] localVarContentTypes = { - "application/json", "application/xml" - }; - final String localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); - - if(progressListener != null) { - apiClient.getHttpClient().networkInterceptors().add(new com.squareup.okhttp.Interceptor() { - @Override - public com.squareup.okhttp.Response intercept(com.squareup.okhttp.Interceptor.Chain chain) throws IOException { - com.squareup.okhttp.Response originalResponse = chain.proceed(chain.request()); - return originalResponse.newBuilder() - .body(new ProgressResponseBody(originalResponse.body(), progressListener)) - .build(); - } - }); - } - - String[] localVarAuthNames = new String[] { }; - return apiClient.buildCall(localVarPath, "PUT", localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, progressRequestListener); - } - - @SuppressWarnings("rawtypes") - private com.squareup.okhttp.Call setPlaceValidateBeforeCall(Long id, Place body, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - - // verify the required parameter 'id' is set - if (id == null) { - throw new ApiException("Missing the required parameter 'id' when calling setPlace(Async)"); - } - - // verify the required parameter 'body' is set - if (body == null) { - throw new ApiException("Missing the required parameter 'body' when calling setPlace(Async)"); - } - - - com.squareup.okhttp.Call call = setPlaceCall(id, body, progressListener, progressRequestListener); - return call; - - - - - - } - - /** - * Updates the place with the specified id. - * - * @param id The place id. (required) - * @param body The place to set. (required) - * @return Place - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public Place setPlace(Long id, Place body) throws ApiException { - ApiResponse resp = setPlaceWithHttpInfo(id, body); - return resp.getData(); - } - - /** - * Updates the place with the specified id. - * - * @param id The place id. (required) - * @param body The place to set. (required) - * @return ApiResponse<Place> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public ApiResponse setPlaceWithHttpInfo(Long id, Place body) throws ApiException { - com.squareup.okhttp.Call call = setPlaceValidateBeforeCall(id, body, null, null); - Type localVarReturnType = new TypeToken(){}.getType(); - return apiClient.execute(call, localVarReturnType); - } - - /** - * Updates the place with the specified id. (asynchronously) - * - * @param id The place id. (required) - * @param body The place to set. (required) - * @param callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - */ - public com.squareup.okhttp.Call setPlaceAsync(Long id, Place body, final ApiCallback callback) throws ApiException { - - ProgressResponseBody.ProgressListener progressListener = null; - ProgressRequestBody.ProgressRequestListener progressRequestListener = null; - - if (callback != null) { - progressListener = new ProgressResponseBody.ProgressListener() { - @Override - public void update(long bytesRead, long contentLength, boolean done) { - callback.onDownloadProgress(bytesRead, contentLength, done); - } - }; - - progressRequestListener = new ProgressRequestBody.ProgressRequestListener() { - @Override - public void onRequestProgress(long bytesWritten, long contentLength, boolean done) { - callback.onUploadProgress(bytesWritten, contentLength, done); - } - }; - } - - com.squareup.okhttp.Call call = setPlaceValidateBeforeCall(id, body, progressListener, progressRequestListener); - Type localVarReturnType = new TypeToken(){}.getType(); - apiClient.executeAsync(call, localVarReturnType, callback); - return call; - } - /** - * Build call for setShare - * @param id The share id. (required) - * @param body The new share to set. (optional) - * @param progressListener Progress listener - * @param progressRequestListener Progress request listener - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - */ - public com.squareup.okhttp.Call setShareCall(Long id, Share body, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - Object localVarPostBody = body; - - // create path and map variables - String localVarPath = "/shares/{id}" - .replaceAll("\\{" + "id" + "\\}", apiClient.escapeString(id.toString())); - - List localVarQueryParams = new ArrayList(); - - Map localVarHeaderParams = new HashMap(); - - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json", "application/xml" - }; - final String localVarAccept = apiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) localVarHeaderParams.put("Accept", localVarAccept); - - final String[] localVarContentTypes = { - "application/json", "application/xml" - }; - final String localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); - - if(progressListener != null) { - apiClient.getHttpClient().networkInterceptors().add(new com.squareup.okhttp.Interceptor() { - @Override - public com.squareup.okhttp.Response intercept(com.squareup.okhttp.Interceptor.Chain chain) throws IOException { - com.squareup.okhttp.Response originalResponse = chain.proceed(chain.request()); - return originalResponse.newBuilder() - .body(new ProgressResponseBody(originalResponse.body(), progressListener)) - .build(); - } - }); - } - - String[] localVarAuthNames = new String[] { "device" }; - return apiClient.buildCall(localVarPath, "PUT", localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, progressRequestListener); - } - - @SuppressWarnings("rawtypes") - private com.squareup.okhttp.Call setShareValidateBeforeCall(Long id, Share body, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - - // verify the required parameter 'id' is set - if (id == null) { - throw new ApiException("Missing the required parameter 'id' when calling setShare(Async)"); - } - - - com.squareup.okhttp.Call call = setShareCall(id, body, progressListener, progressRequestListener); - return call; - - - - - - } - - /** - * Updates an existing share. - * - * @param id The share id. (required) - * @param body The new share to set. (optional) - * @return Share - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public Share setShare(Long id, Share body) throws ApiException { - ApiResponse resp = setShareWithHttpInfo(id, body); - return resp.getData(); - } - - /** - * Updates an existing share. - * - * @param id The share id. (required) - * @param body The new share to set. (optional) - * @return ApiResponse<Share> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public ApiResponse setShareWithHttpInfo(Long id, Share body) throws ApiException { - com.squareup.okhttp.Call call = setShareValidateBeforeCall(id, body, null, null); - Type localVarReturnType = new TypeToken(){}.getType(); - return apiClient.execute(call, localVarReturnType); - } - - /** - * Updates an existing share. (asynchronously) - * - * @param id The share id. (required) - * @param body The new share to set. (optional) - * @param callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - */ - public com.squareup.okhttp.Call setShareAsync(Long id, Share body, final ApiCallback callback) throws ApiException { - - ProgressResponseBody.ProgressListener progressListener = null; - ProgressRequestBody.ProgressRequestListener progressRequestListener = null; - - if (callback != null) { - progressListener = new ProgressResponseBody.ProgressListener() { - @Override - public void update(long bytesRead, long contentLength, boolean done) { - callback.onDownloadProgress(bytesRead, contentLength, done); - } - }; - - progressRequestListener = new ProgressRequestBody.ProgressRequestListener() { - @Override - public void onRequestProgress(long bytesWritten, long contentLength, boolean done) { - callback.onUploadProgress(bytesWritten, contentLength, done); - } - }; - } - - com.squareup.okhttp.Call call = setShareValidateBeforeCall(id, body, progressListener, progressRequestListener); - Type localVarReturnType = new TypeToken(){}.getType(); - apiClient.executeAsync(call, localVarReturnType, callback); - return call; - } - /** - * Build call for setUser - * @param id The id of the user to set. (required) - * @param body The new user data to set. (required) - * @param progressListener Progress listener - * @param progressRequestListener Progress request listener - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - */ - public com.squareup.okhttp.Call setUserCall(Long id, User body, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - Object localVarPostBody = body; - - // create path and map variables - String localVarPath = "/users/{id}" - .replaceAll("\\{" + "id" + "\\}", apiClient.escapeString(id.toString())); - - List localVarQueryParams = new ArrayList(); - - Map localVarHeaderParams = new HashMap(); - - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json", "application/xml" - }; - final String localVarAccept = apiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) localVarHeaderParams.put("Accept", localVarAccept); - - final String[] localVarContentTypes = { - "application/json", "application/xml" - }; - final String localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); - - if(progressListener != null) { - apiClient.getHttpClient().networkInterceptors().add(new com.squareup.okhttp.Interceptor() { - @Override - public com.squareup.okhttp.Response intercept(com.squareup.okhttp.Interceptor.Chain chain) throws IOException { - com.squareup.okhttp.Response originalResponse = chain.proceed(chain.request()); - return originalResponse.newBuilder() - .body(new ProgressResponseBody(originalResponse.body(), progressListener)) - .build(); - } - }); - } - - String[] localVarAuthNames = new String[] { "admin" }; - return apiClient.buildCall(localVarPath, "PUT", localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, progressRequestListener); - } - - @SuppressWarnings("rawtypes") - private com.squareup.okhttp.Call setUserValidateBeforeCall(Long id, User body, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - - // verify the required parameter 'id' is set - if (id == null) { - throw new ApiException("Missing the required parameter 'id' when calling setUser(Async)"); - } - - // verify the required parameter 'body' is set - if (body == null) { - throw new ApiException("Missing the required parameter 'body' when calling setUser(Async)"); - } - - - com.squareup.okhttp.Call call = setUserCall(id, body, progressListener, progressRequestListener); - return call; - - - - - - } - - /** - * Updates the values of a particular user account. - * - * @param id The id of the user to set. (required) - * @param body The new user data to set. (required) - * @return User - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public User setUser(Long id, User body) throws ApiException { - ApiResponse resp = setUserWithHttpInfo(id, body); - return resp.getData(); - } - - /** - * Updates the values of a particular user account. - * - * @param id The id of the user to set. (required) - * @param body The new user data to set. (required) - * @return ApiResponse<User> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public ApiResponse setUserWithHttpInfo(Long id, User body) throws ApiException { - com.squareup.okhttp.Call call = setUserValidateBeforeCall(id, body, null, null); - Type localVarReturnType = new TypeToken(){}.getType(); - return apiClient.execute(call, localVarReturnType); - } - - /** - * Updates the values of a particular user account. (asynchronously) - * - * @param id The id of the user to set. (required) - * @param body The new user data to set. (required) - * @param callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - */ - public com.squareup.okhttp.Call setUserAsync(Long id, User body, final ApiCallback callback) throws ApiException { - - ProgressResponseBody.ProgressListener progressListener = null; - ProgressRequestBody.ProgressRequestListener progressRequestListener = null; - - if (callback != null) { - progressListener = new ProgressResponseBody.ProgressListener() { - @Override - public void update(long bytesRead, long contentLength, boolean done) { - callback.onDownloadProgress(bytesRead, contentLength, done); - } - }; - - progressRequestListener = new ProgressRequestBody.ProgressRequestListener() { - @Override - public void onRequestProgress(long bytesWritten, long contentLength, boolean done) { - callback.onUploadProgress(bytesWritten, contentLength, done); - } - }; - } - - com.squareup.okhttp.Call call = setUserValidateBeforeCall(id, body, progressListener, progressRequestListener); - Type localVarReturnType = new TypeToken(){}.getType(); - apiClient.executeAsync(call, localVarReturnType, callback); - return call; - } - /** - * Build call for setUserPassword - * @param id The id of the user to change. (required) - * @param body The new password. (required) - * @param progressListener Progress listener - * @param progressRequestListener Progress request listener - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - */ - public com.squareup.okhttp.Call setUserPasswordCall(Long id, UserPassword body, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - Object localVarPostBody = body; - - // create path and map variables - String localVarPath = "/users/{id}/password" - .replaceAll("\\{" + "id" + "\\}", apiClient.escapeString(id.toString())); - - List localVarQueryParams = new ArrayList(); - - Map localVarHeaderParams = new HashMap(); - - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json", "application/xml" - }; - final String localVarAccept = apiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) localVarHeaderParams.put("Accept", localVarAccept); - - final String[] localVarContentTypes = { - "application/json", "application/xml" - }; - final String localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); - - if(progressListener != null) { - apiClient.getHttpClient().networkInterceptors().add(new com.squareup.okhttp.Interceptor() { - @Override - public com.squareup.okhttp.Response intercept(com.squareup.okhttp.Interceptor.Chain chain) throws IOException { - com.squareup.okhttp.Response originalResponse = chain.proceed(chain.request()); - return originalResponse.newBuilder() - .body(new ProgressResponseBody(originalResponse.body(), progressListener)) - .build(); - } - }); - } - - String[] localVarAuthNames = new String[] { "admin" }; - return apiClient.buildCall(localVarPath, "PUT", localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, progressRequestListener); - } - - @SuppressWarnings("rawtypes") - private com.squareup.okhttp.Call setUserPasswordValidateBeforeCall(Long id, UserPassword body, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - - // verify the required parameter 'id' is set - if (id == null) { - throw new ApiException("Missing the required parameter 'id' when calling setUserPassword(Async)"); - } - - // verify the required parameter 'body' is set - if (body == null) { - throw new ApiException("Missing the required parameter 'body' when calling setUserPassword(Async)"); - } - - - com.squareup.okhttp.Call call = setUserPasswordCall(id, body, progressListener, progressRequestListener); - return call; - - - - - - } - - /** - * Sets the password of a user. - * - * @param id The id of the user to change. (required) - * @param body The new password. (required) - * @return User - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public User setUserPassword(Long id, UserPassword body) throws ApiException { - ApiResponse resp = setUserPasswordWithHttpInfo(id, body); - return resp.getData(); - } - - /** - * Sets the password of a user. - * - * @param id The id of the user to change. (required) - * @param body The new password. (required) - * @return ApiResponse<User> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public ApiResponse setUserPasswordWithHttpInfo(Long id, UserPassword body) throws ApiException { - com.squareup.okhttp.Call call = setUserPasswordValidateBeforeCall(id, body, null, null); - Type localVarReturnType = new TypeToken(){}.getType(); - return apiClient.execute(call, localVarReturnType); - } - - /** - * Sets the password of a user. (asynchronously) - * - * @param id The id of the user to change. (required) - * @param body The new password. (required) - * @param callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - */ - public com.squareup.okhttp.Call setUserPasswordAsync(Long id, UserPassword body, final ApiCallback callback) throws ApiException { - - ProgressResponseBody.ProgressListener progressListener = null; - ProgressRequestBody.ProgressRequestListener progressRequestListener = null; - - if (callback != null) { - progressListener = new ProgressResponseBody.ProgressListener() { - @Override - public void update(long bytesRead, long contentLength, boolean done) { - callback.onDownloadProgress(bytesRead, contentLength, done); - } - }; - - progressRequestListener = new ProgressRequestBody.ProgressRequestListener() { - @Override - public void onRequestProgress(long bytesWritten, long contentLength, boolean done) { - callback.onUploadProgress(bytesWritten, contentLength, done); - } - }; - } - - com.squareup.okhttp.Call call = setUserPasswordValidateBeforeCall(id, body, progressListener, progressRequestListener); - Type localVarReturnType = new TypeToken(){}.getType(); - apiClient.executeAsync(call, localVarReturnType, callback); - return call; - } - /** - * Build call for verifyUserEmail - * @param token The secret token received via email. (required) - * @param progressListener Progress listener - * @param progressRequestListener Progress request listener - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - */ - public com.squareup.okhttp.Call verifyUserEmailCall(String token, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - Object localVarPostBody = null; - - // create path and map variables - String localVarPath = "/users/verify/{token}" - .replaceAll("\\{" + "token" + "\\}", apiClient.escapeString(token.toString())); - - List localVarQueryParams = new ArrayList(); - - Map localVarHeaderParams = new HashMap(); - - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json", "application/xml" - }; - final String localVarAccept = apiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) localVarHeaderParams.put("Accept", localVarAccept); - - final String[] localVarContentTypes = { - "application/json", "application/xml" - }; - final String localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); - - if(progressListener != null) { - apiClient.getHttpClient().networkInterceptors().add(new com.squareup.okhttp.Interceptor() { - @Override - public com.squareup.okhttp.Response intercept(com.squareup.okhttp.Interceptor.Chain chain) throws IOException { - com.squareup.okhttp.Response originalResponse = chain.proceed(chain.request()); - return originalResponse.newBuilder() - .body(new ProgressResponseBody(originalResponse.body(), progressListener)) - .build(); - } - }); - } - - String[] localVarAuthNames = new String[] { }; - return apiClient.buildCall(localVarPath, "PUT", localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, progressRequestListener); - } - - @SuppressWarnings("rawtypes") - private com.squareup.okhttp.Call verifyUserEmailValidateBeforeCall(String token, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - - // verify the required parameter 'token' is set - if (token == null) { - throw new ApiException("Missing the required parameter 'token' when calling verifyUserEmail(Async)"); - } - - - com.squareup.okhttp.Call call = verifyUserEmailCall(token, progressListener, progressRequestListener); - return call; - - - - - - } - - /** - * Verifies an email address using a token received via email. - * - * @param token The secret token received via email. (required) - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public void verifyUserEmail(String token) throws ApiException { - verifyUserEmailWithHttpInfo(token); - } - - /** - * Verifies an email address using a token received via email. - * - * @param token The secret token received via email. (required) - * @return ApiResponse<Void> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public ApiResponse verifyUserEmailWithHttpInfo(String token) throws ApiException { - com.squareup.okhttp.Call call = verifyUserEmailValidateBeforeCall(token, null, null); - return apiClient.execute(call); - } - - /** - * Verifies an email address using a token received via email. (asynchronously) - * - * @param token The secret token received via email. (required) - * @param callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - */ - public com.squareup.okhttp.Call verifyUserEmailAsync(String token, final ApiCallback callback) throws ApiException { - - ProgressResponseBody.ProgressListener progressListener = null; - ProgressRequestBody.ProgressRequestListener progressRequestListener = null; - - if (callback != null) { - progressListener = new ProgressResponseBody.ProgressListener() { - @Override - public void update(long bytesRead, long contentLength, boolean done) { - callback.onDownloadProgress(bytesRead, contentLength, done); - } - }; - - progressRequestListener = new ProgressRequestBody.ProgressRequestListener() { - @Override - public void onRequestProgress(long bytesWritten, long contentLength, boolean done) { - callback.onUploadProgress(bytesWritten, contentLength, done); - } - }; - } - - com.squareup.okhttp.Call call = verifyUserEmailValidateBeforeCall(token, progressListener, progressRequestListener); - apiClient.executeAsync(call, callback); - return call; - } -} diff --git a/testing/api-client/src/main/java/io/swagger/client/api/DeviceApi.java b/testing/api-client/src/main/java/io/swagger/client/api/DeviceApi.java deleted file mode 100644 index bc50c6e..0000000 --- a/testing/api-client/src/main/java/io/swagger/client/api/DeviceApi.java +++ /dev/null @@ -1,1443 +0,0 @@ -/* - * Maptology Service - * Maptology Service - * - * OpenAPI spec version: 0.0.1-SNAPSHOT - * Contact: nes-admin@uni-due.de - * - * NOTE: This class is auto generated by the swagger code generator program. - * https://github.com/swagger-api/swagger-codegen.git - * Do not edit the class manually. - */ - - -package io.swagger.client.api; - -import io.swagger.client.ApiCallback; -import io.swagger.client.ApiClient; -import io.swagger.client.ApiException; -import io.swagger.client.ApiResponse; -import io.swagger.client.Configuration; -import io.swagger.client.Pair; -import io.swagger.client.ProgressRequestBody; -import io.swagger.client.ProgressResponseBody; - -import com.google.gson.reflect.TypeToken; - -import java.io.IOException; - - -import io.swagger.client.model.Device; -import io.swagger.client.model.DeviceHandle; -import io.swagger.client.model.DeviceInfo; -import io.swagger.client.model.DevicePage; -import io.swagger.client.model.Location; -import io.swagger.client.model.LocationUpdate; -import io.swagger.client.model.Visit; - -import java.lang.reflect.Type; -import java.util.ArrayList; -import java.util.HashMap; -import java.util.List; -import java.util.Map; - -public class DeviceApi { - private ApiClient apiClient; - - public DeviceApi() { - this(Configuration.getDefaultApiClient()); - } - - public DeviceApi(ApiClient apiClient) { - this.apiClient = apiClient; - } - - public ApiClient getApiClient() { - return apiClient; - } - - public void setApiClient(ApiClient apiClient) { - this.apiClient = apiClient; - } - - /** - * Build call for addLocations - * @param body The location update with the locations to add. (required) - * @param progressListener Progress listener - * @param progressRequestListener Progress request listener - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - */ - public com.squareup.okhttp.Call addLocationsCall(LocationUpdate body, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - Object localVarPostBody = body; - - // create path and map variables - String localVarPath = "/devices/current/locations"; - - List localVarQueryParams = new ArrayList(); - - Map localVarHeaderParams = new HashMap(); - - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json", "application/xml" - }; - final String localVarAccept = apiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) localVarHeaderParams.put("Accept", localVarAccept); - - final String[] localVarContentTypes = { - "application/json", "application/xml" - }; - final String localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); - - if(progressListener != null) { - apiClient.getHttpClient().networkInterceptors().add(new com.squareup.okhttp.Interceptor() { - @Override - public com.squareup.okhttp.Response intercept(com.squareup.okhttp.Interceptor.Chain chain) throws IOException { - com.squareup.okhttp.Response originalResponse = chain.proceed(chain.request()); - return originalResponse.newBuilder() - .body(new ProgressResponseBody(originalResponse.body(), progressListener)) - .build(); - } - }); - } - - String[] localVarAuthNames = new String[] { "device" }; - return apiClient.buildCall(localVarPath, "POST", localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, progressRequestListener); - } - - @SuppressWarnings("rawtypes") - private com.squareup.okhttp.Call addLocationsValidateBeforeCall(LocationUpdate body, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - - // verify the required parameter 'body' is set - if (body == null) { - throw new ApiException("Missing the required parameter 'body' when calling addLocations(Async)"); - } - - - com.squareup.okhttp.Call call = addLocationsCall(body, progressListener, progressRequestListener); - return call; - - - - - - } - - /** - * Updates the locations of the current device. - * - * @param body The location update with the locations to add. (required) - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public void addLocations(LocationUpdate body) throws ApiException { - addLocationsWithHttpInfo(body); - } - - /** - * Updates the locations of the current device. - * - * @param body The location update with the locations to add. (required) - * @return ApiResponse<Void> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public ApiResponse addLocationsWithHttpInfo(LocationUpdate body) throws ApiException { - com.squareup.okhttp.Call call = addLocationsValidateBeforeCall(body, null, null); - return apiClient.execute(call); - } - - /** - * Updates the locations of the current device. (asynchronously) - * - * @param body The location update with the locations to add. (required) - * @param callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - */ - public com.squareup.okhttp.Call addLocationsAsync(LocationUpdate body, final ApiCallback callback) throws ApiException { - - ProgressResponseBody.ProgressListener progressListener = null; - ProgressRequestBody.ProgressRequestListener progressRequestListener = null; - - if (callback != null) { - progressListener = new ProgressResponseBody.ProgressListener() { - @Override - public void update(long bytesRead, long contentLength, boolean done) { - callback.onDownloadProgress(bytesRead, contentLength, done); - } - }; - - progressRequestListener = new ProgressRequestBody.ProgressRequestListener() { - @Override - public void onRequestProgress(long bytesWritten, long contentLength, boolean done) { - callback.onUploadProgress(bytesWritten, contentLength, done); - } - }; - } - - com.squareup.okhttp.Call call = addLocationsValidateBeforeCall(body, progressListener, progressRequestListener); - apiClient.executeAsync(call, callback); - return call; - } - /** - * Build call for createDevice - * @param body Necessary data from to create a device. (required) - * @param progressListener Progress listener - * @param progressRequestListener Progress request listener - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - */ - public com.squareup.okhttp.Call createDeviceCall(DeviceInfo body, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - Object localVarPostBody = body; - - // create path and map variables - String localVarPath = "/devices"; - - List localVarQueryParams = new ArrayList(); - - Map localVarHeaderParams = new HashMap(); - - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json", "application/xml" - }; - final String localVarAccept = apiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) localVarHeaderParams.put("Accept", localVarAccept); - - final String[] localVarContentTypes = { - "application/json", "application/xml" - }; - final String localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); - - if(progressListener != null) { - apiClient.getHttpClient().networkInterceptors().add(new com.squareup.okhttp.Interceptor() { - @Override - public com.squareup.okhttp.Response intercept(com.squareup.okhttp.Interceptor.Chain chain) throws IOException { - com.squareup.okhttp.Response originalResponse = chain.proceed(chain.request()); - return originalResponse.newBuilder() - .body(new ProgressResponseBody(originalResponse.body(), progressListener)) - .build(); - } - }); - } - - String[] localVarAuthNames = new String[] { }; - return apiClient.buildCall(localVarPath, "POST", localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, progressRequestListener); - } - - @SuppressWarnings("rawtypes") - private com.squareup.okhttp.Call createDeviceValidateBeforeCall(DeviceInfo body, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - - // verify the required parameter 'body' is set - if (body == null) { - throw new ApiException("Missing the required parameter 'body' when calling createDevice(Async)"); - } - - - com.squareup.okhttp.Call call = createDeviceCall(body, progressListener, progressRequestListener); - return call; - - - - - - } - - /** - * Creates a new device and returns its handle. - * The response will include the auth token to be stored on the device and supplied as authentication on all subsequent api calls. Note that the auth token can not be requested after creation, so when losing the auth token you may lose access to the device data. - * @param body Necessary data from to create a device. (required) - * @return DeviceHandle - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public DeviceHandle createDevice(DeviceInfo body) throws ApiException { - ApiResponse resp = createDeviceWithHttpInfo(body); - return resp.getData(); - } - - /** - * Creates a new device and returns its handle. - * The response will include the auth token to be stored on the device and supplied as authentication on all subsequent api calls. Note that the auth token can not be requested after creation, so when losing the auth token you may lose access to the device data. - * @param body Necessary data from to create a device. (required) - * @return ApiResponse<DeviceHandle> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public ApiResponse createDeviceWithHttpInfo(DeviceInfo body) throws ApiException { - com.squareup.okhttp.Call call = createDeviceValidateBeforeCall(body, null, null); - Type localVarReturnType = new TypeToken(){}.getType(); - return apiClient.execute(call, localVarReturnType); - } - - /** - * Creates a new device and returns its handle. (asynchronously) - * The response will include the auth token to be stored on the device and supplied as authentication on all subsequent api calls. Note that the auth token can not be requested after creation, so when losing the auth token you may lose access to the device data. - * @param body Necessary data from to create a device. (required) - * @param callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - */ - public com.squareup.okhttp.Call createDeviceAsync(DeviceInfo body, final ApiCallback callback) throws ApiException { - - ProgressResponseBody.ProgressListener progressListener = null; - ProgressRequestBody.ProgressRequestListener progressRequestListener = null; - - if (callback != null) { - progressListener = new ProgressResponseBody.ProgressListener() { - @Override - public void update(long bytesRead, long contentLength, boolean done) { - callback.onDownloadProgress(bytesRead, contentLength, done); - } - }; - - progressRequestListener = new ProgressRequestBody.ProgressRequestListener() { - @Override - public void onRequestProgress(long bytesWritten, long contentLength, boolean done) { - callback.onUploadProgress(bytesWritten, contentLength, done); - } - }; - } - - com.squareup.okhttp.Call call = createDeviceValidateBeforeCall(body, progressListener, progressRequestListener); - Type localVarReturnType = new TypeToken(){}.getType(); - apiClient.executeAsync(call, localVarReturnType, callback); - return call; - } - /** - * Build call for deleteCurrentDevice - * @param progressListener Progress listener - * @param progressRequestListener Progress request listener - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - */ - public com.squareup.okhttp.Call deleteCurrentDeviceCall(final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - Object localVarPostBody = null; - - // create path and map variables - String localVarPath = "/devices/current"; - - List localVarQueryParams = new ArrayList(); - - Map localVarHeaderParams = new HashMap(); - - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json", "application/xml" - }; - final String localVarAccept = apiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) localVarHeaderParams.put("Accept", localVarAccept); - - final String[] localVarContentTypes = { - "application/json", "application/xml" - }; - final String localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); - - if(progressListener != null) { - apiClient.getHttpClient().networkInterceptors().add(new com.squareup.okhttp.Interceptor() { - @Override - public com.squareup.okhttp.Response intercept(com.squareup.okhttp.Interceptor.Chain chain) throws IOException { - com.squareup.okhttp.Response originalResponse = chain.proceed(chain.request()); - return originalResponse.newBuilder() - .body(new ProgressResponseBody(originalResponse.body(), progressListener)) - .build(); - } - }); - } - - String[] localVarAuthNames = new String[] { "device" }; - return apiClient.buildCall(localVarPath, "DELETE", localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, progressRequestListener); - } - - @SuppressWarnings("rawtypes") - private com.squareup.okhttp.Call deleteCurrentDeviceValidateBeforeCall(final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - - - com.squareup.okhttp.Call call = deleteCurrentDeviceCall(progressListener, progressRequestListener); - return call; - - - - - - } - - /** - * Deletes the current device. - * - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public void deleteCurrentDevice() throws ApiException { - deleteCurrentDeviceWithHttpInfo(); - } - - /** - * Deletes the current device. - * - * @return ApiResponse<Void> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public ApiResponse deleteCurrentDeviceWithHttpInfo() throws ApiException { - com.squareup.okhttp.Call call = deleteCurrentDeviceValidateBeforeCall(null, null); - return apiClient.execute(call); - } - - /** - * Deletes the current device. (asynchronously) - * - * @param callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - */ - public com.squareup.okhttp.Call deleteCurrentDeviceAsync(final ApiCallback callback) throws ApiException { - - ProgressResponseBody.ProgressListener progressListener = null; - ProgressRequestBody.ProgressRequestListener progressRequestListener = null; - - if (callback != null) { - progressListener = new ProgressResponseBody.ProgressListener() { - @Override - public void update(long bytesRead, long contentLength, boolean done) { - callback.onDownloadProgress(bytesRead, contentLength, done); - } - }; - - progressRequestListener = new ProgressRequestBody.ProgressRequestListener() { - @Override - public void onRequestProgress(long bytesWritten, long contentLength, boolean done) { - callback.onUploadProgress(bytesWritten, contentLength, done); - } - }; - } - - com.squareup.okhttp.Call call = deleteCurrentDeviceValidateBeforeCall(progressListener, progressRequestListener); - apiClient.executeAsync(call, callback); - return call; - } - /** - * Build call for deleteDevice - * @param id The device id. (required) - * @param progressListener Progress listener - * @param progressRequestListener Progress request listener - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - */ - public com.squareup.okhttp.Call deleteDeviceCall(Long id, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - Object localVarPostBody = null; - - // create path and map variables - String localVarPath = "/devices/{id}" - .replaceAll("\\{" + "id" + "\\}", apiClient.escapeString(id.toString())); - - List localVarQueryParams = new ArrayList(); - - Map localVarHeaderParams = new HashMap(); - - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json", "application/xml" - }; - final String localVarAccept = apiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) localVarHeaderParams.put("Accept", localVarAccept); - - final String[] localVarContentTypes = { - "application/json", "application/xml" - }; - final String localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); - - if(progressListener != null) { - apiClient.getHttpClient().networkInterceptors().add(new com.squareup.okhttp.Interceptor() { - @Override - public com.squareup.okhttp.Response intercept(com.squareup.okhttp.Interceptor.Chain chain) throws IOException { - com.squareup.okhttp.Response originalResponse = chain.proceed(chain.request()); - return originalResponse.newBuilder() - .body(new ProgressResponseBody(originalResponse.body(), progressListener)) - .build(); - } - }); - } - - String[] localVarAuthNames = new String[] { "admin", "user" }; - return apiClient.buildCall(localVarPath, "DELETE", localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, progressRequestListener); - } - - @SuppressWarnings("rawtypes") - private com.squareup.okhttp.Call deleteDeviceValidateBeforeCall(Long id, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - - // verify the required parameter 'id' is set - if (id == null) { - throw new ApiException("Missing the required parameter 'id' when calling deleteDevice(Async)"); - } - - - com.squareup.okhttp.Call call = deleteDeviceCall(id, progressListener, progressRequestListener); - return call; - - - - - - } - - /** - * Deletes a device. - * - * @param id The device id. (required) - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public void deleteDevice(Long id) throws ApiException { - deleteDeviceWithHttpInfo(id); - } - - /** - * Deletes a device. - * - * @param id The device id. (required) - * @return ApiResponse<Void> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public ApiResponse deleteDeviceWithHttpInfo(Long id) throws ApiException { - com.squareup.okhttp.Call call = deleteDeviceValidateBeforeCall(id, null, null); - return apiClient.execute(call); - } - - /** - * Deletes a device. (asynchronously) - * - * @param id The device id. (required) - * @param callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - */ - public com.squareup.okhttp.Call deleteDeviceAsync(Long id, final ApiCallback callback) throws ApiException { - - ProgressResponseBody.ProgressListener progressListener = null; - ProgressRequestBody.ProgressRequestListener progressRequestListener = null; - - if (callback != null) { - progressListener = new ProgressResponseBody.ProgressListener() { - @Override - public void update(long bytesRead, long contentLength, boolean done) { - callback.onDownloadProgress(bytesRead, contentLength, done); - } - }; - - progressRequestListener = new ProgressRequestBody.ProgressRequestListener() { - @Override - public void onRequestProgress(long bytesWritten, long contentLength, boolean done) { - callback.onUploadProgress(bytesWritten, contentLength, done); - } - }; - } - - com.squareup.okhttp.Call call = deleteDeviceValidateBeforeCall(id, progressListener, progressRequestListener); - apiClient.executeAsync(call, callback); - return call; - } - /** - * Build call for getCurrentDevice - * @param progressListener Progress listener - * @param progressRequestListener Progress request listener - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - */ - public com.squareup.okhttp.Call getCurrentDeviceCall(final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - Object localVarPostBody = null; - - // create path and map variables - String localVarPath = "/devices/current"; - - List localVarQueryParams = new ArrayList(); - - Map localVarHeaderParams = new HashMap(); - - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json", "application/xml" - }; - final String localVarAccept = apiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) localVarHeaderParams.put("Accept", localVarAccept); - - final String[] localVarContentTypes = { - "application/json", "application/xml" - }; - final String localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); - - if(progressListener != null) { - apiClient.getHttpClient().networkInterceptors().add(new com.squareup.okhttp.Interceptor() { - @Override - public com.squareup.okhttp.Response intercept(com.squareup.okhttp.Interceptor.Chain chain) throws IOException { - com.squareup.okhttp.Response originalResponse = chain.proceed(chain.request()); - return originalResponse.newBuilder() - .body(new ProgressResponseBody(originalResponse.body(), progressListener)) - .build(); - } - }); - } - - String[] localVarAuthNames = new String[] { "device" }; - return apiClient.buildCall(localVarPath, "GET", localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, progressRequestListener); - } - - @SuppressWarnings("rawtypes") - private com.squareup.okhttp.Call getCurrentDeviceValidateBeforeCall(final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - - - com.squareup.okhttp.Call call = getCurrentDeviceCall(progressListener, progressRequestListener); - return call; - - - - - - } - - /** - * Returns the current device. - * - * @return Device - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public Device getCurrentDevice() throws ApiException { - ApiResponse resp = getCurrentDeviceWithHttpInfo(); - return resp.getData(); - } - - /** - * Returns the current device. - * - * @return ApiResponse<Device> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public ApiResponse getCurrentDeviceWithHttpInfo() throws ApiException { - com.squareup.okhttp.Call call = getCurrentDeviceValidateBeforeCall(null, null); - Type localVarReturnType = new TypeToken(){}.getType(); - return apiClient.execute(call, localVarReturnType); - } - - /** - * Returns the current device. (asynchronously) - * - * @param callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - */ - public com.squareup.okhttp.Call getCurrentDeviceAsync(final ApiCallback callback) throws ApiException { - - ProgressResponseBody.ProgressListener progressListener = null; - ProgressRequestBody.ProgressRequestListener progressRequestListener = null; - - if (callback != null) { - progressListener = new ProgressResponseBody.ProgressListener() { - @Override - public void update(long bytesRead, long contentLength, boolean done) { - callback.onDownloadProgress(bytesRead, contentLength, done); - } - }; - - progressRequestListener = new ProgressRequestBody.ProgressRequestListener() { - @Override - public void onRequestProgress(long bytesWritten, long contentLength, boolean done) { - callback.onUploadProgress(bytesWritten, contentLength, done); - } - }; - } - - com.squareup.okhttp.Call call = getCurrentDeviceValidateBeforeCall(progressListener, progressRequestListener); - Type localVarReturnType = new TypeToken(){}.getType(); - apiClient.executeAsync(call, localVarReturnType, callback); - return call; - } - /** - * Build call for getCurrentUserDevices - * @param pageOffset The offset in terms of elements. (optional, default to 0) - * @param pageSize The maximum number of elements on the page. (optional, default to 20) - * @param progressListener Progress listener - * @param progressRequestListener Progress request listener - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - */ - public com.squareup.okhttp.Call getCurrentUserDevicesCall(Integer pageOffset, Integer pageSize, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - Object localVarPostBody = null; - - // create path and map variables - String localVarPath = "/users/current/devices"; - - List localVarQueryParams = new ArrayList(); - if (pageOffset != null) - localVarQueryParams.addAll(apiClient.parameterToPairs("", "pageOffset", pageOffset)); - if (pageSize != null) - localVarQueryParams.addAll(apiClient.parameterToPairs("", "pageSize", pageSize)); - - Map localVarHeaderParams = new HashMap(); - - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json", "application/xml" - }; - final String localVarAccept = apiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) localVarHeaderParams.put("Accept", localVarAccept); - - final String[] localVarContentTypes = { - "application/json", "application/xml" - }; - final String localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); - - if(progressListener != null) { - apiClient.getHttpClient().networkInterceptors().add(new com.squareup.okhttp.Interceptor() { - @Override - public com.squareup.okhttp.Response intercept(com.squareup.okhttp.Interceptor.Chain chain) throws IOException { - com.squareup.okhttp.Response originalResponse = chain.proceed(chain.request()); - return originalResponse.newBuilder() - .body(new ProgressResponseBody(originalResponse.body(), progressListener)) - .build(); - } - }); - } - - String[] localVarAuthNames = new String[] { "user" }; - return apiClient.buildCall(localVarPath, "GET", localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, progressRequestListener); - } - - @SuppressWarnings("rawtypes") - private com.squareup.okhttp.Call getCurrentUserDevicesValidateBeforeCall(Integer pageOffset, Integer pageSize, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - - - com.squareup.okhttp.Call call = getCurrentUserDevicesCall(pageOffset, pageSize, progressListener, progressRequestListener); - return call; - - - - - - } - - /** - * Returns the list of devices for the current user. - * - * @param pageOffset The offset in terms of elements. (optional, default to 0) - * @param pageSize The maximum number of elements on the page. (optional, default to 20) - * @return DevicePage - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public DevicePage getCurrentUserDevices(Integer pageOffset, Integer pageSize) throws ApiException { - ApiResponse resp = getCurrentUserDevicesWithHttpInfo(pageOffset, pageSize); - return resp.getData(); - } - - /** - * Returns the list of devices for the current user. - * - * @param pageOffset The offset in terms of elements. (optional, default to 0) - * @param pageSize The maximum number of elements on the page. (optional, default to 20) - * @return ApiResponse<DevicePage> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public ApiResponse getCurrentUserDevicesWithHttpInfo(Integer pageOffset, Integer pageSize) throws ApiException { - com.squareup.okhttp.Call call = getCurrentUserDevicesValidateBeforeCall(pageOffset, pageSize, null, null); - Type localVarReturnType = new TypeToken(){}.getType(); - return apiClient.execute(call, localVarReturnType); - } - - /** - * Returns the list of devices for the current user. (asynchronously) - * - * @param pageOffset The offset in terms of elements. (optional, default to 0) - * @param pageSize The maximum number of elements on the page. (optional, default to 20) - * @param callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - */ - public com.squareup.okhttp.Call getCurrentUserDevicesAsync(Integer pageOffset, Integer pageSize, final ApiCallback callback) throws ApiException { - - ProgressResponseBody.ProgressListener progressListener = null; - ProgressRequestBody.ProgressRequestListener progressRequestListener = null; - - if (callback != null) { - progressListener = new ProgressResponseBody.ProgressListener() { - @Override - public void update(long bytesRead, long contentLength, boolean done) { - callback.onDownloadProgress(bytesRead, contentLength, done); - } - }; - - progressRequestListener = new ProgressRequestBody.ProgressRequestListener() { - @Override - public void onRequestProgress(long bytesWritten, long contentLength, boolean done) { - callback.onUploadProgress(bytesWritten, contentLength, done); - } - }; - } - - com.squareup.okhttp.Call call = getCurrentUserDevicesValidateBeforeCall(pageOffset, pageSize, progressListener, progressRequestListener); - Type localVarReturnType = new TypeToken(){}.getType(); - apiClient.executeAsync(call, localVarReturnType, callback); - return call; - } - /** - * Build call for getDevice - * @param id The device id. (required) - * @param progressListener Progress listener - * @param progressRequestListener Progress request listener - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - */ - public com.squareup.okhttp.Call getDeviceCall(Long id, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - Object localVarPostBody = null; - - // create path and map variables - String localVarPath = "/devices/{id}" - .replaceAll("\\{" + "id" + "\\}", apiClient.escapeString(id.toString())); - - List localVarQueryParams = new ArrayList(); - - Map localVarHeaderParams = new HashMap(); - - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json", "application/xml" - }; - final String localVarAccept = apiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) localVarHeaderParams.put("Accept", localVarAccept); - - final String[] localVarContentTypes = { - "application/json", "application/xml" - }; - final String localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); - - if(progressListener != null) { - apiClient.getHttpClient().networkInterceptors().add(new com.squareup.okhttp.Interceptor() { - @Override - public com.squareup.okhttp.Response intercept(com.squareup.okhttp.Interceptor.Chain chain) throws IOException { - com.squareup.okhttp.Response originalResponse = chain.proceed(chain.request()); - return originalResponse.newBuilder() - .body(new ProgressResponseBody(originalResponse.body(), progressListener)) - .build(); - } - }); - } - - String[] localVarAuthNames = new String[] { "admin", "user" }; - return apiClient.buildCall(localVarPath, "GET", localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, progressRequestListener); - } - - @SuppressWarnings("rawtypes") - private com.squareup.okhttp.Call getDeviceValidateBeforeCall(Long id, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - - // verify the required parameter 'id' is set - if (id == null) { - throw new ApiException("Missing the required parameter 'id' when calling getDevice(Async)"); - } - - - com.squareup.okhttp.Call call = getDeviceCall(id, progressListener, progressRequestListener); - return call; - - - - - - } - - /** - * Gets a device. - * - * @param id The device id. (required) - * @return Device - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public Device getDevice(Long id) throws ApiException { - ApiResponse resp = getDeviceWithHttpInfo(id); - return resp.getData(); - } - - /** - * Gets a device. - * - * @param id The device id. (required) - * @return ApiResponse<Device> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public ApiResponse getDeviceWithHttpInfo(Long id) throws ApiException { - com.squareup.okhttp.Call call = getDeviceValidateBeforeCall(id, null, null); - Type localVarReturnType = new TypeToken(){}.getType(); - return apiClient.execute(call, localVarReturnType); - } - - /** - * Gets a device. (asynchronously) - * - * @param id The device id. (required) - * @param callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - */ - public com.squareup.okhttp.Call getDeviceAsync(Long id, final ApiCallback callback) throws ApiException { - - ProgressResponseBody.ProgressListener progressListener = null; - ProgressRequestBody.ProgressRequestListener progressRequestListener = null; - - if (callback != null) { - progressListener = new ProgressResponseBody.ProgressListener() { - @Override - public void update(long bytesRead, long contentLength, boolean done) { - callback.onDownloadProgress(bytesRead, contentLength, done); - } - }; - - progressRequestListener = new ProgressRequestBody.ProgressRequestListener() { - @Override - public void onRequestProgress(long bytesWritten, long contentLength, boolean done) { - callback.onUploadProgress(bytesWritten, contentLength, done); - } - }; - } - - com.squareup.okhttp.Call call = getDeviceValidateBeforeCall(id, progressListener, progressRequestListener); - Type localVarReturnType = new TypeToken(){}.getType(); - apiClient.executeAsync(call, localVarReturnType, callback); - return call; - } - /** - * Build call for getDeviceLocation - * @param id The device id. (required) - * @param progressListener Progress listener - * @param progressRequestListener Progress request listener - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - */ - public com.squareup.okhttp.Call getDeviceLocationCall(Long id, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - Object localVarPostBody = null; - - // create path and map variables - String localVarPath = "/devices/{id}/location" - .replaceAll("\\{" + "id" + "\\}", apiClient.escapeString(id.toString())); - - List localVarQueryParams = new ArrayList(); - - Map localVarHeaderParams = new HashMap(); - - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json", "application/xml" - }; - final String localVarAccept = apiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) localVarHeaderParams.put("Accept", localVarAccept); - - final String[] localVarContentTypes = { - "application/json", "application/xml" - }; - final String localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); - - if(progressListener != null) { - apiClient.getHttpClient().networkInterceptors().add(new com.squareup.okhttp.Interceptor() { - @Override - public com.squareup.okhttp.Response intercept(com.squareup.okhttp.Interceptor.Chain chain) throws IOException { - com.squareup.okhttp.Response originalResponse = chain.proceed(chain.request()); - return originalResponse.newBuilder() - .body(new ProgressResponseBody(originalResponse.body(), progressListener)) - .build(); - } - }); - } - - String[] localVarAuthNames = new String[] { "admin", "user" }; - return apiClient.buildCall(localVarPath, "GET", localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, progressRequestListener); - } - - @SuppressWarnings("rawtypes") - private com.squareup.okhttp.Call getDeviceLocationValidateBeforeCall(Long id, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - - // verify the required parameter 'id' is set - if (id == null) { - throw new ApiException("Missing the required parameter 'id' when calling getDeviceLocation(Async)"); - } - - - com.squareup.okhttp.Call call = getDeviceLocationCall(id, progressListener, progressRequestListener); - return call; - - - - - - } - - /** - * Gets the last device location. - * - * @param id The device id. (required) - * @return Location - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public Location getDeviceLocation(Long id) throws ApiException { - ApiResponse resp = getDeviceLocationWithHttpInfo(id); - return resp.getData(); - } - - /** - * Gets the last device location. - * - * @param id The device id. (required) - * @return ApiResponse<Location> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public ApiResponse getDeviceLocationWithHttpInfo(Long id) throws ApiException { - com.squareup.okhttp.Call call = getDeviceLocationValidateBeforeCall(id, null, null); - Type localVarReturnType = new TypeToken(){}.getType(); - return apiClient.execute(call, localVarReturnType); - } - - /** - * Gets the last device location. (asynchronously) - * - * @param id The device id. (required) - * @param callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - */ - public com.squareup.okhttp.Call getDeviceLocationAsync(Long id, final ApiCallback callback) throws ApiException { - - ProgressResponseBody.ProgressListener progressListener = null; - ProgressRequestBody.ProgressRequestListener progressRequestListener = null; - - if (callback != null) { - progressListener = new ProgressResponseBody.ProgressListener() { - @Override - public void update(long bytesRead, long contentLength, boolean done) { - callback.onDownloadProgress(bytesRead, contentLength, done); - } - }; - - progressRequestListener = new ProgressRequestBody.ProgressRequestListener() { - @Override - public void onRequestProgress(long bytesWritten, long contentLength, boolean done) { - callback.onUploadProgress(bytesWritten, contentLength, done); - } - }; - } - - com.squareup.okhttp.Call call = getDeviceLocationValidateBeforeCall(id, progressListener, progressRequestListener); - Type localVarReturnType = new TypeToken(){}.getType(); - apiClient.executeAsync(call, localVarReturnType, callback); - return call; - } - /** - * Build call for getDeviceVisits - * @param id The device id. (required) - * @param start The start time in Epoch milliseconds. (required) - * @param duration The duration in milliseconds. (required) - * @param progressListener Progress listener - * @param progressRequestListener Progress request listener - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - */ - public com.squareup.okhttp.Call getDeviceVisitsCall(Long id, Long start, Long duration, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - Object localVarPostBody = null; - - // create path and map variables - String localVarPath = "/devices/{id}/visits" - .replaceAll("\\{" + "id" + "\\}", apiClient.escapeString(id.toString())) - .replaceAll("\\{" + "start" + "\\}", apiClient.escapeString(start.toString())) - .replaceAll("\\{" + "duration" + "\\}", apiClient.escapeString(duration.toString())); - - List localVarQueryParams = new ArrayList(); - - Map localVarHeaderParams = new HashMap(); - - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json", "application/xml" - }; - final String localVarAccept = apiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) localVarHeaderParams.put("Accept", localVarAccept); - - final String[] localVarContentTypes = { - "application/json", "application/xml" - }; - final String localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); - - if(progressListener != null) { - apiClient.getHttpClient().networkInterceptors().add(new com.squareup.okhttp.Interceptor() { - @Override - public com.squareup.okhttp.Response intercept(com.squareup.okhttp.Interceptor.Chain chain) throws IOException { - com.squareup.okhttp.Response originalResponse = chain.proceed(chain.request()); - return originalResponse.newBuilder() - .body(new ProgressResponseBody(originalResponse.body(), progressListener)) - .build(); - } - }); - } - - String[] localVarAuthNames = new String[] { "admin", "user" }; - return apiClient.buildCall(localVarPath, "GET", localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, progressRequestListener); - } - - @SuppressWarnings("rawtypes") - private com.squareup.okhttp.Call getDeviceVisitsValidateBeforeCall(Long id, Long start, Long duration, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - - // verify the required parameter 'id' is set - if (id == null) { - throw new ApiException("Missing the required parameter 'id' when calling getDeviceVisits(Async)"); - } - - // verify the required parameter 'start' is set - if (start == null) { - throw new ApiException("Missing the required parameter 'start' when calling getDeviceVisits(Async)"); - } - - // verify the required parameter 'duration' is set - if (duration == null) { - throw new ApiException("Missing the required parameter 'duration' when calling getDeviceVisits(Async)"); - } - - - com.squareup.okhttp.Call call = getDeviceVisitsCall(id, start, duration, progressListener, progressRequestListener); - return call; - - - - - - } - - /** - * Gets the last device location. - * - * @param id The device id. (required) - * @param start The start time in Epoch milliseconds. (required) - * @param duration The duration in milliseconds. (required) - * @return List<Visit> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public List getDeviceVisits(Long id, Long start, Long duration) throws ApiException { - ApiResponse> resp = getDeviceVisitsWithHttpInfo(id, start, duration); - return resp.getData(); - } - - /** - * Gets the last device location. - * - * @param id The device id. (required) - * @param start The start time in Epoch milliseconds. (required) - * @param duration The duration in milliseconds. (required) - * @return ApiResponse<List<Visit>> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public ApiResponse> getDeviceVisitsWithHttpInfo(Long id, Long start, Long duration) throws ApiException { - com.squareup.okhttp.Call call = getDeviceVisitsValidateBeforeCall(id, start, duration, null, null); - Type localVarReturnType = new TypeToken>(){}.getType(); - return apiClient.execute(call, localVarReturnType); - } - - /** - * Gets the last device location. (asynchronously) - * - * @param id The device id. (required) - * @param start The start time in Epoch milliseconds. (required) - * @param duration The duration in milliseconds. (required) - * @param callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - */ - public com.squareup.okhttp.Call getDeviceVisitsAsync(Long id, Long start, Long duration, final ApiCallback> callback) throws ApiException { - - ProgressResponseBody.ProgressListener progressListener = null; - ProgressRequestBody.ProgressRequestListener progressRequestListener = null; - - if (callback != null) { - progressListener = new ProgressResponseBody.ProgressListener() { - @Override - public void update(long bytesRead, long contentLength, boolean done) { - callback.onDownloadProgress(bytesRead, contentLength, done); - } - }; - - progressRequestListener = new ProgressRequestBody.ProgressRequestListener() { - @Override - public void onRequestProgress(long bytesWritten, long contentLength, boolean done) { - callback.onUploadProgress(bytesWritten, contentLength, done); - } - }; - } - - com.squareup.okhttp.Call call = getDeviceVisitsValidateBeforeCall(id, start, duration, progressListener, progressRequestListener); - Type localVarReturnType = new TypeToken>(){}.getType(); - apiClient.executeAsync(call, localVarReturnType, callback); - return call; - } - /** - * Build call for getDevices - * @param pageOffset The offset in terms of elements. (optional, default to 0) - * @param pageSize The maximum number of elements on the page. (optional, default to 20) - * @param progressListener Progress listener - * @param progressRequestListener Progress request listener - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - */ - public com.squareup.okhttp.Call getDevicesCall(Integer pageOffset, Integer pageSize, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - Object localVarPostBody = null; - - // create path and map variables - String localVarPath = "/devices"; - - List localVarQueryParams = new ArrayList(); - if (pageOffset != null) - localVarQueryParams.addAll(apiClient.parameterToPairs("", "pageOffset", pageOffset)); - if (pageSize != null) - localVarQueryParams.addAll(apiClient.parameterToPairs("", "pageSize", pageSize)); - - Map localVarHeaderParams = new HashMap(); - - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json", "application/xml" - }; - final String localVarAccept = apiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) localVarHeaderParams.put("Accept", localVarAccept); - - final String[] localVarContentTypes = { - "application/json", "application/xml" - }; - final String localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); - - if(progressListener != null) { - apiClient.getHttpClient().networkInterceptors().add(new com.squareup.okhttp.Interceptor() { - @Override - public com.squareup.okhttp.Response intercept(com.squareup.okhttp.Interceptor.Chain chain) throws IOException { - com.squareup.okhttp.Response originalResponse = chain.proceed(chain.request()); - return originalResponse.newBuilder() - .body(new ProgressResponseBody(originalResponse.body(), progressListener)) - .build(); - } - }); - } - - String[] localVarAuthNames = new String[] { "admin" }; - return apiClient.buildCall(localVarPath, "GET", localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, progressRequestListener); - } - - @SuppressWarnings("rawtypes") - private com.squareup.okhttp.Call getDevicesValidateBeforeCall(Integer pageOffset, Integer pageSize, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - - - com.squareup.okhttp.Call call = getDevicesCall(pageOffset, pageSize, progressListener, progressRequestListener); - return call; - - - - - - } - - /** - * Returns all devices. - * - * @param pageOffset The offset in terms of elements. (optional, default to 0) - * @param pageSize The maximum number of elements on the page. (optional, default to 20) - * @return DevicePage - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public DevicePage getDevices(Integer pageOffset, Integer pageSize) throws ApiException { - ApiResponse resp = getDevicesWithHttpInfo(pageOffset, pageSize); - return resp.getData(); - } - - /** - * Returns all devices. - * - * @param pageOffset The offset in terms of elements. (optional, default to 0) - * @param pageSize The maximum number of elements on the page. (optional, default to 20) - * @return ApiResponse<DevicePage> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public ApiResponse getDevicesWithHttpInfo(Integer pageOffset, Integer pageSize) throws ApiException { - com.squareup.okhttp.Call call = getDevicesValidateBeforeCall(pageOffset, pageSize, null, null); - Type localVarReturnType = new TypeToken(){}.getType(); - return apiClient.execute(call, localVarReturnType); - } - - /** - * Returns all devices. (asynchronously) - * - * @param pageOffset The offset in terms of elements. (optional, default to 0) - * @param pageSize The maximum number of elements on the page. (optional, default to 20) - * @param callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - */ - public com.squareup.okhttp.Call getDevicesAsync(Integer pageOffset, Integer pageSize, final ApiCallback callback) throws ApiException { - - ProgressResponseBody.ProgressListener progressListener = null; - ProgressRequestBody.ProgressRequestListener progressRequestListener = null; - - if (callback != null) { - progressListener = new ProgressResponseBody.ProgressListener() { - @Override - public void update(long bytesRead, long contentLength, boolean done) { - callback.onDownloadProgress(bytesRead, contentLength, done); - } - }; - - progressRequestListener = new ProgressRequestBody.ProgressRequestListener() { - @Override - public void onRequestProgress(long bytesWritten, long contentLength, boolean done) { - callback.onUploadProgress(bytesWritten, contentLength, done); - } - }; - } - - com.squareup.okhttp.Call call = getDevicesValidateBeforeCall(pageOffset, pageSize, progressListener, progressRequestListener); - Type localVarReturnType = new TypeToken(){}.getType(); - apiClient.executeAsync(call, localVarReturnType, callback); - return call; - } - /** - * Build call for setDevice - * @param id The device id. (required) - * @param body The device values. (optional) - * @param progressListener Progress listener - * @param progressRequestListener Progress request listener - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - */ - public com.squareup.okhttp.Call setDeviceCall(Long id, Device body, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - Object localVarPostBody = body; - - // create path and map variables - String localVarPath = "/devices/{id}" - .replaceAll("\\{" + "id" + "\\}", apiClient.escapeString(id.toString())); - - List localVarQueryParams = new ArrayList(); - - Map localVarHeaderParams = new HashMap(); - - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json", "application/xml" - }; - final String localVarAccept = apiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) localVarHeaderParams.put("Accept", localVarAccept); - - final String[] localVarContentTypes = { - "application/json", "application/xml" - }; - final String localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); - - if(progressListener != null) { - apiClient.getHttpClient().networkInterceptors().add(new com.squareup.okhttp.Interceptor() { - @Override - public com.squareup.okhttp.Response intercept(com.squareup.okhttp.Interceptor.Chain chain) throws IOException { - com.squareup.okhttp.Response originalResponse = chain.proceed(chain.request()); - return originalResponse.newBuilder() - .body(new ProgressResponseBody(originalResponse.body(), progressListener)) - .build(); - } - }); - } - - String[] localVarAuthNames = new String[] { "admin" }; - return apiClient.buildCall(localVarPath, "PUT", localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, progressRequestListener); - } - - @SuppressWarnings("rawtypes") - private com.squareup.okhttp.Call setDeviceValidateBeforeCall(Long id, Device body, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - - // verify the required parameter 'id' is set - if (id == null) { - throw new ApiException("Missing the required parameter 'id' when calling setDevice(Async)"); - } - - - com.squareup.okhttp.Call call = setDeviceCall(id, body, progressListener, progressRequestListener); - return call; - - - - - - } - - /** - * Sets the values of a device. - * - * @param id The device id. (required) - * @param body The device values. (optional) - * @return Device - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public Device setDevice(Long id, Device body) throws ApiException { - ApiResponse resp = setDeviceWithHttpInfo(id, body); - return resp.getData(); - } - - /** - * Sets the values of a device. - * - * @param id The device id. (required) - * @param body The device values. (optional) - * @return ApiResponse<Device> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public ApiResponse setDeviceWithHttpInfo(Long id, Device body) throws ApiException { - com.squareup.okhttp.Call call = setDeviceValidateBeforeCall(id, body, null, null); - Type localVarReturnType = new TypeToken(){}.getType(); - return apiClient.execute(call, localVarReturnType); - } - - /** - * Sets the values of a device. (asynchronously) - * - * @param id The device id. (required) - * @param body The device values. (optional) - * @param callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - */ - public com.squareup.okhttp.Call setDeviceAsync(Long id, Device body, final ApiCallback callback) throws ApiException { - - ProgressResponseBody.ProgressListener progressListener = null; - ProgressRequestBody.ProgressRequestListener progressRequestListener = null; - - if (callback != null) { - progressListener = new ProgressResponseBody.ProgressListener() { - @Override - public void update(long bytesRead, long contentLength, boolean done) { - callback.onDownloadProgress(bytesRead, contentLength, done); - } - }; - - progressRequestListener = new ProgressRequestBody.ProgressRequestListener() { - @Override - public void onRequestProgress(long bytesWritten, long contentLength, boolean done) { - callback.onUploadProgress(bytesWritten, contentLength, done); - } - }; - } - - com.squareup.okhttp.Call call = setDeviceValidateBeforeCall(id, body, progressListener, progressRequestListener); - Type localVarReturnType = new TypeToken(){}.getType(); - apiClient.executeAsync(call, localVarReturnType, callback); - return call; - } -} diff --git a/testing/api-client/src/main/java/io/swagger/client/api/PlaceApi.java b/testing/api-client/src/main/java/io/swagger/client/api/PlaceApi.java deleted file mode 100644 index 883241e..0000000 --- a/testing/api-client/src/main/java/io/swagger/client/api/PlaceApi.java +++ /dev/null @@ -1,457 +0,0 @@ -/* - * Maptology Service - * Maptology Service - * - * OpenAPI spec version: 0.0.1-SNAPSHOT - * Contact: nes-admin@uni-due.de - * - * NOTE: This class is auto generated by the swagger code generator program. - * https://github.com/swagger-api/swagger-codegen.git - * Do not edit the class manually. - */ - - -package io.swagger.client.api; - -import io.swagger.client.ApiCallback; -import io.swagger.client.ApiClient; -import io.swagger.client.ApiException; -import io.swagger.client.ApiResponse; -import io.swagger.client.Configuration; -import io.swagger.client.Pair; -import io.swagger.client.ProgressRequestBody; -import io.swagger.client.ProgressResponseBody; - -import com.google.gson.reflect.TypeToken; - -import java.io.IOException; - - -import io.swagger.client.model.Place; -import io.swagger.client.model.VisitPage; - -import java.lang.reflect.Type; -import java.util.ArrayList; -import java.util.HashMap; -import java.util.List; -import java.util.Map; - -public class PlaceApi { - private ApiClient apiClient; - - public PlaceApi() { - this(Configuration.getDefaultApiClient()); - } - - public PlaceApi(ApiClient apiClient) { - this.apiClient = apiClient; - } - - public ApiClient getApiClient() { - return apiClient; - } - - public void setApiClient(ApiClient apiClient) { - this.apiClient = apiClient; - } - - /** - * Build call for getPlace - * @param id The place id. (required) - * @param progressListener Progress listener - * @param progressRequestListener Progress request listener - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - */ - public com.squareup.okhttp.Call getPlaceCall(Long id, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - Object localVarPostBody = null; - - // create path and map variables - String localVarPath = "/places/{id}" - .replaceAll("\\{" + "id" + "\\}", apiClient.escapeString(id.toString())); - - List localVarQueryParams = new ArrayList(); - - Map localVarHeaderParams = new HashMap(); - - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json", "application/xml" - }; - final String localVarAccept = apiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) localVarHeaderParams.put("Accept", localVarAccept); - - final String[] localVarContentTypes = { - "application/json", "application/xml" - }; - final String localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); - - if(progressListener != null) { - apiClient.getHttpClient().networkInterceptors().add(new com.squareup.okhttp.Interceptor() { - @Override - public com.squareup.okhttp.Response intercept(com.squareup.okhttp.Interceptor.Chain chain) throws IOException { - com.squareup.okhttp.Response originalResponse = chain.proceed(chain.request()); - return originalResponse.newBuilder() - .body(new ProgressResponseBody(originalResponse.body(), progressListener)) - .build(); - } - }); - } - - String[] localVarAuthNames = new String[] { }; - return apiClient.buildCall(localVarPath, "GET", localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, progressRequestListener); - } - - @SuppressWarnings("rawtypes") - private com.squareup.okhttp.Call getPlaceValidateBeforeCall(Long id, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - - // verify the required parameter 'id' is set - if (id == null) { - throw new ApiException("Missing the required parameter 'id' when calling getPlace(Async)"); - } - - - com.squareup.okhttp.Call call = getPlaceCall(id, progressListener, progressRequestListener); - return call; - - - - - - } - - /** - * Returns the place with the specified id. - * - * @param id The place id. (required) - * @return Place - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public Place getPlace(Long id) throws ApiException { - ApiResponse resp = getPlaceWithHttpInfo(id); - return resp.getData(); - } - - /** - * Returns the place with the specified id. - * - * @param id The place id. (required) - * @return ApiResponse<Place> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public ApiResponse getPlaceWithHttpInfo(Long id) throws ApiException { - com.squareup.okhttp.Call call = getPlaceValidateBeforeCall(id, null, null); - Type localVarReturnType = new TypeToken(){}.getType(); - return apiClient.execute(call, localVarReturnType); - } - - /** - * Returns the place with the specified id. (asynchronously) - * - * @param id The place id. (required) - * @param callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - */ - public com.squareup.okhttp.Call getPlaceAsync(Long id, final ApiCallback callback) throws ApiException { - - ProgressResponseBody.ProgressListener progressListener = null; - ProgressRequestBody.ProgressRequestListener progressRequestListener = null; - - if (callback != null) { - progressListener = new ProgressResponseBody.ProgressListener() { - @Override - public void update(long bytesRead, long contentLength, boolean done) { - callback.onDownloadProgress(bytesRead, contentLength, done); - } - }; - - progressRequestListener = new ProgressRequestBody.ProgressRequestListener() { - @Override - public void onRequestProgress(long bytesWritten, long contentLength, boolean done) { - callback.onUploadProgress(bytesWritten, contentLength, done); - } - }; - } - - com.squareup.okhttp.Call call = getPlaceValidateBeforeCall(id, progressListener, progressRequestListener); - Type localVarReturnType = new TypeToken(){}.getType(); - apiClient.executeAsync(call, localVarReturnType, callback); - return call; - } - /** - * Build call for getPlaceVisits - * @param id The place id. (required) - * @param pageOffset The offset in terms of elements. (optional, default to 0) - * @param pageSize The maximum number of elements on the page. (optional, default to 20) - * @param progressListener Progress listener - * @param progressRequestListener Progress request listener - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - */ - public com.squareup.okhttp.Call getPlaceVisitsCall(Long id, Integer pageOffset, Integer pageSize, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - Object localVarPostBody = null; - - // create path and map variables - String localVarPath = "/places/{id}/visits" - .replaceAll("\\{" + "id" + "\\}", apiClient.escapeString(id.toString())); - - List localVarQueryParams = new ArrayList(); - if (pageOffset != null) - localVarQueryParams.addAll(apiClient.parameterToPairs("", "pageOffset", pageOffset)); - if (pageSize != null) - localVarQueryParams.addAll(apiClient.parameterToPairs("", "pageSize", pageSize)); - - Map localVarHeaderParams = new HashMap(); - - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json", "application/xml" - }; - final String localVarAccept = apiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) localVarHeaderParams.put("Accept", localVarAccept); - - final String[] localVarContentTypes = { - "application/json", "application/xml" - }; - final String localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); - - if(progressListener != null) { - apiClient.getHttpClient().networkInterceptors().add(new com.squareup.okhttp.Interceptor() { - @Override - public com.squareup.okhttp.Response intercept(com.squareup.okhttp.Interceptor.Chain chain) throws IOException { - com.squareup.okhttp.Response originalResponse = chain.proceed(chain.request()); - return originalResponse.newBuilder() - .body(new ProgressResponseBody(originalResponse.body(), progressListener)) - .build(); - } - }); - } - - String[] localVarAuthNames = new String[] { }; - return apiClient.buildCall(localVarPath, "GET", localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, progressRequestListener); - } - - @SuppressWarnings("rawtypes") - private com.squareup.okhttp.Call getPlaceVisitsValidateBeforeCall(Long id, Integer pageOffset, Integer pageSize, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - - // verify the required parameter 'id' is set - if (id == null) { - throw new ApiException("Missing the required parameter 'id' when calling getPlaceVisits(Async)"); - } - - - com.squareup.okhttp.Call call = getPlaceVisitsCall(id, pageOffset, pageSize, progressListener, progressRequestListener); - return call; - - - - - - } - - /** - * Returns the visits for a particular place. - * - * @param id The place id. (required) - * @param pageOffset The offset in terms of elements. (optional, default to 0) - * @param pageSize The maximum number of elements on the page. (optional, default to 20) - * @return VisitPage - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public VisitPage getPlaceVisits(Long id, Integer pageOffset, Integer pageSize) throws ApiException { - ApiResponse resp = getPlaceVisitsWithHttpInfo(id, pageOffset, pageSize); - return resp.getData(); - } - - /** - * Returns the visits for a particular place. - * - * @param id The place id. (required) - * @param pageOffset The offset in terms of elements. (optional, default to 0) - * @param pageSize The maximum number of elements on the page. (optional, default to 20) - * @return ApiResponse<VisitPage> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public ApiResponse getPlaceVisitsWithHttpInfo(Long id, Integer pageOffset, Integer pageSize) throws ApiException { - com.squareup.okhttp.Call call = getPlaceVisitsValidateBeforeCall(id, pageOffset, pageSize, null, null); - Type localVarReturnType = new TypeToken(){}.getType(); - return apiClient.execute(call, localVarReturnType); - } - - /** - * Returns the visits for a particular place. (asynchronously) - * - * @param id The place id. (required) - * @param pageOffset The offset in terms of elements. (optional, default to 0) - * @param pageSize The maximum number of elements on the page. (optional, default to 20) - * @param callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - */ - public com.squareup.okhttp.Call getPlaceVisitsAsync(Long id, Integer pageOffset, Integer pageSize, final ApiCallback callback) throws ApiException { - - ProgressResponseBody.ProgressListener progressListener = null; - ProgressRequestBody.ProgressRequestListener progressRequestListener = null; - - if (callback != null) { - progressListener = new ProgressResponseBody.ProgressListener() { - @Override - public void update(long bytesRead, long contentLength, boolean done) { - callback.onDownloadProgress(bytesRead, contentLength, done); - } - }; - - progressRequestListener = new ProgressRequestBody.ProgressRequestListener() { - @Override - public void onRequestProgress(long bytesWritten, long contentLength, boolean done) { - callback.onUploadProgress(bytesWritten, contentLength, done); - } - }; - } - - com.squareup.okhttp.Call call = getPlaceVisitsValidateBeforeCall(id, pageOffset, pageSize, progressListener, progressRequestListener); - Type localVarReturnType = new TypeToken(){}.getType(); - apiClient.executeAsync(call, localVarReturnType, callback); - return call; - } - /** - * Build call for setPlace - * @param id The place id. (required) - * @param body The place to set. (required) - * @param progressListener Progress listener - * @param progressRequestListener Progress request listener - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - */ - public com.squareup.okhttp.Call setPlaceCall(Long id, Place body, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - Object localVarPostBody = body; - - // create path and map variables - String localVarPath = "/places/{id}" - .replaceAll("\\{" + "id" + "\\}", apiClient.escapeString(id.toString())); - - List localVarQueryParams = new ArrayList(); - - Map localVarHeaderParams = new HashMap(); - - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json", "application/xml" - }; - final String localVarAccept = apiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) localVarHeaderParams.put("Accept", localVarAccept); - - final String[] localVarContentTypes = { - "application/json", "application/xml" - }; - final String localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); - - if(progressListener != null) { - apiClient.getHttpClient().networkInterceptors().add(new com.squareup.okhttp.Interceptor() { - @Override - public com.squareup.okhttp.Response intercept(com.squareup.okhttp.Interceptor.Chain chain) throws IOException { - com.squareup.okhttp.Response originalResponse = chain.proceed(chain.request()); - return originalResponse.newBuilder() - .body(new ProgressResponseBody(originalResponse.body(), progressListener)) - .build(); - } - }); - } - - String[] localVarAuthNames = new String[] { }; - return apiClient.buildCall(localVarPath, "PUT", localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, progressRequestListener); - } - - @SuppressWarnings("rawtypes") - private com.squareup.okhttp.Call setPlaceValidateBeforeCall(Long id, Place body, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - - // verify the required parameter 'id' is set - if (id == null) { - throw new ApiException("Missing the required parameter 'id' when calling setPlace(Async)"); - } - - // verify the required parameter 'body' is set - if (body == null) { - throw new ApiException("Missing the required parameter 'body' when calling setPlace(Async)"); - } - - - com.squareup.okhttp.Call call = setPlaceCall(id, body, progressListener, progressRequestListener); - return call; - - - - - - } - - /** - * Updates the place with the specified id. - * - * @param id The place id. (required) - * @param body The place to set. (required) - * @return Place - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public Place setPlace(Long id, Place body) throws ApiException { - ApiResponse resp = setPlaceWithHttpInfo(id, body); - return resp.getData(); - } - - /** - * Updates the place with the specified id. - * - * @param id The place id. (required) - * @param body The place to set. (required) - * @return ApiResponse<Place> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public ApiResponse setPlaceWithHttpInfo(Long id, Place body) throws ApiException { - com.squareup.okhttp.Call call = setPlaceValidateBeforeCall(id, body, null, null); - Type localVarReturnType = new TypeToken(){}.getType(); - return apiClient.execute(call, localVarReturnType); - } - - /** - * Updates the place with the specified id. (asynchronously) - * - * @param id The place id. (required) - * @param body The place to set. (required) - * @param callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - */ - public com.squareup.okhttp.Call setPlaceAsync(Long id, Place body, final ApiCallback callback) throws ApiException { - - ProgressResponseBody.ProgressListener progressListener = null; - ProgressRequestBody.ProgressRequestListener progressRequestListener = null; - - if (callback != null) { - progressListener = new ProgressResponseBody.ProgressListener() { - @Override - public void update(long bytesRead, long contentLength, boolean done) { - callback.onDownloadProgress(bytesRead, contentLength, done); - } - }; - - progressRequestListener = new ProgressRequestBody.ProgressRequestListener() { - @Override - public void onRequestProgress(long bytesWritten, long contentLength, boolean done) { - callback.onUploadProgress(bytesWritten, contentLength, done); - } - }; - } - - com.squareup.okhttp.Call call = setPlaceValidateBeforeCall(id, body, progressListener, progressRequestListener); - Type localVarReturnType = new TypeToken(){}.getType(); - apiClient.executeAsync(call, localVarReturnType, callback); - return call; - } -} diff --git a/testing/api-client/src/main/java/io/swagger/client/api/PrivilegeApi.java b/testing/api-client/src/main/java/io/swagger/client/api/PrivilegeApi.java deleted file mode 100644 index 021b920..0000000 --- a/testing/api-client/src/main/java/io/swagger/client/api/PrivilegeApi.java +++ /dev/null @@ -1,432 +0,0 @@ -/* - * Maptology Service - * Maptology Service - * - * OpenAPI spec version: 0.0.1-SNAPSHOT - * Contact: nes-admin@uni-due.de - * - * NOTE: This class is auto generated by the swagger code generator program. - * https://github.com/swagger-api/swagger-codegen.git - * Do not edit the class manually. - */ - - -package io.swagger.client.api; - -import io.swagger.client.ApiCallback; -import io.swagger.client.ApiClient; -import io.swagger.client.ApiException; -import io.swagger.client.ApiResponse; -import io.swagger.client.Configuration; -import io.swagger.client.Pair; -import io.swagger.client.ProgressRequestBody; -import io.swagger.client.ProgressResponseBody; - -import com.google.gson.reflect.TypeToken; - -import java.io.IOException; - - -import io.swagger.client.model.Location; -import io.swagger.client.model.Privilege; - -import java.lang.reflect.Type; -import java.util.ArrayList; -import java.util.HashMap; -import java.util.List; -import java.util.Map; - -public class PrivilegeApi { - private ApiClient apiClient; - - public PrivilegeApi() { - this(Configuration.getDefaultApiClient()); - } - - public PrivilegeApi(ApiClient apiClient) { - this.apiClient = apiClient; - } - - public ApiClient getApiClient() { - return apiClient; - } - - public void setApiClient(ApiClient apiClient) { - this.apiClient = apiClient; - } - - /** - * Build call for deletePrivilege - * @param id The privilege id. (required) - * @param progressListener Progress listener - * @param progressRequestListener Progress request listener - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - */ - public com.squareup.okhttp.Call deletePrivilegeCall(Long id, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - Object localVarPostBody = null; - - // create path and map variables - String localVarPath = "/privileges/{id}" - .replaceAll("\\{" + "id" + "\\}", apiClient.escapeString(id.toString())); - - List localVarQueryParams = new ArrayList(); - - Map localVarHeaderParams = new HashMap(); - - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json", "application/xml" - }; - final String localVarAccept = apiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) localVarHeaderParams.put("Accept", localVarAccept); - - final String[] localVarContentTypes = { - "application/json", "application/xml" - }; - final String localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); - - if(progressListener != null) { - apiClient.getHttpClient().networkInterceptors().add(new com.squareup.okhttp.Interceptor() { - @Override - public com.squareup.okhttp.Response intercept(com.squareup.okhttp.Interceptor.Chain chain) throws IOException { - com.squareup.okhttp.Response originalResponse = chain.proceed(chain.request()); - return originalResponse.newBuilder() - .body(new ProgressResponseBody(originalResponse.body(), progressListener)) - .build(); - } - }); - } - - String[] localVarAuthNames = new String[] { "admin", "user" }; - return apiClient.buildCall(localVarPath, "DELETE", localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, progressRequestListener); - } - - @SuppressWarnings("rawtypes") - private com.squareup.okhttp.Call deletePrivilegeValidateBeforeCall(Long id, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - - // verify the required parameter 'id' is set - if (id == null) { - throw new ApiException("Missing the required parameter 'id' when calling deletePrivilege(Async)"); - } - - - com.squareup.okhttp.Call call = deletePrivilegeCall(id, progressListener, progressRequestListener); - return call; - - - - - - } - - /** - * Deletes a particular privilege. - * - * @param id The privilege id. (required) - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public void deletePrivilege(Long id) throws ApiException { - deletePrivilegeWithHttpInfo(id); - } - - /** - * Deletes a particular privilege. - * - * @param id The privilege id. (required) - * @return ApiResponse<Void> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public ApiResponse deletePrivilegeWithHttpInfo(Long id) throws ApiException { - com.squareup.okhttp.Call call = deletePrivilegeValidateBeforeCall(id, null, null); - return apiClient.execute(call); - } - - /** - * Deletes a particular privilege. (asynchronously) - * - * @param id The privilege id. (required) - * @param callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - */ - public com.squareup.okhttp.Call deletePrivilegeAsync(Long id, final ApiCallback callback) throws ApiException { - - ProgressResponseBody.ProgressListener progressListener = null; - ProgressRequestBody.ProgressRequestListener progressRequestListener = null; - - if (callback != null) { - progressListener = new ProgressResponseBody.ProgressListener() { - @Override - public void update(long bytesRead, long contentLength, boolean done) { - callback.onDownloadProgress(bytesRead, contentLength, done); - } - }; - - progressRequestListener = new ProgressRequestBody.ProgressRequestListener() { - @Override - public void onRequestProgress(long bytesWritten, long contentLength, boolean done) { - callback.onUploadProgress(bytesWritten, contentLength, done); - } - }; - } - - com.squareup.okhttp.Call call = deletePrivilegeValidateBeforeCall(id, progressListener, progressRequestListener); - apiClient.executeAsync(call, callback); - return call; - } - /** - * Build call for getPrivilege - * @param id The privilege id. (required) - * @param progressListener Progress listener - * @param progressRequestListener Progress request listener - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - */ - public com.squareup.okhttp.Call getPrivilegeCall(Long id, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - Object localVarPostBody = null; - - // create path and map variables - String localVarPath = "/privileges/{id}" - .replaceAll("\\{" + "id" + "\\}", apiClient.escapeString(id.toString())); - - List localVarQueryParams = new ArrayList(); - - Map localVarHeaderParams = new HashMap(); - - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json", "application/xml" - }; - final String localVarAccept = apiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) localVarHeaderParams.put("Accept", localVarAccept); - - final String[] localVarContentTypes = { - "application/json", "application/xml" - }; - final String localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); - - if(progressListener != null) { - apiClient.getHttpClient().networkInterceptors().add(new com.squareup.okhttp.Interceptor() { - @Override - public com.squareup.okhttp.Response intercept(com.squareup.okhttp.Interceptor.Chain chain) throws IOException { - com.squareup.okhttp.Response originalResponse = chain.proceed(chain.request()); - return originalResponse.newBuilder() - .body(new ProgressResponseBody(originalResponse.body(), progressListener)) - .build(); - } - }); - } - - String[] localVarAuthNames = new String[] { "admin", "user" }; - return apiClient.buildCall(localVarPath, "GET", localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, progressRequestListener); - } - - @SuppressWarnings("rawtypes") - private com.squareup.okhttp.Call getPrivilegeValidateBeforeCall(Long id, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - - // verify the required parameter 'id' is set - if (id == null) { - throw new ApiException("Missing the required parameter 'id' when calling getPrivilege(Async)"); - } - - - com.squareup.okhttp.Call call = getPrivilegeCall(id, progressListener, progressRequestListener); - return call; - - - - - - } - - /** - * Returns the privileges for a particular user. - * - * @param id The privilege id. (required) - * @return Privilege - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public Privilege getPrivilege(Long id) throws ApiException { - ApiResponse resp = getPrivilegeWithHttpInfo(id); - return resp.getData(); - } - - /** - * Returns the privileges for a particular user. - * - * @param id The privilege id. (required) - * @return ApiResponse<Privilege> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public ApiResponse getPrivilegeWithHttpInfo(Long id) throws ApiException { - com.squareup.okhttp.Call call = getPrivilegeValidateBeforeCall(id, null, null); - Type localVarReturnType = new TypeToken(){}.getType(); - return apiClient.execute(call, localVarReturnType); - } - - /** - * Returns the privileges for a particular user. (asynchronously) - * - * @param id The privilege id. (required) - * @param callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - */ - public com.squareup.okhttp.Call getPrivilegeAsync(Long id, final ApiCallback callback) throws ApiException { - - ProgressResponseBody.ProgressListener progressListener = null; - ProgressRequestBody.ProgressRequestListener progressRequestListener = null; - - if (callback != null) { - progressListener = new ProgressResponseBody.ProgressListener() { - @Override - public void update(long bytesRead, long contentLength, boolean done) { - callback.onDownloadProgress(bytesRead, contentLength, done); - } - }; - - progressRequestListener = new ProgressRequestBody.ProgressRequestListener() { - @Override - public void onRequestProgress(long bytesWritten, long contentLength, boolean done) { - callback.onUploadProgress(bytesWritten, contentLength, done); - } - }; - } - - com.squareup.okhttp.Call call = getPrivilegeValidateBeforeCall(id, progressListener, progressRequestListener); - Type localVarReturnType = new TypeToken(){}.getType(); - apiClient.executeAsync(call, localVarReturnType, callback); - return call; - } - /** - * Build call for getPrivilegeLocation - * @param id The privilege id. (required) - * @param progressListener Progress listener - * @param progressRequestListener Progress request listener - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - */ - public com.squareup.okhttp.Call getPrivilegeLocationCall(Long id, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - Object localVarPostBody = null; - - // create path and map variables - String localVarPath = "/privileges/{id}/location" - .replaceAll("\\{" + "id" + "\\}", apiClient.escapeString(id.toString())); - - List localVarQueryParams = new ArrayList(); - - Map localVarHeaderParams = new HashMap(); - - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json", "application/xml" - }; - final String localVarAccept = apiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) localVarHeaderParams.put("Accept", localVarAccept); - - final String[] localVarContentTypes = { - "application/json", "application/xml" - }; - final String localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); - - if(progressListener != null) { - apiClient.getHttpClient().networkInterceptors().add(new com.squareup.okhttp.Interceptor() { - @Override - public com.squareup.okhttp.Response intercept(com.squareup.okhttp.Interceptor.Chain chain) throws IOException { - com.squareup.okhttp.Response originalResponse = chain.proceed(chain.request()); - return originalResponse.newBuilder() - .body(new ProgressResponseBody(originalResponse.body(), progressListener)) - .build(); - } - }); - } - - String[] localVarAuthNames = new String[] { "admin", "user" }; - return apiClient.buildCall(localVarPath, "GET", localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, progressRequestListener); - } - - @SuppressWarnings("rawtypes") - private com.squareup.okhttp.Call getPrivilegeLocationValidateBeforeCall(Long id, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - - // verify the required parameter 'id' is set - if (id == null) { - throw new ApiException("Missing the required parameter 'id' when calling getPrivilegeLocation(Async)"); - } - - - com.squareup.okhttp.Call call = getPrivilegeLocationCall(id, progressListener, progressRequestListener); - return call; - - - - - - } - - /** - * Returns the location for a particular privilege. - * - * @param id The privilege id. (required) - * @return Location - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public Location getPrivilegeLocation(Long id) throws ApiException { - ApiResponse resp = getPrivilegeLocationWithHttpInfo(id); - return resp.getData(); - } - - /** - * Returns the location for a particular privilege. - * - * @param id The privilege id. (required) - * @return ApiResponse<Location> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public ApiResponse getPrivilegeLocationWithHttpInfo(Long id) throws ApiException { - com.squareup.okhttp.Call call = getPrivilegeLocationValidateBeforeCall(id, null, null); - Type localVarReturnType = new TypeToken(){}.getType(); - return apiClient.execute(call, localVarReturnType); - } - - /** - * Returns the location for a particular privilege. (asynchronously) - * - * @param id The privilege id. (required) - * @param callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - */ - public com.squareup.okhttp.Call getPrivilegeLocationAsync(Long id, final ApiCallback callback) throws ApiException { - - ProgressResponseBody.ProgressListener progressListener = null; - ProgressRequestBody.ProgressRequestListener progressRequestListener = null; - - if (callback != null) { - progressListener = new ProgressResponseBody.ProgressListener() { - @Override - public void update(long bytesRead, long contentLength, boolean done) { - callback.onDownloadProgress(bytesRead, contentLength, done); - } - }; - - progressRequestListener = new ProgressRequestBody.ProgressRequestListener() { - @Override - public void onRequestProgress(long bytesWritten, long contentLength, boolean done) { - callback.onUploadProgress(bytesWritten, contentLength, done); - } - }; - } - - com.squareup.okhttp.Call call = getPrivilegeLocationValidateBeforeCall(id, progressListener, progressRequestListener); - Type localVarReturnType = new TypeToken(){}.getType(); - apiClient.executeAsync(call, localVarReturnType, callback); - return call; - } -} diff --git a/testing/api-client/src/main/java/io/swagger/client/api/ServiceApi.java b/testing/api-client/src/main/java/io/swagger/client/api/ServiceApi.java deleted file mode 100644 index 3e0dfff..0000000 --- a/testing/api-client/src/main/java/io/swagger/client/api/ServiceApi.java +++ /dev/null @@ -1,1412 +0,0 @@ -/* - * Maptology Service - * Maptology Service - * - * OpenAPI spec version: 0.0.1-SNAPSHOT - * Contact: nes-admin@uni-due.de - * - * NOTE: This class is auto generated by the swagger code generator program. - * https://github.com/swagger-api/swagger-codegen.git - * Do not edit the class manually. - */ - - -package io.swagger.client.api; - -import io.swagger.client.ApiCallback; -import io.swagger.client.ApiClient; -import io.swagger.client.ApiException; -import io.swagger.client.ApiResponse; -import io.swagger.client.Configuration; -import io.swagger.client.Pair; -import io.swagger.client.ProgressRequestBody; -import io.swagger.client.ProgressResponseBody; - -import com.google.gson.reflect.TypeToken; - -import java.io.IOException; - - -import io.swagger.client.model.BuildVersion; -import io.swagger.client.model.EntityStatistic; -import io.swagger.client.model.LoadStatistic; -import io.swagger.client.model.LogMessage; -import io.swagger.client.model.Notice; -import io.swagger.client.model.NoticePage; - -import java.lang.reflect.Type; -import java.util.ArrayList; -import java.util.HashMap; -import java.util.List; -import java.util.Map; - -public class ServiceApi { - private ApiClient apiClient; - - public ServiceApi() { - this(Configuration.getDefaultApiClient()); - } - - public ServiceApi(ApiClient apiClient) { - this.apiClient = apiClient; - } - - public ApiClient getApiClient() { - return apiClient; - } - - public void setApiClient(ApiClient apiClient) { - this.apiClient = apiClient; - } - - /** - * Build call for addNotice - * @param body The new notice to add. (required) - * @param progressListener Progress listener - * @param progressRequestListener Progress request listener - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - */ - public com.squareup.okhttp.Call addNoticeCall(Notice body, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - Object localVarPostBody = body; - - // create path and map variables - String localVarPath = "/notices"; - - List localVarQueryParams = new ArrayList(); - - Map localVarHeaderParams = new HashMap(); - - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json", "application/xml" - }; - final String localVarAccept = apiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) localVarHeaderParams.put("Accept", localVarAccept); - - final String[] localVarContentTypes = { - "application/json", "application/xml" - }; - final String localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); - - if(progressListener != null) { - apiClient.getHttpClient().networkInterceptors().add(new com.squareup.okhttp.Interceptor() { - @Override - public com.squareup.okhttp.Response intercept(com.squareup.okhttp.Interceptor.Chain chain) throws IOException { - com.squareup.okhttp.Response originalResponse = chain.proceed(chain.request()); - return originalResponse.newBuilder() - .body(new ProgressResponseBody(originalResponse.body(), progressListener)) - .build(); - } - }); - } - - String[] localVarAuthNames = new String[] { "admin" }; - return apiClient.buildCall(localVarPath, "POST", localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, progressRequestListener); - } - - @SuppressWarnings("rawtypes") - private com.squareup.okhttp.Call addNoticeValidateBeforeCall(Notice body, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - - // verify the required parameter 'body' is set - if (body == null) { - throw new ApiException("Missing the required parameter 'body' when calling addNotice(Async)"); - } - - - com.squareup.okhttp.Call call = addNoticeCall(body, progressListener, progressRequestListener); - return call; - - - - - - } - - /** - * Adds a new notice and returns the notice as well as its location. - * - * @param body The new notice to add. (required) - * @return Notice - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public Notice addNotice(Notice body) throws ApiException { - ApiResponse resp = addNoticeWithHttpInfo(body); - return resp.getData(); - } - - /** - * Adds a new notice and returns the notice as well as its location. - * - * @param body The new notice to add. (required) - * @return ApiResponse<Notice> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public ApiResponse addNoticeWithHttpInfo(Notice body) throws ApiException { - com.squareup.okhttp.Call call = addNoticeValidateBeforeCall(body, null, null); - Type localVarReturnType = new TypeToken(){}.getType(); - return apiClient.execute(call, localVarReturnType); - } - - /** - * Adds a new notice and returns the notice as well as its location. (asynchronously) - * - * @param body The new notice to add. (required) - * @param callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - */ - public com.squareup.okhttp.Call addNoticeAsync(Notice body, final ApiCallback callback) throws ApiException { - - ProgressResponseBody.ProgressListener progressListener = null; - ProgressRequestBody.ProgressRequestListener progressRequestListener = null; - - if (callback != null) { - progressListener = new ProgressResponseBody.ProgressListener() { - @Override - public void update(long bytesRead, long contentLength, boolean done) { - callback.onDownloadProgress(bytesRead, contentLength, done); - } - }; - - progressRequestListener = new ProgressRequestBody.ProgressRequestListener() { - @Override - public void onRequestProgress(long bytesWritten, long contentLength, boolean done) { - callback.onUploadProgress(bytesWritten, contentLength, done); - } - }; - } - - com.squareup.okhttp.Call call = addNoticeValidateBeforeCall(body, progressListener, progressRequestListener); - Type localVarReturnType = new TypeToken(){}.getType(); - apiClient.executeAsync(call, localVarReturnType, callback); - return call; - } - /** - * Build call for getActiveNotices - * @param pageOffset The offset in terms of elements. (optional, default to 0) - * @param pageSize The maximum number of elements on the page. (optional, default to 20) - * @param progressListener Progress listener - * @param progressRequestListener Progress request listener - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - */ - public com.squareup.okhttp.Call getActiveNoticesCall(Integer pageOffset, Integer pageSize, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - Object localVarPostBody = null; - - // create path and map variables - String localVarPath = "/notices/active"; - - List localVarQueryParams = new ArrayList(); - if (pageOffset != null) - localVarQueryParams.addAll(apiClient.parameterToPairs("", "pageOffset", pageOffset)); - if (pageSize != null) - localVarQueryParams.addAll(apiClient.parameterToPairs("", "pageSize", pageSize)); - - Map localVarHeaderParams = new HashMap(); - - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json", "application/xml" - }; - final String localVarAccept = apiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) localVarHeaderParams.put("Accept", localVarAccept); - - final String[] localVarContentTypes = { - "application/json", "application/xml" - }; - final String localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); - - if(progressListener != null) { - apiClient.getHttpClient().networkInterceptors().add(new com.squareup.okhttp.Interceptor() { - @Override - public com.squareup.okhttp.Response intercept(com.squareup.okhttp.Interceptor.Chain chain) throws IOException { - com.squareup.okhttp.Response originalResponse = chain.proceed(chain.request()); - return originalResponse.newBuilder() - .body(new ProgressResponseBody(originalResponse.body(), progressListener)) - .build(); - } - }); - } - - String[] localVarAuthNames = new String[] { }; - return apiClient.buildCall(localVarPath, "GET", localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, progressRequestListener); - } - - @SuppressWarnings("rawtypes") - private com.squareup.okhttp.Call getActiveNoticesValidateBeforeCall(Integer pageOffset, Integer pageSize, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - - - com.squareup.okhttp.Call call = getActiveNoticesCall(pageOffset, pageSize, progressListener, progressRequestListener); - return call; - - - - - - } - - /** - * Returns a page of notices. - * - * @param pageOffset The offset in terms of elements. (optional, default to 0) - * @param pageSize The maximum number of elements on the page. (optional, default to 20) - * @return NoticePage - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public NoticePage getActiveNotices(Integer pageOffset, Integer pageSize) throws ApiException { - ApiResponse resp = getActiveNoticesWithHttpInfo(pageOffset, pageSize); - return resp.getData(); - } - - /** - * Returns a page of notices. - * - * @param pageOffset The offset in terms of elements. (optional, default to 0) - * @param pageSize The maximum number of elements on the page. (optional, default to 20) - * @return ApiResponse<NoticePage> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public ApiResponse getActiveNoticesWithHttpInfo(Integer pageOffset, Integer pageSize) throws ApiException { - com.squareup.okhttp.Call call = getActiveNoticesValidateBeforeCall(pageOffset, pageSize, null, null); - Type localVarReturnType = new TypeToken(){}.getType(); - return apiClient.execute(call, localVarReturnType); - } - - /** - * Returns a page of notices. (asynchronously) - * - * @param pageOffset The offset in terms of elements. (optional, default to 0) - * @param pageSize The maximum number of elements on the page. (optional, default to 20) - * @param callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - */ - public com.squareup.okhttp.Call getActiveNoticesAsync(Integer pageOffset, Integer pageSize, final ApiCallback callback) throws ApiException { - - ProgressResponseBody.ProgressListener progressListener = null; - ProgressRequestBody.ProgressRequestListener progressRequestListener = null; - - if (callback != null) { - progressListener = new ProgressResponseBody.ProgressListener() { - @Override - public void update(long bytesRead, long contentLength, boolean done) { - callback.onDownloadProgress(bytesRead, contentLength, done); - } - }; - - progressRequestListener = new ProgressRequestBody.ProgressRequestListener() { - @Override - public void onRequestProgress(long bytesWritten, long contentLength, boolean done) { - callback.onUploadProgress(bytesWritten, contentLength, done); - } - }; - } - - com.squareup.okhttp.Call call = getActiveNoticesValidateBeforeCall(pageOffset, pageSize, progressListener, progressRequestListener); - Type localVarReturnType = new TypeToken(){}.getType(); - apiClient.executeAsync(call, localVarReturnType, callback); - return call; - } - /** - * Build call for getBuildVersion - * @param progressListener Progress listener - * @param progressRequestListener Progress request listener - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - */ - public com.squareup.okhttp.Call getBuildVersionCall(final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - Object localVarPostBody = null; - - // create path and map variables - String localVarPath = "/versions/build"; - - List localVarQueryParams = new ArrayList(); - - Map localVarHeaderParams = new HashMap(); - - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json", "application/xml" - }; - final String localVarAccept = apiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) localVarHeaderParams.put("Accept", localVarAccept); - - final String[] localVarContentTypes = { - - }; - final String localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); - - if(progressListener != null) { - apiClient.getHttpClient().networkInterceptors().add(new com.squareup.okhttp.Interceptor() { - @Override - public com.squareup.okhttp.Response intercept(com.squareup.okhttp.Interceptor.Chain chain) throws IOException { - com.squareup.okhttp.Response originalResponse = chain.proceed(chain.request()); - return originalResponse.newBuilder() - .body(new ProgressResponseBody(originalResponse.body(), progressListener)) - .build(); - } - }); - } - - String[] localVarAuthNames = new String[] { }; - return apiClient.buildCall(localVarPath, "GET", localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, progressRequestListener); - } - - @SuppressWarnings("rawtypes") - private com.squareup.okhttp.Call getBuildVersionValidateBeforeCall(final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - - - com.squareup.okhttp.Call call = getBuildVersionCall(progressListener, progressRequestListener); - return call; - - - - - - } - - /** - * Returns the build version. - * - * @return BuildVersion - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public BuildVersion getBuildVersion() throws ApiException { - ApiResponse resp = getBuildVersionWithHttpInfo(); - return resp.getData(); - } - - /** - * Returns the build version. - * - * @return ApiResponse<BuildVersion> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public ApiResponse getBuildVersionWithHttpInfo() throws ApiException { - com.squareup.okhttp.Call call = getBuildVersionValidateBeforeCall(null, null); - Type localVarReturnType = new TypeToken(){}.getType(); - return apiClient.execute(call, localVarReturnType); - } - - /** - * Returns the build version. (asynchronously) - * - * @param callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - */ - public com.squareup.okhttp.Call getBuildVersionAsync(final ApiCallback callback) throws ApiException { - - ProgressResponseBody.ProgressListener progressListener = null; - ProgressRequestBody.ProgressRequestListener progressRequestListener = null; - - if (callback != null) { - progressListener = new ProgressResponseBody.ProgressListener() { - @Override - public void update(long bytesRead, long contentLength, boolean done) { - callback.onDownloadProgress(bytesRead, contentLength, done); - } - }; - - progressRequestListener = new ProgressRequestBody.ProgressRequestListener() { - @Override - public void onRequestProgress(long bytesWritten, long contentLength, boolean done) { - callback.onUploadProgress(bytesWritten, contentLength, done); - } - }; - } - - com.squareup.okhttp.Call call = getBuildVersionValidateBeforeCall(progressListener, progressRequestListener); - Type localVarReturnType = new TypeToken(){}.getType(); - apiClient.executeAsync(call, localVarReturnType, callback); - return call; - } - /** - * Build call for getEntityStatistics - * @param progressListener Progress listener - * @param progressRequestListener Progress request listener - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - */ - public com.squareup.okhttp.Call getEntityStatisticsCall(final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - Object localVarPostBody = null; - - // create path and map variables - String localVarPath = "/log/entities"; - - List localVarQueryParams = new ArrayList(); - - Map localVarHeaderParams = new HashMap(); - - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json", "application/xml" - }; - final String localVarAccept = apiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) localVarHeaderParams.put("Accept", localVarAccept); - - final String[] localVarContentTypes = { - - }; - final String localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); - - if(progressListener != null) { - apiClient.getHttpClient().networkInterceptors().add(new com.squareup.okhttp.Interceptor() { - @Override - public com.squareup.okhttp.Response intercept(com.squareup.okhttp.Interceptor.Chain chain) throws IOException { - com.squareup.okhttp.Response originalResponse = chain.proceed(chain.request()); - return originalResponse.newBuilder() - .body(new ProgressResponseBody(originalResponse.body(), progressListener)) - .build(); - } - }); - } - - String[] localVarAuthNames = new String[] { "admin" }; - return apiClient.buildCall(localVarPath, "GET", localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, progressRequestListener); - } - - @SuppressWarnings("rawtypes") - private com.squareup.okhttp.Call getEntityStatisticsValidateBeforeCall(final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - - - com.squareup.okhttp.Call call = getEntityStatisticsCall(progressListener, progressRequestListener); - return call; - - - - - - } - - /** - * Returns a list of entity statistics. - * - * @return List<EntityStatistic> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public List getEntityStatistics() throws ApiException { - ApiResponse> resp = getEntityStatisticsWithHttpInfo(); - return resp.getData(); - } - - /** - * Returns a list of entity statistics. - * - * @return ApiResponse<List<EntityStatistic>> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public ApiResponse> getEntityStatisticsWithHttpInfo() throws ApiException { - com.squareup.okhttp.Call call = getEntityStatisticsValidateBeforeCall(null, null); - Type localVarReturnType = new TypeToken>(){}.getType(); - return apiClient.execute(call, localVarReturnType); - } - - /** - * Returns a list of entity statistics. (asynchronously) - * - * @param callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - */ - public com.squareup.okhttp.Call getEntityStatisticsAsync(final ApiCallback> callback) throws ApiException { - - ProgressResponseBody.ProgressListener progressListener = null; - ProgressRequestBody.ProgressRequestListener progressRequestListener = null; - - if (callback != null) { - progressListener = new ProgressResponseBody.ProgressListener() { - @Override - public void update(long bytesRead, long contentLength, boolean done) { - callback.onDownloadProgress(bytesRead, contentLength, done); - } - }; - - progressRequestListener = new ProgressRequestBody.ProgressRequestListener() { - @Override - public void onRequestProgress(long bytesWritten, long contentLength, boolean done) { - callback.onUploadProgress(bytesWritten, contentLength, done); - } - }; - } - - com.squareup.okhttp.Call call = getEntityStatisticsValidateBeforeCall(progressListener, progressRequestListener); - Type localVarReturnType = new TypeToken>(){}.getType(); - apiClient.executeAsync(call, localVarReturnType, callback); - return call; - } - /** - * Build call for getLoadStatistic - * @param progressListener Progress listener - * @param progressRequestListener Progress request listener - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - */ - public com.squareup.okhttp.Call getLoadStatisticCall(final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - Object localVarPostBody = null; - - // create path and map variables - String localVarPath = "/log/load"; - - List localVarQueryParams = new ArrayList(); - - Map localVarHeaderParams = new HashMap(); - - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json", "application/xml" - }; - final String localVarAccept = apiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) localVarHeaderParams.put("Accept", localVarAccept); - - final String[] localVarContentTypes = { - - }; - final String localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); - - if(progressListener != null) { - apiClient.getHttpClient().networkInterceptors().add(new com.squareup.okhttp.Interceptor() { - @Override - public com.squareup.okhttp.Response intercept(com.squareup.okhttp.Interceptor.Chain chain) throws IOException { - com.squareup.okhttp.Response originalResponse = chain.proceed(chain.request()); - return originalResponse.newBuilder() - .body(new ProgressResponseBody(originalResponse.body(), progressListener)) - .build(); - } - }); - } - - String[] localVarAuthNames = new String[] { "admin" }; - return apiClient.buildCall(localVarPath, "GET", localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, progressRequestListener); - } - - @SuppressWarnings("rawtypes") - private com.squareup.okhttp.Call getLoadStatisticValidateBeforeCall(final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - - - com.squareup.okhttp.Call call = getLoadStatisticCall(progressListener, progressRequestListener); - return call; - - - - - - } - - /** - * Returns the current load statistic. - * - * @return LoadStatistic - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public LoadStatistic getLoadStatistic() throws ApiException { - ApiResponse resp = getLoadStatisticWithHttpInfo(); - return resp.getData(); - } - - /** - * Returns the current load statistic. - * - * @return ApiResponse<LoadStatistic> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public ApiResponse getLoadStatisticWithHttpInfo() throws ApiException { - com.squareup.okhttp.Call call = getLoadStatisticValidateBeforeCall(null, null); - Type localVarReturnType = new TypeToken(){}.getType(); - return apiClient.execute(call, localVarReturnType); - } - - /** - * Returns the current load statistic. (asynchronously) - * - * @param callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - */ - public com.squareup.okhttp.Call getLoadStatisticAsync(final ApiCallback callback) throws ApiException { - - ProgressResponseBody.ProgressListener progressListener = null; - ProgressRequestBody.ProgressRequestListener progressRequestListener = null; - - if (callback != null) { - progressListener = new ProgressResponseBody.ProgressListener() { - @Override - public void update(long bytesRead, long contentLength, boolean done) { - callback.onDownloadProgress(bytesRead, contentLength, done); - } - }; - - progressRequestListener = new ProgressRequestBody.ProgressRequestListener() { - @Override - public void onRequestProgress(long bytesWritten, long contentLength, boolean done) { - callback.onUploadProgress(bytesWritten, contentLength, done); - } - }; - } - - com.squareup.okhttp.Call call = getLoadStatisticValidateBeforeCall(progressListener, progressRequestListener); - Type localVarReturnType = new TypeToken(){}.getType(); - apiClient.executeAsync(call, localVarReturnType, callback); - return call; - } - /** - * Build call for getLogMessages - * @param from The id of the first message to retrieve. (optional, default to 0) - * @param progressListener Progress listener - * @param progressRequestListener Progress request listener - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - */ - public com.squareup.okhttp.Call getLogMessagesCall(Long from, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - Object localVarPostBody = null; - - // create path and map variables - String localVarPath = "/log/messages"; - - List localVarQueryParams = new ArrayList(); - if (from != null) - localVarQueryParams.addAll(apiClient.parameterToPairs("", "from", from)); - - Map localVarHeaderParams = new HashMap(); - - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json", "application/xml" - }; - final String localVarAccept = apiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) localVarHeaderParams.put("Accept", localVarAccept); - - final String[] localVarContentTypes = { - - }; - final String localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); - - if(progressListener != null) { - apiClient.getHttpClient().networkInterceptors().add(new com.squareup.okhttp.Interceptor() { - @Override - public com.squareup.okhttp.Response intercept(com.squareup.okhttp.Interceptor.Chain chain) throws IOException { - com.squareup.okhttp.Response originalResponse = chain.proceed(chain.request()); - return originalResponse.newBuilder() - .body(new ProgressResponseBody(originalResponse.body(), progressListener)) - .build(); - } - }); - } - - String[] localVarAuthNames = new String[] { "admin" }; - return apiClient.buildCall(localVarPath, "GET", localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, progressRequestListener); - } - - @SuppressWarnings("rawtypes") - private com.squareup.okhttp.Call getLogMessagesValidateBeforeCall(Long from, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - - - com.squareup.okhttp.Call call = getLogMessagesCall(from, progressListener, progressRequestListener); - return call; - - - - - - } - - /** - * Returns a list of log messages starting from a particular id. - * - * @param from The id of the first message to retrieve. (optional, default to 0) - * @return List<LogMessage> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public List getLogMessages(Long from) throws ApiException { - ApiResponse> resp = getLogMessagesWithHttpInfo(from); - return resp.getData(); - } - - /** - * Returns a list of log messages starting from a particular id. - * - * @param from The id of the first message to retrieve. (optional, default to 0) - * @return ApiResponse<List<LogMessage>> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public ApiResponse> getLogMessagesWithHttpInfo(Long from) throws ApiException { - com.squareup.okhttp.Call call = getLogMessagesValidateBeforeCall(from, null, null); - Type localVarReturnType = new TypeToken>(){}.getType(); - return apiClient.execute(call, localVarReturnType); - } - - /** - * Returns a list of log messages starting from a particular id. (asynchronously) - * - * @param from The id of the first message to retrieve. (optional, default to 0) - * @param callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - */ - public com.squareup.okhttp.Call getLogMessagesAsync(Long from, final ApiCallback> callback) throws ApiException { - - ProgressResponseBody.ProgressListener progressListener = null; - ProgressRequestBody.ProgressRequestListener progressRequestListener = null; - - if (callback != null) { - progressListener = new ProgressResponseBody.ProgressListener() { - @Override - public void update(long bytesRead, long contentLength, boolean done) { - callback.onDownloadProgress(bytesRead, contentLength, done); - } - }; - - progressRequestListener = new ProgressRequestBody.ProgressRequestListener() { - @Override - public void onRequestProgress(long bytesWritten, long contentLength, boolean done) { - callback.onUploadProgress(bytesWritten, contentLength, done); - } - }; - } - - com.squareup.okhttp.Call call = getLogMessagesValidateBeforeCall(from, progressListener, progressRequestListener); - Type localVarReturnType = new TypeToken>(){}.getType(); - apiClient.executeAsync(call, localVarReturnType, callback); - return call; - } - /** - * Build call for getNotice - * @param id The id of the notice. (required) - * @param progressListener Progress listener - * @param progressRequestListener Progress request listener - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - */ - public com.squareup.okhttp.Call getNoticeCall(Long id, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - Object localVarPostBody = null; - - // create path and map variables - String localVarPath = "/notices/{id}" - .replaceAll("\\{" + "id" + "\\}", apiClient.escapeString(id.toString())); - - List localVarQueryParams = new ArrayList(); - - Map localVarHeaderParams = new HashMap(); - - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json", "application/xml" - }; - final String localVarAccept = apiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) localVarHeaderParams.put("Accept", localVarAccept); - - final String[] localVarContentTypes = { - "application/json", "application/xml" - }; - final String localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); - - if(progressListener != null) { - apiClient.getHttpClient().networkInterceptors().add(new com.squareup.okhttp.Interceptor() { - @Override - public com.squareup.okhttp.Response intercept(com.squareup.okhttp.Interceptor.Chain chain) throws IOException { - com.squareup.okhttp.Response originalResponse = chain.proceed(chain.request()); - return originalResponse.newBuilder() - .body(new ProgressResponseBody(originalResponse.body(), progressListener)) - .build(); - } - }); - } - - String[] localVarAuthNames = new String[] { "admin" }; - return apiClient.buildCall(localVarPath, "GET", localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, progressRequestListener); - } - - @SuppressWarnings("rawtypes") - private com.squareup.okhttp.Call getNoticeValidateBeforeCall(Long id, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - - // verify the required parameter 'id' is set - if (id == null) { - throw new ApiException("Missing the required parameter 'id' when calling getNotice(Async)"); - } - - - com.squareup.okhttp.Call call = getNoticeCall(id, progressListener, progressRequestListener); - return call; - - - - - - } - - /** - * Returns the notice with the specified id. - * - * @param id The id of the notice. (required) - * @return Notice - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public Notice getNotice(Long id) throws ApiException { - ApiResponse resp = getNoticeWithHttpInfo(id); - return resp.getData(); - } - - /** - * Returns the notice with the specified id. - * - * @param id The id of the notice. (required) - * @return ApiResponse<Notice> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public ApiResponse getNoticeWithHttpInfo(Long id) throws ApiException { - com.squareup.okhttp.Call call = getNoticeValidateBeforeCall(id, null, null); - Type localVarReturnType = new TypeToken(){}.getType(); - return apiClient.execute(call, localVarReturnType); - } - - /** - * Returns the notice with the specified id. (asynchronously) - * - * @param id The id of the notice. (required) - * @param callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - */ - public com.squareup.okhttp.Call getNoticeAsync(Long id, final ApiCallback callback) throws ApiException { - - ProgressResponseBody.ProgressListener progressListener = null; - ProgressRequestBody.ProgressRequestListener progressRequestListener = null; - - if (callback != null) { - progressListener = new ProgressResponseBody.ProgressListener() { - @Override - public void update(long bytesRead, long contentLength, boolean done) { - callback.onDownloadProgress(bytesRead, contentLength, done); - } - }; - - progressRequestListener = new ProgressRequestBody.ProgressRequestListener() { - @Override - public void onRequestProgress(long bytesWritten, long contentLength, boolean done) { - callback.onUploadProgress(bytesWritten, contentLength, done); - } - }; - } - - com.squareup.okhttp.Call call = getNoticeValidateBeforeCall(id, progressListener, progressRequestListener); - Type localVarReturnType = new TypeToken(){}.getType(); - apiClient.executeAsync(call, localVarReturnType, callback); - return call; - } - /** - * Build call for getNotices - * @param pageOffset The offset in terms of elements. (optional, default to 0) - * @param pageSize The maximum number of elements on the page. (optional, default to 20) - * @param progressListener Progress listener - * @param progressRequestListener Progress request listener - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - */ - public com.squareup.okhttp.Call getNoticesCall(Integer pageOffset, Integer pageSize, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - Object localVarPostBody = null; - - // create path and map variables - String localVarPath = "/notices"; - - List localVarQueryParams = new ArrayList(); - if (pageOffset != null) - localVarQueryParams.addAll(apiClient.parameterToPairs("", "pageOffset", pageOffset)); - if (pageSize != null) - localVarQueryParams.addAll(apiClient.parameterToPairs("", "pageSize", pageSize)); - - Map localVarHeaderParams = new HashMap(); - - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json", "application/xml" - }; - final String localVarAccept = apiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) localVarHeaderParams.put("Accept", localVarAccept); - - final String[] localVarContentTypes = { - "application/json", "application/xml" - }; - final String localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); - - if(progressListener != null) { - apiClient.getHttpClient().networkInterceptors().add(new com.squareup.okhttp.Interceptor() { - @Override - public com.squareup.okhttp.Response intercept(com.squareup.okhttp.Interceptor.Chain chain) throws IOException { - com.squareup.okhttp.Response originalResponse = chain.proceed(chain.request()); - return originalResponse.newBuilder() - .body(new ProgressResponseBody(originalResponse.body(), progressListener)) - .build(); - } - }); - } - - String[] localVarAuthNames = new String[] { "admin" }; - return apiClient.buildCall(localVarPath, "GET", localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, progressRequestListener); - } - - @SuppressWarnings("rawtypes") - private com.squareup.okhttp.Call getNoticesValidateBeforeCall(Integer pageOffset, Integer pageSize, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - - - com.squareup.okhttp.Call call = getNoticesCall(pageOffset, pageSize, progressListener, progressRequestListener); - return call; - - - - - - } - - /** - * Returns a page of notices. - * - * @param pageOffset The offset in terms of elements. (optional, default to 0) - * @param pageSize The maximum number of elements on the page. (optional, default to 20) - * @return NoticePage - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public NoticePage getNotices(Integer pageOffset, Integer pageSize) throws ApiException { - ApiResponse resp = getNoticesWithHttpInfo(pageOffset, pageSize); - return resp.getData(); - } - - /** - * Returns a page of notices. - * - * @param pageOffset The offset in terms of elements. (optional, default to 0) - * @param pageSize The maximum number of elements on the page. (optional, default to 20) - * @return ApiResponse<NoticePage> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public ApiResponse getNoticesWithHttpInfo(Integer pageOffset, Integer pageSize) throws ApiException { - com.squareup.okhttp.Call call = getNoticesValidateBeforeCall(pageOffset, pageSize, null, null); - Type localVarReturnType = new TypeToken(){}.getType(); - return apiClient.execute(call, localVarReturnType); - } - - /** - * Returns a page of notices. (asynchronously) - * - * @param pageOffset The offset in terms of elements. (optional, default to 0) - * @param pageSize The maximum number of elements on the page. (optional, default to 20) - * @param callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - */ - public com.squareup.okhttp.Call getNoticesAsync(Integer pageOffset, Integer pageSize, final ApiCallback callback) throws ApiException { - - ProgressResponseBody.ProgressListener progressListener = null; - ProgressRequestBody.ProgressRequestListener progressRequestListener = null; - - if (callback != null) { - progressListener = new ProgressResponseBody.ProgressListener() { - @Override - public void update(long bytesRead, long contentLength, boolean done) { - callback.onDownloadProgress(bytesRead, contentLength, done); - } - }; - - progressRequestListener = new ProgressRequestBody.ProgressRequestListener() { - @Override - public void onRequestProgress(long bytesWritten, long contentLength, boolean done) { - callback.onUploadProgress(bytesWritten, contentLength, done); - } - }; - } - - com.squareup.okhttp.Call call = getNoticesValidateBeforeCall(pageOffset, pageSize, progressListener, progressRequestListener); - Type localVarReturnType = new TypeToken(){}.getType(); - apiClient.executeAsync(call, localVarReturnType, callback); - return call; - } - /** - * Build call for getSystemStatistic - * @param progressListener Progress listener - * @param progressRequestListener Progress request listener - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - */ - public com.squareup.okhttp.Call getSystemStatisticCall(final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - Object localVarPostBody = null; - - // create path and map variables - String localVarPath = "/log/system"; - - List localVarQueryParams = new ArrayList(); - - Map localVarHeaderParams = new HashMap(); - - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json", "application/xml" - }; - final String localVarAccept = apiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) localVarHeaderParams.put("Accept", localVarAccept); - - final String[] localVarContentTypes = { - - }; - final String localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); - - if(progressListener != null) { - apiClient.getHttpClient().networkInterceptors().add(new com.squareup.okhttp.Interceptor() { - @Override - public com.squareup.okhttp.Response intercept(com.squareup.okhttp.Interceptor.Chain chain) throws IOException { - com.squareup.okhttp.Response originalResponse = chain.proceed(chain.request()); - return originalResponse.newBuilder() - .body(new ProgressResponseBody(originalResponse.body(), progressListener)) - .build(); - } - }); - } - - String[] localVarAuthNames = new String[] { "admin" }; - return apiClient.buildCall(localVarPath, "GET", localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, progressRequestListener); - } - - @SuppressWarnings("rawtypes") - private com.squareup.okhttp.Call getSystemStatisticValidateBeforeCall(final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - - - com.squareup.okhttp.Call call = getSystemStatisticCall(progressListener, progressRequestListener); - return call; - - - - - - } - - /** - * Returns the system statistic. - * - * @return LoadStatistic - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public LoadStatistic getSystemStatistic() throws ApiException { - ApiResponse resp = getSystemStatisticWithHttpInfo(); - return resp.getData(); - } - - /** - * Returns the system statistic. - * - * @return ApiResponse<LoadStatistic> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public ApiResponse getSystemStatisticWithHttpInfo() throws ApiException { - com.squareup.okhttp.Call call = getSystemStatisticValidateBeforeCall(null, null); - Type localVarReturnType = new TypeToken(){}.getType(); - return apiClient.execute(call, localVarReturnType); - } - - /** - * Returns the system statistic. (asynchronously) - * - * @param callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - */ - public com.squareup.okhttp.Call getSystemStatisticAsync(final ApiCallback callback) throws ApiException { - - ProgressResponseBody.ProgressListener progressListener = null; - ProgressRequestBody.ProgressRequestListener progressRequestListener = null; - - if (callback != null) { - progressListener = new ProgressResponseBody.ProgressListener() { - @Override - public void update(long bytesRead, long contentLength, boolean done) { - callback.onDownloadProgress(bytesRead, contentLength, done); - } - }; - - progressRequestListener = new ProgressRequestBody.ProgressRequestListener() { - @Override - public void onRequestProgress(long bytesWritten, long contentLength, boolean done) { - callback.onUploadProgress(bytesWritten, contentLength, done); - } - }; - } - - com.squareup.okhttp.Call call = getSystemStatisticValidateBeforeCall(progressListener, progressRequestListener); - Type localVarReturnType = new TypeToken(){}.getType(); - apiClient.executeAsync(call, localVarReturnType, callback); - return call; - } - /** - * Build call for getUpdatedNotices - * @param since The earlies time in epoch milliseconds. (optional, default to 0) - * @param progressListener Progress listener - * @param progressRequestListener Progress request listener - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - */ - public com.squareup.okhttp.Call getUpdatedNoticesCall(Long since, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - Object localVarPostBody = null; - - // create path and map variables - String localVarPath = "/notices/updated"; - - List localVarQueryParams = new ArrayList(); - if (since != null) - localVarQueryParams.addAll(apiClient.parameterToPairs("", "since", since)); - - Map localVarHeaderParams = new HashMap(); - - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json", "application/xml" - }; - final String localVarAccept = apiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) localVarHeaderParams.put("Accept", localVarAccept); - - final String[] localVarContentTypes = { - "application/json", "application/xml" - }; - final String localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); - - if(progressListener != null) { - apiClient.getHttpClient().networkInterceptors().add(new com.squareup.okhttp.Interceptor() { - @Override - public com.squareup.okhttp.Response intercept(com.squareup.okhttp.Interceptor.Chain chain) throws IOException { - com.squareup.okhttp.Response originalResponse = chain.proceed(chain.request()); - return originalResponse.newBuilder() - .body(new ProgressResponseBody(originalResponse.body(), progressListener)) - .build(); - } - }); - } - - String[] localVarAuthNames = new String[] { }; - return apiClient.buildCall(localVarPath, "GET", localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, progressRequestListener); - } - - @SuppressWarnings("rawtypes") - private com.squareup.okhttp.Call getUpdatedNoticesValidateBeforeCall(Long since, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - - - com.squareup.okhttp.Call call = getUpdatedNoticesCall(since, progressListener, progressRequestListener); - return call; - - - - - - } - - /** - * Returns all active notices modified after the date. - * - * @param since The earlies time in epoch milliseconds. (optional, default to 0) - * @return List<Notice> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public List getUpdatedNotices(Long since) throws ApiException { - ApiResponse> resp = getUpdatedNoticesWithHttpInfo(since); - return resp.getData(); - } - - /** - * Returns all active notices modified after the date. - * - * @param since The earlies time in epoch milliseconds. (optional, default to 0) - * @return ApiResponse<List<Notice>> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public ApiResponse> getUpdatedNoticesWithHttpInfo(Long since) throws ApiException { - com.squareup.okhttp.Call call = getUpdatedNoticesValidateBeforeCall(since, null, null); - Type localVarReturnType = new TypeToken>(){}.getType(); - return apiClient.execute(call, localVarReturnType); - } - - /** - * Returns all active notices modified after the date. (asynchronously) - * - * @param since The earlies time in epoch milliseconds. (optional, default to 0) - * @param callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - */ - public com.squareup.okhttp.Call getUpdatedNoticesAsync(Long since, final ApiCallback> callback) throws ApiException { - - ProgressResponseBody.ProgressListener progressListener = null; - ProgressRequestBody.ProgressRequestListener progressRequestListener = null; - - if (callback != null) { - progressListener = new ProgressResponseBody.ProgressListener() { - @Override - public void update(long bytesRead, long contentLength, boolean done) { - callback.onDownloadProgress(bytesRead, contentLength, done); - } - }; - - progressRequestListener = new ProgressRequestBody.ProgressRequestListener() { - @Override - public void onRequestProgress(long bytesWritten, long contentLength, boolean done) { - callback.onUploadProgress(bytesWritten, contentLength, done); - } - }; - } - - com.squareup.okhttp.Call call = getUpdatedNoticesValidateBeforeCall(since, progressListener, progressRequestListener); - Type localVarReturnType = new TypeToken>(){}.getType(); - apiClient.executeAsync(call, localVarReturnType, callback); - return call; - } - /** - * Build call for setNotice - * @param id The id of the notice. (required) - * @param body The data of the notice to set. (required) - * @param progressListener Progress listener - * @param progressRequestListener Progress request listener - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - */ - public com.squareup.okhttp.Call setNoticeCall(Long id, Notice body, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - Object localVarPostBody = body; - - // create path and map variables - String localVarPath = "/notices/{id}" - .replaceAll("\\{" + "id" + "\\}", apiClient.escapeString(id.toString())); - - List localVarQueryParams = new ArrayList(); - - Map localVarHeaderParams = new HashMap(); - - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json", "application/xml" - }; - final String localVarAccept = apiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) localVarHeaderParams.put("Accept", localVarAccept); - - final String[] localVarContentTypes = { - "application/json", "application/xml" - }; - final String localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); - - if(progressListener != null) { - apiClient.getHttpClient().networkInterceptors().add(new com.squareup.okhttp.Interceptor() { - @Override - public com.squareup.okhttp.Response intercept(com.squareup.okhttp.Interceptor.Chain chain) throws IOException { - com.squareup.okhttp.Response originalResponse = chain.proceed(chain.request()); - return originalResponse.newBuilder() - .body(new ProgressResponseBody(originalResponse.body(), progressListener)) - .build(); - } - }); - } - - String[] localVarAuthNames = new String[] { "admin" }; - return apiClient.buildCall(localVarPath, "PUT", localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, progressRequestListener); - } - - @SuppressWarnings("rawtypes") - private com.squareup.okhttp.Call setNoticeValidateBeforeCall(Long id, Notice body, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - - // verify the required parameter 'id' is set - if (id == null) { - throw new ApiException("Missing the required parameter 'id' when calling setNotice(Async)"); - } - - // verify the required parameter 'body' is set - if (body == null) { - throw new ApiException("Missing the required parameter 'body' when calling setNotice(Async)"); - } - - - com.squareup.okhttp.Call call = setNoticeCall(id, body, progressListener, progressRequestListener); - return call; - - - - - - } - - /** - * Updates an existing notice. - * - * @param id The id of the notice. (required) - * @param body The data of the notice to set. (required) - * @return Notice - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public Notice setNotice(Long id, Notice body) throws ApiException { - ApiResponse resp = setNoticeWithHttpInfo(id, body); - return resp.getData(); - } - - /** - * Updates an existing notice. - * - * @param id The id of the notice. (required) - * @param body The data of the notice to set. (required) - * @return ApiResponse<Notice> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public ApiResponse setNoticeWithHttpInfo(Long id, Notice body) throws ApiException { - com.squareup.okhttp.Call call = setNoticeValidateBeforeCall(id, body, null, null); - Type localVarReturnType = new TypeToken(){}.getType(); - return apiClient.execute(call, localVarReturnType); - } - - /** - * Updates an existing notice. (asynchronously) - * - * @param id The id of the notice. (required) - * @param body The data of the notice to set. (required) - * @param callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - */ - public com.squareup.okhttp.Call setNoticeAsync(Long id, Notice body, final ApiCallback callback) throws ApiException { - - ProgressResponseBody.ProgressListener progressListener = null; - ProgressRequestBody.ProgressRequestListener progressRequestListener = null; - - if (callback != null) { - progressListener = new ProgressResponseBody.ProgressListener() { - @Override - public void update(long bytesRead, long contentLength, boolean done) { - callback.onDownloadProgress(bytesRead, contentLength, done); - } - }; - - progressRequestListener = new ProgressRequestBody.ProgressRequestListener() { - @Override - public void onRequestProgress(long bytesWritten, long contentLength, boolean done) { - callback.onUploadProgress(bytesWritten, contentLength, done); - } - }; - } - - com.squareup.okhttp.Call call = setNoticeValidateBeforeCall(id, body, progressListener, progressRequestListener); - Type localVarReturnType = new TypeToken(){}.getType(); - apiClient.executeAsync(call, localVarReturnType, callback); - return call; - } -} diff --git a/testing/api-client/src/main/java/io/swagger/client/api/ShareApi.java b/testing/api-client/src/main/java/io/swagger/client/api/ShareApi.java deleted file mode 100644 index b540dab..0000000 --- a/testing/api-client/src/main/java/io/swagger/client/api/ShareApi.java +++ /dev/null @@ -1,814 +0,0 @@ -/* - * Maptology Service - * Maptology Service - * - * OpenAPI spec version: 0.0.1-SNAPSHOT - * Contact: nes-admin@uni-due.de - * - * NOTE: This class is auto generated by the swagger code generator program. - * https://github.com/swagger-api/swagger-codegen.git - * Do not edit the class manually. - */ - - -package io.swagger.client.api; - -import io.swagger.client.ApiCallback; -import io.swagger.client.ApiClient; -import io.swagger.client.ApiException; -import io.swagger.client.ApiResponse; -import io.swagger.client.Configuration; -import io.swagger.client.Pair; -import io.swagger.client.ProgressRequestBody; -import io.swagger.client.ProgressResponseBody; - -import com.google.gson.reflect.TypeToken; - -import java.io.IOException; - - -import io.swagger.client.model.Location; -import io.swagger.client.model.Share; -import io.swagger.client.model.ShareInfo; - -import java.lang.reflect.Type; -import java.util.ArrayList; -import java.util.HashMap; -import java.util.List; -import java.util.Map; - -public class ShareApi { - private ApiClient apiClient; - - public ShareApi() { - this(Configuration.getDefaultApiClient()); - } - - public ShareApi(ApiClient apiClient) { - this.apiClient = apiClient; - } - - public ApiClient getApiClient() { - return apiClient; - } - - public void setApiClient(ApiClient apiClient) { - this.apiClient = apiClient; - } - - /** - * Build call for createShare - * @param body Necessary data from to create a share. (required) - * @param progressListener Progress listener - * @param progressRequestListener Progress request listener - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - */ - public com.squareup.okhttp.Call createShareCall(ShareInfo body, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - Object localVarPostBody = body; - - // create path and map variables - String localVarPath = "/shares"; - - List localVarQueryParams = new ArrayList(); - - Map localVarHeaderParams = new HashMap(); - - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json", "application/xml" - }; - final String localVarAccept = apiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) localVarHeaderParams.put("Accept", localVarAccept); - - final String[] localVarContentTypes = { - "application/json", "application/xml" - }; - final String localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); - - if(progressListener != null) { - apiClient.getHttpClient().networkInterceptors().add(new com.squareup.okhttp.Interceptor() { - @Override - public com.squareup.okhttp.Response intercept(com.squareup.okhttp.Interceptor.Chain chain) throws IOException { - com.squareup.okhttp.Response originalResponse = chain.proceed(chain.request()); - return originalResponse.newBuilder() - .body(new ProgressResponseBody(originalResponse.body(), progressListener)) - .build(); - } - }); - } - - String[] localVarAuthNames = new String[] { "device" }; - return apiClient.buildCall(localVarPath, "POST", localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, progressRequestListener); - } - - @SuppressWarnings("rawtypes") - private com.squareup.okhttp.Call createShareValidateBeforeCall(ShareInfo body, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - - // verify the required parameter 'body' is set - if (body == null) { - throw new ApiException("Missing the required parameter 'body' when calling createShare(Async)"); - } - - - com.squareup.okhttp.Call call = createShareCall(body, progressListener, progressRequestListener); - return call; - - - - - - } - - /** - * Creates a new share. - * - * @param body Necessary data from to create a share. (required) - * @return Share - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public Share createShare(ShareInfo body) throws ApiException { - ApiResponse resp = createShareWithHttpInfo(body); - return resp.getData(); - } - - /** - * Creates a new share. - * - * @param body Necessary data from to create a share. (required) - * @return ApiResponse<Share> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public ApiResponse createShareWithHttpInfo(ShareInfo body) throws ApiException { - com.squareup.okhttp.Call call = createShareValidateBeforeCall(body, null, null); - Type localVarReturnType = new TypeToken(){}.getType(); - return apiClient.execute(call, localVarReturnType); - } - - /** - * Creates a new share. (asynchronously) - * - * @param body Necessary data from to create a share. (required) - * @param callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - */ - public com.squareup.okhttp.Call createShareAsync(ShareInfo body, final ApiCallback callback) throws ApiException { - - ProgressResponseBody.ProgressListener progressListener = null; - ProgressRequestBody.ProgressRequestListener progressRequestListener = null; - - if (callback != null) { - progressListener = new ProgressResponseBody.ProgressListener() { - @Override - public void update(long bytesRead, long contentLength, boolean done) { - callback.onDownloadProgress(bytesRead, contentLength, done); - } - }; - - progressRequestListener = new ProgressRequestBody.ProgressRequestListener() { - @Override - public void onRequestProgress(long bytesWritten, long contentLength, boolean done) { - callback.onUploadProgress(bytesWritten, contentLength, done); - } - }; - } - - com.squareup.okhttp.Call call = createShareValidateBeforeCall(body, progressListener, progressRequestListener); - Type localVarReturnType = new TypeToken(){}.getType(); - apiClient.executeAsync(call, localVarReturnType, callback); - return call; - } - /** - * Build call for deleteShare - * @param id The share id. (required) - * @param progressListener Progress listener - * @param progressRequestListener Progress request listener - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - */ - public com.squareup.okhttp.Call deleteShareCall(Long id, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - Object localVarPostBody = null; - - // create path and map variables - String localVarPath = "/shares/{id}" - .replaceAll("\\{" + "id" + "\\}", apiClient.escapeString(id.toString())); - - List localVarQueryParams = new ArrayList(); - - Map localVarHeaderParams = new HashMap(); - - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json", "application/xml" - }; - final String localVarAccept = apiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) localVarHeaderParams.put("Accept", localVarAccept); - - final String[] localVarContentTypes = { - "application/json", "application/xml" - }; - final String localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); - - if(progressListener != null) { - apiClient.getHttpClient().networkInterceptors().add(new com.squareup.okhttp.Interceptor() { - @Override - public com.squareup.okhttp.Response intercept(com.squareup.okhttp.Interceptor.Chain chain) throws IOException { - com.squareup.okhttp.Response originalResponse = chain.proceed(chain.request()); - return originalResponse.newBuilder() - .body(new ProgressResponseBody(originalResponse.body(), progressListener)) - .build(); - } - }); - } - - String[] localVarAuthNames = new String[] { "device" }; - return apiClient.buildCall(localVarPath, "DELETE", localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, progressRequestListener); - } - - @SuppressWarnings("rawtypes") - private com.squareup.okhttp.Call deleteShareValidateBeforeCall(Long id, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - - // verify the required parameter 'id' is set - if (id == null) { - throw new ApiException("Missing the required parameter 'id' when calling deleteShare(Async)"); - } - - - com.squareup.okhttp.Call call = deleteShareCall(id, progressListener, progressRequestListener); - return call; - - - - - - } - - /** - * Delete a share. - * - * @param id The share id. (required) - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public void deleteShare(Long id) throws ApiException { - deleteShareWithHttpInfo(id); - } - - /** - * Delete a share. - * - * @param id The share id. (required) - * @return ApiResponse<Void> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public ApiResponse deleteShareWithHttpInfo(Long id) throws ApiException { - com.squareup.okhttp.Call call = deleteShareValidateBeforeCall(id, null, null); - return apiClient.execute(call); - } - - /** - * Delete a share. (asynchronously) - * - * @param id The share id. (required) - * @param callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - */ - public com.squareup.okhttp.Call deleteShareAsync(Long id, final ApiCallback callback) throws ApiException { - - ProgressResponseBody.ProgressListener progressListener = null; - ProgressRequestBody.ProgressRequestListener progressRequestListener = null; - - if (callback != null) { - progressListener = new ProgressResponseBody.ProgressListener() { - @Override - public void update(long bytesRead, long contentLength, boolean done) { - callback.onDownloadProgress(bytesRead, contentLength, done); - } - }; - - progressRequestListener = new ProgressRequestBody.ProgressRequestListener() { - @Override - public void onRequestProgress(long bytesWritten, long contentLength, boolean done) { - callback.onUploadProgress(bytesWritten, contentLength, done); - } - }; - } - - com.squareup.okhttp.Call call = deleteShareValidateBeforeCall(id, progressListener, progressRequestListener); - apiClient.executeAsync(call, callback); - return call; - } - /** - * Build call for getShare - * @param id The share id. (required) - * @param progressListener Progress listener - * @param progressRequestListener Progress request listener - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - */ - public com.squareup.okhttp.Call getShareCall(Long id, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - Object localVarPostBody = null; - - // create path and map variables - String localVarPath = "/shares/{id}" - .replaceAll("\\{" + "id" + "\\}", apiClient.escapeString(id.toString())); - - List localVarQueryParams = new ArrayList(); - - Map localVarHeaderParams = new HashMap(); - - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json", "application/xml" - }; - final String localVarAccept = apiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) localVarHeaderParams.put("Accept", localVarAccept); - - final String[] localVarContentTypes = { - "application/json", "application/xml" - }; - final String localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); - - if(progressListener != null) { - apiClient.getHttpClient().networkInterceptors().add(new com.squareup.okhttp.Interceptor() { - @Override - public com.squareup.okhttp.Response intercept(com.squareup.okhttp.Interceptor.Chain chain) throws IOException { - com.squareup.okhttp.Response originalResponse = chain.proceed(chain.request()); - return originalResponse.newBuilder() - .body(new ProgressResponseBody(originalResponse.body(), progressListener)) - .build(); - } - }); - } - - String[] localVarAuthNames = new String[] { "device" }; - return apiClient.buildCall(localVarPath, "GET", localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, progressRequestListener); - } - - @SuppressWarnings("rawtypes") - private com.squareup.okhttp.Call getShareValidateBeforeCall(Long id, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - - // verify the required parameter 'id' is set - if (id == null) { - throw new ApiException("Missing the required parameter 'id' when calling getShare(Async)"); - } - - - com.squareup.okhttp.Call call = getShareCall(id, progressListener, progressRequestListener); - return call; - - - - - - } - - /** - * Returns a share. - * - * @param id The share id. (required) - * @return Share - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public Share getShare(Long id) throws ApiException { - ApiResponse resp = getShareWithHttpInfo(id); - return resp.getData(); - } - - /** - * Returns a share. - * - * @param id The share id. (required) - * @return ApiResponse<Share> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public ApiResponse getShareWithHttpInfo(Long id) throws ApiException { - com.squareup.okhttp.Call call = getShareValidateBeforeCall(id, null, null); - Type localVarReturnType = new TypeToken(){}.getType(); - return apiClient.execute(call, localVarReturnType); - } - - /** - * Returns a share. (asynchronously) - * - * @param id The share id. (required) - * @param callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - */ - public com.squareup.okhttp.Call getShareAsync(Long id, final ApiCallback callback) throws ApiException { - - ProgressResponseBody.ProgressListener progressListener = null; - ProgressRequestBody.ProgressRequestListener progressRequestListener = null; - - if (callback != null) { - progressListener = new ProgressResponseBody.ProgressListener() { - @Override - public void update(long bytesRead, long contentLength, boolean done) { - callback.onDownloadProgress(bytesRead, contentLength, done); - } - }; - - progressRequestListener = new ProgressRequestBody.ProgressRequestListener() { - @Override - public void onRequestProgress(long bytesWritten, long contentLength, boolean done) { - callback.onUploadProgress(bytesWritten, contentLength, done); - } - }; - } - - com.squareup.okhttp.Call call = getShareValidateBeforeCall(id, progressListener, progressRequestListener); - Type localVarReturnType = new TypeToken(){}.getType(); - apiClient.executeAsync(call, localVarReturnType, callback); - return call; - } - /** - * Build call for getShareInfo - * @param token The secret token. (required) - * @param progressListener Progress listener - * @param progressRequestListener Progress request listener - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - */ - public com.squareup.okhttp.Call getShareInfoCall(String token, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - Object localVarPostBody = null; - - // create path and map variables - String localVarPath = "/shares/{token}/info" - .replaceAll("\\{" + "token" + "\\}", apiClient.escapeString(token.toString())); - - List localVarQueryParams = new ArrayList(); - - Map localVarHeaderParams = new HashMap(); - - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json", "application/xml" - }; - final String localVarAccept = apiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) localVarHeaderParams.put("Accept", localVarAccept); - - final String[] localVarContentTypes = { - "application/json", "application/xml" - }; - final String localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); - - if(progressListener != null) { - apiClient.getHttpClient().networkInterceptors().add(new com.squareup.okhttp.Interceptor() { - @Override - public com.squareup.okhttp.Response intercept(com.squareup.okhttp.Interceptor.Chain chain) throws IOException { - com.squareup.okhttp.Response originalResponse = chain.proceed(chain.request()); - return originalResponse.newBuilder() - .body(new ProgressResponseBody(originalResponse.body(), progressListener)) - .build(); - } - }); - } - - String[] localVarAuthNames = new String[] { }; - return apiClient.buildCall(localVarPath, "GET", localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, progressRequestListener); - } - - @SuppressWarnings("rawtypes") - private com.squareup.okhttp.Call getShareInfoValidateBeforeCall(String token, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - - // verify the required parameter 'token' is set - if (token == null) { - throw new ApiException("Missing the required parameter 'token' when calling getShareInfo(Async)"); - } - - - com.squareup.okhttp.Call call = getShareInfoCall(token, progressListener, progressRequestListener); - return call; - - - - - - } - - /** - * Get a share info by its secret token. - * - * @param token The secret token. (required) - * @return ShareInfo - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public ShareInfo getShareInfo(String token) throws ApiException { - ApiResponse resp = getShareInfoWithHttpInfo(token); - return resp.getData(); - } - - /** - * Get a share info by its secret token. - * - * @param token The secret token. (required) - * @return ApiResponse<ShareInfo> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public ApiResponse getShareInfoWithHttpInfo(String token) throws ApiException { - com.squareup.okhttp.Call call = getShareInfoValidateBeforeCall(token, null, null); - Type localVarReturnType = new TypeToken(){}.getType(); - return apiClient.execute(call, localVarReturnType); - } - - /** - * Get a share info by its secret token. (asynchronously) - * - * @param token The secret token. (required) - * @param callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - */ - public com.squareup.okhttp.Call getShareInfoAsync(String token, final ApiCallback callback) throws ApiException { - - ProgressResponseBody.ProgressListener progressListener = null; - ProgressRequestBody.ProgressRequestListener progressRequestListener = null; - - if (callback != null) { - progressListener = new ProgressResponseBody.ProgressListener() { - @Override - public void update(long bytesRead, long contentLength, boolean done) { - callback.onDownloadProgress(bytesRead, contentLength, done); - } - }; - - progressRequestListener = new ProgressRequestBody.ProgressRequestListener() { - @Override - public void onRequestProgress(long bytesWritten, long contentLength, boolean done) { - callback.onUploadProgress(bytesWritten, contentLength, done); - } - }; - } - - com.squareup.okhttp.Call call = getShareInfoValidateBeforeCall(token, progressListener, progressRequestListener); - Type localVarReturnType = new TypeToken(){}.getType(); - apiClient.executeAsync(call, localVarReturnType, callback); - return call; - } - /** - * Build call for getShareLocation - * @param token The secret token. (required) - * @param progressListener Progress listener - * @param progressRequestListener Progress request listener - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - */ - public com.squareup.okhttp.Call getShareLocationCall(String token, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - Object localVarPostBody = null; - - // create path and map variables - String localVarPath = "/shares/{token}/location" - .replaceAll("\\{" + "token" + "\\}", apiClient.escapeString(token.toString())); - - List localVarQueryParams = new ArrayList(); - - Map localVarHeaderParams = new HashMap(); - - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json", "application/xml" - }; - final String localVarAccept = apiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) localVarHeaderParams.put("Accept", localVarAccept); - - final String[] localVarContentTypes = { - "application/json", "application/xml" - }; - final String localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); - - if(progressListener != null) { - apiClient.getHttpClient().networkInterceptors().add(new com.squareup.okhttp.Interceptor() { - @Override - public com.squareup.okhttp.Response intercept(com.squareup.okhttp.Interceptor.Chain chain) throws IOException { - com.squareup.okhttp.Response originalResponse = chain.proceed(chain.request()); - return originalResponse.newBuilder() - .body(new ProgressResponseBody(originalResponse.body(), progressListener)) - .build(); - } - }); - } - - String[] localVarAuthNames = new String[] { }; - return apiClient.buildCall(localVarPath, "GET", localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, progressRequestListener); - } - - @SuppressWarnings("rawtypes") - private com.squareup.okhttp.Call getShareLocationValidateBeforeCall(String token, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - - // verify the required parameter 'token' is set - if (token == null) { - throw new ApiException("Missing the required parameter 'token' when calling getShareLocation(Async)"); - } - - - com.squareup.okhttp.Call call = getShareLocationCall(token, progressListener, progressRequestListener); - return call; - - - - - - } - - /** - * Get a shared location by its secret token. - * - * @param token The secret token. (required) - * @return Location - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public Location getShareLocation(String token) throws ApiException { - ApiResponse resp = getShareLocationWithHttpInfo(token); - return resp.getData(); - } - - /** - * Get a shared location by its secret token. - * - * @param token The secret token. (required) - * @return ApiResponse<Location> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public ApiResponse getShareLocationWithHttpInfo(String token) throws ApiException { - com.squareup.okhttp.Call call = getShareLocationValidateBeforeCall(token, null, null); - Type localVarReturnType = new TypeToken(){}.getType(); - return apiClient.execute(call, localVarReturnType); - } - - /** - * Get a shared location by its secret token. (asynchronously) - * - * @param token The secret token. (required) - * @param callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - */ - public com.squareup.okhttp.Call getShareLocationAsync(String token, final ApiCallback callback) throws ApiException { - - ProgressResponseBody.ProgressListener progressListener = null; - ProgressRequestBody.ProgressRequestListener progressRequestListener = null; - - if (callback != null) { - progressListener = new ProgressResponseBody.ProgressListener() { - @Override - public void update(long bytesRead, long contentLength, boolean done) { - callback.onDownloadProgress(bytesRead, contentLength, done); - } - }; - - progressRequestListener = new ProgressRequestBody.ProgressRequestListener() { - @Override - public void onRequestProgress(long bytesWritten, long contentLength, boolean done) { - callback.onUploadProgress(bytesWritten, contentLength, done); - } - }; - } - - com.squareup.okhttp.Call call = getShareLocationValidateBeforeCall(token, progressListener, progressRequestListener); - Type localVarReturnType = new TypeToken(){}.getType(); - apiClient.executeAsync(call, localVarReturnType, callback); - return call; - } - /** - * Build call for setShare - * @param id The share id. (required) - * @param body The new share to set. (optional) - * @param progressListener Progress listener - * @param progressRequestListener Progress request listener - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - */ - public com.squareup.okhttp.Call setShareCall(Long id, Share body, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - Object localVarPostBody = body; - - // create path and map variables - String localVarPath = "/shares/{id}" - .replaceAll("\\{" + "id" + "\\}", apiClient.escapeString(id.toString())); - - List localVarQueryParams = new ArrayList(); - - Map localVarHeaderParams = new HashMap(); - - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json", "application/xml" - }; - final String localVarAccept = apiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) localVarHeaderParams.put("Accept", localVarAccept); - - final String[] localVarContentTypes = { - "application/json", "application/xml" - }; - final String localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); - - if(progressListener != null) { - apiClient.getHttpClient().networkInterceptors().add(new com.squareup.okhttp.Interceptor() { - @Override - public com.squareup.okhttp.Response intercept(com.squareup.okhttp.Interceptor.Chain chain) throws IOException { - com.squareup.okhttp.Response originalResponse = chain.proceed(chain.request()); - return originalResponse.newBuilder() - .body(new ProgressResponseBody(originalResponse.body(), progressListener)) - .build(); - } - }); - } - - String[] localVarAuthNames = new String[] { "device" }; - return apiClient.buildCall(localVarPath, "PUT", localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, progressRequestListener); - } - - @SuppressWarnings("rawtypes") - private com.squareup.okhttp.Call setShareValidateBeforeCall(Long id, Share body, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - - // verify the required parameter 'id' is set - if (id == null) { - throw new ApiException("Missing the required parameter 'id' when calling setShare(Async)"); - } - - - com.squareup.okhttp.Call call = setShareCall(id, body, progressListener, progressRequestListener); - return call; - - - - - - } - - /** - * Updates an existing share. - * - * @param id The share id. (required) - * @param body The new share to set. (optional) - * @return Share - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public Share setShare(Long id, Share body) throws ApiException { - ApiResponse resp = setShareWithHttpInfo(id, body); - return resp.getData(); - } - - /** - * Updates an existing share. - * - * @param id The share id. (required) - * @param body The new share to set. (optional) - * @return ApiResponse<Share> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public ApiResponse setShareWithHttpInfo(Long id, Share body) throws ApiException { - com.squareup.okhttp.Call call = setShareValidateBeforeCall(id, body, null, null); - Type localVarReturnType = new TypeToken(){}.getType(); - return apiClient.execute(call, localVarReturnType); - } - - /** - * Updates an existing share. (asynchronously) - * - * @param id The share id. (required) - * @param body The new share to set. (optional) - * @param callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - */ - public com.squareup.okhttp.Call setShareAsync(Long id, Share body, final ApiCallback callback) throws ApiException { - - ProgressResponseBody.ProgressListener progressListener = null; - ProgressRequestBody.ProgressRequestListener progressRequestListener = null; - - if (callback != null) { - progressListener = new ProgressResponseBody.ProgressListener() { - @Override - public void update(long bytesRead, long contentLength, boolean done) { - callback.onDownloadProgress(bytesRead, contentLength, done); - } - }; - - progressRequestListener = new ProgressRequestBody.ProgressRequestListener() { - @Override - public void onRequestProgress(long bytesWritten, long contentLength, boolean done) { - callback.onUploadProgress(bytesWritten, contentLength, done); - } - }; - } - - com.squareup.okhttp.Call call = setShareValidateBeforeCall(id, body, progressListener, progressRequestListener); - Type localVarReturnType = new TypeToken(){}.getType(); - apiClient.executeAsync(call, localVarReturnType, callback); - return call; - } -} diff --git a/testing/api-client/src/main/java/io/swagger/client/api/UserApi.java b/testing/api-client/src/main/java/io/swagger/client/api/UserApi.java deleted file mode 100644 index bfad5d8..0000000 --- a/testing/api-client/src/main/java/io/swagger/client/api/UserApi.java +++ /dev/null @@ -1,2518 +0,0 @@ -/* - * Maptology Service - * Maptology Service - * - * OpenAPI spec version: 0.0.1-SNAPSHOT - * Contact: nes-admin@uni-due.de - * - * NOTE: This class is auto generated by the swagger code generator program. - * https://github.com/swagger-api/swagger-codegen.git - * Do not edit the class manually. - */ - - -package io.swagger.client.api; - -import io.swagger.client.ApiCallback; -import io.swagger.client.ApiClient; -import io.swagger.client.ApiException; -import io.swagger.client.ApiResponse; -import io.swagger.client.Configuration; -import io.swagger.client.Pair; -import io.swagger.client.ProgressRequestBody; -import io.swagger.client.ProgressResponseBody; - -import com.google.gson.reflect.TypeToken; - -import java.io.IOException; - - -import io.swagger.client.model.PlacePage; -import io.swagger.client.model.Privilege; -import io.swagger.client.model.PrivilegePage; -import io.swagger.client.model.User; -import io.swagger.client.model.UserPage; -import io.swagger.client.model.UserPassword; -import io.swagger.client.model.UserRegistration; - -import java.lang.reflect.Type; -import java.util.ArrayList; -import java.util.HashMap; -import java.util.List; -import java.util.Map; - -public class UserApi { - private ApiClient apiClient; - - public UserApi() { - this(Configuration.getDefaultApiClient()); - } - - public UserApi(ApiClient apiClient) { - this.apiClient = apiClient; - } - - public ApiClient getApiClient() { - return apiClient; - } - - public void setApiClient(ApiClient apiClient) { - this.apiClient = apiClient; - } - - /** - * Build call for addCurrentUserPrivilege - * @param share The token of the share. (required) - * @param progressListener Progress listener - * @param progressRequestListener Progress request listener - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - */ - public com.squareup.okhttp.Call addCurrentUserPrivilegeCall(String share, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - Object localVarPostBody = null; - - // create path and map variables - String localVarPath = "/users/current/privileges"; - - List localVarQueryParams = new ArrayList(); - if (share != null) - localVarQueryParams.addAll(apiClient.parameterToPairs("", "share", share)); - - Map localVarHeaderParams = new HashMap(); - - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json", "application/xml" - }; - final String localVarAccept = apiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) localVarHeaderParams.put("Accept", localVarAccept); - - final String[] localVarContentTypes = { - "application/json", "application/xml" - }; - final String localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); - - if(progressListener != null) { - apiClient.getHttpClient().networkInterceptors().add(new com.squareup.okhttp.Interceptor() { - @Override - public com.squareup.okhttp.Response intercept(com.squareup.okhttp.Interceptor.Chain chain) throws IOException { - com.squareup.okhttp.Response originalResponse = chain.proceed(chain.request()); - return originalResponse.newBuilder() - .body(new ProgressResponseBody(originalResponse.body(), progressListener)) - .build(); - } - }); - } - - String[] localVarAuthNames = new String[] { "user" }; - return apiClient.buildCall(localVarPath, "POST", localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, progressRequestListener); - } - - @SuppressWarnings("rawtypes") - private com.squareup.okhttp.Call addCurrentUserPrivilegeValidateBeforeCall(String share, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - - // verify the required parameter 'share' is set - if (share == null) { - throw new ApiException("Missing the required parameter 'share' when calling addCurrentUserPrivilege(Async)"); - } - - - com.squareup.okhttp.Call call = addCurrentUserPrivilegeCall(share, progressListener, progressRequestListener); - return call; - - - - - - } - - /** - * Add a privilege for the specified user. - * - * @param share The token of the share. (required) - * @return Privilege - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public Privilege addCurrentUserPrivilege(String share) throws ApiException { - ApiResponse resp = addCurrentUserPrivilegeWithHttpInfo(share); - return resp.getData(); - } - - /** - * Add a privilege for the specified user. - * - * @param share The token of the share. (required) - * @return ApiResponse<Privilege> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public ApiResponse addCurrentUserPrivilegeWithHttpInfo(String share) throws ApiException { - com.squareup.okhttp.Call call = addCurrentUserPrivilegeValidateBeforeCall(share, null, null); - Type localVarReturnType = new TypeToken(){}.getType(); - return apiClient.execute(call, localVarReturnType); - } - - /** - * Add a privilege for the specified user. (asynchronously) - * - * @param share The token of the share. (required) - * @param callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - */ - public com.squareup.okhttp.Call addCurrentUserPrivilegeAsync(String share, final ApiCallback callback) throws ApiException { - - ProgressResponseBody.ProgressListener progressListener = null; - ProgressRequestBody.ProgressRequestListener progressRequestListener = null; - - if (callback != null) { - progressListener = new ProgressResponseBody.ProgressListener() { - @Override - public void update(long bytesRead, long contentLength, boolean done) { - callback.onDownloadProgress(bytesRead, contentLength, done); - } - }; - - progressRequestListener = new ProgressRequestBody.ProgressRequestListener() { - @Override - public void onRequestProgress(long bytesWritten, long contentLength, boolean done) { - callback.onUploadProgress(bytesWritten, contentLength, done); - } - }; - } - - com.squareup.okhttp.Call call = addCurrentUserPrivilegeValidateBeforeCall(share, progressListener, progressRequestListener); - Type localVarReturnType = new TypeToken(){}.getType(); - apiClient.executeAsync(call, localVarReturnType, callback); - return call; - } - /** - * Build call for addUser - * @param body The data for the new user. (required) - * @param progressListener Progress listener - * @param progressRequestListener Progress request listener - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - */ - public com.squareup.okhttp.Call addUserCall(User body, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - Object localVarPostBody = body; - - // create path and map variables - String localVarPath = "/users"; - - List localVarQueryParams = new ArrayList(); - - Map localVarHeaderParams = new HashMap(); - - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json", "application/xml" - }; - final String localVarAccept = apiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) localVarHeaderParams.put("Accept", localVarAccept); - - final String[] localVarContentTypes = { - "application/json", "application/xml" - }; - final String localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); - - if(progressListener != null) { - apiClient.getHttpClient().networkInterceptors().add(new com.squareup.okhttp.Interceptor() { - @Override - public com.squareup.okhttp.Response intercept(com.squareup.okhttp.Interceptor.Chain chain) throws IOException { - com.squareup.okhttp.Response originalResponse = chain.proceed(chain.request()); - return originalResponse.newBuilder() - .body(new ProgressResponseBody(originalResponse.body(), progressListener)) - .build(); - } - }); - } - - String[] localVarAuthNames = new String[] { "admin" }; - return apiClient.buildCall(localVarPath, "POST", localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, progressRequestListener); - } - - @SuppressWarnings("rawtypes") - private com.squareup.okhttp.Call addUserValidateBeforeCall(User body, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - - // verify the required parameter 'body' is set - if (body == null) { - throw new ApiException("Missing the required parameter 'body' when calling addUser(Async)"); - } - - - com.squareup.okhttp.Call call = addUserCall(body, progressListener, progressRequestListener); - return call; - - - - - - } - - /** - * Adds a user account with the specified roles and emails. - * - * @param body The data for the new user. (required) - * @return User - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public User addUser(User body) throws ApiException { - ApiResponse resp = addUserWithHttpInfo(body); - return resp.getData(); - } - - /** - * Adds a user account with the specified roles and emails. - * - * @param body The data for the new user. (required) - * @return ApiResponse<User> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public ApiResponse addUserWithHttpInfo(User body) throws ApiException { - com.squareup.okhttp.Call call = addUserValidateBeforeCall(body, null, null); - Type localVarReturnType = new TypeToken(){}.getType(); - return apiClient.execute(call, localVarReturnType); - } - - /** - * Adds a user account with the specified roles and emails. (asynchronously) - * - * @param body The data for the new user. (required) - * @param callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - */ - public com.squareup.okhttp.Call addUserAsync(User body, final ApiCallback callback) throws ApiException { - - ProgressResponseBody.ProgressListener progressListener = null; - ProgressRequestBody.ProgressRequestListener progressRequestListener = null; - - if (callback != null) { - progressListener = new ProgressResponseBody.ProgressListener() { - @Override - public void update(long bytesRead, long contentLength, boolean done) { - callback.onDownloadProgress(bytesRead, contentLength, done); - } - }; - - progressRequestListener = new ProgressRequestBody.ProgressRequestListener() { - @Override - public void onRequestProgress(long bytesWritten, long contentLength, boolean done) { - callback.onUploadProgress(bytesWritten, contentLength, done); - } - }; - } - - com.squareup.okhttp.Call call = addUserValidateBeforeCall(body, progressListener, progressRequestListener); - Type localVarReturnType = new TypeToken(){}.getType(); - apiClient.executeAsync(call, localVarReturnType, callback); - return call; - } - /** - * Build call for addUserPrivilege - * @param id The user id. (required) - * @param share The token of the share. (required) - * @param progressListener Progress listener - * @param progressRequestListener Progress request listener - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - */ - public com.squareup.okhttp.Call addUserPrivilegeCall(Long id, String share, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - Object localVarPostBody = null; - - // create path and map variables - String localVarPath = "/users/{id}/privileges" - .replaceAll("\\{" + "id" + "\\}", apiClient.escapeString(id.toString())); - - List localVarQueryParams = new ArrayList(); - if (share != null) - localVarQueryParams.addAll(apiClient.parameterToPairs("", "share", share)); - - Map localVarHeaderParams = new HashMap(); - - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json", "application/xml" - }; - final String localVarAccept = apiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) localVarHeaderParams.put("Accept", localVarAccept); - - final String[] localVarContentTypes = { - "application/json", "application/xml" - }; - final String localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); - - if(progressListener != null) { - apiClient.getHttpClient().networkInterceptors().add(new com.squareup.okhttp.Interceptor() { - @Override - public com.squareup.okhttp.Response intercept(com.squareup.okhttp.Interceptor.Chain chain) throws IOException { - com.squareup.okhttp.Response originalResponse = chain.proceed(chain.request()); - return originalResponse.newBuilder() - .body(new ProgressResponseBody(originalResponse.body(), progressListener)) - .build(); - } - }); - } - - String[] localVarAuthNames = new String[] { "admin" }; - return apiClient.buildCall(localVarPath, "POST", localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, progressRequestListener); - } - - @SuppressWarnings("rawtypes") - private com.squareup.okhttp.Call addUserPrivilegeValidateBeforeCall(Long id, String share, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - - // verify the required parameter 'id' is set - if (id == null) { - throw new ApiException("Missing the required parameter 'id' when calling addUserPrivilege(Async)"); - } - - // verify the required parameter 'share' is set - if (share == null) { - throw new ApiException("Missing the required parameter 'share' when calling addUserPrivilege(Async)"); - } - - - com.squareup.okhttp.Call call = addUserPrivilegeCall(id, share, progressListener, progressRequestListener); - return call; - - - - - - } - - /** - * Returns the privileges for a particular user. - * - * @param id The user id. (required) - * @param share The token of the share. (required) - * @return Privilege - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public Privilege addUserPrivilege(Long id, String share) throws ApiException { - ApiResponse resp = addUserPrivilegeWithHttpInfo(id, share); - return resp.getData(); - } - - /** - * Returns the privileges for a particular user. - * - * @param id The user id. (required) - * @param share The token of the share. (required) - * @return ApiResponse<Privilege> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public ApiResponse addUserPrivilegeWithHttpInfo(Long id, String share) throws ApiException { - com.squareup.okhttp.Call call = addUserPrivilegeValidateBeforeCall(id, share, null, null); - Type localVarReturnType = new TypeToken(){}.getType(); - return apiClient.execute(call, localVarReturnType); - } - - /** - * Returns the privileges for a particular user. (asynchronously) - * - * @param id The user id. (required) - * @param share The token of the share. (required) - * @param callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - */ - public com.squareup.okhttp.Call addUserPrivilegeAsync(Long id, String share, final ApiCallback callback) throws ApiException { - - ProgressResponseBody.ProgressListener progressListener = null; - ProgressRequestBody.ProgressRequestListener progressRequestListener = null; - - if (callback != null) { - progressListener = new ProgressResponseBody.ProgressListener() { - @Override - public void update(long bytesRead, long contentLength, boolean done) { - callback.onDownloadProgress(bytesRead, contentLength, done); - } - }; - - progressRequestListener = new ProgressRequestBody.ProgressRequestListener() { - @Override - public void onRequestProgress(long bytesWritten, long contentLength, boolean done) { - callback.onUploadProgress(bytesWritten, contentLength, done); - } - }; - } - - com.squareup.okhttp.Call call = addUserPrivilegeValidateBeforeCall(id, share, progressListener, progressRequestListener); - Type localVarReturnType = new TypeToken(){}.getType(); - apiClient.executeAsync(call, localVarReturnType, callback); - return call; - } - /** - * Build call for getCurrentUser - * @param progressListener Progress listener - * @param progressRequestListener Progress request listener - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - */ - public com.squareup.okhttp.Call getCurrentUserCall(final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - Object localVarPostBody = null; - - // create path and map variables - String localVarPath = "/users/current"; - - List localVarQueryParams = new ArrayList(); - - Map localVarHeaderParams = new HashMap(); - - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json", "application/xml" - }; - final String localVarAccept = apiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) localVarHeaderParams.put("Accept", localVarAccept); - - final String[] localVarContentTypes = { - "application/json", "application/xml" - }; - final String localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); - - if(progressListener != null) { - apiClient.getHttpClient().networkInterceptors().add(new com.squareup.okhttp.Interceptor() { - @Override - public com.squareup.okhttp.Response intercept(com.squareup.okhttp.Interceptor.Chain chain) throws IOException { - com.squareup.okhttp.Response originalResponse = chain.proceed(chain.request()); - return originalResponse.newBuilder() - .body(new ProgressResponseBody(originalResponse.body(), progressListener)) - .build(); - } - }); - } - - String[] localVarAuthNames = new String[] { "user" }; - return apiClient.buildCall(localVarPath, "GET", localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, progressRequestListener); - } - - @SuppressWarnings("rawtypes") - private com.squareup.okhttp.Call getCurrentUserValidateBeforeCall(final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - - - com.squareup.okhttp.Call call = getCurrentUserCall(progressListener, progressRequestListener); - return call; - - - - - - } - - /** - * Returns the user currently authorized. - * - * @return User - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public User getCurrentUser() throws ApiException { - ApiResponse resp = getCurrentUserWithHttpInfo(); - return resp.getData(); - } - - /** - * Returns the user currently authorized. - * - * @return ApiResponse<User> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public ApiResponse getCurrentUserWithHttpInfo() throws ApiException { - com.squareup.okhttp.Call call = getCurrentUserValidateBeforeCall(null, null); - Type localVarReturnType = new TypeToken(){}.getType(); - return apiClient.execute(call, localVarReturnType); - } - - /** - * Returns the user currently authorized. (asynchronously) - * - * @param callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - */ - public com.squareup.okhttp.Call getCurrentUserAsync(final ApiCallback callback) throws ApiException { - - ProgressResponseBody.ProgressListener progressListener = null; - ProgressRequestBody.ProgressRequestListener progressRequestListener = null; - - if (callback != null) { - progressListener = new ProgressResponseBody.ProgressListener() { - @Override - public void update(long bytesRead, long contentLength, boolean done) { - callback.onDownloadProgress(bytesRead, contentLength, done); - } - }; - - progressRequestListener = new ProgressRequestBody.ProgressRequestListener() { - @Override - public void onRequestProgress(long bytesWritten, long contentLength, boolean done) { - callback.onUploadProgress(bytesWritten, contentLength, done); - } - }; - } - - com.squareup.okhttp.Call call = getCurrentUserValidateBeforeCall(progressListener, progressRequestListener); - Type localVarReturnType = new TypeToken(){}.getType(); - apiClient.executeAsync(call, localVarReturnType, callback); - return call; - } - /** - * Build call for getCurrentUserPlaces - * @param pageOffset The offset in terms of elements. (optional, default to 0) - * @param pageSize The maximum number of elements on the page. (optional, default to 20) - * @param progressListener Progress listener - * @param progressRequestListener Progress request listener - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - */ - public com.squareup.okhttp.Call getCurrentUserPlacesCall(Integer pageOffset, Integer pageSize, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - Object localVarPostBody = null; - - // create path and map variables - String localVarPath = "/users/current/places"; - - List localVarQueryParams = new ArrayList(); - if (pageOffset != null) - localVarQueryParams.addAll(apiClient.parameterToPairs("", "pageOffset", pageOffset)); - if (pageSize != null) - localVarQueryParams.addAll(apiClient.parameterToPairs("", "pageSize", pageSize)); - - Map localVarHeaderParams = new HashMap(); - - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json", "application/xml" - }; - final String localVarAccept = apiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) localVarHeaderParams.put("Accept", localVarAccept); - - final String[] localVarContentTypes = { - "application/json", "application/xml" - }; - final String localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); - - if(progressListener != null) { - apiClient.getHttpClient().networkInterceptors().add(new com.squareup.okhttp.Interceptor() { - @Override - public com.squareup.okhttp.Response intercept(com.squareup.okhttp.Interceptor.Chain chain) throws IOException { - com.squareup.okhttp.Response originalResponse = chain.proceed(chain.request()); - return originalResponse.newBuilder() - .body(new ProgressResponseBody(originalResponse.body(), progressListener)) - .build(); - } - }); - } - - String[] localVarAuthNames = new String[] { }; - return apiClient.buildCall(localVarPath, "GET", localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, progressRequestListener); - } - - @SuppressWarnings("rawtypes") - private com.squareup.okhttp.Call getCurrentUserPlacesValidateBeforeCall(Integer pageOffset, Integer pageSize, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - - - com.squareup.okhttp.Call call = getCurrentUserPlacesCall(pageOffset, pageSize, progressListener, progressRequestListener); - return call; - - - - - - } - - /** - * Returns the places for the current user. - * - * @param pageOffset The offset in terms of elements. (optional, default to 0) - * @param pageSize The maximum number of elements on the page. (optional, default to 20) - * @return PlacePage - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public PlacePage getCurrentUserPlaces(Integer pageOffset, Integer pageSize) throws ApiException { - ApiResponse resp = getCurrentUserPlacesWithHttpInfo(pageOffset, pageSize); - return resp.getData(); - } - - /** - * Returns the places for the current user. - * - * @param pageOffset The offset in terms of elements. (optional, default to 0) - * @param pageSize The maximum number of elements on the page. (optional, default to 20) - * @return ApiResponse<PlacePage> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public ApiResponse getCurrentUserPlacesWithHttpInfo(Integer pageOffset, Integer pageSize) throws ApiException { - com.squareup.okhttp.Call call = getCurrentUserPlacesValidateBeforeCall(pageOffset, pageSize, null, null); - Type localVarReturnType = new TypeToken(){}.getType(); - return apiClient.execute(call, localVarReturnType); - } - - /** - * Returns the places for the current user. (asynchronously) - * - * @param pageOffset The offset in terms of elements. (optional, default to 0) - * @param pageSize The maximum number of elements on the page. (optional, default to 20) - * @param callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - */ - public com.squareup.okhttp.Call getCurrentUserPlacesAsync(Integer pageOffset, Integer pageSize, final ApiCallback callback) throws ApiException { - - ProgressResponseBody.ProgressListener progressListener = null; - ProgressRequestBody.ProgressRequestListener progressRequestListener = null; - - if (callback != null) { - progressListener = new ProgressResponseBody.ProgressListener() { - @Override - public void update(long bytesRead, long contentLength, boolean done) { - callback.onDownloadProgress(bytesRead, contentLength, done); - } - }; - - progressRequestListener = new ProgressRequestBody.ProgressRequestListener() { - @Override - public void onRequestProgress(long bytesWritten, long contentLength, boolean done) { - callback.onUploadProgress(bytesWritten, contentLength, done); - } - }; - } - - com.squareup.okhttp.Call call = getCurrentUserPlacesValidateBeforeCall(pageOffset, pageSize, progressListener, progressRequestListener); - Type localVarReturnType = new TypeToken(){}.getType(); - apiClient.executeAsync(call, localVarReturnType, callback); - return call; - } - /** - * Build call for getCurrentUserPrivileges - * @param pageOffset The offset in terms of elements. (optional, default to 0) - * @param pageSize The maximum number of elements on the page. (optional, default to 20) - * @param progressListener Progress listener - * @param progressRequestListener Progress request listener - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - */ - public com.squareup.okhttp.Call getCurrentUserPrivilegesCall(Integer pageOffset, Integer pageSize, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - Object localVarPostBody = null; - - // create path and map variables - String localVarPath = "/users/current/privileges"; - - List localVarQueryParams = new ArrayList(); - if (pageOffset != null) - localVarQueryParams.addAll(apiClient.parameterToPairs("", "pageOffset", pageOffset)); - if (pageSize != null) - localVarQueryParams.addAll(apiClient.parameterToPairs("", "pageSize", pageSize)); - - Map localVarHeaderParams = new HashMap(); - - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json", "application/xml" - }; - final String localVarAccept = apiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) localVarHeaderParams.put("Accept", localVarAccept); - - final String[] localVarContentTypes = { - "application/json", "application/xml" - }; - final String localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); - - if(progressListener != null) { - apiClient.getHttpClient().networkInterceptors().add(new com.squareup.okhttp.Interceptor() { - @Override - public com.squareup.okhttp.Response intercept(com.squareup.okhttp.Interceptor.Chain chain) throws IOException { - com.squareup.okhttp.Response originalResponse = chain.proceed(chain.request()); - return originalResponse.newBuilder() - .body(new ProgressResponseBody(originalResponse.body(), progressListener)) - .build(); - } - }); - } - - String[] localVarAuthNames = new String[] { "user" }; - return apiClient.buildCall(localVarPath, "GET", localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, progressRequestListener); - } - - @SuppressWarnings("rawtypes") - private com.squareup.okhttp.Call getCurrentUserPrivilegesValidateBeforeCall(Integer pageOffset, Integer pageSize, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - - - com.squareup.okhttp.Call call = getCurrentUserPrivilegesCall(pageOffset, pageSize, progressListener, progressRequestListener); - return call; - - - - - - } - - /** - * Returns the privileges for the current user. - * - * @param pageOffset The offset in terms of elements. (optional, default to 0) - * @param pageSize The maximum number of elements on the page. (optional, default to 20) - * @return PrivilegePage - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public PrivilegePage getCurrentUserPrivileges(Integer pageOffset, Integer pageSize) throws ApiException { - ApiResponse resp = getCurrentUserPrivilegesWithHttpInfo(pageOffset, pageSize); - return resp.getData(); - } - - /** - * Returns the privileges for the current user. - * - * @param pageOffset The offset in terms of elements. (optional, default to 0) - * @param pageSize The maximum number of elements on the page. (optional, default to 20) - * @return ApiResponse<PrivilegePage> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public ApiResponse getCurrentUserPrivilegesWithHttpInfo(Integer pageOffset, Integer pageSize) throws ApiException { - com.squareup.okhttp.Call call = getCurrentUserPrivilegesValidateBeforeCall(pageOffset, pageSize, null, null); - Type localVarReturnType = new TypeToken(){}.getType(); - return apiClient.execute(call, localVarReturnType); - } - - /** - * Returns the privileges for the current user. (asynchronously) - * - * @param pageOffset The offset in terms of elements. (optional, default to 0) - * @param pageSize The maximum number of elements on the page. (optional, default to 20) - * @param callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - */ - public com.squareup.okhttp.Call getCurrentUserPrivilegesAsync(Integer pageOffset, Integer pageSize, final ApiCallback callback) throws ApiException { - - ProgressResponseBody.ProgressListener progressListener = null; - ProgressRequestBody.ProgressRequestListener progressRequestListener = null; - - if (callback != null) { - progressListener = new ProgressResponseBody.ProgressListener() { - @Override - public void update(long bytesRead, long contentLength, boolean done) { - callback.onDownloadProgress(bytesRead, contentLength, done); - } - }; - - progressRequestListener = new ProgressRequestBody.ProgressRequestListener() { - @Override - public void onRequestProgress(long bytesWritten, long contentLength, boolean done) { - callback.onUploadProgress(bytesWritten, contentLength, done); - } - }; - } - - com.squareup.okhttp.Call call = getCurrentUserPrivilegesValidateBeforeCall(pageOffset, pageSize, progressListener, progressRequestListener); - Type localVarReturnType = new TypeToken(){}.getType(); - apiClient.executeAsync(call, localVarReturnType, callback); - return call; - } - /** - * Build call for getUser - * @param id The id of the user to retrieve. (required) - * @param progressListener Progress listener - * @param progressRequestListener Progress request listener - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - */ - public com.squareup.okhttp.Call getUserCall(Long id, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - Object localVarPostBody = null; - - // create path and map variables - String localVarPath = "/users/{id}" - .replaceAll("\\{" + "id" + "\\}", apiClient.escapeString(id.toString())); - - List localVarQueryParams = new ArrayList(); - - Map localVarHeaderParams = new HashMap(); - - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json", "application/xml" - }; - final String localVarAccept = apiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) localVarHeaderParams.put("Accept", localVarAccept); - - final String[] localVarContentTypes = { - "application/json", "application/xml" - }; - final String localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); - - if(progressListener != null) { - apiClient.getHttpClient().networkInterceptors().add(new com.squareup.okhttp.Interceptor() { - @Override - public com.squareup.okhttp.Response intercept(com.squareup.okhttp.Interceptor.Chain chain) throws IOException { - com.squareup.okhttp.Response originalResponse = chain.proceed(chain.request()); - return originalResponse.newBuilder() - .body(new ProgressResponseBody(originalResponse.body(), progressListener)) - .build(); - } - }); - } - - String[] localVarAuthNames = new String[] { "admin" }; - return apiClient.buildCall(localVarPath, "GET", localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, progressRequestListener); - } - - @SuppressWarnings("rawtypes") - private com.squareup.okhttp.Call getUserValidateBeforeCall(Long id, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - - // verify the required parameter 'id' is set - if (id == null) { - throw new ApiException("Missing the required parameter 'id' when calling getUser(Async)"); - } - - - com.squareup.okhttp.Call call = getUserCall(id, progressListener, progressRequestListener); - return call; - - - - - - } - - /** - * Returns the user account with the specified id. - * - * @param id The id of the user to retrieve. (required) - * @return User - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public User getUser(Long id) throws ApiException { - ApiResponse resp = getUserWithHttpInfo(id); - return resp.getData(); - } - - /** - * Returns the user account with the specified id. - * - * @param id The id of the user to retrieve. (required) - * @return ApiResponse<User> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public ApiResponse getUserWithHttpInfo(Long id) throws ApiException { - com.squareup.okhttp.Call call = getUserValidateBeforeCall(id, null, null); - Type localVarReturnType = new TypeToken(){}.getType(); - return apiClient.execute(call, localVarReturnType); - } - - /** - * Returns the user account with the specified id. (asynchronously) - * - * @param id The id of the user to retrieve. (required) - * @param callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - */ - public com.squareup.okhttp.Call getUserAsync(Long id, final ApiCallback callback) throws ApiException { - - ProgressResponseBody.ProgressListener progressListener = null; - ProgressRequestBody.ProgressRequestListener progressRequestListener = null; - - if (callback != null) { - progressListener = new ProgressResponseBody.ProgressListener() { - @Override - public void update(long bytesRead, long contentLength, boolean done) { - callback.onDownloadProgress(bytesRead, contentLength, done); - } - }; - - progressRequestListener = new ProgressRequestBody.ProgressRequestListener() { - @Override - public void onRequestProgress(long bytesWritten, long contentLength, boolean done) { - callback.onUploadProgress(bytesWritten, contentLength, done); - } - }; - } - - com.squareup.okhttp.Call call = getUserValidateBeforeCall(id, progressListener, progressRequestListener); - Type localVarReturnType = new TypeToken(){}.getType(); - apiClient.executeAsync(call, localVarReturnType, callback); - return call; - } - /** - * Build call for getUserPlaces - * @param id The user id. (required) - * @param pageOffset The offset in terms of elements. (optional, default to 0) - * @param pageSize The maximum number of elements on the page. (optional, default to 20) - * @param progressListener Progress listener - * @param progressRequestListener Progress request listener - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - */ - public com.squareup.okhttp.Call getUserPlacesCall(Long id, Integer pageOffset, Integer pageSize, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - Object localVarPostBody = null; - - // create path and map variables - String localVarPath = "/users/{id}/places" - .replaceAll("\\{" + "id" + "\\}", apiClient.escapeString(id.toString())); - - List localVarQueryParams = new ArrayList(); - if (pageOffset != null) - localVarQueryParams.addAll(apiClient.parameterToPairs("", "pageOffset", pageOffset)); - if (pageSize != null) - localVarQueryParams.addAll(apiClient.parameterToPairs("", "pageSize", pageSize)); - - Map localVarHeaderParams = new HashMap(); - - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json", "application/xml" - }; - final String localVarAccept = apiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) localVarHeaderParams.put("Accept", localVarAccept); - - final String[] localVarContentTypes = { - "application/json", "application/xml" - }; - final String localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); - - if(progressListener != null) { - apiClient.getHttpClient().networkInterceptors().add(new com.squareup.okhttp.Interceptor() { - @Override - public com.squareup.okhttp.Response intercept(com.squareup.okhttp.Interceptor.Chain chain) throws IOException { - com.squareup.okhttp.Response originalResponse = chain.proceed(chain.request()); - return originalResponse.newBuilder() - .body(new ProgressResponseBody(originalResponse.body(), progressListener)) - .build(); - } - }); - } - - String[] localVarAuthNames = new String[] { }; - return apiClient.buildCall(localVarPath, "GET", localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, progressRequestListener); - } - - @SuppressWarnings("rawtypes") - private com.squareup.okhttp.Call getUserPlacesValidateBeforeCall(Long id, Integer pageOffset, Integer pageSize, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - - // verify the required parameter 'id' is set - if (id == null) { - throw new ApiException("Missing the required parameter 'id' when calling getUserPlaces(Async)"); - } - - - com.squareup.okhttp.Call call = getUserPlacesCall(id, pageOffset, pageSize, progressListener, progressRequestListener); - return call; - - - - - - } - - /** - * Returns the places for a particular user. - * - * @param id The user id. (required) - * @param pageOffset The offset in terms of elements. (optional, default to 0) - * @param pageSize The maximum number of elements on the page. (optional, default to 20) - * @return PlacePage - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public PlacePage getUserPlaces(Long id, Integer pageOffset, Integer pageSize) throws ApiException { - ApiResponse resp = getUserPlacesWithHttpInfo(id, pageOffset, pageSize); - return resp.getData(); - } - - /** - * Returns the places for a particular user. - * - * @param id The user id. (required) - * @param pageOffset The offset in terms of elements. (optional, default to 0) - * @param pageSize The maximum number of elements on the page. (optional, default to 20) - * @return ApiResponse<PlacePage> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public ApiResponse getUserPlacesWithHttpInfo(Long id, Integer pageOffset, Integer pageSize) throws ApiException { - com.squareup.okhttp.Call call = getUserPlacesValidateBeforeCall(id, pageOffset, pageSize, null, null); - Type localVarReturnType = new TypeToken(){}.getType(); - return apiClient.execute(call, localVarReturnType); - } - - /** - * Returns the places for a particular user. (asynchronously) - * - * @param id The user id. (required) - * @param pageOffset The offset in terms of elements. (optional, default to 0) - * @param pageSize The maximum number of elements on the page. (optional, default to 20) - * @param callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - */ - public com.squareup.okhttp.Call getUserPlacesAsync(Long id, Integer pageOffset, Integer pageSize, final ApiCallback callback) throws ApiException { - - ProgressResponseBody.ProgressListener progressListener = null; - ProgressRequestBody.ProgressRequestListener progressRequestListener = null; - - if (callback != null) { - progressListener = new ProgressResponseBody.ProgressListener() { - @Override - public void update(long bytesRead, long contentLength, boolean done) { - callback.onDownloadProgress(bytesRead, contentLength, done); - } - }; - - progressRequestListener = new ProgressRequestBody.ProgressRequestListener() { - @Override - public void onRequestProgress(long bytesWritten, long contentLength, boolean done) { - callback.onUploadProgress(bytesWritten, contentLength, done); - } - }; - } - - com.squareup.okhttp.Call call = getUserPlacesValidateBeforeCall(id, pageOffset, pageSize, progressListener, progressRequestListener); - Type localVarReturnType = new TypeToken(){}.getType(); - apiClient.executeAsync(call, localVarReturnType, callback); - return call; - } - /** - * Build call for getUserPrivileges - * @param id The user id. (required) - * @param pageOffset The offset in terms of elements. (optional, default to 0) - * @param pageSize The maximum number of elements on the page. (optional, default to 20) - * @param progressListener Progress listener - * @param progressRequestListener Progress request listener - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - */ - public com.squareup.okhttp.Call getUserPrivilegesCall(Long id, Integer pageOffset, Integer pageSize, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - Object localVarPostBody = null; - - // create path and map variables - String localVarPath = "/users/{id}/privileges" - .replaceAll("\\{" + "id" + "\\}", apiClient.escapeString(id.toString())); - - List localVarQueryParams = new ArrayList(); - if (pageOffset != null) - localVarQueryParams.addAll(apiClient.parameterToPairs("", "pageOffset", pageOffset)); - if (pageSize != null) - localVarQueryParams.addAll(apiClient.parameterToPairs("", "pageSize", pageSize)); - - Map localVarHeaderParams = new HashMap(); - - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json", "application/xml" - }; - final String localVarAccept = apiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) localVarHeaderParams.put("Accept", localVarAccept); - - final String[] localVarContentTypes = { - "application/json", "application/xml" - }; - final String localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); - - if(progressListener != null) { - apiClient.getHttpClient().networkInterceptors().add(new com.squareup.okhttp.Interceptor() { - @Override - public com.squareup.okhttp.Response intercept(com.squareup.okhttp.Interceptor.Chain chain) throws IOException { - com.squareup.okhttp.Response originalResponse = chain.proceed(chain.request()); - return originalResponse.newBuilder() - .body(new ProgressResponseBody(originalResponse.body(), progressListener)) - .build(); - } - }); - } - - String[] localVarAuthNames = new String[] { "admin" }; - return apiClient.buildCall(localVarPath, "GET", localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, progressRequestListener); - } - - @SuppressWarnings("rawtypes") - private com.squareup.okhttp.Call getUserPrivilegesValidateBeforeCall(Long id, Integer pageOffset, Integer pageSize, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - - // verify the required parameter 'id' is set - if (id == null) { - throw new ApiException("Missing the required parameter 'id' when calling getUserPrivileges(Async)"); - } - - - com.squareup.okhttp.Call call = getUserPrivilegesCall(id, pageOffset, pageSize, progressListener, progressRequestListener); - return call; - - - - - - } - - /** - * Returns the privileges for a particular user. - * - * @param id The user id. (required) - * @param pageOffset The offset in terms of elements. (optional, default to 0) - * @param pageSize The maximum number of elements on the page. (optional, default to 20) - * @return PrivilegePage - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public PrivilegePage getUserPrivileges(Long id, Integer pageOffset, Integer pageSize) throws ApiException { - ApiResponse resp = getUserPrivilegesWithHttpInfo(id, pageOffset, pageSize); - return resp.getData(); - } - - /** - * Returns the privileges for a particular user. - * - * @param id The user id. (required) - * @param pageOffset The offset in terms of elements. (optional, default to 0) - * @param pageSize The maximum number of elements on the page. (optional, default to 20) - * @return ApiResponse<PrivilegePage> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public ApiResponse getUserPrivilegesWithHttpInfo(Long id, Integer pageOffset, Integer pageSize) throws ApiException { - com.squareup.okhttp.Call call = getUserPrivilegesValidateBeforeCall(id, pageOffset, pageSize, null, null); - Type localVarReturnType = new TypeToken(){}.getType(); - return apiClient.execute(call, localVarReturnType); - } - - /** - * Returns the privileges for a particular user. (asynchronously) - * - * @param id The user id. (required) - * @param pageOffset The offset in terms of elements. (optional, default to 0) - * @param pageSize The maximum number of elements on the page. (optional, default to 20) - * @param callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - */ - public com.squareup.okhttp.Call getUserPrivilegesAsync(Long id, Integer pageOffset, Integer pageSize, final ApiCallback callback) throws ApiException { - - ProgressResponseBody.ProgressListener progressListener = null; - ProgressRequestBody.ProgressRequestListener progressRequestListener = null; - - if (callback != null) { - progressListener = new ProgressResponseBody.ProgressListener() { - @Override - public void update(long bytesRead, long contentLength, boolean done) { - callback.onDownloadProgress(bytesRead, contentLength, done); - } - }; - - progressRequestListener = new ProgressRequestBody.ProgressRequestListener() { - @Override - public void onRequestProgress(long bytesWritten, long contentLength, boolean done) { - callback.onUploadProgress(bytesWritten, contentLength, done); - } - }; - } - - com.squareup.okhttp.Call call = getUserPrivilegesValidateBeforeCall(id, pageOffset, pageSize, progressListener, progressRequestListener); - Type localVarReturnType = new TypeToken(){}.getType(); - apiClient.executeAsync(call, localVarReturnType, callback); - return call; - } - /** - * Build call for getUsers - * @param pageOffset The offset in terms of elements. (optional, default to 0) - * @param pageSize The maximum number of elements on the page. (optional, default to 20) - * @param progressListener Progress listener - * @param progressRequestListener Progress request listener - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - */ - public com.squareup.okhttp.Call getUsersCall(Integer pageOffset, Integer pageSize, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - Object localVarPostBody = null; - - // create path and map variables - String localVarPath = "/users"; - - List localVarQueryParams = new ArrayList(); - if (pageOffset != null) - localVarQueryParams.addAll(apiClient.parameterToPairs("", "pageOffset", pageOffset)); - if (pageSize != null) - localVarQueryParams.addAll(apiClient.parameterToPairs("", "pageSize", pageSize)); - - Map localVarHeaderParams = new HashMap(); - - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json", "application/xml" - }; - final String localVarAccept = apiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) localVarHeaderParams.put("Accept", localVarAccept); - - final String[] localVarContentTypes = { - "application/json", "application/xml" - }; - final String localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); - - if(progressListener != null) { - apiClient.getHttpClient().networkInterceptors().add(new com.squareup.okhttp.Interceptor() { - @Override - public com.squareup.okhttp.Response intercept(com.squareup.okhttp.Interceptor.Chain chain) throws IOException { - com.squareup.okhttp.Response originalResponse = chain.proceed(chain.request()); - return originalResponse.newBuilder() - .body(new ProgressResponseBody(originalResponse.body(), progressListener)) - .build(); - } - }); - } - - String[] localVarAuthNames = new String[] { "admin" }; - return apiClient.buildCall(localVarPath, "GET", localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, progressRequestListener); - } - - @SuppressWarnings("rawtypes") - private com.squareup.okhttp.Call getUsersValidateBeforeCall(Integer pageOffset, Integer pageSize, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - - - com.squareup.okhttp.Call call = getUsersCall(pageOffset, pageSize, progressListener, progressRequestListener); - return call; - - - - - - } - - /** - * Returns a list of users. - * - * @param pageOffset The offset in terms of elements. (optional, default to 0) - * @param pageSize The maximum number of elements on the page. (optional, default to 20) - * @return UserPage - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public UserPage getUsers(Integer pageOffset, Integer pageSize) throws ApiException { - ApiResponse resp = getUsersWithHttpInfo(pageOffset, pageSize); - return resp.getData(); - } - - /** - * Returns a list of users. - * - * @param pageOffset The offset in terms of elements. (optional, default to 0) - * @param pageSize The maximum number of elements on the page. (optional, default to 20) - * @return ApiResponse<UserPage> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public ApiResponse getUsersWithHttpInfo(Integer pageOffset, Integer pageSize) throws ApiException { - com.squareup.okhttp.Call call = getUsersValidateBeforeCall(pageOffset, pageSize, null, null); - Type localVarReturnType = new TypeToken(){}.getType(); - return apiClient.execute(call, localVarReturnType); - } - - /** - * Returns a list of users. (asynchronously) - * - * @param pageOffset The offset in terms of elements. (optional, default to 0) - * @param pageSize The maximum number of elements on the page. (optional, default to 20) - * @param callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - */ - public com.squareup.okhttp.Call getUsersAsync(Integer pageOffset, Integer pageSize, final ApiCallback callback) throws ApiException { - - ProgressResponseBody.ProgressListener progressListener = null; - ProgressRequestBody.ProgressRequestListener progressRequestListener = null; - - if (callback != null) { - progressListener = new ProgressResponseBody.ProgressListener() { - @Override - public void update(long bytesRead, long contentLength, boolean done) { - callback.onDownloadProgress(bytesRead, contentLength, done); - } - }; - - progressRequestListener = new ProgressRequestBody.ProgressRequestListener() { - @Override - public void onRequestProgress(long bytesWritten, long contentLength, boolean done) { - callback.onUploadProgress(bytesWritten, contentLength, done); - } - }; - } - - com.squareup.okhttp.Call call = getUsersValidateBeforeCall(pageOffset, pageSize, progressListener, progressRequestListener); - Type localVarReturnType = new TypeToken(){}.getType(); - apiClient.executeAsync(call, localVarReturnType, callback); - return call; - } - /** - * Build call for registerUser - * @param body The data of the new user. (required) - * @param progressListener Progress listener - * @param progressRequestListener Progress request listener - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - */ - public com.squareup.okhttp.Call registerUserCall(UserRegistration body, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - Object localVarPostBody = body; - - // create path and map variables - String localVarPath = "/users/register"; - - List localVarQueryParams = new ArrayList(); - - Map localVarHeaderParams = new HashMap(); - - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json", "application/xml" - }; - final String localVarAccept = apiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) localVarHeaderParams.put("Accept", localVarAccept); - - final String[] localVarContentTypes = { - "application/json", "application/xml" - }; - final String localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); - - if(progressListener != null) { - apiClient.getHttpClient().networkInterceptors().add(new com.squareup.okhttp.Interceptor() { - @Override - public com.squareup.okhttp.Response intercept(com.squareup.okhttp.Interceptor.Chain chain) throws IOException { - com.squareup.okhttp.Response originalResponse = chain.proceed(chain.request()); - return originalResponse.newBuilder() - .body(new ProgressResponseBody(originalResponse.body(), progressListener)) - .build(); - } - }); - } - - String[] localVarAuthNames = new String[] { }; - return apiClient.buildCall(localVarPath, "POST", localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, progressRequestListener); - } - - @SuppressWarnings("rawtypes") - private com.squareup.okhttp.Call registerUserValidateBeforeCall(UserRegistration body, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - - // verify the required parameter 'body' is set - if (body == null) { - throw new ApiException("Missing the required parameter 'body' when calling registerUser(Async)"); - } - - - com.squareup.okhttp.Call call = registerUserCall(body, progressListener, progressRequestListener); - return call; - - - - - - } - - /** - * Registers a new user and sends an email account verification. - * - * @param body The data of the new user. (required) - * @return User - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public User registerUser(UserRegistration body) throws ApiException { - ApiResponse resp = registerUserWithHttpInfo(body); - return resp.getData(); - } - - /** - * Registers a new user and sends an email account verification. - * - * @param body The data of the new user. (required) - * @return ApiResponse<User> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public ApiResponse registerUserWithHttpInfo(UserRegistration body) throws ApiException { - com.squareup.okhttp.Call call = registerUserValidateBeforeCall(body, null, null); - Type localVarReturnType = new TypeToken(){}.getType(); - return apiClient.execute(call, localVarReturnType); - } - - /** - * Registers a new user and sends an email account verification. (asynchronously) - * - * @param body The data of the new user. (required) - * @param callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - */ - public com.squareup.okhttp.Call registerUserAsync(UserRegistration body, final ApiCallback callback) throws ApiException { - - ProgressResponseBody.ProgressListener progressListener = null; - ProgressRequestBody.ProgressRequestListener progressRequestListener = null; - - if (callback != null) { - progressListener = new ProgressResponseBody.ProgressListener() { - @Override - public void update(long bytesRead, long contentLength, boolean done) { - callback.onDownloadProgress(bytesRead, contentLength, done); - } - }; - - progressRequestListener = new ProgressRequestBody.ProgressRequestListener() { - @Override - public void onRequestProgress(long bytesWritten, long contentLength, boolean done) { - callback.onUploadProgress(bytesWritten, contentLength, done); - } - }; - } - - com.squareup.okhttp.Call call = registerUserValidateBeforeCall(body, progressListener, progressRequestListener); - Type localVarReturnType = new TypeToken(){}.getType(); - apiClient.executeAsync(call, localVarReturnType, callback); - return call; - } - /** - * Build call for resetUser - * @param login The login of the user to reset. (required) - * @param progressListener Progress listener - * @param progressRequestListener Progress request listener - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - */ - public com.squareup.okhttp.Call resetUserCall(String login, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - Object localVarPostBody = null; - - // create path and map variables - String localVarPath = "/users/reset"; - - List localVarQueryParams = new ArrayList(); - if (login != null) - localVarQueryParams.addAll(apiClient.parameterToPairs("", "login", login)); - - Map localVarHeaderParams = new HashMap(); - - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json", "application/xml" - }; - final String localVarAccept = apiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) localVarHeaderParams.put("Accept", localVarAccept); - - final String[] localVarContentTypes = { - "application/json", "application/xml" - }; - final String localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); - - if(progressListener != null) { - apiClient.getHttpClient().networkInterceptors().add(new com.squareup.okhttp.Interceptor() { - @Override - public com.squareup.okhttp.Response intercept(com.squareup.okhttp.Interceptor.Chain chain) throws IOException { - com.squareup.okhttp.Response originalResponse = chain.proceed(chain.request()); - return originalResponse.newBuilder() - .body(new ProgressResponseBody(originalResponse.body(), progressListener)) - .build(); - } - }); - } - - String[] localVarAuthNames = new String[] { }; - return apiClient.buildCall(localVarPath, "POST", localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, progressRequestListener); - } - - @SuppressWarnings("rawtypes") - private com.squareup.okhttp.Call resetUserValidateBeforeCall(String login, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - - // verify the required parameter 'login' is set - if (login == null) { - throw new ApiException("Missing the required parameter 'login' when calling resetUser(Async)"); - } - - - com.squareup.okhttp.Call call = resetUserCall(login, progressListener, progressRequestListener); - return call; - - - - - - } - - /** - * Sends a password reset email to the correspondence email account of a user. - * - * @param login The login of the user to reset. (required) - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public void resetUser(String login) throws ApiException { - resetUserWithHttpInfo(login); - } - - /** - * Sends a password reset email to the correspondence email account of a user. - * - * @param login The login of the user to reset. (required) - * @return ApiResponse<Void> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public ApiResponse resetUserWithHttpInfo(String login) throws ApiException { - com.squareup.okhttp.Call call = resetUserValidateBeforeCall(login, null, null); - return apiClient.execute(call); - } - - /** - * Sends a password reset email to the correspondence email account of a user. (asynchronously) - * - * @param login The login of the user to reset. (required) - * @param callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - */ - public com.squareup.okhttp.Call resetUserAsync(String login, final ApiCallback callback) throws ApiException { - - ProgressResponseBody.ProgressListener progressListener = null; - ProgressRequestBody.ProgressRequestListener progressRequestListener = null; - - if (callback != null) { - progressListener = new ProgressResponseBody.ProgressListener() { - @Override - public void update(long bytesRead, long contentLength, boolean done) { - callback.onDownloadProgress(bytesRead, contentLength, done); - } - }; - - progressRequestListener = new ProgressRequestBody.ProgressRequestListener() { - @Override - public void onRequestProgress(long bytesWritten, long contentLength, boolean done) { - callback.onUploadProgress(bytesWritten, contentLength, done); - } - }; - } - - com.squareup.okhttp.Call call = resetUserValidateBeforeCall(login, progressListener, progressRequestListener); - apiClient.executeAsync(call, callback); - return call; - } - /** - * Build call for resetUserPassword - * @param token The secret token received via email. (required) - * @param body The new user password. (required) - * @param progressListener Progress listener - * @param progressRequestListener Progress request listener - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - */ - public com.squareup.okhttp.Call resetUserPasswordCall(String token, UserPassword body, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - Object localVarPostBody = body; - - // create path and map variables - String localVarPath = "/users/password/{token}" - .replaceAll("\\{" + "token" + "\\}", apiClient.escapeString(token.toString())); - - List localVarQueryParams = new ArrayList(); - - Map localVarHeaderParams = new HashMap(); - - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json", "application/xml" - }; - final String localVarAccept = apiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) localVarHeaderParams.put("Accept", localVarAccept); - - final String[] localVarContentTypes = { - "application/json", "application/xml" - }; - final String localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); - - if(progressListener != null) { - apiClient.getHttpClient().networkInterceptors().add(new com.squareup.okhttp.Interceptor() { - @Override - public com.squareup.okhttp.Response intercept(com.squareup.okhttp.Interceptor.Chain chain) throws IOException { - com.squareup.okhttp.Response originalResponse = chain.proceed(chain.request()); - return originalResponse.newBuilder() - .body(new ProgressResponseBody(originalResponse.body(), progressListener)) - .build(); - } - }); - } - - String[] localVarAuthNames = new String[] { }; - return apiClient.buildCall(localVarPath, "PUT", localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, progressRequestListener); - } - - @SuppressWarnings("rawtypes") - private com.squareup.okhttp.Call resetUserPasswordValidateBeforeCall(String token, UserPassword body, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - - // verify the required parameter 'token' is set - if (token == null) { - throw new ApiException("Missing the required parameter 'token' when calling resetUserPassword(Async)"); - } - - // verify the required parameter 'body' is set - if (body == null) { - throw new ApiException("Missing the required parameter 'body' when calling resetUserPassword(Async)"); - } - - - com.squareup.okhttp.Call call = resetUserPasswordCall(token, body, progressListener, progressRequestListener); - return call; - - - - - - } - - /** - * Sets the password of a user account using a token received via email. - * - * @param token The secret token received via email. (required) - * @param body The new user password. (required) - * @return User - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public User resetUserPassword(String token, UserPassword body) throws ApiException { - ApiResponse resp = resetUserPasswordWithHttpInfo(token, body); - return resp.getData(); - } - - /** - * Sets the password of a user account using a token received via email. - * - * @param token The secret token received via email. (required) - * @param body The new user password. (required) - * @return ApiResponse<User> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public ApiResponse resetUserPasswordWithHttpInfo(String token, UserPassword body) throws ApiException { - com.squareup.okhttp.Call call = resetUserPasswordValidateBeforeCall(token, body, null, null); - Type localVarReturnType = new TypeToken(){}.getType(); - return apiClient.execute(call, localVarReturnType); - } - - /** - * Sets the password of a user account using a token received via email. (asynchronously) - * - * @param token The secret token received via email. (required) - * @param body The new user password. (required) - * @param callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - */ - public com.squareup.okhttp.Call resetUserPasswordAsync(String token, UserPassword body, final ApiCallback callback) throws ApiException { - - ProgressResponseBody.ProgressListener progressListener = null; - ProgressRequestBody.ProgressRequestListener progressRequestListener = null; - - if (callback != null) { - progressListener = new ProgressResponseBody.ProgressListener() { - @Override - public void update(long bytesRead, long contentLength, boolean done) { - callback.onDownloadProgress(bytesRead, contentLength, done); - } - }; - - progressRequestListener = new ProgressRequestBody.ProgressRequestListener() { - @Override - public void onRequestProgress(long bytesWritten, long contentLength, boolean done) { - callback.onUploadProgress(bytesWritten, contentLength, done); - } - }; - } - - com.squareup.okhttp.Call call = resetUserPasswordValidateBeforeCall(token, body, progressListener, progressRequestListener); - Type localVarReturnType = new TypeToken(){}.getType(); - apiClient.executeAsync(call, localVarReturnType, callback); - return call; - } - /** - * Build call for searchUsers - * @param term The search term. (required) - * @param pageOffset The offset in terms of elements. (optional, default to 0) - * @param pageSize The maximum number of elements on the page. (optional, default to 20) - * @param progressListener Progress listener - * @param progressRequestListener Progress request listener - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - */ - public com.squareup.okhttp.Call searchUsersCall(String term, Integer pageOffset, Integer pageSize, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - Object localVarPostBody = null; - - // create path and map variables - String localVarPath = "/users/search"; - - List localVarQueryParams = new ArrayList(); - if (pageOffset != null) - localVarQueryParams.addAll(apiClient.parameterToPairs("", "pageOffset", pageOffset)); - if (pageSize != null) - localVarQueryParams.addAll(apiClient.parameterToPairs("", "pageSize", pageSize)); - if (term != null) - localVarQueryParams.addAll(apiClient.parameterToPairs("", "term", term)); - - Map localVarHeaderParams = new HashMap(); - - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json", "application/xml" - }; - final String localVarAccept = apiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) localVarHeaderParams.put("Accept", localVarAccept); - - final String[] localVarContentTypes = { - "application/json", "application/xml" - }; - final String localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); - - if(progressListener != null) { - apiClient.getHttpClient().networkInterceptors().add(new com.squareup.okhttp.Interceptor() { - @Override - public com.squareup.okhttp.Response intercept(com.squareup.okhttp.Interceptor.Chain chain) throws IOException { - com.squareup.okhttp.Response originalResponse = chain.proceed(chain.request()); - return originalResponse.newBuilder() - .body(new ProgressResponseBody(originalResponse.body(), progressListener)) - .build(); - } - }); - } - - String[] localVarAuthNames = new String[] { "admin" }; - return apiClient.buildCall(localVarPath, "GET", localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, progressRequestListener); - } - - @SuppressWarnings("rawtypes") - private com.squareup.okhttp.Call searchUsersValidateBeforeCall(String term, Integer pageOffset, Integer pageSize, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - - // verify the required parameter 'term' is set - if (term == null) { - throw new ApiException("Missing the required parameter 'term' when calling searchUsers(Async)"); - } - - - com.squareup.okhttp.Call call = searchUsersCall(term, pageOffset, pageSize, progressListener, progressRequestListener); - return call; - - - - - - } - - /** - * Returns a list of users whose login name or name contains the term. - * - * @param term The search term. (required) - * @param pageOffset The offset in terms of elements. (optional, default to 0) - * @param pageSize The maximum number of elements on the page. (optional, default to 20) - * @return UserPage - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public UserPage searchUsers(String term, Integer pageOffset, Integer pageSize) throws ApiException { - ApiResponse resp = searchUsersWithHttpInfo(term, pageOffset, pageSize); - return resp.getData(); - } - - /** - * Returns a list of users whose login name or name contains the term. - * - * @param term The search term. (required) - * @param pageOffset The offset in terms of elements. (optional, default to 0) - * @param pageSize The maximum number of elements on the page. (optional, default to 20) - * @return ApiResponse<UserPage> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public ApiResponse searchUsersWithHttpInfo(String term, Integer pageOffset, Integer pageSize) throws ApiException { - com.squareup.okhttp.Call call = searchUsersValidateBeforeCall(term, pageOffset, pageSize, null, null); - Type localVarReturnType = new TypeToken(){}.getType(); - return apiClient.execute(call, localVarReturnType); - } - - /** - * Returns a list of users whose login name or name contains the term. (asynchronously) - * - * @param term The search term. (required) - * @param pageOffset The offset in terms of elements. (optional, default to 0) - * @param pageSize The maximum number of elements on the page. (optional, default to 20) - * @param callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - */ - public com.squareup.okhttp.Call searchUsersAsync(String term, Integer pageOffset, Integer pageSize, final ApiCallback callback) throws ApiException { - - ProgressResponseBody.ProgressListener progressListener = null; - ProgressRequestBody.ProgressRequestListener progressRequestListener = null; - - if (callback != null) { - progressListener = new ProgressResponseBody.ProgressListener() { - @Override - public void update(long bytesRead, long contentLength, boolean done) { - callback.onDownloadProgress(bytesRead, contentLength, done); - } - }; - - progressRequestListener = new ProgressRequestBody.ProgressRequestListener() { - @Override - public void onRequestProgress(long bytesWritten, long contentLength, boolean done) { - callback.onUploadProgress(bytesWritten, contentLength, done); - } - }; - } - - com.squareup.okhttp.Call call = searchUsersValidateBeforeCall(term, pageOffset, pageSize, progressListener, progressRequestListener); - Type localVarReturnType = new TypeToken(){}.getType(); - apiClient.executeAsync(call, localVarReturnType, callback); - return call; - } - /** - * Build call for setCurrentPassword - * @param body The new password to set. (required) - * @param progressListener Progress listener - * @param progressRequestListener Progress request listener - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - */ - public com.squareup.okhttp.Call setCurrentPasswordCall(UserPassword body, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - Object localVarPostBody = body; - - // create path and map variables - String localVarPath = "/users/current/password"; - - List localVarQueryParams = new ArrayList(); - - Map localVarHeaderParams = new HashMap(); - - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json", "application/xml" - }; - final String localVarAccept = apiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) localVarHeaderParams.put("Accept", localVarAccept); - - final String[] localVarContentTypes = { - "application/json", "application/xml" - }; - final String localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); - - if(progressListener != null) { - apiClient.getHttpClient().networkInterceptors().add(new com.squareup.okhttp.Interceptor() { - @Override - public com.squareup.okhttp.Response intercept(com.squareup.okhttp.Interceptor.Chain chain) throws IOException { - com.squareup.okhttp.Response originalResponse = chain.proceed(chain.request()); - return originalResponse.newBuilder() - .body(new ProgressResponseBody(originalResponse.body(), progressListener)) - .build(); - } - }); - } - - String[] localVarAuthNames = new String[] { "user" }; - return apiClient.buildCall(localVarPath, "PUT", localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, progressRequestListener); - } - - @SuppressWarnings("rawtypes") - private com.squareup.okhttp.Call setCurrentPasswordValidateBeforeCall(UserPassword body, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - - // verify the required parameter 'body' is set - if (body == null) { - throw new ApiException("Missing the required parameter 'body' when calling setCurrentPassword(Async)"); - } - - - com.squareup.okhttp.Call call = setCurrentPasswordCall(body, progressListener, progressRequestListener); - return call; - - - - - - } - - /** - * Sets the password of the currently authorized user. - * - * @param body The new password to set. (required) - * @return User - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public User setCurrentPassword(UserPassword body) throws ApiException { - ApiResponse resp = setCurrentPasswordWithHttpInfo(body); - return resp.getData(); - } - - /** - * Sets the password of the currently authorized user. - * - * @param body The new password to set. (required) - * @return ApiResponse<User> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public ApiResponse setCurrentPasswordWithHttpInfo(UserPassword body) throws ApiException { - com.squareup.okhttp.Call call = setCurrentPasswordValidateBeforeCall(body, null, null); - Type localVarReturnType = new TypeToken(){}.getType(); - return apiClient.execute(call, localVarReturnType); - } - - /** - * Sets the password of the currently authorized user. (asynchronously) - * - * @param body The new password to set. (required) - * @param callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - */ - public com.squareup.okhttp.Call setCurrentPasswordAsync(UserPassword body, final ApiCallback callback) throws ApiException { - - ProgressResponseBody.ProgressListener progressListener = null; - ProgressRequestBody.ProgressRequestListener progressRequestListener = null; - - if (callback != null) { - progressListener = new ProgressResponseBody.ProgressListener() { - @Override - public void update(long bytesRead, long contentLength, boolean done) { - callback.onDownloadProgress(bytesRead, contentLength, done); - } - }; - - progressRequestListener = new ProgressRequestBody.ProgressRequestListener() { - @Override - public void onRequestProgress(long bytesWritten, long contentLength, boolean done) { - callback.onUploadProgress(bytesWritten, contentLength, done); - } - }; - } - - com.squareup.okhttp.Call call = setCurrentPasswordValidateBeforeCall(body, progressListener, progressRequestListener); - Type localVarReturnType = new TypeToken(){}.getType(); - apiClient.executeAsync(call, localVarReturnType, callback); - return call; - } - /** - * Build call for setCurrentUser - * @param body The new user values to set. (required) - * @param progressListener Progress listener - * @param progressRequestListener Progress request listener - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - */ - public com.squareup.okhttp.Call setCurrentUserCall(User body, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - Object localVarPostBody = body; - - // create path and map variables - String localVarPath = "/users/current"; - - List localVarQueryParams = new ArrayList(); - - Map localVarHeaderParams = new HashMap(); - - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json", "application/xml" - }; - final String localVarAccept = apiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) localVarHeaderParams.put("Accept", localVarAccept); - - final String[] localVarContentTypes = { - "application/json", "application/xml" - }; - final String localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); - - if(progressListener != null) { - apiClient.getHttpClient().networkInterceptors().add(new com.squareup.okhttp.Interceptor() { - @Override - public com.squareup.okhttp.Response intercept(com.squareup.okhttp.Interceptor.Chain chain) throws IOException { - com.squareup.okhttp.Response originalResponse = chain.proceed(chain.request()); - return originalResponse.newBuilder() - .body(new ProgressResponseBody(originalResponse.body(), progressListener)) - .build(); - } - }); - } - - String[] localVarAuthNames = new String[] { "user" }; - return apiClient.buildCall(localVarPath, "PUT", localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, progressRequestListener); - } - - @SuppressWarnings("rawtypes") - private com.squareup.okhttp.Call setCurrentUserValidateBeforeCall(User body, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - - // verify the required parameter 'body' is set - if (body == null) { - throw new ApiException("Missing the required parameter 'body' when calling setCurrentUser(Async)"); - } - - - com.squareup.okhttp.Call call = setCurrentUserCall(body, progressListener, progressRequestListener); - return call; - - - - - - } - - /** - * Updates the currently authorized user. - * - * @param body The new user values to set. (required) - * @return User - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public User setCurrentUser(User body) throws ApiException { - ApiResponse resp = setCurrentUserWithHttpInfo(body); - return resp.getData(); - } - - /** - * Updates the currently authorized user. - * - * @param body The new user values to set. (required) - * @return ApiResponse<User> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public ApiResponse setCurrentUserWithHttpInfo(User body) throws ApiException { - com.squareup.okhttp.Call call = setCurrentUserValidateBeforeCall(body, null, null); - Type localVarReturnType = new TypeToken(){}.getType(); - return apiClient.execute(call, localVarReturnType); - } - - /** - * Updates the currently authorized user. (asynchronously) - * - * @param body The new user values to set. (required) - * @param callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - */ - public com.squareup.okhttp.Call setCurrentUserAsync(User body, final ApiCallback callback) throws ApiException { - - ProgressResponseBody.ProgressListener progressListener = null; - ProgressRequestBody.ProgressRequestListener progressRequestListener = null; - - if (callback != null) { - progressListener = new ProgressResponseBody.ProgressListener() { - @Override - public void update(long bytesRead, long contentLength, boolean done) { - callback.onDownloadProgress(bytesRead, contentLength, done); - } - }; - - progressRequestListener = new ProgressRequestBody.ProgressRequestListener() { - @Override - public void onRequestProgress(long bytesWritten, long contentLength, boolean done) { - callback.onUploadProgress(bytesWritten, contentLength, done); - } - }; - } - - com.squareup.okhttp.Call call = setCurrentUserValidateBeforeCall(body, progressListener, progressRequestListener); - Type localVarReturnType = new TypeToken(){}.getType(); - apiClient.executeAsync(call, localVarReturnType, callback); - return call; - } - /** - * Build call for setUser - * @param id The id of the user to set. (required) - * @param body The new user data to set. (required) - * @param progressListener Progress listener - * @param progressRequestListener Progress request listener - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - */ - public com.squareup.okhttp.Call setUserCall(Long id, User body, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - Object localVarPostBody = body; - - // create path and map variables - String localVarPath = "/users/{id}" - .replaceAll("\\{" + "id" + "\\}", apiClient.escapeString(id.toString())); - - List localVarQueryParams = new ArrayList(); - - Map localVarHeaderParams = new HashMap(); - - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json", "application/xml" - }; - final String localVarAccept = apiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) localVarHeaderParams.put("Accept", localVarAccept); - - final String[] localVarContentTypes = { - "application/json", "application/xml" - }; - final String localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); - - if(progressListener != null) { - apiClient.getHttpClient().networkInterceptors().add(new com.squareup.okhttp.Interceptor() { - @Override - public com.squareup.okhttp.Response intercept(com.squareup.okhttp.Interceptor.Chain chain) throws IOException { - com.squareup.okhttp.Response originalResponse = chain.proceed(chain.request()); - return originalResponse.newBuilder() - .body(new ProgressResponseBody(originalResponse.body(), progressListener)) - .build(); - } - }); - } - - String[] localVarAuthNames = new String[] { "admin" }; - return apiClient.buildCall(localVarPath, "PUT", localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, progressRequestListener); - } - - @SuppressWarnings("rawtypes") - private com.squareup.okhttp.Call setUserValidateBeforeCall(Long id, User body, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - - // verify the required parameter 'id' is set - if (id == null) { - throw new ApiException("Missing the required parameter 'id' when calling setUser(Async)"); - } - - // verify the required parameter 'body' is set - if (body == null) { - throw new ApiException("Missing the required parameter 'body' when calling setUser(Async)"); - } - - - com.squareup.okhttp.Call call = setUserCall(id, body, progressListener, progressRequestListener); - return call; - - - - - - } - - /** - * Updates the values of a particular user account. - * - * @param id The id of the user to set. (required) - * @param body The new user data to set. (required) - * @return User - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public User setUser(Long id, User body) throws ApiException { - ApiResponse resp = setUserWithHttpInfo(id, body); - return resp.getData(); - } - - /** - * Updates the values of a particular user account. - * - * @param id The id of the user to set. (required) - * @param body The new user data to set. (required) - * @return ApiResponse<User> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public ApiResponse setUserWithHttpInfo(Long id, User body) throws ApiException { - com.squareup.okhttp.Call call = setUserValidateBeforeCall(id, body, null, null); - Type localVarReturnType = new TypeToken(){}.getType(); - return apiClient.execute(call, localVarReturnType); - } - - /** - * Updates the values of a particular user account. (asynchronously) - * - * @param id The id of the user to set. (required) - * @param body The new user data to set. (required) - * @param callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - */ - public com.squareup.okhttp.Call setUserAsync(Long id, User body, final ApiCallback callback) throws ApiException { - - ProgressResponseBody.ProgressListener progressListener = null; - ProgressRequestBody.ProgressRequestListener progressRequestListener = null; - - if (callback != null) { - progressListener = new ProgressResponseBody.ProgressListener() { - @Override - public void update(long bytesRead, long contentLength, boolean done) { - callback.onDownloadProgress(bytesRead, contentLength, done); - } - }; - - progressRequestListener = new ProgressRequestBody.ProgressRequestListener() { - @Override - public void onRequestProgress(long bytesWritten, long contentLength, boolean done) { - callback.onUploadProgress(bytesWritten, contentLength, done); - } - }; - } - - com.squareup.okhttp.Call call = setUserValidateBeforeCall(id, body, progressListener, progressRequestListener); - Type localVarReturnType = new TypeToken(){}.getType(); - apiClient.executeAsync(call, localVarReturnType, callback); - return call; - } - /** - * Build call for setUserPassword - * @param id The id of the user to change. (required) - * @param body The new password. (required) - * @param progressListener Progress listener - * @param progressRequestListener Progress request listener - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - */ - public com.squareup.okhttp.Call setUserPasswordCall(Long id, UserPassword body, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - Object localVarPostBody = body; - - // create path and map variables - String localVarPath = "/users/{id}/password" - .replaceAll("\\{" + "id" + "\\}", apiClient.escapeString(id.toString())); - - List localVarQueryParams = new ArrayList(); - - Map localVarHeaderParams = new HashMap(); - - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json", "application/xml" - }; - final String localVarAccept = apiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) localVarHeaderParams.put("Accept", localVarAccept); - - final String[] localVarContentTypes = { - "application/json", "application/xml" - }; - final String localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); - - if(progressListener != null) { - apiClient.getHttpClient().networkInterceptors().add(new com.squareup.okhttp.Interceptor() { - @Override - public com.squareup.okhttp.Response intercept(com.squareup.okhttp.Interceptor.Chain chain) throws IOException { - com.squareup.okhttp.Response originalResponse = chain.proceed(chain.request()); - return originalResponse.newBuilder() - .body(new ProgressResponseBody(originalResponse.body(), progressListener)) - .build(); - } - }); - } - - String[] localVarAuthNames = new String[] { "admin" }; - return apiClient.buildCall(localVarPath, "PUT", localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, progressRequestListener); - } - - @SuppressWarnings("rawtypes") - private com.squareup.okhttp.Call setUserPasswordValidateBeforeCall(Long id, UserPassword body, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - - // verify the required parameter 'id' is set - if (id == null) { - throw new ApiException("Missing the required parameter 'id' when calling setUserPassword(Async)"); - } - - // verify the required parameter 'body' is set - if (body == null) { - throw new ApiException("Missing the required parameter 'body' when calling setUserPassword(Async)"); - } - - - com.squareup.okhttp.Call call = setUserPasswordCall(id, body, progressListener, progressRequestListener); - return call; - - - - - - } - - /** - * Sets the password of a user. - * - * @param id The id of the user to change. (required) - * @param body The new password. (required) - * @return User - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public User setUserPassword(Long id, UserPassword body) throws ApiException { - ApiResponse resp = setUserPasswordWithHttpInfo(id, body); - return resp.getData(); - } - - /** - * Sets the password of a user. - * - * @param id The id of the user to change. (required) - * @param body The new password. (required) - * @return ApiResponse<User> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public ApiResponse setUserPasswordWithHttpInfo(Long id, UserPassword body) throws ApiException { - com.squareup.okhttp.Call call = setUserPasswordValidateBeforeCall(id, body, null, null); - Type localVarReturnType = new TypeToken(){}.getType(); - return apiClient.execute(call, localVarReturnType); - } - - /** - * Sets the password of a user. (asynchronously) - * - * @param id The id of the user to change. (required) - * @param body The new password. (required) - * @param callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - */ - public com.squareup.okhttp.Call setUserPasswordAsync(Long id, UserPassword body, final ApiCallback callback) throws ApiException { - - ProgressResponseBody.ProgressListener progressListener = null; - ProgressRequestBody.ProgressRequestListener progressRequestListener = null; - - if (callback != null) { - progressListener = new ProgressResponseBody.ProgressListener() { - @Override - public void update(long bytesRead, long contentLength, boolean done) { - callback.onDownloadProgress(bytesRead, contentLength, done); - } - }; - - progressRequestListener = new ProgressRequestBody.ProgressRequestListener() { - @Override - public void onRequestProgress(long bytesWritten, long contentLength, boolean done) { - callback.onUploadProgress(bytesWritten, contentLength, done); - } - }; - } - - com.squareup.okhttp.Call call = setUserPasswordValidateBeforeCall(id, body, progressListener, progressRequestListener); - Type localVarReturnType = new TypeToken(){}.getType(); - apiClient.executeAsync(call, localVarReturnType, callback); - return call; - } - /** - * Build call for verifyUserEmail - * @param token The secret token received via email. (required) - * @param progressListener Progress listener - * @param progressRequestListener Progress request listener - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - */ - public com.squareup.okhttp.Call verifyUserEmailCall(String token, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - Object localVarPostBody = null; - - // create path and map variables - String localVarPath = "/users/verify/{token}" - .replaceAll("\\{" + "token" + "\\}", apiClient.escapeString(token.toString())); - - List localVarQueryParams = new ArrayList(); - - Map localVarHeaderParams = new HashMap(); - - Map localVarFormParams = new HashMap(); - - final String[] localVarAccepts = { - "application/json", "application/xml" - }; - final String localVarAccept = apiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) localVarHeaderParams.put("Accept", localVarAccept); - - final String[] localVarContentTypes = { - "application/json", "application/xml" - }; - final String localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); - - if(progressListener != null) { - apiClient.getHttpClient().networkInterceptors().add(new com.squareup.okhttp.Interceptor() { - @Override - public com.squareup.okhttp.Response intercept(com.squareup.okhttp.Interceptor.Chain chain) throws IOException { - com.squareup.okhttp.Response originalResponse = chain.proceed(chain.request()); - return originalResponse.newBuilder() - .body(new ProgressResponseBody(originalResponse.body(), progressListener)) - .build(); - } - }); - } - - String[] localVarAuthNames = new String[] { }; - return apiClient.buildCall(localVarPath, "PUT", localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, progressRequestListener); - } - - @SuppressWarnings("rawtypes") - private com.squareup.okhttp.Call verifyUserEmailValidateBeforeCall(String token, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - - // verify the required parameter 'token' is set - if (token == null) { - throw new ApiException("Missing the required parameter 'token' when calling verifyUserEmail(Async)"); - } - - - com.squareup.okhttp.Call call = verifyUserEmailCall(token, progressListener, progressRequestListener); - return call; - - - - - - } - - /** - * Verifies an email address using a token received via email. - * - * @param token The secret token received via email. (required) - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public void verifyUserEmail(String token) throws ApiException { - verifyUserEmailWithHttpInfo(token); - } - - /** - * Verifies an email address using a token received via email. - * - * @param token The secret token received via email. (required) - * @return ApiResponse<Void> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public ApiResponse verifyUserEmailWithHttpInfo(String token) throws ApiException { - com.squareup.okhttp.Call call = verifyUserEmailValidateBeforeCall(token, null, null); - return apiClient.execute(call); - } - - /** - * Verifies an email address using a token received via email. (asynchronously) - * - * @param token The secret token received via email. (required) - * @param callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - */ - public com.squareup.okhttp.Call verifyUserEmailAsync(String token, final ApiCallback callback) throws ApiException { - - ProgressResponseBody.ProgressListener progressListener = null; - ProgressRequestBody.ProgressRequestListener progressRequestListener = null; - - if (callback != null) { - progressListener = new ProgressResponseBody.ProgressListener() { - @Override - public void update(long bytesRead, long contentLength, boolean done) { - callback.onDownloadProgress(bytesRead, contentLength, done); - } - }; - - progressRequestListener = new ProgressRequestBody.ProgressRequestListener() { - @Override - public void onRequestProgress(long bytesWritten, long contentLength, boolean done) { - callback.onUploadProgress(bytesWritten, contentLength, done); - } - }; - } - - com.squareup.okhttp.Call call = verifyUserEmailValidateBeforeCall(token, progressListener, progressRequestListener); - apiClient.executeAsync(call, callback); - return call; - } -} diff --git a/testing/api-client/src/main/java/io/swagger/client/auth/ApiKeyAuth.java b/testing/api-client/src/main/java/io/swagger/client/auth/ApiKeyAuth.java deleted file mode 100644 index a981ee9..0000000 --- a/testing/api-client/src/main/java/io/swagger/client/auth/ApiKeyAuth.java +++ /dev/null @@ -1,75 +0,0 @@ -/* - * Maptology Service - * Maptology Service - * - * OpenAPI spec version: 0.0.1-SNAPSHOT - * Contact: nes-admin@uni-due.de - * - * NOTE: This class is auto generated by the swagger code generator program. - * https://github.com/swagger-api/swagger-codegen.git - * Do not edit the class manually. - */ - - -package io.swagger.client.auth; - -import io.swagger.client.Pair; - -import java.util.Map; -import java.util.List; - -@javax.annotation.Generated(value = "io.swagger.codegen.languages.JavaClientCodegen", date = "2018-01-25T01:26:31.138+01:00") -public class ApiKeyAuth implements Authentication { - private final String location; - private final String paramName; - - private String apiKey; - private String apiKeyPrefix; - - public ApiKeyAuth(String location, String paramName) { - this.location = location; - this.paramName = paramName; - } - - public String getLocation() { - return location; - } - - public String getParamName() { - return paramName; - } - - public String getApiKey() { - return apiKey; - } - - public void setApiKey(String apiKey) { - this.apiKey = apiKey; - } - - public String getApiKeyPrefix() { - return apiKeyPrefix; - } - - public void setApiKeyPrefix(String apiKeyPrefix) { - this.apiKeyPrefix = apiKeyPrefix; - } - - @Override - public void applyToParams(List queryParams, Map headerParams) { - if (apiKey == null) { - return; - } - String value; - if (apiKeyPrefix != null) { - value = apiKeyPrefix + " " + apiKey; - } else { - value = apiKey; - } - if ("query".equals(location)) { - queryParams.add(new Pair(paramName, value)); - } else if ("header".equals(location)) { - headerParams.put(paramName, value); - } - } -} diff --git a/testing/api-client/src/main/java/io/swagger/client/auth/Authentication.java b/testing/api-client/src/main/java/io/swagger/client/auth/Authentication.java deleted file mode 100644 index 9523ded..0000000 --- a/testing/api-client/src/main/java/io/swagger/client/auth/Authentication.java +++ /dev/null @@ -1,29 +0,0 @@ -/* - * Maptology Service - * Maptology Service - * - * OpenAPI spec version: 0.0.1-SNAPSHOT - * Contact: nes-admin@uni-due.de - * - * NOTE: This class is auto generated by the swagger code generator program. - * https://github.com/swagger-api/swagger-codegen.git - * Do not edit the class manually. - */ - - -package io.swagger.client.auth; - -import io.swagger.client.Pair; - -import java.util.Map; -import java.util.List; - -public interface Authentication { - /** - * Apply authentication settings to header and query params. - * - * @param queryParams List of query parameters - * @param headerParams Map of header parameters - */ - void applyToParams(List queryParams, Map headerParams); -} diff --git a/testing/api-client/src/main/java/io/swagger/client/auth/HttpBasicAuth.java b/testing/api-client/src/main/java/io/swagger/client/auth/HttpBasicAuth.java deleted file mode 100644 index 87573e6..0000000 --- a/testing/api-client/src/main/java/io/swagger/client/auth/HttpBasicAuth.java +++ /dev/null @@ -1,54 +0,0 @@ -/* - * Maptology Service - * Maptology Service - * - * OpenAPI spec version: 0.0.1-SNAPSHOT - * Contact: nes-admin@uni-due.de - * - * NOTE: This class is auto generated by the swagger code generator program. - * https://github.com/swagger-api/swagger-codegen.git - * Do not edit the class manually. - */ - - -package io.swagger.client.auth; - -import io.swagger.client.Pair; - -import com.squareup.okhttp.Credentials; - -import java.util.Map; -import java.util.List; - -import java.io.UnsupportedEncodingException; - -public class HttpBasicAuth implements Authentication { - private String username; - private String password; - - public String getUsername() { - return username; - } - - public void setUsername(String username) { - this.username = username; - } - - public String getPassword() { - return password; - } - - public void setPassword(String password) { - this.password = password; - } - - @Override - public void applyToParams(List queryParams, Map headerParams) { - if (username == null && password == null) { - return; - } - headerParams.put("Authorization", Credentials.basic( - username == null ? "" : username, - password == null ? "" : password)); - } -} diff --git a/testing/api-client/src/main/java/io/swagger/client/auth/OAuth.java b/testing/api-client/src/main/java/io/swagger/client/auth/OAuth.java deleted file mode 100644 index f3a29fd..0000000 --- a/testing/api-client/src/main/java/io/swagger/client/auth/OAuth.java +++ /dev/null @@ -1,39 +0,0 @@ -/* - * Maptology Service - * Maptology Service - * - * OpenAPI spec version: 0.0.1-SNAPSHOT - * Contact: nes-admin@uni-due.de - * - * NOTE: This class is auto generated by the swagger code generator program. - * https://github.com/swagger-api/swagger-codegen.git - * Do not edit the class manually. - */ - - -package io.swagger.client.auth; - -import io.swagger.client.Pair; - -import java.util.Map; -import java.util.List; - -@javax.annotation.Generated(value = "io.swagger.codegen.languages.JavaClientCodegen", date = "2018-01-25T01:26:31.138+01:00") -public class OAuth implements Authentication { - private String accessToken; - - public String getAccessToken() { - return accessToken; - } - - public void setAccessToken(String accessToken) { - this.accessToken = accessToken; - } - - @Override - public void applyToParams(List queryParams, Map headerParams) { - if (accessToken != null) { - headerParams.put("Authorization", "Bearer " + accessToken); - } - } -} diff --git a/testing/api-client/src/main/java/io/swagger/client/auth/OAuthFlow.java b/testing/api-client/src/main/java/io/swagger/client/auth/OAuthFlow.java deleted file mode 100644 index c3ad67a..0000000 --- a/testing/api-client/src/main/java/io/swagger/client/auth/OAuthFlow.java +++ /dev/null @@ -1,18 +0,0 @@ -/* - * Maptology Service - * Maptology Service - * - * OpenAPI spec version: 0.0.1-SNAPSHOT - * Contact: nes-admin@uni-due.de - * - * NOTE: This class is auto generated by the swagger code generator program. - * https://github.com/swagger-api/swagger-codegen.git - * Do not edit the class manually. - */ - - -package io.swagger.client.auth; - -public enum OAuthFlow { - accessCode, implicit, password, application -} diff --git a/testing/api-client/src/main/java/io/swagger/client/model/BuildVersion.java b/testing/api-client/src/main/java/io/swagger/client/model/BuildVersion.java deleted file mode 100644 index cdaba13..0000000 --- a/testing/api-client/src/main/java/io/swagger/client/model/BuildVersion.java +++ /dev/null @@ -1,163 +0,0 @@ -/* - * Maptology Service - * Maptology Service - * - * OpenAPI spec version: 0.0.1-SNAPSHOT - * Contact: nes-admin@uni-due.de - * - * NOTE: This class is auto generated by the swagger code generator program. - * https://github.com/swagger-api/swagger-codegen.git - * Do not edit the class manually. - */ - - -package io.swagger.client.model; - -import java.util.Objects; -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.JsonAdapter; -import com.google.gson.annotations.SerializedName; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; -import io.swagger.annotations.ApiModel; -import io.swagger.annotations.ApiModelProperty; -import java.io.IOException; - -/** - * Represents version information about the running build. - */ -@ApiModel(description = "Represents version information about the running build.") -@javax.annotation.Generated(value = "io.swagger.codegen.languages.JavaClientCodegen", date = "2018-01-25T01:26:31.138+01:00") -public class BuildVersion { - @SerializedName("time") - private Long time = null; - - @SerializedName("build") - private String build = null; - - @SerializedName("creator") - private String creator = null; - - @SerializedName("version") - private String version = null; - - public BuildVersion time(Long time) { - this.time = time; - return this; - } - - /** - * The build time in Epoch milliseconds. - * @return time - **/ - @ApiModelProperty(required = true, value = "The build time in Epoch milliseconds.") - public Long getTime() { - return time; - } - - public void setTime(Long time) { - this.time = time; - } - - public BuildVersion build(String build) { - this.build = build; - return this; - } - - /** - * The build number. - * @return build - **/ - @ApiModelProperty(required = true, value = "The build number.") - public String getBuild() { - return build; - } - - public void setBuild(String build) { - this.build = build; - } - - public BuildVersion creator(String creator) { - this.creator = creator; - return this; - } - - /** - * The creator of the build. - * @return creator - **/ - @ApiModelProperty(required = true, value = "The creator of the build.") - public String getCreator() { - return creator; - } - - public void setCreator(String creator) { - this.creator = creator; - } - - public BuildVersion version(String version) { - this.version = version; - return this; - } - - /** - * The version of the build. - * @return version - **/ - @ApiModelProperty(required = true, value = "The version of the build.") - public String getVersion() { - return version; - } - - public void setVersion(String version) { - this.version = version; - } - - - @Override - public boolean equals(java.lang.Object o) { - if (this == o) { - return true; - } - if (o == null || getClass() != o.getClass()) { - return false; - } - BuildVersion buildVersion = (BuildVersion) o; - return Objects.equals(this.time, buildVersion.time) && - Objects.equals(this.build, buildVersion.build) && - Objects.equals(this.creator, buildVersion.creator) && - Objects.equals(this.version, buildVersion.version); - } - - @Override - public int hashCode() { - return Objects.hash(time, build, creator, version); - } - - - @Override - public String toString() { - StringBuilder sb = new StringBuilder(); - sb.append("class BuildVersion {\n"); - - sb.append(" time: ").append(toIndentedString(time)).append("\n"); - sb.append(" build: ").append(toIndentedString(build)).append("\n"); - sb.append(" creator: ").append(toIndentedString(creator)).append("\n"); - sb.append(" version: ").append(toIndentedString(version)).append("\n"); - sb.append("}"); - return sb.toString(); - } - - /** - * Convert the given object to string with each line indented by 4 spaces - * (except the first line). - */ - private String toIndentedString(java.lang.Object o) { - if (o == null) { - return "null"; - } - return o.toString().replace("\n", "\n "); - } - -} - diff --git a/testing/api-client/src/main/java/io/swagger/client/model/Coordinate.java b/testing/api-client/src/main/java/io/swagger/client/model/Coordinate.java deleted file mode 100644 index 0d77099..0000000 --- a/testing/api-client/src/main/java/io/swagger/client/model/Coordinate.java +++ /dev/null @@ -1,121 +0,0 @@ -/* - * Maptology Service - * Maptology Service - * - * OpenAPI spec version: 0.0.1-SNAPSHOT - * Contact: nes-admin@uni-due.de - * - * NOTE: This class is auto generated by the swagger code generator program. - * https://github.com/swagger-api/swagger-codegen.git - * Do not edit the class manually. - */ - - -package io.swagger.client.model; - -import java.util.Objects; -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.JsonAdapter; -import com.google.gson.annotations.SerializedName; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; -import io.swagger.annotations.ApiModel; -import io.swagger.annotations.ApiModelProperty; -import java.io.IOException; - -/** - * Represents a WGS84 position. - */ -@ApiModel(description = "Represents a WGS84 position.") -@javax.annotation.Generated(value = "io.swagger.codegen.languages.JavaClientCodegen", date = "2018-01-25T01:26:31.138+01:00") -public class Coordinate { - @SerializedName("longitude") - private Double longitude = null; - - @SerializedName("latitude") - private Double latitude = null; - - public Coordinate longitude(Double longitude) { - this.longitude = longitude; - return this; - } - - /** - * The longitude of a location. - * minimum: -180 - * maximum: 180 - * @return longitude - **/ - @ApiModelProperty(required = true, value = "The longitude of a location.") - public Double getLongitude() { - return longitude; - } - - public void setLongitude(Double longitude) { - this.longitude = longitude; - } - - public Coordinate latitude(Double latitude) { - this.latitude = latitude; - return this; - } - - /** - * The latitude of a location. - * minimum: -90 - * maximum: 90 - * @return latitude - **/ - @ApiModelProperty(required = true, value = "The latitude of a location.") - public Double getLatitude() { - return latitude; - } - - public void setLatitude(Double latitude) { - this.latitude = latitude; - } - - - @Override - public boolean equals(java.lang.Object o) { - if (this == o) { - return true; - } - if (o == null || getClass() != o.getClass()) { - return false; - } - Coordinate coordinate = (Coordinate) o; - return Objects.equals(this.longitude, coordinate.longitude) && - Objects.equals(this.latitude, coordinate.latitude); - } - - @Override - public int hashCode() { - return Objects.hash(longitude, latitude); - } - - - @Override - public String toString() { - StringBuilder sb = new StringBuilder(); - sb.append("class Coordinate {\n"); - - sb.append(" longitude: ").append(toIndentedString(longitude)).append("\n"); - sb.append(" latitude: ").append(toIndentedString(latitude)).append("\n"); - sb.append("}"); - return sb.toString(); - } - - /** - * Convert the given object to string with each line indented by 4 spaces - * (except the first line). - */ - private String toIndentedString(java.lang.Object o) { - if (o == null) { - return "null"; - } - return o.toString().replace("\n", "\n "); - } - -} - diff --git a/testing/api-client/src/main/java/io/swagger/client/model/Device.java b/testing/api-client/src/main/java/io/swagger/client/model/Device.java deleted file mode 100644 index bac97cd..0000000 --- a/testing/api-client/src/main/java/io/swagger/client/model/Device.java +++ /dev/null @@ -1,298 +0,0 @@ -/* - * Maptology Service - * Maptology Service - * - * OpenAPI spec version: 0.0.1-SNAPSHOT - * Contact: nes-admin@uni-due.de - * - * NOTE: This class is auto generated by the swagger code generator program. - * https://github.com/swagger-api/swagger-codegen.git - * Do not edit the class manually. - */ - - -package io.swagger.client.model; - -import java.util.Objects; -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.JsonAdapter; -import com.google.gson.annotations.SerializedName; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; -import io.swagger.annotations.ApiModel; -import io.swagger.annotations.ApiModelProperty; -import java.io.IOException; - -/** - * Represents a device. - */ -@ApiModel(description = "Represents a device.") -@javax.annotation.Generated(value = "io.swagger.codegen.languages.JavaClientCodegen", date = "2018-01-25T01:26:31.138+01:00") -public class Device { - @SerializedName("id") - private Long id = null; - - @SerializedName("creationTime") - private Long creationTime = null; - - @SerializedName("modificationTime") - private Long modificationTime = null; - - @SerializedName("deleted") - private Boolean deleted = null; - - @SerializedName("user") - private Long user = null; - - /** - * The operating system. - */ - @JsonAdapter(OsEnum.Adapter.class) - public enum OsEnum { - ANDROID("ANDROID"), - - IOS("IOS"); - - private String value; - - OsEnum(String value) { - this.value = value; - } - - public String getValue() { - return value; - } - - @Override - public String toString() { - return String.valueOf(value); - } - - public static OsEnum fromValue(String text) { - for (OsEnum b : OsEnum.values()) { - if (String.valueOf(b.value).equals(text)) { - return b; - } - } - return null; - } - - public static class Adapter extends TypeAdapter { - @Override - public void write(final JsonWriter jsonWriter, final OsEnum enumeration) throws IOException { - jsonWriter.value(enumeration.getValue()); - } - - @Override - public OsEnum read(final JsonReader jsonReader) throws IOException { - String value = jsonReader.nextString(); - return OsEnum.fromValue(String.valueOf(value)); - } - } - } - - @SerializedName("os") - private OsEnum os = null; - - @SerializedName("manufacturer") - private String manufacturer = null; - - @SerializedName("device") - private String device = null; - - @SerializedName("model") - private String model = null; - - /** - * The unique identifier of the data. - * @return id - **/ - @ApiModelProperty(value = "The unique identifier of the data.") - public Long getId() { - return id; - } - - /** - * The time stamp when the data was created. - * @return creationTime - **/ - @ApiModelProperty(value = "The time stamp when the data was created.") - public Long getCreationTime() { - return creationTime; - } - - /** - * The time stamp when the data was created. - * @return modificationTime - **/ - @ApiModelProperty(value = "The time stamp when the data was created.") - public Long getModificationTime() { - return modificationTime; - } - - public Device deleted(Boolean deleted) { - this.deleted = deleted; - return this; - } - - /** - * A flag to indicate whether the data was deleted. - * @return deleted - **/ - @ApiModelProperty(value = "A flag to indicate whether the data was deleted.") - public Boolean getDeleted() { - return deleted; - } - - public void setDeleted(Boolean deleted) { - this.deleted = deleted; - } - - public Device user(Long user) { - this.user = user; - return this; - } - - /** - * The id of the owning user or null, if there is none. - * @return user - **/ - @ApiModelProperty(value = "The id of the owning user or null, if there is none.") - public Long getUser() { - return user; - } - - public void setUser(Long user) { - this.user = user; - } - - public Device os(OsEnum os) { - this.os = os; - return this; - } - - /** - * The operating system. - * @return os - **/ - @ApiModelProperty(required = true, value = "The operating system.") - public OsEnum getOs() { - return os; - } - - public void setOs(OsEnum os) { - this.os = os; - } - - public Device manufacturer(String manufacturer) { - this.manufacturer = manufacturer; - return this; - } - - /** - * The manufacturer name, see android.os.Build.MANUFACTURER. - * @return manufacturer - **/ - @ApiModelProperty(required = true, value = "The manufacturer name, see android.os.Build.MANUFACTURER.") - public String getManufacturer() { - return manufacturer; - } - - public void setManufacturer(String manufacturer) { - this.manufacturer = manufacturer; - } - - public Device device(String device) { - this.device = device; - return this; - } - - /** - * The device name, see android.os.Build.DEVICE. - * @return device - **/ - @ApiModelProperty(required = true, value = "The device name, see android.os.Build.DEVICE.") - public String getDevice() { - return device; - } - - public void setDevice(String device) { - this.device = device; - } - - public Device model(String model) { - this.model = model; - return this; - } - - /** - * The model name, see android.os.Build.MODEL. - * @return model - **/ - @ApiModelProperty(required = true, value = "The model name, see android.os.Build.MODEL.") - public String getModel() { - return model; - } - - public void setModel(String model) { - this.model = model; - } - - - @Override - public boolean equals(java.lang.Object o) { - if (this == o) { - return true; - } - if (o == null || getClass() != o.getClass()) { - return false; - } - Device device = (Device) o; - return Objects.equals(this.id, device.id) && - Objects.equals(this.creationTime, device.creationTime) && - Objects.equals(this.modificationTime, device.modificationTime) && - Objects.equals(this.deleted, device.deleted) && - Objects.equals(this.user, device.user) && - Objects.equals(this.os, device.os) && - Objects.equals(this.manufacturer, device.manufacturer) && - Objects.equals(this.device, device.device) && - Objects.equals(this.model, device.model); - } - - @Override - public int hashCode() { - return Objects.hash(id, creationTime, modificationTime, deleted, user, os, manufacturer, device, model); - } - - - @Override - public String toString() { - StringBuilder sb = new StringBuilder(); - sb.append("class Device {\n"); - - sb.append(" id: ").append(toIndentedString(id)).append("\n"); - sb.append(" creationTime: ").append(toIndentedString(creationTime)).append("\n"); - sb.append(" modificationTime: ").append(toIndentedString(modificationTime)).append("\n"); - sb.append(" deleted: ").append(toIndentedString(deleted)).append("\n"); - sb.append(" user: ").append(toIndentedString(user)).append("\n"); - sb.append(" os: ").append(toIndentedString(os)).append("\n"); - sb.append(" manufacturer: ").append(toIndentedString(manufacturer)).append("\n"); - sb.append(" device: ").append(toIndentedString(device)).append("\n"); - sb.append(" model: ").append(toIndentedString(model)).append("\n"); - sb.append("}"); - return sb.toString(); - } - - /** - * Convert the given object to string with each line indented by 4 spaces - * (except the first line). - */ - private String toIndentedString(java.lang.Object o) { - if (o == null) { - return "null"; - } - return o.toString().replace("\n", "\n "); - } - -} - diff --git a/testing/api-client/src/main/java/io/swagger/client/model/DeviceHandle.java b/testing/api-client/src/main/java/io/swagger/client/model/DeviceHandle.java deleted file mode 100644 index b2c2df5..0000000 --- a/testing/api-client/src/main/java/io/swagger/client/model/DeviceHandle.java +++ /dev/null @@ -1,321 +0,0 @@ -/* - * Maptology Service - * Maptology Service - * - * OpenAPI spec version: 0.0.1-SNAPSHOT - * Contact: nes-admin@uni-due.de - * - * NOTE: This class is auto generated by the swagger code generator program. - * https://github.com/swagger-api/swagger-codegen.git - * Do not edit the class manually. - */ - - -package io.swagger.client.model; - -import java.util.Objects; -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.JsonAdapter; -import com.google.gson.annotations.SerializedName; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; -import io.swagger.annotations.ApiModel; -import io.swagger.annotations.ApiModelProperty; -import java.io.IOException; - -/** - * Represents a device with a secret token. - */ -@ApiModel(description = "Represents a device with a secret token.") -@javax.annotation.Generated(value = "io.swagger.codegen.languages.JavaClientCodegen", date = "2018-01-25T01:26:31.138+01:00") -public class DeviceHandle { - @SerializedName("id") - private Long id = null; - - @SerializedName("creationTime") - private Long creationTime = null; - - @SerializedName("modificationTime") - private Long modificationTime = null; - - @SerializedName("deleted") - private Boolean deleted = null; - - @SerializedName("user") - private Long user = null; - - /** - * The operating system. - */ - @JsonAdapter(OsEnum.Adapter.class) - public enum OsEnum { - ANDROID("ANDROID"), - - IOS("IOS"); - - private String value; - - OsEnum(String value) { - this.value = value; - } - - public String getValue() { - return value; - } - - @Override - public String toString() { - return String.valueOf(value); - } - - public static OsEnum fromValue(String text) { - for (OsEnum b : OsEnum.values()) { - if (String.valueOf(b.value).equals(text)) { - return b; - } - } - return null; - } - - public static class Adapter extends TypeAdapter { - @Override - public void write(final JsonWriter jsonWriter, final OsEnum enumeration) throws IOException { - jsonWriter.value(enumeration.getValue()); - } - - @Override - public OsEnum read(final JsonReader jsonReader) throws IOException { - String value = jsonReader.nextString(); - return OsEnum.fromValue(String.valueOf(value)); - } - } - } - - @SerializedName("os") - private OsEnum os = null; - - @SerializedName("manufacturer") - private String manufacturer = null; - - @SerializedName("device") - private String device = null; - - @SerializedName("model") - private String model = null; - - @SerializedName("token") - private String token = null; - - /** - * The unique identifier of the data. - * @return id - **/ - @ApiModelProperty(value = "The unique identifier of the data.") - public Long getId() { - return id; - } - - /** - * The time stamp when the data was created. - * @return creationTime - **/ - @ApiModelProperty(value = "The time stamp when the data was created.") - public Long getCreationTime() { - return creationTime; - } - - /** - * The time stamp when the data was created. - * @return modificationTime - **/ - @ApiModelProperty(value = "The time stamp when the data was created.") - public Long getModificationTime() { - return modificationTime; - } - - public DeviceHandle deleted(Boolean deleted) { - this.deleted = deleted; - return this; - } - - /** - * A flag to indicate whether the data was deleted. - * @return deleted - **/ - @ApiModelProperty(value = "A flag to indicate whether the data was deleted.") - public Boolean getDeleted() { - return deleted; - } - - public void setDeleted(Boolean deleted) { - this.deleted = deleted; - } - - public DeviceHandle user(Long user) { - this.user = user; - return this; - } - - /** - * The id of the owning user or null, if there is none. - * @return user - **/ - @ApiModelProperty(value = "The id of the owning user or null, if there is none.") - public Long getUser() { - return user; - } - - public void setUser(Long user) { - this.user = user; - } - - public DeviceHandle os(OsEnum os) { - this.os = os; - return this; - } - - /** - * The operating system. - * @return os - **/ - @ApiModelProperty(required = true, value = "The operating system.") - public OsEnum getOs() { - return os; - } - - public void setOs(OsEnum os) { - this.os = os; - } - - public DeviceHandle manufacturer(String manufacturer) { - this.manufacturer = manufacturer; - return this; - } - - /** - * The manufacturer name, see android.os.Build.MANUFACTURER. - * @return manufacturer - **/ - @ApiModelProperty(required = true, value = "The manufacturer name, see android.os.Build.MANUFACTURER.") - public String getManufacturer() { - return manufacturer; - } - - public void setManufacturer(String manufacturer) { - this.manufacturer = manufacturer; - } - - public DeviceHandle device(String device) { - this.device = device; - return this; - } - - /** - * The device name, see android.os.Build.DEVICE. - * @return device - **/ - @ApiModelProperty(required = true, value = "The device name, see android.os.Build.DEVICE.") - public String getDevice() { - return device; - } - - public void setDevice(String device) { - this.device = device; - } - - public DeviceHandle model(String model) { - this.model = model; - return this; - } - - /** - * The model name, see android.os.Build.MODEL. - * @return model - **/ - @ApiModelProperty(required = true, value = "The model name, see android.os.Build.MODEL.") - public String getModel() { - return model; - } - - public void setModel(String model) { - this.model = model; - } - - public DeviceHandle token(String token) { - this.token = token; - return this; - } - - /** - * The secret token used for authenticating the device. - * @return token - **/ - @ApiModelProperty(required = true, value = "The secret token used for authenticating the device.") - public String getToken() { - return token; - } - - public void setToken(String token) { - this.token = token; - } - - - @Override - public boolean equals(java.lang.Object o) { - if (this == o) { - return true; - } - if (o == null || getClass() != o.getClass()) { - return false; - } - DeviceHandle deviceHandle = (DeviceHandle) o; - return Objects.equals(this.id, deviceHandle.id) && - Objects.equals(this.creationTime, deviceHandle.creationTime) && - Objects.equals(this.modificationTime, deviceHandle.modificationTime) && - Objects.equals(this.deleted, deviceHandle.deleted) && - Objects.equals(this.user, deviceHandle.user) && - Objects.equals(this.os, deviceHandle.os) && - Objects.equals(this.manufacturer, deviceHandle.manufacturer) && - Objects.equals(this.device, deviceHandle.device) && - Objects.equals(this.model, deviceHandle.model) && - Objects.equals(this.token, deviceHandle.token); - } - - @Override - public int hashCode() { - return Objects.hash(id, creationTime, modificationTime, deleted, user, os, manufacturer, device, model, token); - } - - - @Override - public String toString() { - StringBuilder sb = new StringBuilder(); - sb.append("class DeviceHandle {\n"); - - sb.append(" id: ").append(toIndentedString(id)).append("\n"); - sb.append(" creationTime: ").append(toIndentedString(creationTime)).append("\n"); - sb.append(" modificationTime: ").append(toIndentedString(modificationTime)).append("\n"); - sb.append(" deleted: ").append(toIndentedString(deleted)).append("\n"); - sb.append(" user: ").append(toIndentedString(user)).append("\n"); - sb.append(" os: ").append(toIndentedString(os)).append("\n"); - sb.append(" manufacturer: ").append(toIndentedString(manufacturer)).append("\n"); - sb.append(" device: ").append(toIndentedString(device)).append("\n"); - sb.append(" model: ").append(toIndentedString(model)).append("\n"); - sb.append(" token: ").append(toIndentedString(token)).append("\n"); - sb.append("}"); - return sb.toString(); - } - - /** - * Convert the given object to string with each line indented by 4 spaces - * (except the first line). - */ - private String toIndentedString(java.lang.Object o) { - if (o == null) { - return "null"; - } - return o.toString().replace("\n", "\n "); - } - -} - diff --git a/testing/api-client/src/main/java/io/swagger/client/model/DeviceInfo.java b/testing/api-client/src/main/java/io/swagger/client/model/DeviceInfo.java deleted file mode 100644 index cc73da5..0000000 --- a/testing/api-client/src/main/java/io/swagger/client/model/DeviceInfo.java +++ /dev/null @@ -1,210 +0,0 @@ -/* - * Maptology Service - * Maptology Service - * - * OpenAPI spec version: 0.0.1-SNAPSHOT - * Contact: nes-admin@uni-due.de - * - * NOTE: This class is auto generated by the swagger code generator program. - * https://github.com/swagger-api/swagger-codegen.git - * Do not edit the class manually. - */ - - -package io.swagger.client.model; - -import java.util.Objects; -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.JsonAdapter; -import com.google.gson.annotations.SerializedName; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; -import io.swagger.annotations.ApiModel; -import io.swagger.annotations.ApiModelProperty; -import java.io.IOException; - -/** - * Represents information about a device. - */ -@ApiModel(description = "Represents information about a device.") -@javax.annotation.Generated(value = "io.swagger.codegen.languages.JavaClientCodegen", date = "2018-01-25T01:26:31.138+01:00") -public class DeviceInfo { - /** - * The operating system. - */ - @JsonAdapter(OsEnum.Adapter.class) - public enum OsEnum { - ANDROID("ANDROID"), - - IOS("IOS"); - - private String value; - - OsEnum(String value) { - this.value = value; - } - - public String getValue() { - return value; - } - - @Override - public String toString() { - return String.valueOf(value); - } - - public static OsEnum fromValue(String text) { - for (OsEnum b : OsEnum.values()) { - if (String.valueOf(b.value).equals(text)) { - return b; - } - } - return null; - } - - public static class Adapter extends TypeAdapter { - @Override - public void write(final JsonWriter jsonWriter, final OsEnum enumeration) throws IOException { - jsonWriter.value(enumeration.getValue()); - } - - @Override - public OsEnum read(final JsonReader jsonReader) throws IOException { - String value = jsonReader.nextString(); - return OsEnum.fromValue(String.valueOf(value)); - } - } - } - - @SerializedName("os") - private OsEnum os = null; - - @SerializedName("manufacturer") - private String manufacturer = null; - - @SerializedName("device") - private String device = null; - - @SerializedName("model") - private String model = null; - - public DeviceInfo os(OsEnum os) { - this.os = os; - return this; - } - - /** - * The operating system. - * @return os - **/ - @ApiModelProperty(required = true, value = "The operating system.") - public OsEnum getOs() { - return os; - } - - public void setOs(OsEnum os) { - this.os = os; - } - - public DeviceInfo manufacturer(String manufacturer) { - this.manufacturer = manufacturer; - return this; - } - - /** - * The manufacturer name, see android.os.Build.MANUFACTURER. - * @return manufacturer - **/ - @ApiModelProperty(required = true, value = "The manufacturer name, see android.os.Build.MANUFACTURER.") - public String getManufacturer() { - return manufacturer; - } - - public void setManufacturer(String manufacturer) { - this.manufacturer = manufacturer; - } - - public DeviceInfo device(String device) { - this.device = device; - return this; - } - - /** - * The device name, see android.os.Build.DEVICE. - * @return device - **/ - @ApiModelProperty(required = true, value = "The device name, see android.os.Build.DEVICE.") - public String getDevice() { - return device; - } - - public void setDevice(String device) { - this.device = device; - } - - public DeviceInfo model(String model) { - this.model = model; - return this; - } - - /** - * The model name, see android.os.Build.MODEL. - * @return model - **/ - @ApiModelProperty(required = true, value = "The model name, see android.os.Build.MODEL.") - public String getModel() { - return model; - } - - public void setModel(String model) { - this.model = model; - } - - - @Override - public boolean equals(java.lang.Object o) { - if (this == o) { - return true; - } - if (o == null || getClass() != o.getClass()) { - return false; - } - DeviceInfo deviceInfo = (DeviceInfo) o; - return Objects.equals(this.os, deviceInfo.os) && - Objects.equals(this.manufacturer, deviceInfo.manufacturer) && - Objects.equals(this.device, deviceInfo.device) && - Objects.equals(this.model, deviceInfo.model); - } - - @Override - public int hashCode() { - return Objects.hash(os, manufacturer, device, model); - } - - - @Override - public String toString() { - StringBuilder sb = new StringBuilder(); - sb.append("class DeviceInfo {\n"); - - sb.append(" os: ").append(toIndentedString(os)).append("\n"); - sb.append(" manufacturer: ").append(toIndentedString(manufacturer)).append("\n"); - sb.append(" device: ").append(toIndentedString(device)).append("\n"); - sb.append(" model: ").append(toIndentedString(model)).append("\n"); - sb.append("}"); - return sb.toString(); - } - - /** - * Convert the given object to string with each line indented by 4 spaces - * (except the first line). - */ - private String toIndentedString(java.lang.Object o) { - if (o == null) { - return "null"; - } - return o.toString().replace("\n", "\n "); - } - -} - diff --git a/testing/api-client/src/main/java/io/swagger/client/model/DevicePage.java b/testing/api-client/src/main/java/io/swagger/client/model/DevicePage.java deleted file mode 100644 index d11309e..0000000 --- a/testing/api-client/src/main/java/io/swagger/client/model/DevicePage.java +++ /dev/null @@ -1,171 +0,0 @@ -/* - * Maptology Service - * Maptology Service - * - * OpenAPI spec version: 0.0.1-SNAPSHOT - * Contact: nes-admin@uni-due.de - * - * NOTE: This class is auto generated by the swagger code generator program. - * https://github.com/swagger-api/swagger-codegen.git - * Do not edit the class manually. - */ - - -package io.swagger.client.model; - -import java.util.Objects; -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.JsonAdapter; -import com.google.gson.annotations.SerializedName; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; -import io.swagger.annotations.ApiModel; -import io.swagger.annotations.ApiModelProperty; -import io.swagger.client.model.Device; -import java.io.IOException; -import java.util.ArrayList; -import java.util.List; - -/** - * Represents a page of devices. - */ -@ApiModel(description = "Represents a page of devices.") -@javax.annotation.Generated(value = "io.swagger.codegen.languages.JavaClientCodegen", date = "2018-01-25T01:26:31.138+01:00") -public class DevicePage { - @SerializedName("size") - private Integer size = null; - - @SerializedName("offset") - private Integer offset = null; - - @SerializedName("total") - private Integer total = null; - - @SerializedName("elements") - private List elements = new ArrayList(); - - public DevicePage size(Integer size) { - this.size = size; - return this; - } - - /** - * The maximum number of elements on the page. - * @return size - **/ - @ApiModelProperty(required = true, value = "The maximum number of elements on the page.") - public Integer getSize() { - return size; - } - - public void setSize(Integer size) { - this.size = size; - } - - public DevicePage offset(Integer offset) { - this.offset = offset; - return this; - } - - /** - * The page offset (0-based) in number of elements. - * @return offset - **/ - @ApiModelProperty(required = true, value = "The page offset (0-based) in number of elements.") - public Integer getOffset() { - return offset; - } - - public void setOffset(Integer offset) { - this.offset = offset; - } - - public DevicePage total(Integer total) { - this.total = total; - return this; - } - - /** - * The total number of elements available. - * @return total - **/ - @ApiModelProperty(required = true, value = "The total number of elements available.") - public Integer getTotal() { - return total; - } - - public void setTotal(Integer total) { - this.total = total; - } - - public DevicePage elements(List elements) { - this.elements = elements; - return this; - } - - public DevicePage addElementsItem(Device elementsItem) { - this.elements.add(elementsItem); - return this; - } - - /** - * The elements of the page. - * @return elements - **/ - @ApiModelProperty(required = true, value = "The elements of the page.") - public List getElements() { - return elements; - } - - public void setElements(List elements) { - this.elements = elements; - } - - - @Override - public boolean equals(java.lang.Object o) { - if (this == o) { - return true; - } - if (o == null || getClass() != o.getClass()) { - return false; - } - DevicePage devicePage = (DevicePage) o; - return Objects.equals(this.size, devicePage.size) && - Objects.equals(this.offset, devicePage.offset) && - Objects.equals(this.total, devicePage.total) && - Objects.equals(this.elements, devicePage.elements); - } - - @Override - public int hashCode() { - return Objects.hash(size, offset, total, elements); - } - - - @Override - public String toString() { - StringBuilder sb = new StringBuilder(); - sb.append("class DevicePage {\n"); - - sb.append(" size: ").append(toIndentedString(size)).append("\n"); - sb.append(" offset: ").append(toIndentedString(offset)).append("\n"); - sb.append(" total: ").append(toIndentedString(total)).append("\n"); - sb.append(" elements: ").append(toIndentedString(elements)).append("\n"); - sb.append("}"); - return sb.toString(); - } - - /** - * Convert the given object to string with each line indented by 4 spaces - * (except the first line). - */ - private String toIndentedString(java.lang.Object o) { - if (o == null) { - return "null"; - } - return o.toString().replace("\n", "\n "); - } - -} - diff --git a/testing/api-client/src/main/java/io/swagger/client/model/Email.java b/testing/api-client/src/main/java/io/swagger/client/model/Email.java deleted file mode 100644 index f3737fa..0000000 --- a/testing/api-client/src/main/java/io/swagger/client/model/Email.java +++ /dev/null @@ -1,205 +0,0 @@ -/* - * Maptology Service - * Maptology Service - * - * OpenAPI spec version: 0.0.1-SNAPSHOT - * Contact: nes-admin@uni-due.de - * - * NOTE: This class is auto generated by the swagger code generator program. - * https://github.com/swagger-api/swagger-codegen.git - * Do not edit the class manually. - */ - - -package io.swagger.client.model; - -import java.util.Objects; -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.JsonAdapter; -import com.google.gson.annotations.SerializedName; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; -import io.swagger.annotations.ApiModel; -import io.swagger.annotations.ApiModelProperty; -import java.io.IOException; - -/** - * Represents a user. - */ -@ApiModel(description = "Represents a user.") -@javax.annotation.Generated(value = "io.swagger.codegen.languages.JavaClientCodegen", date = "2018-01-25T01:26:31.138+01:00") -public class Email { - @SerializedName("id") - private Long id = null; - - @SerializedName("creationTime") - private Long creationTime = null; - - @SerializedName("modificationTime") - private Long modificationTime = null; - - @SerializedName("deleted") - private Boolean deleted = null; - - @SerializedName("address") - private String address = null; - - @SerializedName("correspondence") - private Boolean correspondence = null; - - @SerializedName("verified") - private Boolean verified = null; - - /** - * The unique identifier of the data. - * @return id - **/ - @ApiModelProperty(value = "The unique identifier of the data.") - public Long getId() { - return id; - } - - /** - * The time stamp when the data was created. - * @return creationTime - **/ - @ApiModelProperty(value = "The time stamp when the data was created.") - public Long getCreationTime() { - return creationTime; - } - - /** - * The time stamp when the data was created. - * @return modificationTime - **/ - @ApiModelProperty(value = "The time stamp when the data was created.") - public Long getModificationTime() { - return modificationTime; - } - - public Email deleted(Boolean deleted) { - this.deleted = deleted; - return this; - } - - /** - * A flag to indicate whether the data was deleted. - * @return deleted - **/ - @ApiModelProperty(value = "A flag to indicate whether the data was deleted.") - public Boolean getDeleted() { - return deleted; - } - - public void setDeleted(Boolean deleted) { - this.deleted = deleted; - } - - public Email address(String address) { - this.address = address; - return this; - } - - /** - * The email address. - * @return address - **/ - @ApiModelProperty(required = true, value = "The email address.") - public String getAddress() { - return address; - } - - public void setAddress(String address) { - this.address = address; - } - - public Email correspondence(Boolean correspondence) { - this.correspondence = correspondence; - return this; - } - - /** - * A flag to mark the email address as primary email. - * @return correspondence - **/ - @ApiModelProperty(required = true, value = "A flag to mark the email address as primary email.") - public Boolean getCorrespondence() { - return correspondence; - } - - public void setCorrespondence(Boolean correspondence) { - this.correspondence = correspondence; - } - - public Email verified(Boolean verified) { - this.verified = verified; - return this; - } - - /** - * A flag to mark the email address as verified. - * @return verified - **/ - @ApiModelProperty(required = true, value = "A flag to mark the email address as verified.") - public Boolean getVerified() { - return verified; - } - - public void setVerified(Boolean verified) { - this.verified = verified; - } - - - @Override - public boolean equals(java.lang.Object o) { - if (this == o) { - return true; - } - if (o == null || getClass() != o.getClass()) { - return false; - } - Email email = (Email) o; - return Objects.equals(this.id, email.id) && - Objects.equals(this.creationTime, email.creationTime) && - Objects.equals(this.modificationTime, email.modificationTime) && - Objects.equals(this.deleted, email.deleted) && - Objects.equals(this.address, email.address) && - Objects.equals(this.correspondence, email.correspondence) && - Objects.equals(this.verified, email.verified); - } - - @Override - public int hashCode() { - return Objects.hash(id, creationTime, modificationTime, deleted, address, correspondence, verified); - } - - - @Override - public String toString() { - StringBuilder sb = new StringBuilder(); - sb.append("class Email {\n"); - - sb.append(" id: ").append(toIndentedString(id)).append("\n"); - sb.append(" creationTime: ").append(toIndentedString(creationTime)).append("\n"); - sb.append(" modificationTime: ").append(toIndentedString(modificationTime)).append("\n"); - sb.append(" deleted: ").append(toIndentedString(deleted)).append("\n"); - sb.append(" address: ").append(toIndentedString(address)).append("\n"); - sb.append(" correspondence: ").append(toIndentedString(correspondence)).append("\n"); - sb.append(" verified: ").append(toIndentedString(verified)).append("\n"); - sb.append("}"); - return sb.toString(); - } - - /** - * Convert the given object to string with each line indented by 4 spaces - * (except the first line). - */ - private String toIndentedString(java.lang.Object o) { - if (o == null) { - return "null"; - } - return o.toString().replace("\n", "\n "); - } - -} - diff --git a/testing/api-client/src/main/java/io/swagger/client/model/EntityStatistic.java b/testing/api-client/src/main/java/io/swagger/client/model/EntityStatistic.java deleted file mode 100644 index 70e9dad..0000000 --- a/testing/api-client/src/main/java/io/swagger/client/model/EntityStatistic.java +++ /dev/null @@ -1,140 +0,0 @@ -/* - * Maptology Service - * Maptology Service - * - * OpenAPI spec version: 0.0.1-SNAPSHOT - * Contact: nes-admin@uni-due.de - * - * NOTE: This class is auto generated by the swagger code generator program. - * https://github.com/swagger-api/swagger-codegen.git - * Do not edit the class manually. - */ - - -package io.swagger.client.model; - -import java.util.Objects; -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.JsonAdapter; -import com.google.gson.annotations.SerializedName; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; -import io.swagger.annotations.ApiModel; -import io.swagger.annotations.ApiModelProperty; -import java.io.IOException; - -/** - * Represents statistics about peristent entities. - */ -@ApiModel(description = "Represents statistics about peristent entities.") -@javax.annotation.Generated(value = "io.swagger.codegen.languages.JavaClientCodegen", date = "2018-01-25T01:26:31.138+01:00") -public class EntityStatistic { - @SerializedName("name") - private String name = null; - - @SerializedName("total") - private Long total = null; - - @SerializedName("deleted") - private Long deleted = null; - - public EntityStatistic name(String name) { - this.name = name; - return this; - } - - /** - * The name of the entity. - * @return name - **/ - @ApiModelProperty(required = true, value = "The name of the entity.") - public String getName() { - return name; - } - - public void setName(String name) { - this.name = name; - } - - public EntityStatistic total(Long total) { - this.total = total; - return this; - } - - /** - * The total number of stored entities. - * @return total - **/ - @ApiModelProperty(required = true, value = "The total number of stored entities.") - public Long getTotal() { - return total; - } - - public void setTotal(Long total) { - this.total = total; - } - - public EntityStatistic deleted(Long deleted) { - this.deleted = deleted; - return this; - } - - /** - * The number of deleted entities. - * @return deleted - **/ - @ApiModelProperty(required = true, value = "The number of deleted entities.") - public Long getDeleted() { - return deleted; - } - - public void setDeleted(Long deleted) { - this.deleted = deleted; - } - - - @Override - public boolean equals(java.lang.Object o) { - if (this == o) { - return true; - } - if (o == null || getClass() != o.getClass()) { - return false; - } - EntityStatistic entityStatistic = (EntityStatistic) o; - return Objects.equals(this.name, entityStatistic.name) && - Objects.equals(this.total, entityStatistic.total) && - Objects.equals(this.deleted, entityStatistic.deleted); - } - - @Override - public int hashCode() { - return Objects.hash(name, total, deleted); - } - - - @Override - public String toString() { - StringBuilder sb = new StringBuilder(); - sb.append("class EntityStatistic {\n"); - - sb.append(" name: ").append(toIndentedString(name)).append("\n"); - sb.append(" total: ").append(toIndentedString(total)).append("\n"); - sb.append(" deleted: ").append(toIndentedString(deleted)).append("\n"); - sb.append("}"); - return sb.toString(); - } - - /** - * Convert the given object to string with each line indented by 4 spaces - * (except the first line). - */ - private String toIndentedString(java.lang.Object o) { - if (o == null) { - return "null"; - } - return o.toString().replace("\n", "\n "); - } - -} - diff --git a/testing/api-client/src/main/java/io/swagger/client/model/LoadStatistic.java b/testing/api-client/src/main/java/io/swagger/client/model/LoadStatistic.java deleted file mode 100644 index 2d527de..0000000 --- a/testing/api-client/src/main/java/io/swagger/client/model/LoadStatistic.java +++ /dev/null @@ -1,255 +0,0 @@ -/* - * Maptology Service - * Maptology Service - * - * OpenAPI spec version: 0.0.1-SNAPSHOT - * Contact: nes-admin@uni-due.de - * - * NOTE: This class is auto generated by the swagger code generator program. - * https://github.com/swagger-api/swagger-codegen.git - * Do not edit the class manually. - */ - - -package io.swagger.client.model; - -import java.util.Objects; -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.JsonAdapter; -import com.google.gson.annotations.SerializedName; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; -import io.swagger.annotations.ApiModel; -import io.swagger.annotations.ApiModelProperty; -import java.io.IOException; - -/** - * Represents statistics about the system usage. - */ -@ApiModel(description = "Represents statistics about the system usage.") -@javax.annotation.Generated(value = "io.swagger.codegen.languages.JavaClientCodegen", date = "2018-01-25T01:26:31.138+01:00") -public class LoadStatistic { - @SerializedName("cpuLoad") - private Double cpuLoad = null; - - @SerializedName("uptime") - private Long uptime = null; - - @SerializedName("gcCount") - private Long gcCount = null; - - @SerializedName("gcDuration") - private Long gcDuration = null; - - @SerializedName("maxHeapSize") - private Long maxHeapSize = null; - - @SerializedName("usedHeapSize") - private Long usedHeapSize = null; - - @SerializedName("maxNonHeapSize") - private Long maxNonHeapSize = null; - - @SerializedName("usedNonHeapSize") - private Long usedNonHeapSize = null; - - public LoadStatistic cpuLoad(Double cpuLoad) { - this.cpuLoad = cpuLoad; - return this; - } - - /** - * The average cpu load over the last minute. - * @return cpuLoad - **/ - @ApiModelProperty(required = true, value = "The average cpu load over the last minute.") - public Double getCpuLoad() { - return cpuLoad; - } - - public void setCpuLoad(Double cpuLoad) { - this.cpuLoad = cpuLoad; - } - - public LoadStatistic uptime(Long uptime) { - this.uptime = uptime; - return this; - } - - /** - * The uptime of the jvm in milliseconds. - * @return uptime - **/ - @ApiModelProperty(required = true, value = "The uptime of the jvm in milliseconds.") - public Long getUptime() { - return uptime; - } - - public void setUptime(Long uptime) { - this.uptime = uptime; - } - - public LoadStatistic gcCount(Long gcCount) { - this.gcCount = gcCount; - return this; - } - - /** - * The total number of garbage collector executions. - * @return gcCount - **/ - @ApiModelProperty(required = true, value = "The total number of garbage collector executions.") - public Long getGcCount() { - return gcCount; - } - - public void setGcCount(Long gcCount) { - this.gcCount = gcCount; - } - - public LoadStatistic gcDuration(Long gcDuration) { - this.gcDuration = gcDuration; - return this; - } - - /** - * The total time for garbage collection in milliseconds. - * @return gcDuration - **/ - @ApiModelProperty(required = true, value = "The total time for garbage collection in milliseconds.") - public Long getGcDuration() { - return gcDuration; - } - - public void setGcDuration(Long gcDuration) { - this.gcDuration = gcDuration; - } - - public LoadStatistic maxHeapSize(Long maxHeapSize) { - this.maxHeapSize = maxHeapSize; - return this; - } - - /** - * The maximum heap size available in bytes. - * @return maxHeapSize - **/ - @ApiModelProperty(required = true, value = "The maximum heap size available in bytes.") - public Long getMaxHeapSize() { - return maxHeapSize; - } - - public void setMaxHeapSize(Long maxHeapSize) { - this.maxHeapSize = maxHeapSize; - } - - public LoadStatistic usedHeapSize(Long usedHeapSize) { - this.usedHeapSize = usedHeapSize; - return this; - } - - /** - * The used heap size available in bytes. - * @return usedHeapSize - **/ - @ApiModelProperty(required = true, value = "The used heap size available in bytes.") - public Long getUsedHeapSize() { - return usedHeapSize; - } - - public void setUsedHeapSize(Long usedHeapSize) { - this.usedHeapSize = usedHeapSize; - } - - public LoadStatistic maxNonHeapSize(Long maxNonHeapSize) { - this.maxNonHeapSize = maxNonHeapSize; - return this; - } - - /** - * The maximum non heap size available in bytes. - * @return maxNonHeapSize - **/ - @ApiModelProperty(required = true, value = "The maximum non heap size available in bytes.") - public Long getMaxNonHeapSize() { - return maxNonHeapSize; - } - - public void setMaxNonHeapSize(Long maxNonHeapSize) { - this.maxNonHeapSize = maxNonHeapSize; - } - - public LoadStatistic usedNonHeapSize(Long usedNonHeapSize) { - this.usedNonHeapSize = usedNonHeapSize; - return this; - } - - /** - * The used non heap size available in bytes. - * @return usedNonHeapSize - **/ - @ApiModelProperty(required = true, value = "The used non heap size available in bytes.") - public Long getUsedNonHeapSize() { - return usedNonHeapSize; - } - - public void setUsedNonHeapSize(Long usedNonHeapSize) { - this.usedNonHeapSize = usedNonHeapSize; - } - - - @Override - public boolean equals(java.lang.Object o) { - if (this == o) { - return true; - } - if (o == null || getClass() != o.getClass()) { - return false; - } - LoadStatistic loadStatistic = (LoadStatistic) o; - return Objects.equals(this.cpuLoad, loadStatistic.cpuLoad) && - Objects.equals(this.uptime, loadStatistic.uptime) && - Objects.equals(this.gcCount, loadStatistic.gcCount) && - Objects.equals(this.gcDuration, loadStatistic.gcDuration) && - Objects.equals(this.maxHeapSize, loadStatistic.maxHeapSize) && - Objects.equals(this.usedHeapSize, loadStatistic.usedHeapSize) && - Objects.equals(this.maxNonHeapSize, loadStatistic.maxNonHeapSize) && - Objects.equals(this.usedNonHeapSize, loadStatistic.usedNonHeapSize); - } - - @Override - public int hashCode() { - return Objects.hash(cpuLoad, uptime, gcCount, gcDuration, maxHeapSize, usedHeapSize, maxNonHeapSize, usedNonHeapSize); - } - - - @Override - public String toString() { - StringBuilder sb = new StringBuilder(); - sb.append("class LoadStatistic {\n"); - - sb.append(" cpuLoad: ").append(toIndentedString(cpuLoad)).append("\n"); - sb.append(" uptime: ").append(toIndentedString(uptime)).append("\n"); - sb.append(" gcCount: ").append(toIndentedString(gcCount)).append("\n"); - sb.append(" gcDuration: ").append(toIndentedString(gcDuration)).append("\n"); - sb.append(" maxHeapSize: ").append(toIndentedString(maxHeapSize)).append("\n"); - sb.append(" usedHeapSize: ").append(toIndentedString(usedHeapSize)).append("\n"); - sb.append(" maxNonHeapSize: ").append(toIndentedString(maxNonHeapSize)).append("\n"); - sb.append(" usedNonHeapSize: ").append(toIndentedString(usedNonHeapSize)).append("\n"); - sb.append("}"); - return sb.toString(); - } - - /** - * Convert the given object to string with each line indented by 4 spaces - * (except the first line). - */ - private String toIndentedString(java.lang.Object o) { - if (o == null) { - return "null"; - } - return o.toString().replace("\n", "\n "); - } - -} - diff --git a/testing/api-client/src/main/java/io/swagger/client/model/Location.java b/testing/api-client/src/main/java/io/swagger/client/model/Location.java deleted file mode 100644 index ab2eded..0000000 --- a/testing/api-client/src/main/java/io/swagger/client/model/Location.java +++ /dev/null @@ -1,192 +0,0 @@ -/* - * Maptology Service - * Maptology Service - * - * OpenAPI spec version: 0.0.1-SNAPSHOT - * Contact: nes-admin@uni-due.de - * - * NOTE: This class is auto generated by the swagger code generator program. - * https://github.com/swagger-api/swagger-codegen.git - * Do not edit the class manually. - */ - - -package io.swagger.client.model; - -import java.util.Objects; -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.JsonAdapter; -import com.google.gson.annotations.SerializedName; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; -import io.swagger.annotations.ApiModel; -import io.swagger.annotations.ApiModelProperty; -import io.swagger.client.model.Coordinate; -import java.io.IOException; - -/** - * Represents a location. - */ -@ApiModel(description = "Represents a location.") -@javax.annotation.Generated(value = "io.swagger.codegen.languages.JavaClientCodegen", date = "2018-01-25T01:26:31.138+01:00") -public class Location { - @SerializedName("timestamp") - private Long timestamp = null; - - @SerializedName("coordinate") - private Coordinate coordinate = null; - - /** - * The availability information of the location. - */ - @JsonAdapter(AvailabilityEnum.Adapter.class) - public enum AvailabilityEnum { - FRESH("FRESH"), - - CACHED("CACHED"), - - UNABLE("UNABLE"), - - PRIVATE("PRIVATE"); - - private String value; - - AvailabilityEnum(String value) { - this.value = value; - } - - public String getValue() { - return value; - } - - @Override - public String toString() { - return String.valueOf(value); - } - - public static AvailabilityEnum fromValue(String text) { - for (AvailabilityEnum b : AvailabilityEnum.values()) { - if (String.valueOf(b.value).equals(text)) { - return b; - } - } - return null; - } - - public static class Adapter extends TypeAdapter { - @Override - public void write(final JsonWriter jsonWriter, final AvailabilityEnum enumeration) throws IOException { - jsonWriter.value(enumeration.getValue()); - } - - @Override - public AvailabilityEnum read(final JsonReader jsonReader) throws IOException { - String value = jsonReader.nextString(); - return AvailabilityEnum.fromValue(String.valueOf(value)); - } - } - } - - @SerializedName("availability") - private AvailabilityEnum availability = null; - - public Location timestamp(Long timestamp) { - this.timestamp = timestamp; - return this; - } - - /** - * The timestamp of the location. - * @return timestamp - **/ - @ApiModelProperty(required = true, value = "The timestamp of the location.") - public Long getTimestamp() { - return timestamp; - } - - public void setTimestamp(Long timestamp) { - this.timestamp = timestamp; - } - - public Location coordinate(Coordinate coordinate) { - this.coordinate = coordinate; - return this; - } - - /** - * The coordinate of the location. - * @return coordinate - **/ - @ApiModelProperty(value = "The coordinate of the location.") - public Coordinate getCoordinate() { - return coordinate; - } - - public void setCoordinate(Coordinate coordinate) { - this.coordinate = coordinate; - } - - public Location availability(AvailabilityEnum availability) { - this.availability = availability; - return this; - } - - /** - * The availability information of the location. - * @return availability - **/ - @ApiModelProperty(required = true, value = "The availability information of the location.") - public AvailabilityEnum getAvailability() { - return availability; - } - - public void setAvailability(AvailabilityEnum availability) { - this.availability = availability; - } - - - @Override - public boolean equals(java.lang.Object o) { - if (this == o) { - return true; - } - if (o == null || getClass() != o.getClass()) { - return false; - } - Location location = (Location) o; - return Objects.equals(this.timestamp, location.timestamp) && - Objects.equals(this.coordinate, location.coordinate) && - Objects.equals(this.availability, location.availability); - } - - @Override - public int hashCode() { - return Objects.hash(timestamp, coordinate, availability); - } - - - @Override - public String toString() { - StringBuilder sb = new StringBuilder(); - sb.append("class Location {\n"); - - sb.append(" timestamp: ").append(toIndentedString(timestamp)).append("\n"); - sb.append(" coordinate: ").append(toIndentedString(coordinate)).append("\n"); - sb.append(" availability: ").append(toIndentedString(availability)).append("\n"); - sb.append("}"); - return sb.toString(); - } - - /** - * Convert the given object to string with each line indented by 4 spaces - * (except the first line). - */ - private String toIndentedString(java.lang.Object o) { - if (o == null) { - return "null"; - } - return o.toString().replace("\n", "\n "); - } - -} - diff --git a/testing/api-client/src/main/java/io/swagger/client/model/LocationUpdate.java b/testing/api-client/src/main/java/io/swagger/client/model/LocationUpdate.java deleted file mode 100644 index fda4fa5..0000000 --- a/testing/api-client/src/main/java/io/swagger/client/model/LocationUpdate.java +++ /dev/null @@ -1,102 +0,0 @@ -/* - * Maptology Service - * Maptology Service - * - * OpenAPI spec version: 0.0.1-SNAPSHOT - * Contact: nes-admin@uni-due.de - * - * NOTE: This class is auto generated by the swagger code generator program. - * https://github.com/swagger-api/swagger-codegen.git - * Do not edit the class manually. - */ - - -package io.swagger.client.model; - -import java.util.Objects; -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.JsonAdapter; -import com.google.gson.annotations.SerializedName; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; -import io.swagger.annotations.ApiModel; -import io.swagger.annotations.ApiModelProperty; -import io.swagger.client.model.ReleasedLocation; -import java.io.IOException; -import java.util.ArrayList; -import java.util.List; - -/** - * Represents a location update conisting of a batch of locations. - */ -@ApiModel(description = "Represents a location update conisting of a batch of locations.") -@javax.annotation.Generated(value = "io.swagger.codegen.languages.JavaClientCodegen", date = "2018-01-25T01:26:31.138+01:00") -public class LocationUpdate { - @SerializedName("locations") - private List locations = new ArrayList(); - - public LocationUpdate locations(List locations) { - this.locations = locations; - return this; - } - - public LocationUpdate addLocationsItem(ReleasedLocation locationsItem) { - this.locations.add(locationsItem); - return this; - } - - /** - * The locations released with this update. - * @return locations - **/ - @ApiModelProperty(required = true, value = "The locations released with this update.") - public List getLocations() { - return locations; - } - - public void setLocations(List locations) { - this.locations = locations; - } - - - @Override - public boolean equals(java.lang.Object o) { - if (this == o) { - return true; - } - if (o == null || getClass() != o.getClass()) { - return false; - } - LocationUpdate locationUpdate = (LocationUpdate) o; - return Objects.equals(this.locations, locationUpdate.locations); - } - - @Override - public int hashCode() { - return Objects.hash(locations); - } - - - @Override - public String toString() { - StringBuilder sb = new StringBuilder(); - sb.append("class LocationUpdate {\n"); - - sb.append(" locations: ").append(toIndentedString(locations)).append("\n"); - sb.append("}"); - return sb.toString(); - } - - /** - * Convert the given object to string with each line indented by 4 spaces - * (except the first line). - */ - private String toIndentedString(java.lang.Object o) { - if (o == null) { - return "null"; - } - return o.toString().replace("\n", "\n "); - } - -} - diff --git a/testing/api-client/src/main/java/io/swagger/client/model/LogMessage.java b/testing/api-client/src/main/java/io/swagger/client/model/LogMessage.java deleted file mode 100644 index 0b8c5cf..0000000 --- a/testing/api-client/src/main/java/io/swagger/client/model/LogMessage.java +++ /dev/null @@ -1,278 +0,0 @@ -/* - * Maptology Service - * Maptology Service - * - * OpenAPI spec version: 0.0.1-SNAPSHOT - * Contact: nes-admin@uni-due.de - * - * NOTE: This class is auto generated by the swagger code generator program. - * https://github.com/swagger-api/swagger-codegen.git - * Do not edit the class manually. - */ - - -package io.swagger.client.model; - -import java.util.Objects; -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.JsonAdapter; -import com.google.gson.annotations.SerializedName; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; -import io.swagger.annotations.ApiModel; -import io.swagger.annotations.ApiModelProperty; -import java.io.IOException; - -/** - * Represents a log message. - */ -@ApiModel(description = "Represents a log message.") -@javax.annotation.Generated(value = "io.swagger.codegen.languages.JavaClientCodegen", date = "2018-01-25T01:26:31.138+01:00") -public class LogMessage { - @SerializedName("id") - private Long id = null; - - @SerializedName("time") - private Long time = null; - - @SerializedName("thread") - private Integer thread = null; - - @SerializedName("level") - private String level = null; - - @SerializedName("loggerName") - private String loggerName = null; - - @SerializedName("className") - private String className = null; - - @SerializedName("methodName") - private String methodName = null; - - @SerializedName("message") - private String message = null; - - @SerializedName("trace") - private String trace = null; - - public LogMessage id(Long id) { - this.id = id; - return this; - } - - /** - * An auto-generated sequential id. - * @return id - **/ - @ApiModelProperty(required = true, value = "An auto-generated sequential id.") - public Long getId() { - return id; - } - - public void setId(Long id) { - this.id = id; - } - - public LogMessage time(Long time) { - this.time = time; - return this; - } - - /** - * The creation time in Epoch milliseconds. - * @return time - **/ - @ApiModelProperty(required = true, value = "The creation time in Epoch milliseconds.") - public Long getTime() { - return time; - } - - public void setTime(Long time) { - this.time = time; - } - - public LogMessage thread(Integer thread) { - this.thread = thread; - return this; - } - - /** - * The id of the thread. - * @return thread - **/ - @ApiModelProperty(required = true, value = "The id of the thread.") - public Integer getThread() { - return thread; - } - - public void setThread(Integer thread) { - this.thread = thread; - } - - public LogMessage level(String level) { - this.level = level; - return this; - } - - /** - * The message severity. - * @return level - **/ - @ApiModelProperty(required = true, value = "The message severity.") - public String getLevel() { - return level; - } - - public void setLevel(String level) { - this.level = level; - } - - public LogMessage loggerName(String loggerName) { - this.loggerName = loggerName; - return this; - } - - /** - * The name of the logger. - * @return loggerName - **/ - @ApiModelProperty(required = true, value = "The name of the logger.") - public String getLoggerName() { - return loggerName; - } - - public void setLoggerName(String loggerName) { - this.loggerName = loggerName; - } - - public LogMessage className(String className) { - this.className = className; - return this; - } - - /** - * The name of the class. - * @return className - **/ - @ApiModelProperty(required = true, value = "The name of the class.") - public String getClassName() { - return className; - } - - public void setClassName(String className) { - this.className = className; - } - - public LogMessage methodName(String methodName) { - this.methodName = methodName; - return this; - } - - /** - * The name of the method. - * @return methodName - **/ - @ApiModelProperty(required = true, value = "The name of the method.") - public String getMethodName() { - return methodName; - } - - public void setMethodName(String methodName) { - this.methodName = methodName; - } - - public LogMessage message(String message) { - this.message = message; - return this; - } - - /** - * The actual (optional) message. - * @return message - **/ - @ApiModelProperty(value = "The actual (optional) message.") - public String getMessage() { - return message; - } - - public void setMessage(String message) { - this.message = message; - } - - public LogMessage trace(String trace) { - this.trace = trace; - return this; - } - - /** - * An optional stack trace. - * @return trace - **/ - @ApiModelProperty(value = "An optional stack trace.") - public String getTrace() { - return trace; - } - - public void setTrace(String trace) { - this.trace = trace; - } - - - @Override - public boolean equals(java.lang.Object o) { - if (this == o) { - return true; - } - if (o == null || getClass() != o.getClass()) { - return false; - } - LogMessage logMessage = (LogMessage) o; - return Objects.equals(this.id, logMessage.id) && - Objects.equals(this.time, logMessage.time) && - Objects.equals(this.thread, logMessage.thread) && - Objects.equals(this.level, logMessage.level) && - Objects.equals(this.loggerName, logMessage.loggerName) && - Objects.equals(this.className, logMessage.className) && - Objects.equals(this.methodName, logMessage.methodName) && - Objects.equals(this.message, logMessage.message) && - Objects.equals(this.trace, logMessage.trace); - } - - @Override - public int hashCode() { - return Objects.hash(id, time, thread, level, loggerName, className, methodName, message, trace); - } - - - @Override - public String toString() { - StringBuilder sb = new StringBuilder(); - sb.append("class LogMessage {\n"); - - sb.append(" id: ").append(toIndentedString(id)).append("\n"); - sb.append(" time: ").append(toIndentedString(time)).append("\n"); - sb.append(" thread: ").append(toIndentedString(thread)).append("\n"); - sb.append(" level: ").append(toIndentedString(level)).append("\n"); - sb.append(" loggerName: ").append(toIndentedString(loggerName)).append("\n"); - sb.append(" className: ").append(toIndentedString(className)).append("\n"); - sb.append(" methodName: ").append(toIndentedString(methodName)).append("\n"); - sb.append(" message: ").append(toIndentedString(message)).append("\n"); - sb.append(" trace: ").append(toIndentedString(trace)).append("\n"); - sb.append("}"); - return sb.toString(); - } - - /** - * Convert the given object to string with each line indented by 4 spaces - * (except the first line). - */ - private String toIndentedString(java.lang.Object o) { - if (o == null) { - return "null"; - } - return o.toString().replace("\n", "\n "); - } - -} - diff --git a/testing/api-client/src/main/java/io/swagger/client/model/Message.java b/testing/api-client/src/main/java/io/swagger/client/model/Message.java deleted file mode 100644 index 49cae5b..0000000 --- a/testing/api-client/src/main/java/io/swagger/client/model/Message.java +++ /dev/null @@ -1,193 +0,0 @@ -/* - * Maptology Service - * Maptology Service - * - * OpenAPI spec version: 0.0.1-SNAPSHOT - * Contact: nes-admin@uni-due.de - * - * NOTE: This class is auto generated by the swagger code generator program. - * https://github.com/swagger-api/swagger-codegen.git - * Do not edit the class manually. - */ - - -package io.swagger.client.model; - -import java.util.Objects; -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.JsonAdapter; -import com.google.gson.annotations.SerializedName; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; -import io.swagger.annotations.ApiModel; -import io.swagger.annotations.ApiModelProperty; -import java.io.IOException; - -/** - * Represents a message in a particular language. - */ -@ApiModel(description = "Represents a message in a particular language.") -@javax.annotation.Generated(value = "io.swagger.codegen.languages.JavaClientCodegen", date = "2018-01-25T01:26:31.138+01:00") -public class Message { - @SerializedName("title") - private String title = null; - - @SerializedName("body") - private String body = null; - - /** - * The two letter language code in lower case. - */ - @JsonAdapter(LanguageEnum.Adapter.class) - public enum LanguageEnum { - DE("de"), - - EN("en"), - - FR("fr"), - - IT("it"), - - ES("es"); - - private String value; - - LanguageEnum(String value) { - this.value = value; - } - - public String getValue() { - return value; - } - - @Override - public String toString() { - return String.valueOf(value); - } - - public static LanguageEnum fromValue(String text) { - for (LanguageEnum b : LanguageEnum.values()) { - if (String.valueOf(b.value).equals(text)) { - return b; - } - } - return null; - } - - public static class Adapter extends TypeAdapter { - @Override - public void write(final JsonWriter jsonWriter, final LanguageEnum enumeration) throws IOException { - jsonWriter.value(enumeration.getValue()); - } - - @Override - public LanguageEnum read(final JsonReader jsonReader) throws IOException { - String value = jsonReader.nextString(); - return LanguageEnum.fromValue(String.valueOf(value)); - } - } - } - - @SerializedName("language") - private LanguageEnum language = null; - - public Message title(String title) { - this.title = title; - return this; - } - - /** - * The message title. - * @return title - **/ - @ApiModelProperty(required = true, value = "The message title.") - public String getTitle() { - return title; - } - - public void setTitle(String title) { - this.title = title; - } - - public Message body(String body) { - this.body = body; - return this; - } - - /** - * The message body. - * @return body - **/ - @ApiModelProperty(required = true, value = " The message body.") - public String getBody() { - return body; - } - - public void setBody(String body) { - this.body = body; - } - - public Message language(LanguageEnum language) { - this.language = language; - return this; - } - - /** - * The two letter language code in lower case. - * @return language - **/ - @ApiModelProperty(value = "The two letter language code in lower case.") - public LanguageEnum getLanguage() { - return language; - } - - public void setLanguage(LanguageEnum language) { - this.language = language; - } - - - @Override - public boolean equals(java.lang.Object o) { - if (this == o) { - return true; - } - if (o == null || getClass() != o.getClass()) { - return false; - } - Message message = (Message) o; - return Objects.equals(this.title, message.title) && - Objects.equals(this.body, message.body) && - Objects.equals(this.language, message.language); - } - - @Override - public int hashCode() { - return Objects.hash(title, body, language); - } - - - @Override - public String toString() { - StringBuilder sb = new StringBuilder(); - sb.append("class Message {\n"); - - sb.append(" title: ").append(toIndentedString(title)).append("\n"); - sb.append(" body: ").append(toIndentedString(body)).append("\n"); - sb.append(" language: ").append(toIndentedString(language)).append("\n"); - sb.append("}"); - return sb.toString(); - } - - /** - * Convert the given object to string with each line indented by 4 spaces - * (except the first line). - */ - private String toIndentedString(java.lang.Object o) { - if (o == null) { - return "null"; - } - return o.toString().replace("\n", "\n "); - } - -} - diff --git a/testing/api-client/src/main/java/io/swagger/client/model/Notice.java b/testing/api-client/src/main/java/io/swagger/client/model/Notice.java deleted file mode 100644 index e714e10..0000000 --- a/testing/api-client/src/main/java/io/swagger/client/model/Notice.java +++ /dev/null @@ -1,284 +0,0 @@ -/* - * Maptology Service - * Maptology Service - * - * OpenAPI spec version: 0.0.1-SNAPSHOT - * Contact: nes-admin@uni-due.de - * - * NOTE: This class is auto generated by the swagger code generator program. - * https://github.com/swagger-api/swagger-codegen.git - * Do not edit the class manually. - */ - - -package io.swagger.client.model; - -import java.util.Objects; -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.JsonAdapter; -import com.google.gson.annotations.SerializedName; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; -import io.swagger.annotations.ApiModel; -import io.swagger.annotations.ApiModelProperty; -import io.swagger.client.model.Message; -import java.io.IOException; -import java.util.ArrayList; -import java.util.List; - -/** - * Represents a multi-lingual notice. - */ -@ApiModel(description = "Represents a multi-lingual notice.") -@javax.annotation.Generated(value = "io.swagger.codegen.languages.JavaClientCodegen", date = "2018-01-25T01:26:31.138+01:00") -public class Notice { - @SerializedName("id") - private Long id = null; - - @SerializedName("creationTime") - private Long creationTime = null; - - @SerializedName("modificationTime") - private Long modificationTime = null; - - @SerializedName("deleted") - private Boolean deleted = null; - - @SerializedName("announced") - private Boolean announced = null; - - @SerializedName("published") - private Boolean published = null; - - @SerializedName("minimumVersion") - private Integer minimumVersion = null; - - @SerializedName("maximumVersion") - private Integer maximumVersion = null; - - @SerializedName("expirationTime") - private Long expirationTime = null; - - @SerializedName("messages") - private List messages = new ArrayList(); - - /** - * The unique identifier of the data. - * @return id - **/ - @ApiModelProperty(value = "The unique identifier of the data.") - public Long getId() { - return id; - } - - /** - * The time stamp when the data was created. - * @return creationTime - **/ - @ApiModelProperty(value = "The time stamp when the data was created.") - public Long getCreationTime() { - return creationTime; - } - - /** - * The time stamp when the data was created. - * @return modificationTime - **/ - @ApiModelProperty(value = "The time stamp when the data was created.") - public Long getModificationTime() { - return modificationTime; - } - - public Notice deleted(Boolean deleted) { - this.deleted = deleted; - return this; - } - - /** - * A flag to indicate whether the data was deleted. - * @return deleted - **/ - @ApiModelProperty(value = "A flag to indicate whether the data was deleted.") - public Boolean getDeleted() { - return deleted; - } - - public void setDeleted(Boolean deleted) { - this.deleted = deleted; - } - - public Notice announced(Boolean announced) { - this.announced = announced; - return this; - } - - /** - * A flag to indicate whether the message should be announced. - * @return announced - **/ - @ApiModelProperty(required = true, value = "A flag to indicate whether the message should be announced.") - public Boolean getAnnounced() { - return announced; - } - - public void setAnnounced(Boolean announced) { - this.announced = announced; - } - - public Notice published(Boolean published) { - this.published = published; - return this; - } - - /** - * A flag to indicate whether the message is published. - * @return published - **/ - @ApiModelProperty(required = true, value = "A flag to indicate whether the message is published.") - public Boolean getPublished() { - return published; - } - - public void setPublished(Boolean published) { - this.published = published; - } - - public Notice minimumVersion(Integer minimumVersion) { - this.minimumVersion = minimumVersion; - return this; - } - - /** - * The minimum app version to display the message or null. - * minimum: 0 - * @return minimumVersion - **/ - @ApiModelProperty(value = "The minimum app version to display the message or null.") - public Integer getMinimumVersion() { - return minimumVersion; - } - - public void setMinimumVersion(Integer minimumVersion) { - this.minimumVersion = minimumVersion; - } - - public Notice maximumVersion(Integer maximumVersion) { - this.maximumVersion = maximumVersion; - return this; - } - - /** - * The maximum app version to display the message or null. - * minimum: 0 - * @return maximumVersion - **/ - @ApiModelProperty(value = "The maximum app version to display the message or null.") - public Integer getMaximumVersion() { - return maximumVersion; - } - - public void setMaximumVersion(Integer maximumVersion) { - this.maximumVersion = maximumVersion; - } - - public Notice expirationTime(Long expirationTime) { - this.expirationTime = expirationTime; - return this; - } - - /** - * The expiration time in epoch milliseconds. - * @return expirationTime - **/ - @ApiModelProperty(required = true, value = "The expiration time in epoch milliseconds.") - public Long getExpirationTime() { - return expirationTime; - } - - public void setExpirationTime(Long expirationTime) { - this.expirationTime = expirationTime; - } - - public Notice messages(List messages) { - this.messages = messages; - return this; - } - - public Notice addMessagesItem(Message messagesItem) { - this.messages.add(messagesItem); - return this; - } - - /** - * The list of translated messages. - * @return messages - **/ - @ApiModelProperty(required = true, value = "The list of translated messages.") - public List getMessages() { - return messages; - } - - public void setMessages(List messages) { - this.messages = messages; - } - - - @Override - public boolean equals(java.lang.Object o) { - if (this == o) { - return true; - } - if (o == null || getClass() != o.getClass()) { - return false; - } - Notice notice = (Notice) o; - return Objects.equals(this.id, notice.id) && - Objects.equals(this.creationTime, notice.creationTime) && - Objects.equals(this.modificationTime, notice.modificationTime) && - Objects.equals(this.deleted, notice.deleted) && - Objects.equals(this.announced, notice.announced) && - Objects.equals(this.published, notice.published) && - Objects.equals(this.minimumVersion, notice.minimumVersion) && - Objects.equals(this.maximumVersion, notice.maximumVersion) && - Objects.equals(this.expirationTime, notice.expirationTime) && - Objects.equals(this.messages, notice.messages); - } - - @Override - public int hashCode() { - return Objects.hash(id, creationTime, modificationTime, deleted, announced, published, minimumVersion, maximumVersion, expirationTime, messages); - } - - - @Override - public String toString() { - StringBuilder sb = new StringBuilder(); - sb.append("class Notice {\n"); - - sb.append(" id: ").append(toIndentedString(id)).append("\n"); - sb.append(" creationTime: ").append(toIndentedString(creationTime)).append("\n"); - sb.append(" modificationTime: ").append(toIndentedString(modificationTime)).append("\n"); - sb.append(" deleted: ").append(toIndentedString(deleted)).append("\n"); - sb.append(" announced: ").append(toIndentedString(announced)).append("\n"); - sb.append(" published: ").append(toIndentedString(published)).append("\n"); - sb.append(" minimumVersion: ").append(toIndentedString(minimumVersion)).append("\n"); - sb.append(" maximumVersion: ").append(toIndentedString(maximumVersion)).append("\n"); - sb.append(" expirationTime: ").append(toIndentedString(expirationTime)).append("\n"); - sb.append(" messages: ").append(toIndentedString(messages)).append("\n"); - sb.append("}"); - return sb.toString(); - } - - /** - * Convert the given object to string with each line indented by 4 spaces - * (except the first line). - */ - private String toIndentedString(java.lang.Object o) { - if (o == null) { - return "null"; - } - return o.toString().replace("\n", "\n "); - } - -} - diff --git a/testing/api-client/src/main/java/io/swagger/client/model/NoticePage.java b/testing/api-client/src/main/java/io/swagger/client/model/NoticePage.java deleted file mode 100644 index c4c7743..0000000 --- a/testing/api-client/src/main/java/io/swagger/client/model/NoticePage.java +++ /dev/null @@ -1,171 +0,0 @@ -/* - * Maptology Service - * Maptology Service - * - * OpenAPI spec version: 0.0.1-SNAPSHOT - * Contact: nes-admin@uni-due.de - * - * NOTE: This class is auto generated by the swagger code generator program. - * https://github.com/swagger-api/swagger-codegen.git - * Do not edit the class manually. - */ - - -package io.swagger.client.model; - -import java.util.Objects; -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.JsonAdapter; -import com.google.gson.annotations.SerializedName; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; -import io.swagger.annotations.ApiModel; -import io.swagger.annotations.ApiModelProperty; -import io.swagger.client.model.Notice; -import java.io.IOException; -import java.util.ArrayList; -import java.util.List; - -/** - * Represents a page of notices. - */ -@ApiModel(description = "Represents a page of notices.") -@javax.annotation.Generated(value = "io.swagger.codegen.languages.JavaClientCodegen", date = "2018-01-25T01:26:31.138+01:00") -public class NoticePage { - @SerializedName("size") - private Integer size = null; - - @SerializedName("offset") - private Integer offset = null; - - @SerializedName("total") - private Integer total = null; - - @SerializedName("elements") - private List elements = new ArrayList(); - - public NoticePage size(Integer size) { - this.size = size; - return this; - } - - /** - * The maximum number of elements on the page. - * @return size - **/ - @ApiModelProperty(required = true, value = "The maximum number of elements on the page.") - public Integer getSize() { - return size; - } - - public void setSize(Integer size) { - this.size = size; - } - - public NoticePage offset(Integer offset) { - this.offset = offset; - return this; - } - - /** - * The page offset (0-based) in number of elements. - * @return offset - **/ - @ApiModelProperty(required = true, value = "The page offset (0-based) in number of elements.") - public Integer getOffset() { - return offset; - } - - public void setOffset(Integer offset) { - this.offset = offset; - } - - public NoticePage total(Integer total) { - this.total = total; - return this; - } - - /** - * The total number of elements available. - * @return total - **/ - @ApiModelProperty(required = true, value = "The total number of elements available.") - public Integer getTotal() { - return total; - } - - public void setTotal(Integer total) { - this.total = total; - } - - public NoticePage elements(List elements) { - this.elements = elements; - return this; - } - - public NoticePage addElementsItem(Notice elementsItem) { - this.elements.add(elementsItem); - return this; - } - - /** - * The elements of the page. - * @return elements - **/ - @ApiModelProperty(required = true, value = "The elements of the page.") - public List getElements() { - return elements; - } - - public void setElements(List elements) { - this.elements = elements; - } - - - @Override - public boolean equals(java.lang.Object o) { - if (this == o) { - return true; - } - if (o == null || getClass() != o.getClass()) { - return false; - } - NoticePage noticePage = (NoticePage) o; - return Objects.equals(this.size, noticePage.size) && - Objects.equals(this.offset, noticePage.offset) && - Objects.equals(this.total, noticePage.total) && - Objects.equals(this.elements, noticePage.elements); - } - - @Override - public int hashCode() { - return Objects.hash(size, offset, total, elements); - } - - - @Override - public String toString() { - StringBuilder sb = new StringBuilder(); - sb.append("class NoticePage {\n"); - - sb.append(" size: ").append(toIndentedString(size)).append("\n"); - sb.append(" offset: ").append(toIndentedString(offset)).append("\n"); - sb.append(" total: ").append(toIndentedString(total)).append("\n"); - sb.append(" elements: ").append(toIndentedString(elements)).append("\n"); - sb.append("}"); - return sb.toString(); - } - - /** - * Convert the given object to string with each line indented by 4 spaces - * (except the first line). - */ - private String toIndentedString(java.lang.Object o) { - if (o == null) { - return "null"; - } - return o.toString().replace("\n", "\n "); - } - -} - diff --git a/testing/api-client/src/main/java/io/swagger/client/model/Place.java b/testing/api-client/src/main/java/io/swagger/client/model/Place.java deleted file mode 100644 index 12530f0..0000000 --- a/testing/api-client/src/main/java/io/swagger/client/model/Place.java +++ /dev/null @@ -1,206 +0,0 @@ -/* - * Maptology Service - * Maptology Service - * - * OpenAPI spec version: 0.0.1-SNAPSHOT - * Contact: nes-admin@uni-due.de - * - * NOTE: This class is auto generated by the swagger code generator program. - * https://github.com/swagger-api/swagger-codegen.git - * Do not edit the class manually. - */ - - -package io.swagger.client.model; - -import java.util.Objects; -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.JsonAdapter; -import com.google.gson.annotations.SerializedName; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; -import io.swagger.annotations.ApiModel; -import io.swagger.annotations.ApiModelProperty; -import io.swagger.client.model.Coordinate; -import java.io.IOException; - -/** - * Represents a place. - */ -@ApiModel(description = "Represents a place.") -@javax.annotation.Generated(value = "io.swagger.codegen.languages.JavaClientCodegen", date = "2018-01-25T01:26:31.138+01:00") -public class Place { - @SerializedName("id") - private Long id = null; - - @SerializedName("creationTime") - private Long creationTime = null; - - @SerializedName("modificationTime") - private Long modificationTime = null; - - @SerializedName("deleted") - private Boolean deleted = null; - - @SerializedName("coordinate") - private Coordinate coordinate = null; - - @SerializedName("address") - private String address = null; - - @SerializedName("nickname") - private String nickname = null; - - /** - * The unique identifier of the data. - * @return id - **/ - @ApiModelProperty(value = "The unique identifier of the data.") - public Long getId() { - return id; - } - - /** - * The time stamp when the data was created. - * @return creationTime - **/ - @ApiModelProperty(value = "The time stamp when the data was created.") - public Long getCreationTime() { - return creationTime; - } - - /** - * The time stamp when the data was created. - * @return modificationTime - **/ - @ApiModelProperty(value = "The time stamp when the data was created.") - public Long getModificationTime() { - return modificationTime; - } - - public Place deleted(Boolean deleted) { - this.deleted = deleted; - return this; - } - - /** - * A flag to indicate whether the data was deleted. - * @return deleted - **/ - @ApiModelProperty(value = "A flag to indicate whether the data was deleted.") - public Boolean getDeleted() { - return deleted; - } - - public void setDeleted(Boolean deleted) { - this.deleted = deleted; - } - - public Place coordinate(Coordinate coordinate) { - this.coordinate = coordinate; - return this; - } - - /** - * The coordinate of the place. - * @return coordinate - **/ - @ApiModelProperty(value = "The coordinate of the place.") - public Coordinate getCoordinate() { - return coordinate; - } - - public void setCoordinate(Coordinate coordinate) { - this.coordinate = coordinate; - } - - public Place address(String address) { - this.address = address; - return this; - } - - /** - * An automatically resolved address for the coordinate. - * @return address - **/ - @ApiModelProperty(value = "An automatically resolved address for the coordinate.") - public String getAddress() { - return address; - } - - public void setAddress(String address) { - this.address = address; - } - - public Place nickname(String nickname) { - this.nickname = nickname; - return this; - } - - /** - * A nickname for the place assigned by the user. - * @return nickname - **/ - @ApiModelProperty(value = "A nickname for the place assigned by the user.") - public String getNickname() { - return nickname; - } - - public void setNickname(String nickname) { - this.nickname = nickname; - } - - - @Override - public boolean equals(java.lang.Object o) { - if (this == o) { - return true; - } - if (o == null || getClass() != o.getClass()) { - return false; - } - Place place = (Place) o; - return Objects.equals(this.id, place.id) && - Objects.equals(this.creationTime, place.creationTime) && - Objects.equals(this.modificationTime, place.modificationTime) && - Objects.equals(this.deleted, place.deleted) && - Objects.equals(this.coordinate, place.coordinate) && - Objects.equals(this.address, place.address) && - Objects.equals(this.nickname, place.nickname); - } - - @Override - public int hashCode() { - return Objects.hash(id, creationTime, modificationTime, deleted, coordinate, address, nickname); - } - - - @Override - public String toString() { - StringBuilder sb = new StringBuilder(); - sb.append("class Place {\n"); - - sb.append(" id: ").append(toIndentedString(id)).append("\n"); - sb.append(" creationTime: ").append(toIndentedString(creationTime)).append("\n"); - sb.append(" modificationTime: ").append(toIndentedString(modificationTime)).append("\n"); - sb.append(" deleted: ").append(toIndentedString(deleted)).append("\n"); - sb.append(" coordinate: ").append(toIndentedString(coordinate)).append("\n"); - sb.append(" address: ").append(toIndentedString(address)).append("\n"); - sb.append(" nickname: ").append(toIndentedString(nickname)).append("\n"); - sb.append("}"); - return sb.toString(); - } - - /** - * Convert the given object to string with each line indented by 4 spaces - * (except the first line). - */ - private String toIndentedString(java.lang.Object o) { - if (o == null) { - return "null"; - } - return o.toString().replace("\n", "\n "); - } - -} - diff --git a/testing/api-client/src/main/java/io/swagger/client/model/PlacePage.java b/testing/api-client/src/main/java/io/swagger/client/model/PlacePage.java deleted file mode 100644 index a8142dc..0000000 --- a/testing/api-client/src/main/java/io/swagger/client/model/PlacePage.java +++ /dev/null @@ -1,171 +0,0 @@ -/* - * Maptology Service - * Maptology Service - * - * OpenAPI spec version: 0.0.1-SNAPSHOT - * Contact: nes-admin@uni-due.de - * - * NOTE: This class is auto generated by the swagger code generator program. - * https://github.com/swagger-api/swagger-codegen.git - * Do not edit the class manually. - */ - - -package io.swagger.client.model; - -import java.util.Objects; -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.JsonAdapter; -import com.google.gson.annotations.SerializedName; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; -import io.swagger.annotations.ApiModel; -import io.swagger.annotations.ApiModelProperty; -import io.swagger.client.model.Place; -import java.io.IOException; -import java.util.ArrayList; -import java.util.List; - -/** - * Represents a page of places. - */ -@ApiModel(description = "Represents a page of places.") -@javax.annotation.Generated(value = "io.swagger.codegen.languages.JavaClientCodegen", date = "2018-01-25T01:26:31.138+01:00") -public class PlacePage { - @SerializedName("size") - private Integer size = null; - - @SerializedName("offset") - private Integer offset = null; - - @SerializedName("total") - private Integer total = null; - - @SerializedName("elements") - private List elements = new ArrayList(); - - public PlacePage size(Integer size) { - this.size = size; - return this; - } - - /** - * The maximum number of elements on the page. - * @return size - **/ - @ApiModelProperty(required = true, value = "The maximum number of elements on the page.") - public Integer getSize() { - return size; - } - - public void setSize(Integer size) { - this.size = size; - } - - public PlacePage offset(Integer offset) { - this.offset = offset; - return this; - } - - /** - * The page offset (0-based) in number of elements. - * @return offset - **/ - @ApiModelProperty(required = true, value = "The page offset (0-based) in number of elements.") - public Integer getOffset() { - return offset; - } - - public void setOffset(Integer offset) { - this.offset = offset; - } - - public PlacePage total(Integer total) { - this.total = total; - return this; - } - - /** - * The total number of elements available. - * @return total - **/ - @ApiModelProperty(required = true, value = "The total number of elements available.") - public Integer getTotal() { - return total; - } - - public void setTotal(Integer total) { - this.total = total; - } - - public PlacePage elements(List elements) { - this.elements = elements; - return this; - } - - public PlacePage addElementsItem(Place elementsItem) { - this.elements.add(elementsItem); - return this; - } - - /** - * The elements of the page. - * @return elements - **/ - @ApiModelProperty(required = true, value = "The elements of the page.") - public List getElements() { - return elements; - } - - public void setElements(List elements) { - this.elements = elements; - } - - - @Override - public boolean equals(java.lang.Object o) { - if (this == o) { - return true; - } - if (o == null || getClass() != o.getClass()) { - return false; - } - PlacePage placePage = (PlacePage) o; - return Objects.equals(this.size, placePage.size) && - Objects.equals(this.offset, placePage.offset) && - Objects.equals(this.total, placePage.total) && - Objects.equals(this.elements, placePage.elements); - } - - @Override - public int hashCode() { - return Objects.hash(size, offset, total, elements); - } - - - @Override - public String toString() { - StringBuilder sb = new StringBuilder(); - sb.append("class PlacePage {\n"); - - sb.append(" size: ").append(toIndentedString(size)).append("\n"); - sb.append(" offset: ").append(toIndentedString(offset)).append("\n"); - sb.append(" total: ").append(toIndentedString(total)).append("\n"); - sb.append(" elements: ").append(toIndentedString(elements)).append("\n"); - sb.append("}"); - return sb.toString(); - } - - /** - * Convert the given object to string with each line indented by 4 spaces - * (except the first line). - */ - private String toIndentedString(java.lang.Object o) { - if (o == null) { - return "null"; - } - return o.toString().replace("\n", "\n "); - } - -} - diff --git a/testing/api-client/src/main/java/io/swagger/client/model/Privilege.java b/testing/api-client/src/main/java/io/swagger/client/model/Privilege.java deleted file mode 100644 index 97ac431..0000000 --- a/testing/api-client/src/main/java/io/swagger/client/model/Privilege.java +++ /dev/null @@ -1,183 +0,0 @@ -/* - * Maptology Service - * Maptology Service - * - * OpenAPI spec version: 0.0.1-SNAPSHOT - * Contact: nes-admin@uni-due.de - * - * NOTE: This class is auto generated by the swagger code generator program. - * https://github.com/swagger-api/swagger-codegen.git - * Do not edit the class manually. - */ - - -package io.swagger.client.model; - -import java.util.Objects; -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.JsonAdapter; -import com.google.gson.annotations.SerializedName; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; -import io.swagger.annotations.ApiModel; -import io.swagger.annotations.ApiModelProperty; -import io.swagger.client.model.ShareInfo; -import java.io.IOException; - -/** - * Represents an entity. - */ -@ApiModel(description = "Represents an entity.") -@javax.annotation.Generated(value = "io.swagger.codegen.languages.JavaClientCodegen", date = "2018-01-25T01:26:31.138+01:00") -public class Privilege { - @SerializedName("id") - private Long id = null; - - @SerializedName("creationTime") - private Long creationTime = null; - - @SerializedName("modificationTime") - private Long modificationTime = null; - - @SerializedName("deleted") - private Boolean deleted = null; - - @SerializedName("shareInfo") - private ShareInfo shareInfo = null; - - @SerializedName("token") - private String token = null; - - /** - * The unique identifier of the data. - * @return id - **/ - @ApiModelProperty(value = "The unique identifier of the data.") - public Long getId() { - return id; - } - - /** - * The time stamp when the data was created. - * @return creationTime - **/ - @ApiModelProperty(value = "The time stamp when the data was created.") - public Long getCreationTime() { - return creationTime; - } - - /** - * The time stamp when the data was created. - * @return modificationTime - **/ - @ApiModelProperty(value = "The time stamp when the data was created.") - public Long getModificationTime() { - return modificationTime; - } - - public Privilege deleted(Boolean deleted) { - this.deleted = deleted; - return this; - } - - /** - * A flag to indicate whether the data was deleted. - * @return deleted - **/ - @ApiModelProperty(value = "A flag to indicate whether the data was deleted.") - public Boolean getDeleted() { - return deleted; - } - - public void setDeleted(Boolean deleted) { - this.deleted = deleted; - } - - public Privilege shareInfo(ShareInfo shareInfo) { - this.shareInfo = shareInfo; - return this; - } - - /** - * The share info of the privilege. - * @return shareInfo - **/ - @ApiModelProperty(value = "The share info of the privilege.") - public ShareInfo getShareInfo() { - return shareInfo; - } - - public void setShareInfo(ShareInfo shareInfo) { - this.shareInfo = shareInfo; - } - - public Privilege token(String token) { - this.token = token; - return this; - } - - /** - * The token used to get the privilege. - * @return token - **/ - @ApiModelProperty(value = "The token used to get the privilege.") - public String getToken() { - return token; - } - - public void setToken(String token) { - this.token = token; - } - - - @Override - public boolean equals(java.lang.Object o) { - if (this == o) { - return true; - } - if (o == null || getClass() != o.getClass()) { - return false; - } - Privilege privilege = (Privilege) o; - return Objects.equals(this.id, privilege.id) && - Objects.equals(this.creationTime, privilege.creationTime) && - Objects.equals(this.modificationTime, privilege.modificationTime) && - Objects.equals(this.deleted, privilege.deleted) && - Objects.equals(this.shareInfo, privilege.shareInfo) && - Objects.equals(this.token, privilege.token); - } - - @Override - public int hashCode() { - return Objects.hash(id, creationTime, modificationTime, deleted, shareInfo, token); - } - - - @Override - public String toString() { - StringBuilder sb = new StringBuilder(); - sb.append("class Privilege {\n"); - - sb.append(" id: ").append(toIndentedString(id)).append("\n"); - sb.append(" creationTime: ").append(toIndentedString(creationTime)).append("\n"); - sb.append(" modificationTime: ").append(toIndentedString(modificationTime)).append("\n"); - sb.append(" deleted: ").append(toIndentedString(deleted)).append("\n"); - sb.append(" shareInfo: ").append(toIndentedString(shareInfo)).append("\n"); - sb.append(" token: ").append(toIndentedString(token)).append("\n"); - sb.append("}"); - return sb.toString(); - } - - /** - * Convert the given object to string with each line indented by 4 spaces - * (except the first line). - */ - private String toIndentedString(java.lang.Object o) { - if (o == null) { - return "null"; - } - return o.toString().replace("\n", "\n "); - } - -} - diff --git a/testing/api-client/src/main/java/io/swagger/client/model/PrivilegePage.java b/testing/api-client/src/main/java/io/swagger/client/model/PrivilegePage.java deleted file mode 100644 index 30186b4..0000000 --- a/testing/api-client/src/main/java/io/swagger/client/model/PrivilegePage.java +++ /dev/null @@ -1,171 +0,0 @@ -/* - * Maptology Service - * Maptology Service - * - * OpenAPI spec version: 0.0.1-SNAPSHOT - * Contact: nes-admin@uni-due.de - * - * NOTE: This class is auto generated by the swagger code generator program. - * https://github.com/swagger-api/swagger-codegen.git - * Do not edit the class manually. - */ - - -package io.swagger.client.model; - -import java.util.Objects; -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.JsonAdapter; -import com.google.gson.annotations.SerializedName; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; -import io.swagger.annotations.ApiModel; -import io.swagger.annotations.ApiModelProperty; -import io.swagger.client.model.Privilege; -import java.io.IOException; -import java.util.ArrayList; -import java.util.List; - -/** - * A page of privilges - */ -@ApiModel(description = "A page of privilges") -@javax.annotation.Generated(value = "io.swagger.codegen.languages.JavaClientCodegen", date = "2018-01-25T01:26:31.138+01:00") -public class PrivilegePage { - @SerializedName("size") - private Integer size = null; - - @SerializedName("offset") - private Integer offset = null; - - @SerializedName("total") - private Integer total = null; - - @SerializedName("elements") - private List elements = new ArrayList(); - - public PrivilegePage size(Integer size) { - this.size = size; - return this; - } - - /** - * The maximum number of elements on the page. - * @return size - **/ - @ApiModelProperty(required = true, value = "The maximum number of elements on the page.") - public Integer getSize() { - return size; - } - - public void setSize(Integer size) { - this.size = size; - } - - public PrivilegePage offset(Integer offset) { - this.offset = offset; - return this; - } - - /** - * The page offset (0-based) in number of elements. - * @return offset - **/ - @ApiModelProperty(required = true, value = "The page offset (0-based) in number of elements.") - public Integer getOffset() { - return offset; - } - - public void setOffset(Integer offset) { - this.offset = offset; - } - - public PrivilegePage total(Integer total) { - this.total = total; - return this; - } - - /** - * The total number of elements available. - * @return total - **/ - @ApiModelProperty(required = true, value = "The total number of elements available.") - public Integer getTotal() { - return total; - } - - public void setTotal(Integer total) { - this.total = total; - } - - public PrivilegePage elements(List elements) { - this.elements = elements; - return this; - } - - public PrivilegePage addElementsItem(Privilege elementsItem) { - this.elements.add(elementsItem); - return this; - } - - /** - * The elements of the page. - * @return elements - **/ - @ApiModelProperty(required = true, value = "The elements of the page.") - public List getElements() { - return elements; - } - - public void setElements(List elements) { - this.elements = elements; - } - - - @Override - public boolean equals(java.lang.Object o) { - if (this == o) { - return true; - } - if (o == null || getClass() != o.getClass()) { - return false; - } - PrivilegePage privilegePage = (PrivilegePage) o; - return Objects.equals(this.size, privilegePage.size) && - Objects.equals(this.offset, privilegePage.offset) && - Objects.equals(this.total, privilegePage.total) && - Objects.equals(this.elements, privilegePage.elements); - } - - @Override - public int hashCode() { - return Objects.hash(size, offset, total, elements); - } - - - @Override - public String toString() { - StringBuilder sb = new StringBuilder(); - sb.append("class PrivilegePage {\n"); - - sb.append(" size: ").append(toIndentedString(size)).append("\n"); - sb.append(" offset: ").append(toIndentedString(offset)).append("\n"); - sb.append(" total: ").append(toIndentedString(total)).append("\n"); - sb.append(" elements: ").append(toIndentedString(elements)).append("\n"); - sb.append("}"); - return sb.toString(); - } - - /** - * Convert the given object to string with each line indented by 4 spaces - * (except the first line). - */ - private String toIndentedString(java.lang.Object o) { - if (o == null) { - return "null"; - } - return o.toString().replace("\n", "\n "); - } - -} - diff --git a/testing/api-client/src/main/java/io/swagger/client/model/ReleasedLocation.java b/testing/api-client/src/main/java/io/swagger/client/model/ReleasedLocation.java deleted file mode 100644 index 96e1021..0000000 --- a/testing/api-client/src/main/java/io/swagger/client/model/ReleasedLocation.java +++ /dev/null @@ -1,376 +0,0 @@ -/* - * Maptology Service - * Maptology Service - * - * OpenAPI spec version: 0.0.1-SNAPSHOT - * Contact: nes-admin@uni-due.de - * - * NOTE: This class is auto generated by the swagger code generator program. - * https://github.com/swagger-api/swagger-codegen.git - * Do not edit the class manually. - */ - - -package io.swagger.client.model; - -import java.util.Objects; -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.JsonAdapter; -import com.google.gson.annotations.SerializedName; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; -import io.swagger.annotations.ApiModel; -import io.swagger.annotations.ApiModelProperty; -import io.swagger.client.model.Coordinate; -import java.io.IOException; - -/** - * Represents a detailed location with usage approved or prohibited by the user. - */ -@ApiModel(description = "Represents a detailed location with usage approved or prohibited by the user.") -@javax.annotation.Generated(value = "io.swagger.codegen.languages.JavaClientCodegen", date = "2018-01-25T01:26:31.138+01:00") -public class ReleasedLocation { - @SerializedName("timestamp") - private Long timestamp = null; - - @SerializedName("coordinate") - private Coordinate coordinate = null; - - /** - * The availability information of the location. - */ - @JsonAdapter(AvailabilityEnum.Adapter.class) - public enum AvailabilityEnum { - FRESH("FRESH"), - - CACHED("CACHED"), - - UNABLE("UNABLE"), - - PRIVATE("PRIVATE"); - - private String value; - - AvailabilityEnum(String value) { - this.value = value; - } - - public String getValue() { - return value; - } - - @Override - public String toString() { - return String.valueOf(value); - } - - public static AvailabilityEnum fromValue(String text) { - for (AvailabilityEnum b : AvailabilityEnum.values()) { - if (String.valueOf(b.value).equals(text)) { - return b; - } - } - return null; - } - - public static class Adapter extends TypeAdapter { - @Override - public void write(final JsonWriter jsonWriter, final AvailabilityEnum enumeration) throws IOException { - jsonWriter.value(enumeration.getValue()); - } - - @Override - public AvailabilityEnum read(final JsonReader jsonReader) throws IOException { - String value = jsonReader.nextString(); - return AvailabilityEnum.fromValue(String.valueOf(value)); - } - } - } - - @SerializedName("availability") - private AvailabilityEnum availability = null; - - @SerializedName("version") - private Integer version = null; - - @SerializedName("speed") - private Double speed = null; - - @SerializedName("bearing") - private Double bearing = null; - - @SerializedName("altitude") - private Double altitude = null; - - @SerializedName("accuracy") - private Double accuracy = null; - - @SerializedName("provider") - private String provider = null; - - @SerializedName("sharable") - private Boolean sharable = null; - - @SerializedName("analyzable") - private Boolean analyzable = null; - - public ReleasedLocation timestamp(Long timestamp) { - this.timestamp = timestamp; - return this; - } - - /** - * The timestamp of the location. - * @return timestamp - **/ - @ApiModelProperty(required = true, value = "The timestamp of the location.") - public Long getTimestamp() { - return timestamp; - } - - public void setTimestamp(Long timestamp) { - this.timestamp = timestamp; - } - - public ReleasedLocation coordinate(Coordinate coordinate) { - this.coordinate = coordinate; - return this; - } - - /** - * The coordinate of the location. - * @return coordinate - **/ - @ApiModelProperty(value = "The coordinate of the location.") - public Coordinate getCoordinate() { - return coordinate; - } - - public void setCoordinate(Coordinate coordinate) { - this.coordinate = coordinate; - } - - public ReleasedLocation availability(AvailabilityEnum availability) { - this.availability = availability; - return this; - } - - /** - * The availability information of the location. - * @return availability - **/ - @ApiModelProperty(required = true, value = "The availability information of the location.") - public AvailabilityEnum getAvailability() { - return availability; - } - - public void setAvailability(AvailabilityEnum availability) { - this.availability = availability; - } - - public ReleasedLocation version(Integer version) { - this.version = version; - return this; - } - - /** - * The version code of the application. - * @return version - **/ - @ApiModelProperty(required = true, value = "The version code of the application.") - public Integer getVersion() { - return version; - } - - public void setVersion(Integer version) { - this.version = version; - } - - public ReleasedLocation speed(Double speed) { - this.speed = speed; - return this; - } - - /** - * The speed in meter per second or null, if not available. - * @return speed - **/ - @ApiModelProperty(value = "The speed in meter per second or null, if not available.") - public Double getSpeed() { - return speed; - } - - public void setSpeed(Double speed) { - this.speed = speed; - } - - public ReleasedLocation bearing(Double bearing) { - this.bearing = bearing; - return this; - } - - /** - * The bearing in degree or null, if not available. - * @return bearing - **/ - @ApiModelProperty(value = "The bearing in degree or null, if not available.") - public Double getBearing() { - return bearing; - } - - public void setBearing(Double bearing) { - this.bearing = bearing; - } - - public ReleasedLocation altitude(Double altitude) { - this.altitude = altitude; - return this; - } - - /** - * The altitude in meters or null, if not available. - * @return altitude - **/ - @ApiModelProperty(value = "The altitude in meters or null, if not available.") - public Double getAltitude() { - return altitude; - } - - public void setAltitude(Double altitude) { - this.altitude = altitude; - } - - public ReleasedLocation accuracy(Double accuracy) { - this.accuracy = accuracy; - return this; - } - - /** - * The accuracy in meters or null, if not available. - * @return accuracy - **/ - @ApiModelProperty(value = "The accuracy in meters or null, if not available.") - public Double getAccuracy() { - return accuracy; - } - - public void setAccuracy(Double accuracy) { - this.accuracy = accuracy; - } - - public ReleasedLocation provider(String provider) { - this.provider = provider; - return this; - } - - /** - * The provider name or null, if not available. - * @return provider - **/ - @ApiModelProperty(value = "The provider name or null, if not available.") - public String getProvider() { - return provider; - } - - public void setProvider(String provider) { - this.provider = provider; - } - - public ReleasedLocation sharable(Boolean sharable) { - this.sharable = sharable; - return this; - } - - /** - * A boolean value to mark the update as sharable for research purposes. - * @return sharable - **/ - @ApiModelProperty(required = true, value = "A boolean value to mark the update as sharable for research purposes.") - public Boolean getSharable() { - return sharable; - } - - public void setSharable(Boolean sharable) { - this.sharable = sharable; - } - - public ReleasedLocation analyzable(Boolean analyzable) { - this.analyzable = analyzable; - return this; - } - - /** - * A boolean value to mark the update as analyzable to compute places and visits. - * @return analyzable - **/ - @ApiModelProperty(required = true, value = "A boolean value to mark the update as analyzable to compute places and visits.") - public Boolean getAnalyzable() { - return analyzable; - } - - public void setAnalyzable(Boolean analyzable) { - this.analyzable = analyzable; - } - - - @Override - public boolean equals(java.lang.Object o) { - if (this == o) { - return true; - } - if (o == null || getClass() != o.getClass()) { - return false; - } - ReleasedLocation releasedLocation = (ReleasedLocation) o; - return Objects.equals(this.timestamp, releasedLocation.timestamp) && - Objects.equals(this.coordinate, releasedLocation.coordinate) && - Objects.equals(this.availability, releasedLocation.availability) && - Objects.equals(this.version, releasedLocation.version) && - Objects.equals(this.speed, releasedLocation.speed) && - Objects.equals(this.bearing, releasedLocation.bearing) && - Objects.equals(this.altitude, releasedLocation.altitude) && - Objects.equals(this.accuracy, releasedLocation.accuracy) && - Objects.equals(this.provider, releasedLocation.provider) && - Objects.equals(this.sharable, releasedLocation.sharable) && - Objects.equals(this.analyzable, releasedLocation.analyzable); - } - - @Override - public int hashCode() { - return Objects.hash(timestamp, coordinate, availability, version, speed, bearing, altitude, accuracy, provider, sharable, analyzable); - } - - - @Override - public String toString() { - StringBuilder sb = new StringBuilder(); - sb.append("class ReleasedLocation {\n"); - - sb.append(" timestamp: ").append(toIndentedString(timestamp)).append("\n"); - sb.append(" coordinate: ").append(toIndentedString(coordinate)).append("\n"); - sb.append(" availability: ").append(toIndentedString(availability)).append("\n"); - sb.append(" version: ").append(toIndentedString(version)).append("\n"); - sb.append(" speed: ").append(toIndentedString(speed)).append("\n"); - sb.append(" bearing: ").append(toIndentedString(bearing)).append("\n"); - sb.append(" altitude: ").append(toIndentedString(altitude)).append("\n"); - sb.append(" accuracy: ").append(toIndentedString(accuracy)).append("\n"); - sb.append(" provider: ").append(toIndentedString(provider)).append("\n"); - sb.append(" sharable: ").append(toIndentedString(sharable)).append("\n"); - sb.append(" analyzable: ").append(toIndentedString(analyzable)).append("\n"); - sb.append("}"); - return sb.toString(); - } - - /** - * Convert the given object to string with each line indented by 4 spaces - * (except the first line). - */ - private String toIndentedString(java.lang.Object o) { - if (o == null) { - return "null"; - } - return o.toString().replace("\n", "\n "); - } - -} - diff --git a/testing/api-client/src/main/java/io/swagger/client/model/Share.java b/testing/api-client/src/main/java/io/swagger/client/model/Share.java deleted file mode 100644 index ea4cf4c..0000000 --- a/testing/api-client/src/main/java/io/swagger/client/model/Share.java +++ /dev/null @@ -1,265 +0,0 @@ -/* - * Maptology Service - * Maptology Service - * - * OpenAPI spec version: 0.0.1-SNAPSHOT - * Contact: nes-admin@uni-due.de - * - * NOTE: This class is auto generated by the swagger code generator program. - * https://github.com/swagger-api/swagger-codegen.git - * Do not edit the class manually. - */ - - -package io.swagger.client.model; - -import java.util.Objects; -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.JsonAdapter; -import com.google.gson.annotations.SerializedName; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; -import io.swagger.annotations.ApiModel; -import io.swagger.annotations.ApiModelProperty; -import java.io.IOException; - -/** - * Represents a share. - */ -@ApiModel(description = "Represents a share.") -@javax.annotation.Generated(value = "io.swagger.codegen.languages.JavaClientCodegen", date = "2018-01-25T01:26:31.138+01:00") -public class Share { - @SerializedName("id") - private Long id = null; - - @SerializedName("creationTime") - private Long creationTime = null; - - @SerializedName("modificationTime") - private Long modificationTime = null; - - @SerializedName("deleted") - private Boolean deleted = null; - - @SerializedName("token") - private String token = null; - - @SerializedName("device") - private Long device = null; - - @SerializedName("message") - private String message = null; - - @SerializedName("destination") - private String destination = null; - - @SerializedName("expirationTime") - private Long expirationTime = null; - - @SerializedName("paused") - private Boolean paused = null; - - /** - * The unique identifier of the data. - * @return id - **/ - @ApiModelProperty(value = "The unique identifier of the data.") - public Long getId() { - return id; - } - - /** - * The time stamp when the data was created. - * @return creationTime - **/ - @ApiModelProperty(value = "The time stamp when the data was created.") - public Long getCreationTime() { - return creationTime; - } - - /** - * The time stamp when the data was created. - * @return modificationTime - **/ - @ApiModelProperty(value = "The time stamp when the data was created.") - public Long getModificationTime() { - return modificationTime; - } - - public Share deleted(Boolean deleted) { - this.deleted = deleted; - return this; - } - - /** - * A flag to indicate whether the data was deleted. - * @return deleted - **/ - @ApiModelProperty(value = "A flag to indicate whether the data was deleted.") - public Boolean getDeleted() { - return deleted; - } - - public void setDeleted(Boolean deleted) { - this.deleted = deleted; - } - - public Share token(String token) { - this.token = token; - return this; - } - - /** - * The token to forward to other persons to be able to access the share. - * @return token - **/ - @ApiModelProperty(required = true, value = "The token to forward to other persons to be able to access the share.") - public String getToken() { - return token; - } - - public void setToken(String token) { - this.token = token; - } - - /** - * The id of the related device. - * @return device - **/ - @ApiModelProperty(value = "The id of the related device.") - public Long getDevice() { - return device; - } - - public Share message(String message) { - this.message = message; - return this; - } - - /** - * A message to be displayed to the share receiving users. - * @return message - **/ - @ApiModelProperty(value = "A message to be displayed to the share receiving users.") - public String getMessage() { - return message; - } - - public void setMessage(String message) { - this.message = message; - } - - public Share destination(String destination) { - this.destination = destination; - return this; - } - - /** - * A destination to be displayed to the share receiving users. - * @return destination - **/ - @ApiModelProperty(value = "A destination to be displayed to the share receiving users.") - public String getDestination() { - return destination; - } - - public void setDestination(String destination) { - this.destination = destination; - } - - public Share expirationTime(Long expirationTime) { - this.expirationTime = expirationTime; - return this; - } - - /** - * The expiration time of the share that should be created. - * @return expirationTime - **/ - @ApiModelProperty(required = true, value = "The expiration time of the share that should be created.") - public Long getExpirationTime() { - return expirationTime; - } - - public void setExpirationTime(Long expirationTime) { - this.expirationTime = expirationTime; - } - - public Share paused(Boolean paused) { - this.paused = paused; - return this; - } - - /** - * A flag to indicate whether the sharing is temporarily paused. - * @return paused - **/ - @ApiModelProperty(value = "A flag to indicate whether the sharing is temporarily paused.") - public Boolean getPaused() { - return paused; - } - - public void setPaused(Boolean paused) { - this.paused = paused; - } - - - @Override - public boolean equals(java.lang.Object o) { - if (this == o) { - return true; - } - if (o == null || getClass() != o.getClass()) { - return false; - } - Share share = (Share) o; - return Objects.equals(this.id, share.id) && - Objects.equals(this.creationTime, share.creationTime) && - Objects.equals(this.modificationTime, share.modificationTime) && - Objects.equals(this.deleted, share.deleted) && - Objects.equals(this.token, share.token) && - Objects.equals(this.device, share.device) && - Objects.equals(this.message, share.message) && - Objects.equals(this.destination, share.destination) && - Objects.equals(this.expirationTime, share.expirationTime) && - Objects.equals(this.paused, share.paused); - } - - @Override - public int hashCode() { - return Objects.hash(id, creationTime, modificationTime, deleted, token, device, message, destination, expirationTime, paused); - } - - - @Override - public String toString() { - StringBuilder sb = new StringBuilder(); - sb.append("class Share {\n"); - - sb.append(" id: ").append(toIndentedString(id)).append("\n"); - sb.append(" creationTime: ").append(toIndentedString(creationTime)).append("\n"); - sb.append(" modificationTime: ").append(toIndentedString(modificationTime)).append("\n"); - sb.append(" deleted: ").append(toIndentedString(deleted)).append("\n"); - sb.append(" token: ").append(toIndentedString(token)).append("\n"); - sb.append(" device: ").append(toIndentedString(device)).append("\n"); - sb.append(" message: ").append(toIndentedString(message)).append("\n"); - sb.append(" destination: ").append(toIndentedString(destination)).append("\n"); - sb.append(" expirationTime: ").append(toIndentedString(expirationTime)).append("\n"); - sb.append(" paused: ").append(toIndentedString(paused)).append("\n"); - sb.append("}"); - return sb.toString(); - } - - /** - * Convert the given object to string with each line indented by 4 spaces - * (except the first line). - */ - private String toIndentedString(java.lang.Object o) { - if (o == null) { - return "null"; - } - return o.toString().replace("\n", "\n "); - } - -} - diff --git a/testing/api-client/src/main/java/io/swagger/client/model/ShareInfo.java b/testing/api-client/src/main/java/io/swagger/client/model/ShareInfo.java deleted file mode 100644 index 2914250..0000000 --- a/testing/api-client/src/main/java/io/swagger/client/model/ShareInfo.java +++ /dev/null @@ -1,140 +0,0 @@ -/* - * Maptology Service - * Maptology Service - * - * OpenAPI spec version: 0.0.1-SNAPSHOT - * Contact: nes-admin@uni-due.de - * - * NOTE: This class is auto generated by the swagger code generator program. - * https://github.com/swagger-api/swagger-codegen.git - * Do not edit the class manually. - */ - - -package io.swagger.client.model; - -import java.util.Objects; -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.JsonAdapter; -import com.google.gson.annotations.SerializedName; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; -import io.swagger.annotations.ApiModel; -import io.swagger.annotations.ApiModelProperty; -import java.io.IOException; - -/** - * Represents a request to create a new share. - */ -@ApiModel(description = "Represents a request to create a new share.") -@javax.annotation.Generated(value = "io.swagger.codegen.languages.JavaClientCodegen", date = "2018-01-25T01:26:31.138+01:00") -public class ShareInfo { - @SerializedName("message") - private String message = null; - - @SerializedName("destination") - private String destination = null; - - @SerializedName("expirationTime") - private Long expirationTime = null; - - public ShareInfo message(String message) { - this.message = message; - return this; - } - - /** - * A message to be displayed to the share receiving users. - * @return message - **/ - @ApiModelProperty(value = "A message to be displayed to the share receiving users.") - public String getMessage() { - return message; - } - - public void setMessage(String message) { - this.message = message; - } - - public ShareInfo destination(String destination) { - this.destination = destination; - return this; - } - - /** - * A destination to be displayed to the share receiving users. - * @return destination - **/ - @ApiModelProperty(value = "A destination to be displayed to the share receiving users.") - public String getDestination() { - return destination; - } - - public void setDestination(String destination) { - this.destination = destination; - } - - public ShareInfo expirationTime(Long expirationTime) { - this.expirationTime = expirationTime; - return this; - } - - /** - * The expiration time of the share that should be created. - * @return expirationTime - **/ - @ApiModelProperty(required = true, value = "The expiration time of the share that should be created.") - public Long getExpirationTime() { - return expirationTime; - } - - public void setExpirationTime(Long expirationTime) { - this.expirationTime = expirationTime; - } - - - @Override - public boolean equals(java.lang.Object o) { - if (this == o) { - return true; - } - if (o == null || getClass() != o.getClass()) { - return false; - } - ShareInfo shareInfo = (ShareInfo) o; - return Objects.equals(this.message, shareInfo.message) && - Objects.equals(this.destination, shareInfo.destination) && - Objects.equals(this.expirationTime, shareInfo.expirationTime); - } - - @Override - public int hashCode() { - return Objects.hash(message, destination, expirationTime); - } - - - @Override - public String toString() { - StringBuilder sb = new StringBuilder(); - sb.append("class ShareInfo {\n"); - - sb.append(" message: ").append(toIndentedString(message)).append("\n"); - sb.append(" destination: ").append(toIndentedString(destination)).append("\n"); - sb.append(" expirationTime: ").append(toIndentedString(expirationTime)).append("\n"); - sb.append("}"); - return sb.toString(); - } - - /** - * Convert the given object to string with each line indented by 4 spaces - * (except the first line). - */ - private String toIndentedString(java.lang.Object o) { - if (o == null) { - return "null"; - } - return o.toString().replace("\n", "\n "); - } - -} - diff --git a/testing/api-client/src/main/java/io/swagger/client/model/User.java b/testing/api-client/src/main/java/io/swagger/client/model/User.java deleted file mode 100644 index cf3d797..0000000 --- a/testing/api-client/src/main/java/io/swagger/client/model/User.java +++ /dev/null @@ -1,264 +0,0 @@ -/* - * Maptology Service - * Maptology Service - * - * OpenAPI spec version: 0.0.1-SNAPSHOT - * Contact: nes-admin@uni-due.de - * - * NOTE: This class is auto generated by the swagger code generator program. - * https://github.com/swagger-api/swagger-codegen.git - * Do not edit the class manually. - */ - - -package io.swagger.client.model; - -import java.util.Objects; -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.JsonAdapter; -import com.google.gson.annotations.SerializedName; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; -import io.swagger.annotations.ApiModel; -import io.swagger.annotations.ApiModelProperty; -import io.swagger.client.model.Email; -import java.io.IOException; -import java.util.ArrayList; -import java.util.List; - -/** - * Represents a user. - */ -@ApiModel(description = "Represents a user.") -@javax.annotation.Generated(value = "io.swagger.codegen.languages.JavaClientCodegen", date = "2018-01-25T01:26:31.138+01:00") -public class User { - @SerializedName("id") - private Long id = null; - - @SerializedName("creationTime") - private Long creationTime = null; - - @SerializedName("modificationTime") - private Long modificationTime = null; - - @SerializedName("deleted") - private Boolean deleted = null; - - @SerializedName("login") - private String login = null; - - @SerializedName("name") - private String name = null; - - @SerializedName("suspended") - private Boolean suspended = null; - - @SerializedName("roles") - private List roles = new ArrayList(); - - @SerializedName("emails") - private List emails = new ArrayList(); - - /** - * The unique identifier of the data. - * @return id - **/ - @ApiModelProperty(value = "The unique identifier of the data.") - public Long getId() { - return id; - } - - /** - * The time stamp when the data was created. - * @return creationTime - **/ - @ApiModelProperty(value = "The time stamp when the data was created.") - public Long getCreationTime() { - return creationTime; - } - - /** - * The time stamp when the data was created. - * @return modificationTime - **/ - @ApiModelProperty(value = "The time stamp when the data was created.") - public Long getModificationTime() { - return modificationTime; - } - - public User deleted(Boolean deleted) { - this.deleted = deleted; - return this; - } - - /** - * A flag to indicate whether the data was deleted. - * @return deleted - **/ - @ApiModelProperty(value = "A flag to indicate whether the data was deleted.") - public Boolean getDeleted() { - return deleted; - } - - public void setDeleted(Boolean deleted) { - this.deleted = deleted; - } - - public User login(String login) { - this.login = login; - return this; - } - - /** - * The (globally unique) login of the user. - * @return login - **/ - @ApiModelProperty(required = true, value = "The (globally unique) login of the user.") - public String getLogin() { - return login; - } - - public void setLogin(String login) { - this.login = login; - } - - public User name(String name) { - this.name = name; - return this; - } - - /** - * The human name of the user. - * @return name - **/ - @ApiModelProperty(required = true, value = "The human name of the user.") - public String getName() { - return name; - } - - public void setName(String name) { - this.name = name; - } - - public User suspended(Boolean suspended) { - this.suspended = suspended; - return this; - } - - /** - * A flag to indicate that user account is suspended. - * @return suspended - **/ - @ApiModelProperty(required = true, value = "A flag to indicate that user account is suspended.") - public Boolean getSuspended() { - return suspended; - } - - public void setSuspended(Boolean suspended) { - this.suspended = suspended; - } - - public User roles(List roles) { - this.roles = roles; - return this; - } - - public User addRolesItem(String rolesItem) { - this.roles.add(rolesItem); - return this; - } - - /** - * Get roles - * @return roles - **/ - @ApiModelProperty(required = true, value = "") - public List getRoles() { - return roles; - } - - public void setRoles(List roles) { - this.roles = roles; - } - - public User emails(List emails) { - this.emails = emails; - return this; - } - - public User addEmailsItem(Email emailsItem) { - this.emails.add(emailsItem); - return this; - } - - /** - * Get emails - * @return emails - **/ - @ApiModelProperty(required = true, value = "") - public List getEmails() { - return emails; - } - - public void setEmails(List emails) { - this.emails = emails; - } - - - @Override - public boolean equals(java.lang.Object o) { - if (this == o) { - return true; - } - if (o == null || getClass() != o.getClass()) { - return false; - } - User user = (User) o; - return Objects.equals(this.id, user.id) && - Objects.equals(this.creationTime, user.creationTime) && - Objects.equals(this.modificationTime, user.modificationTime) && - Objects.equals(this.deleted, user.deleted) && - Objects.equals(this.login, user.login) && - Objects.equals(this.name, user.name) && - Objects.equals(this.suspended, user.suspended) && - Objects.equals(this.roles, user.roles) && - Objects.equals(this.emails, user.emails); - } - - @Override - public int hashCode() { - return Objects.hash(id, creationTime, modificationTime, deleted, login, name, suspended, roles, emails); - } - - - @Override - public String toString() { - StringBuilder sb = new StringBuilder(); - sb.append("class User {\n"); - - sb.append(" id: ").append(toIndentedString(id)).append("\n"); - sb.append(" creationTime: ").append(toIndentedString(creationTime)).append("\n"); - sb.append(" modificationTime: ").append(toIndentedString(modificationTime)).append("\n"); - sb.append(" deleted: ").append(toIndentedString(deleted)).append("\n"); - sb.append(" login: ").append(toIndentedString(login)).append("\n"); - sb.append(" name: ").append(toIndentedString(name)).append("\n"); - sb.append(" suspended: ").append(toIndentedString(suspended)).append("\n"); - sb.append(" roles: ").append(toIndentedString(roles)).append("\n"); - sb.append(" emails: ").append(toIndentedString(emails)).append("\n"); - sb.append("}"); - return sb.toString(); - } - - /** - * Convert the given object to string with each line indented by 4 spaces - * (except the first line). - */ - private String toIndentedString(java.lang.Object o) { - if (o == null) { - return "null"; - } - return o.toString().replace("\n", "\n "); - } - -} - diff --git a/testing/api-client/src/main/java/io/swagger/client/model/UserPage.java b/testing/api-client/src/main/java/io/swagger/client/model/UserPage.java deleted file mode 100644 index d08d0c7..0000000 --- a/testing/api-client/src/main/java/io/swagger/client/model/UserPage.java +++ /dev/null @@ -1,171 +0,0 @@ -/* - * Maptology Service - * Maptology Service - * - * OpenAPI spec version: 0.0.1-SNAPSHOT - * Contact: nes-admin@uni-due.de - * - * NOTE: This class is auto generated by the swagger code generator program. - * https://github.com/swagger-api/swagger-codegen.git - * Do not edit the class manually. - */ - - -package io.swagger.client.model; - -import java.util.Objects; -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.JsonAdapter; -import com.google.gson.annotations.SerializedName; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; -import io.swagger.annotations.ApiModel; -import io.swagger.annotations.ApiModelProperty; -import io.swagger.client.model.User; -import java.io.IOException; -import java.util.ArrayList; -import java.util.List; - -/** - * Represents a page of users. - */ -@ApiModel(description = "Represents a page of users.") -@javax.annotation.Generated(value = "io.swagger.codegen.languages.JavaClientCodegen", date = "2018-01-25T01:26:31.138+01:00") -public class UserPage { - @SerializedName("size") - private Integer size = null; - - @SerializedName("offset") - private Integer offset = null; - - @SerializedName("total") - private Integer total = null; - - @SerializedName("elements") - private List elements = new ArrayList(); - - public UserPage size(Integer size) { - this.size = size; - return this; - } - - /** - * The maximum number of elements on the page. - * @return size - **/ - @ApiModelProperty(required = true, value = "The maximum number of elements on the page.") - public Integer getSize() { - return size; - } - - public void setSize(Integer size) { - this.size = size; - } - - public UserPage offset(Integer offset) { - this.offset = offset; - return this; - } - - /** - * The page offset (0-based) in number of elements. - * @return offset - **/ - @ApiModelProperty(required = true, value = "The page offset (0-based) in number of elements.") - public Integer getOffset() { - return offset; - } - - public void setOffset(Integer offset) { - this.offset = offset; - } - - public UserPage total(Integer total) { - this.total = total; - return this; - } - - /** - * The total number of elements available. - * @return total - **/ - @ApiModelProperty(required = true, value = "The total number of elements available.") - public Integer getTotal() { - return total; - } - - public void setTotal(Integer total) { - this.total = total; - } - - public UserPage elements(List elements) { - this.elements = elements; - return this; - } - - public UserPage addElementsItem(User elementsItem) { - this.elements.add(elementsItem); - return this; - } - - /** - * The elements of the page. - * @return elements - **/ - @ApiModelProperty(required = true, value = "The elements of the page.") - public List getElements() { - return elements; - } - - public void setElements(List elements) { - this.elements = elements; - } - - - @Override - public boolean equals(java.lang.Object o) { - if (this == o) { - return true; - } - if (o == null || getClass() != o.getClass()) { - return false; - } - UserPage userPage = (UserPage) o; - return Objects.equals(this.size, userPage.size) && - Objects.equals(this.offset, userPage.offset) && - Objects.equals(this.total, userPage.total) && - Objects.equals(this.elements, userPage.elements); - } - - @Override - public int hashCode() { - return Objects.hash(size, offset, total, elements); - } - - - @Override - public String toString() { - StringBuilder sb = new StringBuilder(); - sb.append("class UserPage {\n"); - - sb.append(" size: ").append(toIndentedString(size)).append("\n"); - sb.append(" offset: ").append(toIndentedString(offset)).append("\n"); - sb.append(" total: ").append(toIndentedString(total)).append("\n"); - sb.append(" elements: ").append(toIndentedString(elements)).append("\n"); - sb.append("}"); - return sb.toString(); - } - - /** - * Convert the given object to string with each line indented by 4 spaces - * (except the first line). - */ - private String toIndentedString(java.lang.Object o) { - if (o == null) { - return "null"; - } - return o.toString().replace("\n", "\n "); - } - -} - diff --git a/testing/api-client/src/main/java/io/swagger/client/model/UserPassword.java b/testing/api-client/src/main/java/io/swagger/client/model/UserPassword.java deleted file mode 100644 index 4b3c605..0000000 --- a/testing/api-client/src/main/java/io/swagger/client/model/UserPassword.java +++ /dev/null @@ -1,94 +0,0 @@ -/* - * Maptology Service - * Maptology Service - * - * OpenAPI spec version: 0.0.1-SNAPSHOT - * Contact: nes-admin@uni-due.de - * - * NOTE: This class is auto generated by the swagger code generator program. - * https://github.com/swagger-api/swagger-codegen.git - * Do not edit the class manually. - */ - - -package io.swagger.client.model; - -import java.util.Objects; -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.JsonAdapter; -import com.google.gson.annotations.SerializedName; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; -import io.swagger.annotations.ApiModel; -import io.swagger.annotations.ApiModelProperty; -import java.io.IOException; - -/** - * Represents a user password. - */ -@ApiModel(description = "Represents a user password.") -@javax.annotation.Generated(value = "io.swagger.codegen.languages.JavaClientCodegen", date = "2018-01-25T01:26:31.138+01:00") -public class UserPassword { - @SerializedName("password") - private String password = null; - - public UserPassword password(String password) { - this.password = password; - return this; - } - - /** - * The new password. - * @return password - **/ - @ApiModelProperty(required = true, value = "The new password.") - public String getPassword() { - return password; - } - - public void setPassword(String password) { - this.password = password; - } - - - @Override - public boolean equals(java.lang.Object o) { - if (this == o) { - return true; - } - if (o == null || getClass() != o.getClass()) { - return false; - } - UserPassword userPassword = (UserPassword) o; - return Objects.equals(this.password, userPassword.password); - } - - @Override - public int hashCode() { - return Objects.hash(password); - } - - - @Override - public String toString() { - StringBuilder sb = new StringBuilder(); - sb.append("class UserPassword {\n"); - - sb.append(" password: ").append(toIndentedString(password)).append("\n"); - sb.append("}"); - return sb.toString(); - } - - /** - * Convert the given object to string with each line indented by 4 spaces - * (except the first line). - */ - private String toIndentedString(java.lang.Object o) { - if (o == null) { - return "null"; - } - return o.toString().replace("\n", "\n "); - } - -} - diff --git a/testing/api-client/src/main/java/io/swagger/client/model/UserRegistration.java b/testing/api-client/src/main/java/io/swagger/client/model/UserRegistration.java deleted file mode 100644 index ce71d84..0000000 --- a/testing/api-client/src/main/java/io/swagger/client/model/UserRegistration.java +++ /dev/null @@ -1,163 +0,0 @@ -/* - * Maptology Service - * Maptology Service - * - * OpenAPI spec version: 0.0.1-SNAPSHOT - * Contact: nes-admin@uni-due.de - * - * NOTE: This class is auto generated by the swagger code generator program. - * https://github.com/swagger-api/swagger-codegen.git - * Do not edit the class manually. - */ - - -package io.swagger.client.model; - -import java.util.Objects; -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.JsonAdapter; -import com.google.gson.annotations.SerializedName; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; -import io.swagger.annotations.ApiModel; -import io.swagger.annotations.ApiModelProperty; -import java.io.IOException; - -/** - * Represents a user registration. - */ -@ApiModel(description = "Represents a user registration.") -@javax.annotation.Generated(value = "io.swagger.codegen.languages.JavaClientCodegen", date = "2018-01-25T01:26:31.138+01:00") -public class UserRegistration { - @SerializedName("password") - private String password = null; - - @SerializedName("login") - private String login = null; - - @SerializedName("name") - private String name = null; - - @SerializedName("email") - private String email = null; - - public UserRegistration password(String password) { - this.password = password; - return this; - } - - /** - * The new password. - * @return password - **/ - @ApiModelProperty(required = true, value = "The new password.") - public String getPassword() { - return password; - } - - public void setPassword(String password) { - this.password = password; - } - - public UserRegistration login(String login) { - this.login = login; - return this; - } - - /** - * The requested login name. - * @return login - **/ - @ApiModelProperty(required = true, value = "The requested login name.") - public String getLogin() { - return login; - } - - public void setLogin(String login) { - this.login = login; - } - - public UserRegistration name(String name) { - this.name = name; - return this; - } - - /** - * The human name. - * @return name - **/ - @ApiModelProperty(required = true, value = "The human name.") - public String getName() { - return name; - } - - public void setName(String name) { - this.name = name; - } - - public UserRegistration email(String email) { - this.email = email; - return this; - } - - /** - * The email address. - * @return email - **/ - @ApiModelProperty(required = true, value = "The email address.") - public String getEmail() { - return email; - } - - public void setEmail(String email) { - this.email = email; - } - - - @Override - public boolean equals(java.lang.Object o) { - if (this == o) { - return true; - } - if (o == null || getClass() != o.getClass()) { - return false; - } - UserRegistration userRegistration = (UserRegistration) o; - return Objects.equals(this.password, userRegistration.password) && - Objects.equals(this.login, userRegistration.login) && - Objects.equals(this.name, userRegistration.name) && - Objects.equals(this.email, userRegistration.email); - } - - @Override - public int hashCode() { - return Objects.hash(password, login, name, email); - } - - - @Override - public String toString() { - StringBuilder sb = new StringBuilder(); - sb.append("class UserRegistration {\n"); - - sb.append(" password: ").append(toIndentedString(password)).append("\n"); - sb.append(" login: ").append(toIndentedString(login)).append("\n"); - sb.append(" name: ").append(toIndentedString(name)).append("\n"); - sb.append(" email: ").append(toIndentedString(email)).append("\n"); - sb.append("}"); - return sb.toString(); - } - - /** - * Convert the given object to string with each line indented by 4 spaces - * (except the first line). - */ - private String toIndentedString(java.lang.Object o) { - if (o == null) { - return "null"; - } - return o.toString().replace("\n", "\n "); - } - -} - diff --git a/testing/api-client/src/main/java/io/swagger/client/model/Visit.java b/testing/api-client/src/main/java/io/swagger/client/model/Visit.java deleted file mode 100644 index a0892ee..0000000 --- a/testing/api-client/src/main/java/io/swagger/client/model/Visit.java +++ /dev/null @@ -1,228 +0,0 @@ -/* - * Maptology Service - * Maptology Service - * - * OpenAPI spec version: 0.0.1-SNAPSHOT - * Contact: nes-admin@uni-due.de - * - * NOTE: This class is auto generated by the swagger code generator program. - * https://github.com/swagger-api/swagger-codegen.git - * Do not edit the class manually. - */ - - -package io.swagger.client.model; - -import java.util.Objects; -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.JsonAdapter; -import com.google.gson.annotations.SerializedName; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; -import io.swagger.annotations.ApiModel; -import io.swagger.annotations.ApiModelProperty; -import java.io.IOException; - -/** - * Represents a visit of a device at a place. - */ -@ApiModel(description = "Represents a visit of a device at a place.") -@javax.annotation.Generated(value = "io.swagger.codegen.languages.JavaClientCodegen", date = "2018-01-25T01:26:31.138+01:00") -public class Visit { - @SerializedName("id") - private Long id = null; - - @SerializedName("creationTime") - private Long creationTime = null; - - @SerializedName("modificationTime") - private Long modificationTime = null; - - @SerializedName("deleted") - private Boolean deleted = null; - - @SerializedName("place") - private Long place = null; - - @SerializedName("device") - private Long device = null; - - @SerializedName("beginTime") - private Long beginTime = null; - - @SerializedName("endTime") - private Long endTime = null; - - /** - * The unique identifier of the data. - * @return id - **/ - @ApiModelProperty(value = "The unique identifier of the data.") - public Long getId() { - return id; - } - - /** - * The time stamp when the data was created. - * @return creationTime - **/ - @ApiModelProperty(value = "The time stamp when the data was created.") - public Long getCreationTime() { - return creationTime; - } - - /** - * The time stamp when the data was created. - * @return modificationTime - **/ - @ApiModelProperty(value = "The time stamp when the data was created.") - public Long getModificationTime() { - return modificationTime; - } - - public Visit deleted(Boolean deleted) { - this.deleted = deleted; - return this; - } - - /** - * A flag to indicate whether the data was deleted. - * @return deleted - **/ - @ApiModelProperty(value = "A flag to indicate whether the data was deleted.") - public Boolean getDeleted() { - return deleted; - } - - public void setDeleted(Boolean deleted) { - this.deleted = deleted; - } - - public Visit place(Long place) { - this.place = place; - return this; - } - - /** - * The id of the place. - * @return place - **/ - @ApiModelProperty(value = "The id of the place.") - public Long getPlace() { - return place; - } - - public void setPlace(Long place) { - this.place = place; - } - - public Visit device(Long device) { - this.device = device; - return this; - } - - /** - * The id of the device. - * @return device - **/ - @ApiModelProperty(value = "The id of the device.") - public Long getDevice() { - return device; - } - - public void setDevice(Long device) { - this.device = device; - } - - public Visit beginTime(Long beginTime) { - this.beginTime = beginTime; - return this; - } - - /** - * The beginning of the visit in Epoch milliseconds. - * @return beginTime - **/ - @ApiModelProperty(value = "The beginning of the visit in Epoch milliseconds.") - public Long getBeginTime() { - return beginTime; - } - - public void setBeginTime(Long beginTime) { - this.beginTime = beginTime; - } - - public Visit endTime(Long endTime) { - this.endTime = endTime; - return this; - } - - /** - * The end of the visit in Epoch milliseconds. - * @return endTime - **/ - @ApiModelProperty(value = "The end of the visit in Epoch milliseconds.") - public Long getEndTime() { - return endTime; - } - - public void setEndTime(Long endTime) { - this.endTime = endTime; - } - - - @Override - public boolean equals(java.lang.Object o) { - if (this == o) { - return true; - } - if (o == null || getClass() != o.getClass()) { - return false; - } - Visit visit = (Visit) o; - return Objects.equals(this.id, visit.id) && - Objects.equals(this.creationTime, visit.creationTime) && - Objects.equals(this.modificationTime, visit.modificationTime) && - Objects.equals(this.deleted, visit.deleted) && - Objects.equals(this.place, visit.place) && - Objects.equals(this.device, visit.device) && - Objects.equals(this.beginTime, visit.beginTime) && - Objects.equals(this.endTime, visit.endTime); - } - - @Override - public int hashCode() { - return Objects.hash(id, creationTime, modificationTime, deleted, place, device, beginTime, endTime); - } - - - @Override - public String toString() { - StringBuilder sb = new StringBuilder(); - sb.append("class Visit {\n"); - - sb.append(" id: ").append(toIndentedString(id)).append("\n"); - sb.append(" creationTime: ").append(toIndentedString(creationTime)).append("\n"); - sb.append(" modificationTime: ").append(toIndentedString(modificationTime)).append("\n"); - sb.append(" deleted: ").append(toIndentedString(deleted)).append("\n"); - sb.append(" place: ").append(toIndentedString(place)).append("\n"); - sb.append(" device: ").append(toIndentedString(device)).append("\n"); - sb.append(" beginTime: ").append(toIndentedString(beginTime)).append("\n"); - sb.append(" endTime: ").append(toIndentedString(endTime)).append("\n"); - sb.append("}"); - return sb.toString(); - } - - /** - * Convert the given object to string with each line indented by 4 spaces - * (except the first line). - */ - private String toIndentedString(java.lang.Object o) { - if (o == null) { - return "null"; - } - return o.toString().replace("\n", "\n "); - } - -} - diff --git a/testing/api-client/src/main/java/io/swagger/client/model/VisitPage.java b/testing/api-client/src/main/java/io/swagger/client/model/VisitPage.java deleted file mode 100644 index 2212e92..0000000 --- a/testing/api-client/src/main/java/io/swagger/client/model/VisitPage.java +++ /dev/null @@ -1,171 +0,0 @@ -/* - * Maptology Service - * Maptology Service - * - * OpenAPI spec version: 0.0.1-SNAPSHOT - * Contact: nes-admin@uni-due.de - * - * NOTE: This class is auto generated by the swagger code generator program. - * https://github.com/swagger-api/swagger-codegen.git - * Do not edit the class manually. - */ - - -package io.swagger.client.model; - -import java.util.Objects; -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.JsonAdapter; -import com.google.gson.annotations.SerializedName; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; -import io.swagger.annotations.ApiModel; -import io.swagger.annotations.ApiModelProperty; -import io.swagger.client.model.Visit; -import java.io.IOException; -import java.util.ArrayList; -import java.util.List; - -/** - * Represents a page of visits. - */ -@ApiModel(description = "Represents a page of visits.") -@javax.annotation.Generated(value = "io.swagger.codegen.languages.JavaClientCodegen", date = "2018-01-25T01:26:31.138+01:00") -public class VisitPage { - @SerializedName("size") - private Integer size = null; - - @SerializedName("offset") - private Integer offset = null; - - @SerializedName("total") - private Integer total = null; - - @SerializedName("elements") - private List elements = new ArrayList(); - - public VisitPage size(Integer size) { - this.size = size; - return this; - } - - /** - * The maximum number of elements on the page. - * @return size - **/ - @ApiModelProperty(required = true, value = "The maximum number of elements on the page.") - public Integer getSize() { - return size; - } - - public void setSize(Integer size) { - this.size = size; - } - - public VisitPage offset(Integer offset) { - this.offset = offset; - return this; - } - - /** - * The page offset (0-based) in number of elements. - * @return offset - **/ - @ApiModelProperty(required = true, value = "The page offset (0-based) in number of elements.") - public Integer getOffset() { - return offset; - } - - public void setOffset(Integer offset) { - this.offset = offset; - } - - public VisitPage total(Integer total) { - this.total = total; - return this; - } - - /** - * The total number of elements available. - * @return total - **/ - @ApiModelProperty(required = true, value = "The total number of elements available.") - public Integer getTotal() { - return total; - } - - public void setTotal(Integer total) { - this.total = total; - } - - public VisitPage elements(List elements) { - this.elements = elements; - return this; - } - - public VisitPage addElementsItem(Visit elementsItem) { - this.elements.add(elementsItem); - return this; - } - - /** - * The elements of the page. - * @return elements - **/ - @ApiModelProperty(required = true, value = "The elements of the page.") - public List getElements() { - return elements; - } - - public void setElements(List elements) { - this.elements = elements; - } - - - @Override - public boolean equals(java.lang.Object o) { - if (this == o) { - return true; - } - if (o == null || getClass() != o.getClass()) { - return false; - } - VisitPage visitPage = (VisitPage) o; - return Objects.equals(this.size, visitPage.size) && - Objects.equals(this.offset, visitPage.offset) && - Objects.equals(this.total, visitPage.total) && - Objects.equals(this.elements, visitPage.elements); - } - - @Override - public int hashCode() { - return Objects.hash(size, offset, total, elements); - } - - - @Override - public String toString() { - StringBuilder sb = new StringBuilder(); - sb.append("class VisitPage {\n"); - - sb.append(" size: ").append(toIndentedString(size)).append("\n"); - sb.append(" offset: ").append(toIndentedString(offset)).append("\n"); - sb.append(" total: ").append(toIndentedString(total)).append("\n"); - sb.append(" elements: ").append(toIndentedString(elements)).append("\n"); - sb.append("}"); - return sb.toString(); - } - - /** - * Convert the given object to string with each line indented by 4 spaces - * (except the first line). - */ - private String toIndentedString(java.lang.Object o) { - if (o == null) { - return "null"; - } - return o.toString().replace("\n", "\n "); - } - -} - diff --git a/testing/api-client/src/main/resources/api/maptology.json b/testing/api-client/src/main/resources/api/maptology.json deleted file mode 100644 index 631b25f..0000000 --- a/testing/api-client/src/main/resources/api/maptology.json +++ /dev/null @@ -1,3502 +0,0 @@ -{ - "swagger" : "2.0", - "info" : { - "description" : "Maptology Service", - "version" : "0.0.1-SNAPSHOT", - "title" : "Maptology Service", - "termsOfService" : "https://maptology.com/terms-of-service", - "contact" : { - "name" : "NES Universitaet Duisburg-Essen", - "url" : "https://www.nes.uni-due.de", - "email" : "nes-admin@uni-due.de" - }, - "license" : { - "name" : "Proprietary", - "url" : "https://maptology.com/license" - } - }, - "basePath" : "/api", - "tags" : [ { - "name" : "Default" - }, { - "name" : "Device" - }, { - "name" : "Place" - }, { - "name" : "Privilege" - }, { - "name" : "Service" - }, { - "name" : "Share" - }, { - "name" : "User" - } ], - "schemes" : [ "http", "https" ], - "paths" : { - "/devices" : { - "get" : { - "tags" : [ "Default", "Device" ], - "summary" : "Returns all devices.", - "description" : "", - "operationId" : "getDevices", - "consumes" : [ "application/json", "application/xml" ], - "produces" : [ "application/json", "application/xml" ], - "parameters" : [ { - "name" : "pageOffset", - "in" : "query", - "description" : "The offset in terms of elements.", - "required" : false, - "type" : "integer", - "default" : 0, - "format" : "int32" - }, { - "name" : "pageSize", - "in" : "query", - "description" : "The maximum number of elements on the page.", - "required" : false, - "type" : "integer", - "default" : 20, - "format" : "int32" - } ], - "responses" : { - "200" : { - "description" : "The request was successful.", - "schema" : { - "$ref" : "#/definitions/DevicePage" - } - }, - "400" : { - "description" : "Invalid request parameter." - }, - "403" : { - "description" : "Insufficient privileges for retrieval." - } - }, - "security" : [ { - "admin" : [ ] - } ] - }, - "post" : { - "tags" : [ "Default", "Device" ], - "summary" : "Creates a new device and returns its handle.", - "description" : "The response will include the auth token to be stored on the device and supplied as authentication on all subsequent api calls. Note that the auth token can not be requested after creation, so when losing the auth token you may lose access to the device data.", - "operationId" : "createDevice", - "consumes" : [ "application/json", "application/xml" ], - "produces" : [ "application/json", "application/xml" ], - "parameters" : [ { - "in" : "body", - "name" : "body", - "description" : "Necessary data from to create a device.", - "required" : true, - "schema" : { - "$ref" : "#/definitions/DeviceInfo" - } - } ], - "responses" : { - "201" : { - "description" : "The device was created successfully.", - "schema" : { - "$ref" : "#/definitions/DeviceHandle" - } - } - } - } - }, - "/devices/current" : { - "get" : { - "tags" : [ "Default", "Device" ], - "summary" : "Returns the current device.", - "description" : "", - "operationId" : "getCurrentDevice", - "consumes" : [ "application/json", "application/xml" ], - "produces" : [ "application/json", "application/xml" ], - "responses" : { - "200" : { - "description" : "The operation was successful.", - "schema" : { - "$ref" : "#/definitions/Device" - } - }, - "403" : { - "description" : "Insufficient privileges for executing this method." - }, - "404" : { - "description" : "The device was not found." - } - }, - "security" : [ { - "device" : [ ] - } ] - }, - "delete" : { - "tags" : [ "Default", "Device" ], - "summary" : "Deletes the current device.", - "description" : "", - "operationId" : "deleteCurrentDevice", - "consumes" : [ "application/json", "application/xml" ], - "produces" : [ "application/json", "application/xml" ], - "responses" : { - "200" : { - "description" : "The device was deleted successfully." - }, - "403" : { - "description" : "Insufficient privileges for executing this method." - }, - "404" : { - "description" : "The device was not found." - } - }, - "security" : [ { - "device" : [ ] - } ] - } - }, - "/devices/current/locations" : { - "post" : { - "tags" : [ "Default", "Device" ], - "summary" : "Updates the locations of the current device.", - "description" : "", - "operationId" : "addLocations", - "consumes" : [ "application/json", "application/xml" ], - "produces" : [ "application/json", "application/xml" ], - "parameters" : [ { - "in" : "body", - "name" : "body", - "description" : "The location update with the locations to add.", - "required" : true, - "schema" : { - "$ref" : "#/definitions/LocationUpdate" - } - } ], - "responses" : { - "200" : { - "description" : "The request was successfully." - }, - "400" : { - "description" : "Invalid request parameter." - }, - "403" : { - "description" : "Insufficient privileges." - } - }, - "security" : [ { - "device" : [ ] - } ] - } - }, - "/devices/{id}" : { - "get" : { - "tags" : [ "Default", "Device" ], - "summary" : "Gets a device.", - "description" : "", - "operationId" : "getDevice", - "consumes" : [ "application/json", "application/xml" ], - "produces" : [ "application/json", "application/xml" ], - "parameters" : [ { - "name" : "id", - "in" : "path", - "description" : "The device id.", - "required" : true, - "type" : "integer", - "minimum" : 0, - "pattern" : "[0-9]+", - "format" : "int64" - } ], - "responses" : { - "200" : { - "description" : "The device returned successfully.", - "schema" : { - "$ref" : "#/definitions/Device" - } - }, - "403" : { - "description" : "Insufficient privileges for executing this method." - }, - "404" : { - "description" : "The device does not exists." - } - }, - "security" : [ { - "admin" : [ ] - }, { - "user" : [ ] - } ] - }, - "put" : { - "tags" : [ "Default", "Device" ], - "summary" : "Sets the values of a device.", - "description" : "", - "operationId" : "setDevice", - "consumes" : [ "application/json", "application/xml" ], - "produces" : [ "application/json", "application/xml" ], - "parameters" : [ { - "name" : "id", - "in" : "path", - "description" : "The device id.", - "required" : true, - "type" : "integer", - "minimum" : 0, - "pattern" : "[0-9]+", - "format" : "int64" - }, { - "in" : "body", - "name" : "body", - "description" : "The device values.", - "required" : false, - "schema" : { - "$ref" : "#/definitions/Device" - } - } ], - "responses" : { - "200" : { - "description" : "The device returned successfully.", - "schema" : { - "$ref" : "#/definitions/Device" - } - }, - "403" : { - "description" : "Insufficient privileges for executing this method." - }, - "404" : { - "description" : "The device does not exists." - }, - "409" : { - "description" : "The device has been updated in parallel." - } - }, - "security" : [ { - "admin" : [ ] - } ] - }, - "delete" : { - "tags" : [ "Default", "Device" ], - "summary" : "Deletes a device.", - "description" : "", - "operationId" : "deleteDevice", - "consumes" : [ "application/json", "application/xml" ], - "produces" : [ "application/json", "application/xml" ], - "parameters" : [ { - "name" : "id", - "in" : "path", - "description" : "The device id.", - "required" : true, - "type" : "integer", - "minimum" : 0, - "pattern" : "[0-9]+", - "format" : "int64" - } ], - "responses" : { - "200" : { - "description" : "The device was deleted successfully." - }, - "403" : { - "description" : "Insufficient privileges for executing this method." - }, - "404" : { - "description" : "The device does not exists." - } - }, - "security" : [ { - "user" : [ ] - }, { - "admin" : [ ] - } ] - } - }, - "/devices/{id}/location" : { - "get" : { - "tags" : [ "Default", "Device" ], - "summary" : "Gets the last device location.", - "description" : "", - "operationId" : "getDeviceLocation", - "consumes" : [ "application/json", "application/xml" ], - "produces" : [ "application/json", "application/xml" ], - "parameters" : [ { - "name" : "id", - "in" : "path", - "description" : "The device id.", - "required" : true, - "type" : "integer", - "minimum" : 0, - "pattern" : "[0-9]+", - "format" : "int64" - } ], - "responses" : { - "200" : { - "description" : "The location has been found.", - "schema" : { - "$ref" : "#/definitions/Location" - } - }, - "403" : { - "description" : "Insufficient privileges for executing this method." - }, - "404" : { - "description" : "The device does not exists." - } - }, - "security" : [ { - "admin" : [ ] - }, { - "user" : [ ] - } ] - } - }, - "/devices/{id}/visits" : { - "get" : { - "tags" : [ "Default", "Device" ], - "summary" : "Gets the last device location.", - "description" : "", - "operationId" : "getDeviceVisits", - "consumes" : [ "application/json", "application/xml" ], - "produces" : [ "application/json", "application/xml" ], - "parameters" : [ { - "name" : "id", - "in" : "path", - "description" : "The device id.", - "required" : true, - "type" : "integer", - "minimum" : 0, - "pattern" : "[0-9]+", - "format" : "int64" - }, { - "name" : "start", - "in" : "path", - "description" : "The start time in Epoch milliseconds.", - "required" : true, - "type" : "integer", - "format" : "int64" - }, { - "name" : "duration", - "in" : "path", - "description" : "The duration in milliseconds.", - "required" : true, - "type" : "integer", - "maximum" : 172800000, - "minimum" : 0, - "format" : "int64" - } ], - "responses" : { - "200" : { - "description" : "The list of visits from the begin time for the duration.", - "schema" : { - "type" : "array", - "items" : { - "$ref" : "#/definitions/Visit" - } - } - }, - "400" : { - "description" : "Invalid request parameter." - }, - "403" : { - "description" : "Insufficient rights for executing this method." - }, - "404" : { - "description" : "The device does not exists." - } - }, - "security" : [ { - "admin" : [ ] - }, { - "user" : [ ] - } ] - } - }, - "/log/entities" : { - "get" : { - "tags" : [ "Default", "Service" ], - "summary" : "Returns a list of entity statistics.", - "description" : "", - "operationId" : "getEntityStatistics", - "produces" : [ "application/json", "application/xml" ], - "responses" : { - "200" : { - "description" : "Entity statistics retrieved successfully.", - "schema" : { - "type" : "array", - "items" : { - "$ref" : "#/definitions/EntityStatistic" - } - } - }, - "403" : { - "description" : "Insufficient privileges for retrieval." - } - }, - "security" : [ { - "admin" : [ ] - } ] - } - }, - "/log/load" : { - "get" : { - "tags" : [ "Default", "Service" ], - "summary" : "Returns the current load statistic.", - "description" : "", - "operationId" : "getLoadStatistic", - "produces" : [ "application/json", "application/xml" ], - "responses" : { - "200" : { - "description" : "Load statistic retrieved successfully.", - "schema" : { - "$ref" : "#/definitions/LoadStatistic" - } - }, - "403" : { - "description" : "Insufficient privileges for retrieval." - } - }, - "security" : [ { - "admin" : [ ] - } ] - } - }, - "/log/messages" : { - "get" : { - "tags" : [ "Default", "Service" ], - "summary" : "Returns a list of log messages starting from a particular id.", - "description" : "", - "operationId" : "getLogMessages", - "produces" : [ "application/json", "application/xml" ], - "parameters" : [ { - "name" : "from", - "in" : "query", - "description" : "The id of the first message to retrieve.", - "required" : false, - "type" : "integer", - "default" : 0, - "minimum" : 0, - "format" : "int64" - } ], - "responses" : { - "200" : { - "description" : "Log messages retrieved successfully.", - "schema" : { - "type" : "array", - "items" : { - "$ref" : "#/definitions/LogMessage" - } - } - }, - "400" : { - "description" : "Invalid request parameter." - }, - "403" : { - "description" : "Insufficient privileges for retrieval." - } - }, - "security" : [ { - "admin" : [ ] - } ] - } - }, - "/log/system" : { - "get" : { - "tags" : [ "Default", "Service" ], - "summary" : "Returns the system statistic.", - "description" : "", - "operationId" : "getSystemStatistic", - "produces" : [ "application/json", "application/xml" ], - "responses" : { - "200" : { - "description" : "System statistic retrieved successfully.", - "schema" : { - "$ref" : "#/definitions/LoadStatistic" - } - }, - "403" : { - "description" : "Insufficient privileges for retrieval." - } - }, - "security" : [ { - "admin" : [ ] - } ] - } - }, - "/notices" : { - "get" : { - "tags" : [ "Default", "Service" ], - "summary" : "Returns a page of notices.", - "description" : "", - "operationId" : "getNotices", - "consumes" : [ "application/json", "application/xml" ], - "produces" : [ "application/json", "application/xml" ], - "parameters" : [ { - "name" : "pageOffset", - "in" : "query", - "description" : "The offset in terms of elements.", - "required" : false, - "type" : "integer", - "default" : 0, - "format" : "int32" - }, { - "name" : "pageSize", - "in" : "query", - "description" : "The maximum number of elements on the page.", - "required" : false, - "type" : "integer", - "default" : 20, - "format" : "int32" - } ], - "responses" : { - "200" : { - "description" : "Notice page retrieved successfully.", - "schema" : { - "$ref" : "#/definitions/NoticePage" - } - }, - "400" : { - "description" : "Invalid request parameter." - }, - "403" : { - "description" : "Insufficient privileges for retrival." - } - }, - "security" : [ { - "admin" : [ ] - } ] - }, - "post" : { - "tags" : [ "Default", "Service" ], - "summary" : "Adds a new notice and returns the notice as well as its location.", - "description" : "", - "operationId" : "addNotice", - "consumes" : [ "application/json", "application/xml" ], - "produces" : [ "application/json", "application/xml" ], - "parameters" : [ { - "in" : "body", - "name" : "body", - "description" : "The new notice to add.", - "required" : true, - "schema" : { - "$ref" : "#/definitions/Notice" - } - } ], - "responses" : { - "201" : { - "description" : "Notice created successfully.", - "schema" : { - "$ref" : "#/definitions/Notice" - } - }, - "400" : { - "description" : "Invalid notice." - }, - "403" : { - "description" : "Insufficient privileges for addition." - } - }, - "security" : [ { - "admin" : [ ] - } ] - } - }, - "/notices/active" : { - "get" : { - "tags" : [ "Default", "Service" ], - "summary" : "Returns a page of notices.", - "description" : "", - "operationId" : "getActiveNotices", - "consumes" : [ "application/json", "application/xml" ], - "produces" : [ "application/json", "application/xml" ], - "parameters" : [ { - "name" : "pageOffset", - "in" : "query", - "description" : "The offset in terms of elements.", - "required" : false, - "type" : "integer", - "default" : 0, - "format" : "int32" - }, { - "name" : "pageSize", - "in" : "query", - "description" : "The maximum number of elements on the page.", - "required" : false, - "type" : "integer", - "default" : 20, - "format" : "int32" - } ], - "responses" : { - "200" : { - "description" : "Notice page retrieved successfully.", - "schema" : { - "$ref" : "#/definitions/NoticePage" - } - }, - "400" : { - "description" : "Invalid request parameter." - } - } - } - }, - "/notices/updated" : { - "get" : { - "tags" : [ "Default", "Service" ], - "summary" : "Returns all active notices modified after the date.", - "description" : "", - "operationId" : "getUpdatedNotices", - "consumes" : [ "application/json", "application/xml" ], - "produces" : [ "application/json", "application/xml" ], - "parameters" : [ { - "name" : "since", - "in" : "query", - "description" : "The earlies time in epoch milliseconds.", - "required" : false, - "type" : "integer", - "default" : 0, - "format" : "int64" - } ], - "responses" : { - "200" : { - "description" : "successful operation", - "schema" : { - "type" : "array", - "items" : { - "$ref" : "#/definitions/Notice" - } - } - } - } - } - }, - "/notices/{id}" : { - "get" : { - "tags" : [ "Default", "Service" ], - "summary" : "Returns the notice with the specified id.", - "description" : "", - "operationId" : "getNotice", - "consumes" : [ "application/json", "application/xml" ], - "produces" : [ "application/json", "application/xml" ], - "parameters" : [ { - "name" : "id", - "in" : "path", - "description" : "The id of the notice.", - "required" : true, - "type" : "integer", - "pattern" : "-?\\d+", - "format" : "int64" - } ], - "responses" : { - "200" : { - "description" : "Notice retrieved successfully.", - "schema" : { - "$ref" : "#/definitions/Notice" - } - }, - "403" : { - "description" : "Insufficient privileges for retrieval." - }, - "404" : { - "description" : "Notice not found." - } - }, - "security" : [ { - "admin" : [ ] - } ] - }, - "put" : { - "tags" : [ "Default", "Service" ], - "summary" : "Updates an existing notice.", - "description" : "", - "operationId" : "setNotice", - "consumes" : [ "application/json", "application/xml" ], - "produces" : [ "application/json", "application/xml" ], - "parameters" : [ { - "name" : "id", - "in" : "path", - "description" : "The id of the notice.", - "required" : true, - "type" : "integer", - "pattern" : "-?\\d+", - "format" : "int64" - }, { - "in" : "body", - "name" : "body", - "description" : "The data of the notice to set.", - "required" : true, - "schema" : { - "$ref" : "#/definitions/Notice" - } - } ], - "responses" : { - "200" : { - "description" : "Notice updated successfully.", - "schema" : { - "$ref" : "#/definitions/Notice" - } - }, - "400" : { - "description" : "Invalid notice." - }, - "403" : { - "description" : "Insufficient privileges for modification." - }, - "409" : { - "description" : "Update conflicts with another update." - } - }, - "security" : [ { - "admin" : [ ] - } ] - } - }, - "/places/{id}" : { - "get" : { - "tags" : [ "Default", "Place" ], - "summary" : "Returns the place with the specified id.", - "description" : "", - "operationId" : "getPlace", - "consumes" : [ "application/json", "application/xml" ], - "produces" : [ "application/json", "application/xml" ], - "parameters" : [ { - "name" : "id", - "in" : "path", - "description" : "The place id.", - "required" : true, - "type" : "integer", - "pattern" : "[0-9]+", - "format" : "int64" - } ], - "responses" : { - "200" : { - "description" : "The request was successful.", - "schema" : { - "$ref" : "#/definitions/Place" - } - }, - "400" : { - "description" : "Invalid request parameter." - }, - "403" : { - "description" : "Insufficient privileges to execute." - }, - "404" : { - "description" : "The place does not exists." - } - } - }, - "put" : { - "tags" : [ "Default", "Place" ], - "summary" : "Updates the place with the specified id.", - "description" : "", - "operationId" : "setPlace", - "consumes" : [ "application/json", "application/xml" ], - "produces" : [ "application/json", "application/xml" ], - "parameters" : [ { - "name" : "id", - "in" : "path", - "description" : "The place id.", - "required" : true, - "type" : "integer", - "pattern" : "[0-9]+", - "format" : "int64" - }, { - "in" : "body", - "name" : "body", - "description" : "The place to set.", - "required" : true, - "schema" : { - "$ref" : "#/definitions/Place" - } - } ], - "responses" : { - "200" : { - "description" : "The request was successful.", - "schema" : { - "$ref" : "#/definitions/Place" - } - }, - "400" : { - "description" : "Invalid request parameter." - }, - "403" : { - "description" : "Insufficient privileges to execute." - }, - "404" : { - "description" : "The place does not exists." - }, - "409" : { - "description" : "Parallel modification detected.", - "schema" : { - "$ref" : "#/definitions/Place" - } - } - } - } - }, - "/places/{id}/visits" : { - "get" : { - "tags" : [ "Default", "Place" ], - "summary" : "Returns the visits for a particular place.", - "description" : "", - "operationId" : "getPlaceVisits", - "consumes" : [ "application/json", "application/xml" ], - "produces" : [ "application/json", "application/xml" ], - "parameters" : [ { - "name" : "id", - "in" : "path", - "description" : "The place id.", - "required" : true, - "type" : "integer", - "pattern" : "[0-9]+", - "format" : "int64" - }, { - "name" : "pageOffset", - "in" : "query", - "description" : "The offset in terms of elements.", - "required" : false, - "type" : "integer", - "default" : 0, - "format" : "int32" - }, { - "name" : "pageSize", - "in" : "query", - "description" : "The maximum number of elements on the page.", - "required" : false, - "type" : "integer", - "default" : 20, - "format" : "int32" - } ], - "responses" : { - "200" : { - "description" : "The request was successful.", - "schema" : { - "$ref" : "#/definitions/VisitPage" - } - }, - "400" : { - "description" : "Invalid request parameter." - }, - "403" : { - "description" : "Insufficient rights for executing this method." - }, - "404" : { - "description" : "The place does not exists." - } - } - } - }, - "/privileges/{id}" : { - "get" : { - "tags" : [ "Default", "Privilege" ], - "summary" : "Returns the privileges for a particular user.", - "description" : "", - "operationId" : "getPrivilege", - "consumes" : [ "application/json", "application/xml" ], - "produces" : [ "application/json", "application/xml" ], - "parameters" : [ { - "name" : "id", - "in" : "path", - "description" : "The privilege id.", - "required" : true, - "type" : "integer", - "pattern" : "[0-9]+", - "format" : "int64" - } ], - "responses" : { - "200" : { - "description" : "The request was successful.", - "schema" : { - "$ref" : "#/definitions/Privilege" - } - }, - "400" : { - "description" : "Invalid request parameter." - }, - "403" : { - "description" : "Insufficient access rights." - }, - "404" : { - "description" : "The share does not exists." - } - }, - "security" : [ { - "user" : [ ] - }, { - "admin" : [ ] - } ] - }, - "delete" : { - "tags" : [ "Default", "Privilege" ], - "summary" : "Deletes a particular privilege.", - "description" : "", - "operationId" : "deletePrivilege", - "consumes" : [ "application/json", "application/xml" ], - "produces" : [ "application/json", "application/xml" ], - "parameters" : [ { - "name" : "id", - "in" : "path", - "description" : "The privilege id.", - "required" : true, - "type" : "integer", - "pattern" : "[0-9]+", - "format" : "int64" - } ], - "responses" : { - "200" : { - "description" : "The request was successful." - }, - "400" : { - "description" : "Invalid request parameter." - }, - "403" : { - "description" : "Insufficient access rights." - }, - "404" : { - "description" : "The share does not exists." - } - }, - "security" : [ { - "user" : [ ] - }, { - "admin" : [ ] - } ] - } - }, - "/privileges/{id}/location" : { - "get" : { - "tags" : [ "Default", "Privilege" ], - "summary" : "Returns the location for a particular privilege.", - "description" : "", - "operationId" : "getPrivilegeLocation", - "consumes" : [ "application/json", "application/xml" ], - "produces" : [ "application/json", "application/xml" ], - "parameters" : [ { - "name" : "id", - "in" : "path", - "description" : "The privilege id.", - "required" : true, - "type" : "integer", - "pattern" : "[0-9]+", - "format" : "int64" - } ], - "responses" : { - "200" : { - "description" : "The request was successful.", - "schema" : { - "$ref" : "#/definitions/Location" - } - }, - "400" : { - "description" : "Invalid request parameter." - }, - "403" : { - "description" : "Insufficient access rights." - }, - "404" : { - "description" : "The privilege does not exists." - } - }, - "security" : [ { - "user" : [ ] - }, { - "admin" : [ ] - } ] - } - }, - "/shares" : { - "post" : { - "tags" : [ "Default", "Share" ], - "summary" : "Creates a new share.", - "description" : "", - "operationId" : "createShare", - "consumes" : [ "application/json", "application/xml" ], - "produces" : [ "application/json", "application/xml" ], - "parameters" : [ { - "in" : "body", - "name" : "body", - "description" : "Necessary data from to create a share.", - "required" : true, - "schema" : { - "$ref" : "#/definitions/ShareInfo" - } - } ], - "responses" : { - "201" : { - "description" : "The share was created successfully.", - "schema" : { - "$ref" : "#/definitions/Share" - } - }, - "400" : { - "description" : "Invalid request parameter." - }, - "403" : { - "description" : "Insufficient privileges for this method." - } - }, - "security" : [ { - "device" : [ ] - } ] - } - }, - "/shares/{id}" : { - "get" : { - "tags" : [ "Default", "Share" ], - "summary" : "Returns a share.", - "description" : "", - "operationId" : "getShare", - "consumes" : [ "application/json", "application/xml" ], - "produces" : [ "application/json", "application/xml" ], - "parameters" : [ { - "name" : "id", - "in" : "path", - "description" : "The share id.", - "required" : true, - "type" : "integer", - "pattern" : "([0-9])+", - "format" : "int64" - } ], - "responses" : { - "200" : { - "description" : "The request was successful.", - "schema" : { - "$ref" : "#/definitions/Share" - } - }, - "400" : { - "description" : "Invalid request parameter." - }, - "403" : { - "description" : "Insufficient privileges for this method." - }, - "404" : { - "description" : "The share does not exists" - } - }, - "security" : [ { - "device" : [ ] - } ] - }, - "put" : { - "tags" : [ "Default", "Share" ], - "summary" : "Updates an existing share.", - "description" : "", - "operationId" : "setShare", - "consumes" : [ "application/json", "application/xml" ], - "produces" : [ "application/json", "application/xml" ], - "parameters" : [ { - "name" : "id", - "in" : "path", - "description" : "The share id.", - "required" : true, - "type" : "integer", - "pattern" : "([0-9])+", - "format" : "int64" - }, { - "in" : "body", - "name" : "body", - "description" : "The new share to set.", - "required" : false, - "schema" : { - "$ref" : "#/definitions/Share" - } - } ], - "responses" : { - "200" : { - "description" : "The request was successful.", - "schema" : { - "$ref" : "#/definitions/Share" - } - }, - "400" : { - "description" : "Invalid request parameter." - }, - "403" : { - "description" : "Insufficient privileges to set the share." - }, - "404" : { - "description" : "The share does not exists." - }, - "409" : { - "description" : "Conflicting change detected.", - "schema" : { - "$ref" : "#/definitions/Share" - } - } - }, - "security" : [ { - "device" : [ ] - } ] - }, - "delete" : { - "tags" : [ "Default", "Share" ], - "summary" : "Delete a share.", - "description" : "", - "operationId" : "deleteShare", - "consumes" : [ "application/json", "application/xml" ], - "produces" : [ "application/json", "application/xml" ], - "parameters" : [ { - "name" : "id", - "in" : "path", - "description" : "The share id.", - "required" : true, - "type" : "integer", - "pattern" : "([0-9])+", - "format" : "int64" - } ], - "responses" : { - "200" : { - "description" : "The request was successful." - }, - "400" : { - "description" : "Invalid request parameter." - }, - "403" : { - "description" : "Insufficient privileges for this method." - }, - "404" : { - "description" : "The share does not exists" - } - }, - "security" : [ { - "device" : [ ] - } ] - } - }, - "/shares/{token}/info" : { - "get" : { - "tags" : [ "Default", "Share" ], - "summary" : "Get a share info by its secret token.", - "description" : "", - "operationId" : "getShareInfo", - "consumes" : [ "application/json", "application/xml" ], - "produces" : [ "application/json", "application/xml" ], - "parameters" : [ { - "name" : "token", - "in" : "path", - "description" : "The secret token.", - "required" : true, - "type" : "string", - "pattern" : "[A-Za-z0-9_-]+" - } ], - "responses" : { - "200" : { - "description" : "The request was successful.", - "schema" : { - "$ref" : "#/definitions/ShareInfo" - } - }, - "400" : { - "description" : "Invalid request parameter." - }, - "404" : { - "description" : "The share does not exists" - } - } - } - }, - "/shares/{token}/location" : { - "get" : { - "tags" : [ "Default", "Share" ], - "summary" : "Get a shared location by its secret token.", - "description" : "", - "operationId" : "getShareLocation", - "consumes" : [ "application/json", "application/xml" ], - "produces" : [ "application/json", "application/xml" ], - "parameters" : [ { - "name" : "token", - "in" : "path", - "description" : "The secret token.", - "required" : true, - "type" : "string", - "pattern" : "[A-Za-z0-9_-]+" - } ], - "responses" : { - "200" : { - "description" : "The request was successful.", - "schema" : { - "$ref" : "#/definitions/Location" - } - }, - "400" : { - "description" : "Invalid request parameter." - }, - "404" : { - "description" : "The share does not exists" - } - } - } - }, - "/users" : { - "get" : { - "tags" : [ "Default", "User" ], - "summary" : "Returns a list of users.", - "description" : "", - "operationId" : "getUsers", - "consumes" : [ "application/json", "application/xml" ], - "produces" : [ "application/json", "application/xml" ], - "parameters" : [ { - "name" : "pageOffset", - "in" : "query", - "description" : "The offset in terms of elements.", - "required" : false, - "type" : "integer", - "default" : 0, - "format" : "int32" - }, { - "name" : "pageSize", - "in" : "query", - "description" : "The maximum number of elements on the page.", - "required" : false, - "type" : "integer", - "default" : 20, - "format" : "int32" - } ], - "responses" : { - "200" : { - "description" : "User page retrieved successfully.", - "schema" : { - "$ref" : "#/definitions/UserPage" - } - }, - "400" : { - "description" : "Invalid request parameter." - }, - "403" : { - "description" : "Insufficient privileges for retrieval." - } - }, - "security" : [ { - "admin" : [ ] - } ] - }, - "post" : { - "tags" : [ "Default", "User" ], - "summary" : "Adds a user account with the specified roles and emails.", - "description" : "", - "operationId" : "addUser", - "consumes" : [ "application/json", "application/xml" ], - "produces" : [ "application/json", "application/xml" ], - "parameters" : [ { - "in" : "body", - "name" : "body", - "description" : "The data for the new user.", - "required" : true, - "schema" : { - "$ref" : "#/definitions/User" - } - } ], - "responses" : { - "201" : { - "description" : "User added successfully.", - "schema" : { - "$ref" : "#/definitions/User" - } - }, - "400" : { - "description" : "Invalid user." - }, - "403" : { - "description" : "Insufficient privileges to add the user." - }, - "409" : { - "description" : "User login exists already." - } - }, - "security" : [ { - "admin" : [ ] - } ] - } - }, - "/users/current" : { - "get" : { - "tags" : [ "Default", "User" ], - "summary" : "Returns the user currently authorized.", - "description" : "", - "operationId" : "getCurrentUser", - "consumes" : [ "application/json", "application/xml" ], - "produces" : [ "application/json", "application/xml" ], - "responses" : { - "200" : { - "description" : "User retrieved successfully.", - "schema" : { - "$ref" : "#/definitions/User" - } - }, - "403" : { - "description" : "No valid authorization found." - } - }, - "security" : [ { - "user" : [ ] - } ] - }, - "put" : { - "tags" : [ "Default", "User" ], - "summary" : "Updates the currently authorized user.", - "description" : "", - "operationId" : "setCurrentUser", - "consumes" : [ "application/json", "application/xml" ], - "produces" : [ "application/json", "application/xml" ], - "parameters" : [ { - "in" : "body", - "name" : "body", - "description" : "The new user values to set.", - "required" : true, - "schema" : { - "$ref" : "#/definitions/User" - } - } ], - "responses" : { - "200" : { - "description" : "User updated successfully.", - "schema" : { - "$ref" : "#/definitions/User" - } - }, - "400" : { - "description" : "Invalid user." - }, - "403" : { - "description" : "No valid authorization found." - }, - "409" : { - "description" : "User modified in parallel.", - "schema" : { - "$ref" : "#/definitions/User" - } - } - }, - "security" : [ { - "user" : [ ] - } ] - } - }, - "/users/current/devices" : { - "get" : { - "tags" : [ "Default", "Device" ], - "summary" : "Returns the list of devices for the current user.", - "description" : "", - "operationId" : "getCurrentUserDevices", - "consumes" : [ "application/json", "application/xml" ], - "produces" : [ "application/json", "application/xml" ], - "parameters" : [ { - "name" : "pageOffset", - "in" : "query", - "description" : "The offset in terms of elements.", - "required" : false, - "type" : "integer", - "default" : 0, - "format" : "int32" - }, { - "name" : "pageSize", - "in" : "query", - "description" : "The maximum number of elements on the page.", - "required" : false, - "type" : "integer", - "default" : 20, - "format" : "int32" - } ], - "responses" : { - "200" : { - "description" : "The list of devices of the current user", - "schema" : { - "$ref" : "#/definitions/DevicePage" - } - }, - "403" : { - "description" : "Insufficient privileges for executing this method." - }, - "404" : { - "description" : "The device was not found." - } - }, - "security" : [ { - "user" : [ ] - } ] - } - }, - "/users/current/password" : { - "put" : { - "tags" : [ "Default", "User" ], - "summary" : "Sets the password of the currently authorized user.", - "description" : "", - "operationId" : "setCurrentPassword", - "consumes" : [ "application/json", "application/xml" ], - "produces" : [ "application/json", "application/xml" ], - "parameters" : [ { - "in" : "body", - "name" : "body", - "description" : "The new password to set.", - "required" : true, - "schema" : { - "$ref" : "#/definitions/UserPassword" - } - } ], - "responses" : { - "200" : { - "description" : "Password updated successfully.", - "schema" : { - "$ref" : "#/definitions/User" - } - }, - "400" : { - "description" : "Invalid password." - }, - "403" : { - "description" : "No valid authorization found." - } - }, - "security" : [ { - "user" : [ ] - } ] - } - }, - "/users/current/places" : { - "get" : { - "tags" : [ "Default", "User" ], - "summary" : "Returns the places for the current user.", - "description" : "", - "operationId" : "getCurrentUserPlaces", - "consumes" : [ "application/json", "application/xml" ], - "produces" : [ "application/json", "application/xml" ], - "parameters" : [ { - "name" : "pageOffset", - "in" : "query", - "description" : "The offset in terms of elements.", - "required" : false, - "type" : "integer", - "default" : 0, - "format" : "int32" - }, { - "name" : "pageSize", - "in" : "query", - "description" : "The maximum number of elements on the page.", - "required" : false, - "type" : "integer", - "default" : 20, - "format" : "int32" - } ], - "responses" : { - "200" : { - "description" : "The request was successful.", - "schema" : { - "$ref" : "#/definitions/PlacePage" - } - }, - "400" : { - "description" : "Invalid request parameter." - }, - "403" : { - "description" : "Insufficient rights to execute this method." - }, - "404" : { - "description" : "The place does not exists." - } - } - } - }, - "/users/current/privileges" : { - "get" : { - "tags" : [ "Default", "User" ], - "summary" : "Returns the privileges for the current user.", - "description" : "", - "operationId" : "getCurrentUserPrivileges", - "consumes" : [ "application/json", "application/xml" ], - "produces" : [ "application/json", "application/xml" ], - "parameters" : [ { - "name" : "pageOffset", - "in" : "query", - "description" : "The offset in terms of elements.", - "required" : false, - "type" : "integer", - "default" : 0, - "format" : "int32" - }, { - "name" : "pageSize", - "in" : "query", - "description" : "The maximum number of elements on the page.", - "required" : false, - "type" : "integer", - "default" : 20, - "format" : "int32" - } ], - "responses" : { - "200" : { - "description" : "The request was successful.", - "schema" : { - "$ref" : "#/definitions/PrivilegePage" - } - }, - "400" : { - "description" : "Invalid request parameter." - }, - "403" : { - "description" : "Insufficient access rights." - } - }, - "security" : [ { - "user" : [ ] - } ] - }, - "post" : { - "tags" : [ "Default", "User" ], - "summary" : "Add a privilege for the specified user.", - "description" : "", - "operationId" : "addCurrentUserPrivilege", - "consumes" : [ "application/json", "application/xml" ], - "produces" : [ "application/json", "application/xml" ], - "parameters" : [ { - "name" : "share", - "in" : "query", - "description" : "The token of the share.", - "required" : true, - "type" : "string" - } ], - "responses" : { - "200" : { - "description" : "The request was successful.", - "schema" : { - "$ref" : "#/definitions/Privilege" - } - }, - "400" : { - "description" : "Invalid request parameter." - }, - "403" : { - "description" : "Insufficient access rights." - }, - "404" : { - "description" : "The share does not exists." - } - }, - "security" : [ { - "user" : [ ] - } ] - } - }, - "/users/password/{token}" : { - "put" : { - "tags" : [ "Default", "User" ], - "summary" : "Sets the password of a user account using a token received via email.", - "description" : "", - "operationId" : "resetUserPassword", - "consumes" : [ "application/json", "application/xml" ], - "produces" : [ "application/json", "application/xml" ], - "parameters" : [ { - "name" : "token", - "in" : "path", - "description" : "The secret token received via email.", - "required" : true, - "type" : "string" - }, { - "in" : "body", - "name" : "body", - "description" : "The new user password.", - "required" : true, - "schema" : { - "$ref" : "#/definitions/UserPassword" - } - } ], - "responses" : { - "200" : { - "description" : "Password updated successfully.", - "schema" : { - "$ref" : "#/definitions/User" - } - }, - "400" : { - "description" : "Invalid token or password." - }, - "403" : { - "description" : "Password modification not allowed." - } - } - } - }, - "/users/register" : { - "post" : { - "tags" : [ "Default", "User" ], - "summary" : "Registers a new user and sends an email account verification.", - "description" : "", - "operationId" : "registerUser", - "consumes" : [ "application/json", "application/xml" ], - "produces" : [ "application/json", "application/xml" ], - "parameters" : [ { - "in" : "body", - "name" : "body", - "description" : "The data of the new user.", - "required" : true, - "schema" : { - "$ref" : "#/definitions/UserRegistration" - } - } ], - "responses" : { - "201" : { - "description" : "User registered successfully.", - "schema" : { - "$ref" : "#/definitions/User" - } - }, - "400" : { - "description" : "Invalid user registration." - }, - "409" : { - "description" : "User login already registered." - } - } - } - }, - "/users/reset" : { - "post" : { - "tags" : [ "Default", "User" ], - "summary" : "Sends a password reset email to the correspondence email account of a user.", - "description" : "", - "operationId" : "resetUser", - "consumes" : [ "application/json", "application/xml" ], - "produces" : [ "application/json", "application/xml" ], - "parameters" : [ { - "name" : "login", - "in" : "query", - "description" : "The login of the user to reset.", - "required" : true, - "type" : "string" - } ], - "responses" : { - "204" : { - "description" : "Reset email sent successfully." - }, - "400" : { - "description" : "Invalid request parameter." - }, - "403" : { - "description" : "Login does not exist or email is not verified." - } - } - } - }, - "/users/search" : { - "get" : { - "tags" : [ "Default", "User" ], - "summary" : "Returns a list of users whose login name or name contains the term.", - "description" : "", - "operationId" : "searchUsers", - "consumes" : [ "application/json", "application/xml" ], - "produces" : [ "application/json", "application/xml" ], - "parameters" : [ { - "name" : "pageOffset", - "in" : "query", - "description" : "The offset in terms of elements.", - "required" : false, - "type" : "integer", - "default" : 0, - "format" : "int32" - }, { - "name" : "pageSize", - "in" : "query", - "description" : "The maximum number of elements on the page.", - "required" : false, - "type" : "integer", - "default" : 20, - "format" : "int32" - }, { - "name" : "term", - "in" : "query", - "description" : "The search term.", - "required" : true, - "type" : "string" - } ], - "responses" : { - "200" : { - "description" : "User page retrieved successfully.", - "schema" : { - "$ref" : "#/definitions/UserPage" - } - }, - "400" : { - "description" : "Invalid request parameter." - }, - "403" : { - "description" : "Insufficient privileges for retrieval." - } - }, - "security" : [ { - "admin" : [ ] - } ] - } - }, - "/users/verify/{token}" : { - "put" : { - "tags" : [ "Default", "User" ], - "summary" : "Verifies an email address using a token received via email.", - "description" : "", - "operationId" : "verifyUserEmail", - "consumes" : [ "application/json", "application/xml" ], - "produces" : [ "application/json", "application/xml" ], - "parameters" : [ { - "name" : "token", - "in" : "path", - "description" : "The secret token received via email.", - "required" : true, - "type" : "string" - } ], - "responses" : { - "204" : { - "description" : "Email verified successfully." - }, - "400" : { - "description" : "Invalid token." - }, - "403" : { - "description" : "Email verification is not valid." - } - } - } - }, - "/users/{id}" : { - "get" : { - "tags" : [ "Default", "User" ], - "summary" : "Returns the user account with the specified id.", - "description" : "", - "operationId" : "getUser", - "consumes" : [ "application/json", "application/xml" ], - "produces" : [ "application/json", "application/xml" ], - "parameters" : [ { - "name" : "id", - "in" : "path", - "description" : "The id of the user to retrieve.", - "required" : true, - "type" : "integer", - "pattern" : "([0-9])+", - "format" : "int64" - } ], - "responses" : { - "200" : { - "description" : "User retrieved successfully.", - "schema" : { - "$ref" : "#/definitions/User" - } - }, - "403" : { - "description" : "Insufficient privileges to retrieve the user." - } - }, - "security" : [ { - "admin" : [ ] - } ] - }, - "put" : { - "tags" : [ "Default", "User" ], - "summary" : "Updates the values of a particular user account.", - "description" : "", - "operationId" : "setUser", - "consumes" : [ "application/json", "application/xml" ], - "produces" : [ "application/json", "application/xml" ], - "parameters" : [ { - "name" : "id", - "in" : "path", - "description" : "The id of the user to set.", - "required" : true, - "type" : "integer", - "pattern" : "([0-9])+", - "format" : "int64" - }, { - "in" : "body", - "name" : "body", - "description" : "The new user data to set.", - "required" : true, - "schema" : { - "$ref" : "#/definitions/User" - } - } ], - "responses" : { - "200" : { - "description" : "User updated successfully.", - "schema" : { - "$ref" : "#/definitions/User" - } - }, - "400" : { - "description" : "Invalid user." - }, - "403" : { - "description" : "Insufficient privileges to retrieve the user." - }, - "409" : { - "description" : "User modified in parallel.", - "schema" : { - "$ref" : "#/definitions/User" - } - } - }, - "security" : [ { - "admin" : [ ] - } ] - } - }, - "/users/{id}/password" : { - "put" : { - "tags" : [ "Default", "User" ], - "summary" : "Sets the password of a user.", - "description" : "", - "operationId" : "setUserPassword", - "consumes" : [ "application/json", "application/xml" ], - "produces" : [ "application/json", "application/xml" ], - "parameters" : [ { - "name" : "id", - "in" : "path", - "description" : "The id of the user to change.", - "required" : true, - "type" : "integer", - "pattern" : "([0-9])+", - "format" : "int64" - }, { - "in" : "body", - "name" : "body", - "description" : "The new password.", - "required" : true, - "schema" : { - "$ref" : "#/definitions/UserPassword" - } - } ], - "responses" : { - "200" : { - "description" : "Password updated successfully.", - "schema" : { - "$ref" : "#/definitions/User" - } - }, - "400" : { - "description" : "Invalid password." - }, - "403" : { - "description" : "Password modification not allowed." - } - }, - "security" : [ { - "admin" : [ ] - } ] - } - }, - "/users/{id}/places" : { - "get" : { - "tags" : [ "Default", "User" ], - "summary" : "Returns the places for a particular user.", - "description" : "", - "operationId" : "getUserPlaces", - "consumes" : [ "application/json", "application/xml" ], - "produces" : [ "application/json", "application/xml" ], - "parameters" : [ { - "name" : "id", - "in" : "path", - "description" : "The user id.", - "required" : true, - "type" : "integer", - "pattern" : "[0-9]+", - "format" : "int64" - }, { - "name" : "pageOffset", - "in" : "query", - "description" : "The offset in terms of elements.", - "required" : false, - "type" : "integer", - "default" : 0, - "format" : "int32" - }, { - "name" : "pageSize", - "in" : "query", - "description" : "The maximum number of elements on the page.", - "required" : false, - "type" : "integer", - "default" : 20, - "format" : "int32" - } ], - "responses" : { - "200" : { - "description" : "The request was successful.", - "schema" : { - "$ref" : "#/definitions/PlacePage" - } - }, - "400" : { - "description" : "Invalid request parameter." - }, - "404" : { - "description" : "The place does not exists." - } - } - } - }, - "/users/{id}/privileges" : { - "get" : { - "tags" : [ "Default", "User" ], - "summary" : "Returns the privileges for a particular user.", - "description" : "", - "operationId" : "getUserPrivileges", - "consumes" : [ "application/json", "application/xml" ], - "produces" : [ "application/json", "application/xml" ], - "parameters" : [ { - "name" : "id", - "in" : "path", - "description" : "The user id.", - "required" : true, - "type" : "integer", - "pattern" : "[0-9]+", - "format" : "int64" - }, { - "name" : "pageOffset", - "in" : "query", - "description" : "The offset in terms of elements.", - "required" : false, - "type" : "integer", - "default" : 0, - "format" : "int32" - }, { - "name" : "pageSize", - "in" : "query", - "description" : "The maximum number of elements on the page.", - "required" : false, - "type" : "integer", - "default" : 20, - "format" : "int32" - } ], - "responses" : { - "200" : { - "description" : "The request was successful.", - "schema" : { - "$ref" : "#/definitions/PrivilegePage" - } - }, - "400" : { - "description" : "Invalid request parameter." - }, - "403" : { - "description" : "Insufficient access rights." - }, - "404" : { - "description" : "The share does not exists." - } - }, - "security" : [ { - "admin" : [ ] - } ] - }, - "post" : { - "tags" : [ "Default", "User" ], - "summary" : "Returns the privileges for a particular user.", - "description" : "", - "operationId" : "addUserPrivilege", - "consumes" : [ "application/json", "application/xml" ], - "produces" : [ "application/json", "application/xml" ], - "parameters" : [ { - "name" : "id", - "in" : "path", - "description" : "The user id.", - "required" : true, - "type" : "integer", - "pattern" : "[0-9]+", - "format" : "int64" - }, { - "name" : "share", - "in" : "query", - "description" : "The token of the share.", - "required" : true, - "type" : "string" - } ], - "responses" : { - "200" : { - "description" : "The request was successful.", - "schema" : { - "$ref" : "#/definitions/Privilege" - } - }, - "400" : { - "description" : "Invalid request parameter." - }, - "403" : { - "description" : "Insufficient access rights." - }, - "404" : { - "description" : "The share does not exists." - } - }, - "security" : [ { - "admin" : [ ] - } ] - } - }, - "/versions/build" : { - "get" : { - "tags" : [ "Default", "Service" ], - "summary" : "Returns the build version.", - "description" : "", - "operationId" : "getBuildVersion", - "produces" : [ "application/json", "application/xml" ], - "responses" : { - "200" : { - "description" : "Build version retrieved successfully.", - "schema" : { - "$ref" : "#/definitions/BuildVersion" - } - } - } - } - } - }, - "securityDefinitions" : { - "admin" : { - "description" : "Operations requiring admin privileges.", - "type" : "basic" - }, - "device" : { - "description" : "Operations requiring device privileges.", - "type" : "apiKey", - "name" : "Authorization", - "in" : "header" - }, - "user" : { - "description" : "Operations requiring a valid user.", - "type" : "basic" - } - }, - "definitions" : { - "BuildVersion" : { - "type" : "object", - "required" : [ "build", "creator", "time", "version" ], - "properties" : { - "time" : { - "type" : "integer", - "format" : "int64", - "xml" : { - "attribute" : true - }, - "description" : "The build time in Epoch milliseconds." - }, - "build" : { - "type" : "string", - "xml" : { - "attribute" : true - }, - "description" : "The build number." - }, - "creator" : { - "type" : "string", - "xml" : { - "attribute" : true - }, - "description" : "The creator of the build." - }, - "version" : { - "type" : "string", - "xml" : { - "attribute" : true - }, - "description" : "The version of the build." - } - }, - "description" : "Represents version information about the running build." - }, - "Coordinate" : { - "type" : "object", - "required" : [ "latitude", "longitude" ], - "properties" : { - "longitude" : { - "type" : "number", - "format" : "double", - "xml" : { - "attribute" : true - }, - "description" : "The longitude of a location.", - "minimum" : -180, - "maximum" : 180 - }, - "latitude" : { - "type" : "number", - "format" : "double", - "xml" : { - "attribute" : true - }, - "description" : "The latitude of a location.", - "minimum" : -90, - "maximum" : 90 - } - }, - "description" : "Represents a WGS84 position." - }, - "Device" : { - "type" : "object", - "required" : [ "device", "manufacturer", "model", "os" ], - "properties" : { - "id" : { - "type" : "integer", - "format" : "int64", - "xml" : { - "attribute" : true - }, - "description" : "The unique identifier of the data.", - "readOnly" : true - }, - "creationTime" : { - "type" : "integer", - "format" : "int64", - "xml" : { - "attribute" : true - }, - "description" : "The time stamp when the data was created.", - "readOnly" : true - }, - "modificationTime" : { - "type" : "integer", - "format" : "int64", - "xml" : { - "attribute" : true - }, - "description" : "The time stamp when the data was created.", - "readOnly" : true - }, - "deleted" : { - "type" : "boolean", - "xml" : { - "attribute" : true - }, - "description" : "A flag to indicate whether the data was deleted." - }, - "user" : { - "type" : "integer", - "format" : "int64", - "xml" : { - "attribute" : true - }, - "description" : "The id of the owning user or null, if there is none." - }, - "os" : { - "type" : "string", - "xml" : { - "attribute" : true - }, - "description" : "The operating system.", - "enum" : [ "ANDROID", "IOS" ] - }, - "manufacturer" : { - "type" : "string", - "xml" : { - "attribute" : true - }, - "description" : "The manufacturer name, see android.os.Build.MANUFACTURER." - }, - "device" : { - "type" : "string", - "xml" : { - "attribute" : true - }, - "description" : "The device name, see android.os.Build.DEVICE." - }, - "model" : { - "type" : "string", - "xml" : { - "attribute" : true - }, - "description" : "The model name, see android.os.Build.MODEL." - } - }, - "description" : "Represents a device." - }, - "DeviceHandle" : { - "type" : "object", - "required" : [ "device", "manufacturer", "model", "os", "token" ], - "properties" : { - "id" : { - "type" : "integer", - "format" : "int64", - "xml" : { - "attribute" : true - }, - "description" : "The unique identifier of the data.", - "readOnly" : true - }, - "creationTime" : { - "type" : "integer", - "format" : "int64", - "xml" : { - "attribute" : true - }, - "description" : "The time stamp when the data was created.", - "readOnly" : true - }, - "modificationTime" : { - "type" : "integer", - "format" : "int64", - "xml" : { - "attribute" : true - }, - "description" : "The time stamp when the data was created.", - "readOnly" : true - }, - "deleted" : { - "type" : "boolean", - "xml" : { - "attribute" : true - }, - "description" : "A flag to indicate whether the data was deleted." - }, - "user" : { - "type" : "integer", - "format" : "int64", - "xml" : { - "attribute" : true - }, - "description" : "The id of the owning user or null, if there is none." - }, - "os" : { - "type" : "string", - "xml" : { - "attribute" : true - }, - "description" : "The operating system.", - "enum" : [ "ANDROID", "IOS" ] - }, - "manufacturer" : { - "type" : "string", - "xml" : { - "attribute" : true - }, - "description" : "The manufacturer name, see android.os.Build.MANUFACTURER." - }, - "device" : { - "type" : "string", - "xml" : { - "attribute" : true - }, - "description" : "The device name, see android.os.Build.DEVICE." - }, - "model" : { - "type" : "string", - "xml" : { - "attribute" : true - }, - "description" : "The model name, see android.os.Build.MODEL." - }, - "token" : { - "type" : "string", - "xml" : { - "attribute" : true - }, - "description" : "The secret token used for authenticating the device." - } - }, - "description" : "Represents a device with a secret token." - }, - "DeviceInfo" : { - "type" : "object", - "required" : [ "device", "manufacturer", "model", "os" ], - "properties" : { - "os" : { - "type" : "string", - "xml" : { - "attribute" : true - }, - "description" : "The operating system.", - "enum" : [ "ANDROID", "IOS" ] - }, - "manufacturer" : { - "type" : "string", - "xml" : { - "attribute" : true - }, - "description" : "The manufacturer name, see android.os.Build.MANUFACTURER." - }, - "device" : { - "type" : "string", - "xml" : { - "attribute" : true - }, - "description" : "The device name, see android.os.Build.DEVICE." - }, - "model" : { - "type" : "string", - "xml" : { - "attribute" : true - }, - "description" : "The model name, see android.os.Build.MODEL." - } - }, - "description" : "Represents information about a device." - }, - "DevicePage" : { - "type" : "object", - "required" : [ "elements", "offset", "size", "total" ], - "properties" : { - "size" : { - "type" : "integer", - "format" : "int32", - "xml" : { - "attribute" : true - }, - "description" : "The maximum number of elements on the page." - }, - "offset" : { - "type" : "integer", - "format" : "int32", - "xml" : { - "attribute" : true - }, - "description" : "The page offset (0-based) in number of elements." - }, - "total" : { - "type" : "integer", - "format" : "int32", - "xml" : { - "attribute" : true - }, - "description" : "The total number of elements available." - }, - "elements" : { - "type" : "array", - "xml" : { - "wrapped" : true - }, - "description" : "The elements of the page.", - "items" : { - "xml" : { - "name" : "element" - }, - "$ref" : "#/definitions/Device" - } - } - }, - "description" : "Represents a page of devices." - }, - "Email" : { - "type" : "object", - "required" : [ "address", "correspondence", "verified" ], - "properties" : { - "id" : { - "type" : "integer", - "format" : "int64", - "xml" : { - "attribute" : true - }, - "description" : "The unique identifier of the data.", - "readOnly" : true - }, - "creationTime" : { - "type" : "integer", - "format" : "int64", - "xml" : { - "attribute" : true - }, - "description" : "The time stamp when the data was created.", - "readOnly" : true - }, - "modificationTime" : { - "type" : "integer", - "format" : "int64", - "xml" : { - "attribute" : true - }, - "description" : "The time stamp when the data was created.", - "readOnly" : true - }, - "deleted" : { - "type" : "boolean", - "xml" : { - "attribute" : true - }, - "description" : "A flag to indicate whether the data was deleted." - }, - "address" : { - "type" : "string", - "xml" : { - "attribute" : true - }, - "description" : "The email address." - }, - "correspondence" : { - "type" : "boolean", - "xml" : { - "attribute" : true - }, - "description" : "A flag to mark the email address as primary email." - }, - "verified" : { - "type" : "boolean", - "xml" : { - "attribute" : true - }, - "description" : "A flag to mark the email address as verified." - } - }, - "description" : "Represents a user." - }, - "EntityStatistic" : { - "type" : "object", - "required" : [ "deleted", "name", "total" ], - "properties" : { - "name" : { - "type" : "string", - "xml" : { - "attribute" : true - }, - "description" : "The name of the entity." - }, - "total" : { - "type" : "integer", - "format" : "int64", - "xml" : { - "attribute" : true - }, - "description" : "The total number of stored entities." - }, - "deleted" : { - "type" : "integer", - "format" : "int64", - "xml" : { - "attribute" : true - }, - "description" : "The number of deleted entities." - } - }, - "description" : "Represents statistics about peristent entities." - }, - "LoadStatistic" : { - "type" : "object", - "required" : [ "cpuLoad", "gcCount", "gcDuration", "maxHeapSize", "maxNonHeapSize", "uptime", "usedHeapSize", "usedNonHeapSize" ], - "properties" : { - "cpuLoad" : { - "type" : "number", - "format" : "double", - "xml" : { - "attribute" : true - }, - "description" : "The average cpu load over the last minute." - }, - "uptime" : { - "type" : "integer", - "format" : "int64", - "xml" : { - "attribute" : true - }, - "description" : "The uptime of the jvm in milliseconds." - }, - "gcCount" : { - "type" : "integer", - "format" : "int64", - "xml" : { - "attribute" : true - }, - "description" : "The total number of garbage collector executions." - }, - "gcDuration" : { - "type" : "integer", - "format" : "int64", - "xml" : { - "attribute" : true - }, - "description" : "The total time for garbage collection in milliseconds." - }, - "maxHeapSize" : { - "type" : "integer", - "format" : "int64", - "xml" : { - "attribute" : true - }, - "description" : "The maximum heap size available in bytes." - }, - "usedHeapSize" : { - "type" : "integer", - "format" : "int64", - "xml" : { - "attribute" : true - }, - "description" : "The used heap size available in bytes." - }, - "maxNonHeapSize" : { - "type" : "integer", - "format" : "int64", - "xml" : { - "attribute" : true - }, - "description" : "The maximum non heap size available in bytes." - }, - "usedNonHeapSize" : { - "type" : "integer", - "format" : "int64", - "xml" : { - "attribute" : true - }, - "description" : "The used non heap size available in bytes." - } - }, - "description" : "Represents statistics about the system usage." - }, - "Location" : { - "type" : "object", - "required" : [ "availability", "timestamp" ], - "properties" : { - "timestamp" : { - "type" : "integer", - "format" : "int64", - "xml" : { - "attribute" : true - }, - "description" : "The timestamp of the location." - }, - "coordinate" : { - "description" : "The coordinate of the location.", - "$ref" : "#/definitions/Coordinate" - }, - "availability" : { - "type" : "string", - "xml" : { - "attribute" : true - }, - "description" : "The availability information of the location.", - "enum" : [ "FRESH", "CACHED", "UNABLE", "PRIVATE" ] - } - }, - "description" : "Represents a location." - }, - "LocationUpdate" : { - "type" : "object", - "required" : [ "locations" ], - "properties" : { - "locations" : { - "type" : "array", - "xml" : { - "wrapped" : true - }, - "description" : "The locations released with this update.", - "items" : { - "xml" : { - "name" : "location" - }, - "$ref" : "#/definitions/ReleasedLocation" - } - } - }, - "description" : "Represents a location update conisting of a batch of locations." - }, - "LogMessage" : { - "type" : "object", - "required" : [ "className", "id", "level", "loggerName", "methodName", "thread", "time" ], - "properties" : { - "id" : { - "type" : "integer", - "format" : "int64", - "xml" : { - "attribute" : true - }, - "description" : "An auto-generated sequential id." - }, - "time" : { - "type" : "integer", - "format" : "int64", - "xml" : { - "attribute" : true - }, - "description" : "The creation time in Epoch milliseconds." - }, - "thread" : { - "type" : "integer", - "format" : "int32", - "xml" : { - "attribute" : true - }, - "description" : "The id of the thread." - }, - "level" : { - "type" : "string", - "xml" : { - "attribute" : true - }, - "description" : "The message severity." - }, - "loggerName" : { - "type" : "string", - "xml" : { - "attribute" : true - }, - "description" : "The name of the logger." - }, - "className" : { - "type" : "string", - "xml" : { - "attribute" : true - }, - "description" : "The name of the class." - }, - "methodName" : { - "type" : "string", - "xml" : { - "attribute" : true - }, - "description" : "The name of the method." - }, - "message" : { - "type" : "string", - "description" : "The actual (optional) message." - }, - "trace" : { - "type" : "string", - "description" : "An optional stack trace." - } - }, - "description" : "Represents a log message." - }, - "Message" : { - "type" : "object", - "required" : [ "body", "title" ], - "properties" : { - "title" : { - "type" : "string", - "description" : "The message title." - }, - "body" : { - "type" : "string", - "description" : " The message body." - }, - "language" : { - "type" : "string", - "description" : "The two letter language code in lower case.", - "pattern" : "de|en|fr|it|es", - "enum" : [ "de", "en", "fr", "it", "es" ] - } - }, - "description" : "Represents a message in a particular language." - }, - "Notice" : { - "type" : "object", - "required" : [ "announced", "expirationTime", "messages", "published" ], - "properties" : { - "id" : { - "type" : "integer", - "format" : "int64", - "xml" : { - "attribute" : true - }, - "description" : "The unique identifier of the data.", - "readOnly" : true - }, - "creationTime" : { - "type" : "integer", - "format" : "int64", - "xml" : { - "attribute" : true - }, - "description" : "The time stamp when the data was created.", - "readOnly" : true - }, - "modificationTime" : { - "type" : "integer", - "format" : "int64", - "xml" : { - "attribute" : true - }, - "description" : "The time stamp when the data was created.", - "readOnly" : true - }, - "deleted" : { - "type" : "boolean", - "xml" : { - "attribute" : true - }, - "description" : "A flag to indicate whether the data was deleted." - }, - "announced" : { - "type" : "boolean", - "xml" : { - "attribute" : true - }, - "description" : "A flag to indicate whether the message should be announced." - }, - "published" : { - "type" : "boolean", - "xml" : { - "attribute" : true - }, - "description" : "A flag to indicate whether the message is published." - }, - "minimumVersion" : { - "type" : "integer", - "format" : "int32", - "xml" : { - "attribute" : true - }, - "description" : "The minimum app version to display the message or null.", - "minimum" : 0 - }, - "maximumVersion" : { - "type" : "integer", - "format" : "int32", - "xml" : { - "attribute" : true - }, - "description" : "The maximum app version to display the message or null.", - "minimum" : 0 - }, - "expirationTime" : { - "type" : "integer", - "format" : "int64", - "xml" : { - "attribute" : true - }, - "description" : "The expiration time in epoch milliseconds." - }, - "messages" : { - "type" : "array", - "xml" : { - "wrapped" : true - }, - "description" : "The list of translated messages.", - "items" : { - "xml" : { - "name" : "message" - }, - "$ref" : "#/definitions/Message" - } - } - }, - "description" : "Represents a multi-lingual notice." - }, - "NoticePage" : { - "type" : "object", - "required" : [ "elements", "offset", "size", "total" ], - "properties" : { - "size" : { - "type" : "integer", - "format" : "int32", - "xml" : { - "attribute" : true - }, - "description" : "The maximum number of elements on the page." - }, - "offset" : { - "type" : "integer", - "format" : "int32", - "xml" : { - "attribute" : true - }, - "description" : "The page offset (0-based) in number of elements." - }, - "total" : { - "type" : "integer", - "format" : "int32", - "xml" : { - "attribute" : true - }, - "description" : "The total number of elements available." - }, - "elements" : { - "type" : "array", - "xml" : { - "wrapped" : true - }, - "description" : "The elements of the page.", - "items" : { - "xml" : { - "name" : "element" - }, - "$ref" : "#/definitions/Notice" - } - } - }, - "description" : "Represents a page of notices." - }, - "Place" : { - "type" : "object", - "properties" : { - "id" : { - "type" : "integer", - "format" : "int64", - "xml" : { - "attribute" : true - }, - "description" : "The unique identifier of the data.", - "readOnly" : true - }, - "creationTime" : { - "type" : "integer", - "format" : "int64", - "xml" : { - "attribute" : true - }, - "description" : "The time stamp when the data was created.", - "readOnly" : true - }, - "modificationTime" : { - "type" : "integer", - "format" : "int64", - "xml" : { - "attribute" : true - }, - "description" : "The time stamp when the data was created.", - "readOnly" : true - }, - "deleted" : { - "type" : "boolean", - "xml" : { - "attribute" : true - }, - "description" : "A flag to indicate whether the data was deleted." - }, - "coordinate" : { - "description" : "The coordinate of the place.", - "$ref" : "#/definitions/Coordinate" - }, - "address" : { - "type" : "string", - "xml" : { - "attribute" : true - }, - "description" : "An automatically resolved address for the coordinate." - }, - "nickname" : { - "type" : "string", - "xml" : { - "attribute" : true - }, - "description" : "A nickname for the place assigned by the user." - } - }, - "description" : "Represents a place." - }, - "PlacePage" : { - "type" : "object", - "required" : [ "elements", "offset", "size", "total" ], - "properties" : { - "size" : { - "type" : "integer", - "format" : "int32", - "xml" : { - "attribute" : true - }, - "description" : "The maximum number of elements on the page." - }, - "offset" : { - "type" : "integer", - "format" : "int32", - "xml" : { - "attribute" : true - }, - "description" : "The page offset (0-based) in number of elements." - }, - "total" : { - "type" : "integer", - "format" : "int32", - "xml" : { - "attribute" : true - }, - "description" : "The total number of elements available." - }, - "elements" : { - "type" : "array", - "xml" : { - "wrapped" : true - }, - "description" : "The elements of the page.", - "items" : { - "xml" : { - "name" : "element" - }, - "$ref" : "#/definitions/Place" - } - } - }, - "description" : "Represents a page of places." - }, - "Privilege" : { - "type" : "object", - "properties" : { - "id" : { - "type" : "integer", - "format" : "int64", - "xml" : { - "attribute" : true - }, - "description" : "The unique identifier of the data.", - "readOnly" : true - }, - "creationTime" : { - "type" : "integer", - "format" : "int64", - "xml" : { - "attribute" : true - }, - "description" : "The time stamp when the data was created.", - "readOnly" : true - }, - "modificationTime" : { - "type" : "integer", - "format" : "int64", - "xml" : { - "attribute" : true - }, - "description" : "The time stamp when the data was created.", - "readOnly" : true - }, - "deleted" : { - "type" : "boolean", - "xml" : { - "attribute" : true - }, - "description" : "A flag to indicate whether the data was deleted." - }, - "shareInfo" : { - "description" : "The share info of the privilege.", - "$ref" : "#/definitions/ShareInfo" - }, - "token" : { - "type" : "string", - "xml" : { - "attribute" : true - }, - "description" : "The token used to get the privilege." - } - }, - "description" : "Represents an entity." - }, - "PrivilegePage" : { - "type" : "object", - "required" : [ "elements", "offset", "size", "total" ], - "properties" : { - "size" : { - "type" : "integer", - "format" : "int32", - "xml" : { - "attribute" : true - }, - "description" : "The maximum number of elements on the page." - }, - "offset" : { - "type" : "integer", - "format" : "int32", - "xml" : { - "attribute" : true - }, - "description" : "The page offset (0-based) in number of elements." - }, - "total" : { - "type" : "integer", - "format" : "int32", - "xml" : { - "attribute" : true - }, - "description" : "The total number of elements available." - }, - "elements" : { - "type" : "array", - "xml" : { - "wrapped" : true - }, - "description" : "The elements of the page.", - "items" : { - "xml" : { - "name" : "element" - }, - "$ref" : "#/definitions/Privilege" - } - } - }, - "description" : "A page of privilges" - }, - "ReleasedLocation" : { - "type" : "object", - "required" : [ "analyzable", "availability", "sharable", "timestamp", "version" ], - "properties" : { - "timestamp" : { - "type" : "integer", - "format" : "int64", - "xml" : { - "attribute" : true - }, - "description" : "The timestamp of the location." - }, - "coordinate" : { - "description" : "The coordinate of the location.", - "$ref" : "#/definitions/Coordinate" - }, - "availability" : { - "type" : "string", - "xml" : { - "attribute" : true - }, - "description" : "The availability information of the location.", - "enum" : [ "FRESH", "CACHED", "UNABLE", "PRIVATE" ] - }, - "version" : { - "type" : "integer", - "format" : "int32", - "xml" : { - "attribute" : true - }, - "description" : "The version code of the application." - }, - "speed" : { - "type" : "number", - "format" : "double", - "xml" : { - "attribute" : true - }, - "description" : "The speed in meter per second or null, if not available." - }, - "bearing" : { - "type" : "number", - "format" : "double", - "xml" : { - "attribute" : true - }, - "description" : "The bearing in degree or null, if not available." - }, - "altitude" : { - "type" : "number", - "format" : "double", - "xml" : { - "attribute" : true - }, - "description" : "The altitude in meters or null, if not available." - }, - "accuracy" : { - "type" : "number", - "format" : "double", - "xml" : { - "attribute" : true - }, - "description" : "The accuracy in meters or null, if not available." - }, - "provider" : { - "type" : "string", - "xml" : { - "attribute" : true - }, - "description" : "The provider name or null, if not available." - }, - "sharable" : { - "type" : "boolean", - "xml" : { - "attribute" : true - }, - "description" : "A boolean value to mark the update as sharable for research purposes." - }, - "analyzable" : { - "type" : "boolean", - "xml" : { - "attribute" : true - }, - "description" : "A boolean value to mark the update as analyzable to compute places and visits." - } - }, - "description" : "Represents a detailed location with usage approved or prohibited by the user." - }, - "Share" : { - "type" : "object", - "required" : [ "expirationTime", "token" ], - "properties" : { - "id" : { - "type" : "integer", - "format" : "int64", - "xml" : { - "attribute" : true - }, - "description" : "The unique identifier of the data.", - "readOnly" : true - }, - "creationTime" : { - "type" : "integer", - "format" : "int64", - "xml" : { - "attribute" : true - }, - "description" : "The time stamp when the data was created.", - "readOnly" : true - }, - "modificationTime" : { - "type" : "integer", - "format" : "int64", - "xml" : { - "attribute" : true - }, - "description" : "The time stamp when the data was created.", - "readOnly" : true - }, - "deleted" : { - "type" : "boolean", - "xml" : { - "attribute" : true - }, - "description" : "A flag to indicate whether the data was deleted." - }, - "token" : { - "type" : "string", - "xml" : { - "attribute" : true - }, - "description" : "The token to forward to other persons to be able to access the share." - }, - "device" : { - "type" : "integer", - "format" : "int64", - "xml" : { - "attribute" : true - }, - "description" : "The id of the related device.", - "readOnly" : true - }, - "message" : { - "type" : "string", - "xml" : { - "attribute" : true - }, - "description" : "A message to be displayed to the share receiving users." - }, - "destination" : { - "type" : "string", - "xml" : { - "attribute" : true - }, - "description" : "A destination to be displayed to the share receiving users." - }, - "expirationTime" : { - "type" : "integer", - "format" : "int64", - "xml" : { - "attribute" : true - }, - "description" : "The expiration time of the share that should be created." - }, - "paused" : { - "type" : "boolean", - "xml" : { - "attribute" : true - }, - "description" : "A flag to indicate whether the sharing is temporarily paused." - } - }, - "description" : "Represents a share." - }, - "ShareInfo" : { - "type" : "object", - "required" : [ "expirationTime" ], - "properties" : { - "message" : { - "type" : "string", - "xml" : { - "attribute" : true - }, - "description" : "A message to be displayed to the share receiving users." - }, - "destination" : { - "type" : "string", - "xml" : { - "attribute" : true - }, - "description" : "A destination to be displayed to the share receiving users." - }, - "expirationTime" : { - "type" : "integer", - "format" : "int64", - "xml" : { - "attribute" : true - }, - "description" : "The expiration time of the share that should be created." - } - }, - "description" : "Represents a request to create a new share." - }, - "User" : { - "type" : "object", - "required" : [ "emails", "login", "name", "roles", "suspended" ], - "properties" : { - "id" : { - "type" : "integer", - "format" : "int64", - "xml" : { - "attribute" : true - }, - "description" : "The unique identifier of the data.", - "readOnly" : true - }, - "creationTime" : { - "type" : "integer", - "format" : "int64", - "xml" : { - "attribute" : true - }, - "description" : "The time stamp when the data was created.", - "readOnly" : true - }, - "modificationTime" : { - "type" : "integer", - "format" : "int64", - "xml" : { - "attribute" : true - }, - "description" : "The time stamp when the data was created.", - "readOnly" : true - }, - "deleted" : { - "type" : "boolean", - "xml" : { - "attribute" : true - }, - "description" : "A flag to indicate whether the data was deleted." - }, - "login" : { - "type" : "string", - "xml" : { - "attribute" : true - }, - "description" : "The (globally unique) login of the user.", - "pattern" : "(\\p{L}|[0-9]){5,32}" - }, - "name" : { - "type" : "string", - "xml" : { - "attribute" : true - }, - "description" : "The human name of the user.", - "pattern" : "(\\p{L}| ){0,64}" - }, - "suspended" : { - "type" : "boolean", - "xml" : { - "attribute" : true - }, - "description" : "A flag to indicate that user account is suspended." - }, - "roles" : { - "type" : "array", - "xml" : { - "wrapped" : true - }, - "items" : { - "type" : "string", - "xml" : { - "name" : "role" - } - } - }, - "emails" : { - "type" : "array", - "xml" : { - "wrapped" : true - }, - "items" : { - "xml" : { - "name" : "email" - }, - "$ref" : "#/definitions/Email" - } - } - }, - "description" : "Represents a user." - }, - "UserPage" : { - "type" : "object", - "required" : [ "elements", "offset", "size", "total" ], - "properties" : { - "size" : { - "type" : "integer", - "format" : "int32", - "xml" : { - "attribute" : true - }, - "description" : "The maximum number of elements on the page." - }, - "offset" : { - "type" : "integer", - "format" : "int32", - "xml" : { - "attribute" : true - }, - "description" : "The page offset (0-based) in number of elements." - }, - "total" : { - "type" : "integer", - "format" : "int32", - "xml" : { - "attribute" : true - }, - "description" : "The total number of elements available." - }, - "elements" : { - "type" : "array", - "xml" : { - "wrapped" : true - }, - "description" : "The elements of the page.", - "items" : { - "xml" : { - "name" : "element" - }, - "$ref" : "#/definitions/User" - } - } - }, - "description" : "Represents a page of users." - }, - "UserPassword" : { - "type" : "object", - "required" : [ "password" ], - "properties" : { - "password" : { - "type" : "string", - "xml" : { - "attribute" : true - }, - "description" : "The new password.", - "minLength" : 6, - "maxLength" : 2147483647 - } - }, - "description" : "Represents a user password." - }, - "UserRegistration" : { - "type" : "object", - "required" : [ "email", "login", "name", "password" ], - "properties" : { - "password" : { - "type" : "string", - "xml" : { - "attribute" : true - }, - "description" : "The new password.", - "minLength" : 6, - "maxLength" : 2147483647 - }, - "login" : { - "type" : "string", - "xml" : { - "attribute" : true - }, - "description" : "The requested login name.", - "pattern" : "(\\p{L}|[0-9]){5,32}" - }, - "name" : { - "type" : "string", - "xml" : { - "attribute" : true - }, - "description" : "The human name.", - "pattern" : "(\\p{L}| ){0,64}" - }, - "email" : { - "type" : "string", - "xml" : { - "attribute" : true - }, - "description" : "The email address.", - "pattern" : ".+@.+\\..+" - } - }, - "description" : "Represents a user registration." - }, - "Visit" : { - "type" : "object", - "properties" : { - "id" : { - "type" : "integer", - "format" : "int64", - "xml" : { - "attribute" : true - }, - "description" : "The unique identifier of the data.", - "readOnly" : true - }, - "creationTime" : { - "type" : "integer", - "format" : "int64", - "xml" : { - "attribute" : true - }, - "description" : "The time stamp when the data was created.", - "readOnly" : true - }, - "modificationTime" : { - "type" : "integer", - "format" : "int64", - "xml" : { - "attribute" : true - }, - "description" : "The time stamp when the data was created.", - "readOnly" : true - }, - "deleted" : { - "type" : "boolean", - "xml" : { - "attribute" : true - }, - "description" : "A flag to indicate whether the data was deleted." - }, - "place" : { - "type" : "integer", - "format" : "int64", - "xml" : { - "attribute" : true - }, - "description" : "The id of the place." - }, - "device" : { - "type" : "integer", - "format" : "int64", - "xml" : { - "attribute" : true - }, - "description" : "The id of the device." - }, - "beginTime" : { - "type" : "integer", - "format" : "int64", - "xml" : { - "attribute" : true - }, - "description" : "The beginning of the visit in Epoch milliseconds." - }, - "endTime" : { - "type" : "integer", - "format" : "int64", - "xml" : { - "attribute" : true - }, - "description" : "The end of the visit in Epoch milliseconds." - } - }, - "description" : "Represents a visit of a device at a place." - }, - "VisitPage" : { - "type" : "object", - "required" : [ "elements", "offset", "size", "total" ], - "properties" : { - "size" : { - "type" : "integer", - "format" : "int32", - "xml" : { - "attribute" : true - }, - "description" : "The maximum number of elements on the page." - }, - "offset" : { - "type" : "integer", - "format" : "int32", - "xml" : { - "attribute" : true - }, - "description" : "The page offset (0-based) in number of elements." - }, - "total" : { - "type" : "integer", - "format" : "int32", - "xml" : { - "attribute" : true - }, - "description" : "The total number of elements available." - }, - "elements" : { - "type" : "array", - "xml" : { - "wrapped" : true - }, - "description" : "The elements of the page.", - "items" : { - "xml" : { - "name" : "element" - }, - "$ref" : "#/definitions/Visit" - } - } - }, - "description" : "Represents a page of visits." - } - } -} \ No newline at end of file diff --git a/testing/api-client/src/test/java/io/swagger/client/api/DefaultApiTest.java b/testing/api-client/src/test/java/io/swagger/client/api/DefaultApiTest.java deleted file mode 100644 index 2b8208e..0000000 --- a/testing/api-client/src/test/java/io/swagger/client/api/DefaultApiTest.java +++ /dev/null @@ -1,924 +0,0 @@ -/* - * Maptology Service - * Maptology Service - * - * OpenAPI spec version: 0.0.1-SNAPSHOT - * Contact: nes-admin@uni-due.de - * - * NOTE: This class is auto generated by the swagger code generator program. - * https://github.com/swagger-api/swagger-codegen.git - * Do not edit the class manually. - */ - - -package io.swagger.client.api; - -import io.swagger.client.ApiException; -import io.swagger.client.model.BuildVersion; -import io.swagger.client.model.Device; -import io.swagger.client.model.DeviceHandle; -import io.swagger.client.model.DeviceInfo; -import io.swagger.client.model.DevicePage; -import io.swagger.client.model.EntityStatistic; -import io.swagger.client.model.LoadStatistic; -import io.swagger.client.model.Location; -import io.swagger.client.model.LocationUpdate; -import io.swagger.client.model.LogMessage; -import io.swagger.client.model.Notice; -import io.swagger.client.model.NoticePage; -import io.swagger.client.model.Place; -import io.swagger.client.model.PlacePage; -import io.swagger.client.model.Privilege; -import io.swagger.client.model.PrivilegePage; -import io.swagger.client.model.Share; -import io.swagger.client.model.ShareInfo; -import io.swagger.client.model.User; -import io.swagger.client.model.UserPage; -import io.swagger.client.model.UserPassword; -import io.swagger.client.model.UserRegistration; -import io.swagger.client.model.Visit; -import io.swagger.client.model.VisitPage; -import org.junit.Test; -import org.junit.Ignore; - -import java.util.ArrayList; -import java.util.HashMap; -import java.util.List; -import java.util.Map; - -/** - * API tests for DefaultApi - */ -@Ignore -public class DefaultApiTest { - - private final DefaultApi api = new DefaultApi(); - - - /** - * Add a privilege for the specified user. - * - * - * - * @throws ApiException - * if the Api call fails - */ - @Test - public void addCurrentUserPrivilegeTest() throws ApiException { - String share = null; - Privilege response = api.addCurrentUserPrivilege(share); - - // TODO: test validations - } - - /** - * Updates the locations of the current device. - * - * - * - * @throws ApiException - * if the Api call fails - */ - @Test - public void addLocationsTest() throws ApiException { - LocationUpdate body = null; - api.addLocations(body); - - // TODO: test validations - } - - /** - * Adds a new notice and returns the notice as well as its location. - * - * - * - * @throws ApiException - * if the Api call fails - */ - @Test - public void addNoticeTest() throws ApiException { - Notice body = null; - Notice response = api.addNotice(body); - - // TODO: test validations - } - - /** - * Adds a user account with the specified roles and emails. - * - * - * - * @throws ApiException - * if the Api call fails - */ - @Test - public void addUserTest() throws ApiException { - User body = null; - User response = api.addUser(body); - - // TODO: test validations - } - - /** - * Returns the privileges for a particular user. - * - * - * - * @throws ApiException - * if the Api call fails - */ - @Test - public void addUserPrivilegeTest() throws ApiException { - Long id = null; - String share = null; - Privilege response = api.addUserPrivilege(id, share); - - // TODO: test validations - } - - /** - * Creates a new device and returns its handle. - * - * The response will include the auth token to be stored on the device and supplied as authentication on all subsequent api calls. Note that the auth token can not be requested after creation, so when losing the auth token you may lose access to the device data. - * - * @throws ApiException - * if the Api call fails - */ - @Test - public void createDeviceTest() throws ApiException { - DeviceInfo body = null; - DeviceHandle response = api.createDevice(body); - - // TODO: test validations - } - - /** - * Creates a new share. - * - * - * - * @throws ApiException - * if the Api call fails - */ - @Test - public void createShareTest() throws ApiException { - ShareInfo body = null; - Share response = api.createShare(body); - - // TODO: test validations - } - - /** - * Deletes the current device. - * - * - * - * @throws ApiException - * if the Api call fails - */ - @Test - public void deleteCurrentDeviceTest() throws ApiException { - api.deleteCurrentDevice(); - - // TODO: test validations - } - - /** - * Deletes a device. - * - * - * - * @throws ApiException - * if the Api call fails - */ - @Test - public void deleteDeviceTest() throws ApiException { - Long id = null; - api.deleteDevice(id); - - // TODO: test validations - } - - /** - * Deletes a particular privilege. - * - * - * - * @throws ApiException - * if the Api call fails - */ - @Test - public void deletePrivilegeTest() throws ApiException { - Long id = null; - api.deletePrivilege(id); - - // TODO: test validations - } - - /** - * Delete a share. - * - * - * - * @throws ApiException - * if the Api call fails - */ - @Test - public void deleteShareTest() throws ApiException { - Long id = null; - api.deleteShare(id); - - // TODO: test validations - } - - /** - * Returns a page of notices. - * - * - * - * @throws ApiException - * if the Api call fails - */ - @Test - public void getActiveNoticesTest() throws ApiException { - Integer pageOffset = null; - Integer pageSize = null; - NoticePage response = api.getActiveNotices(pageOffset, pageSize); - - // TODO: test validations - } - - /** - * Returns the build version. - * - * - * - * @throws ApiException - * if the Api call fails - */ - @Test - public void getBuildVersionTest() throws ApiException { - BuildVersion response = api.getBuildVersion(); - - // TODO: test validations - } - - /** - * Returns the current device. - * - * - * - * @throws ApiException - * if the Api call fails - */ - @Test - public void getCurrentDeviceTest() throws ApiException { - Device response = api.getCurrentDevice(); - - // TODO: test validations - } - - /** - * Returns the user currently authorized. - * - * - * - * @throws ApiException - * if the Api call fails - */ - @Test - public void getCurrentUserTest() throws ApiException { - User response = api.getCurrentUser(); - - // TODO: test validations - } - - /** - * Returns the list of devices for the current user. - * - * - * - * @throws ApiException - * if the Api call fails - */ - @Test - public void getCurrentUserDevicesTest() throws ApiException { - Integer pageOffset = null; - Integer pageSize = null; - DevicePage response = api.getCurrentUserDevices(pageOffset, pageSize); - - // TODO: test validations - } - - /** - * Returns the places for the current user. - * - * - * - * @throws ApiException - * if the Api call fails - */ - @Test - public void getCurrentUserPlacesTest() throws ApiException { - Integer pageOffset = null; - Integer pageSize = null; - PlacePage response = api.getCurrentUserPlaces(pageOffset, pageSize); - - // TODO: test validations - } - - /** - * Returns the privileges for the current user. - * - * - * - * @throws ApiException - * if the Api call fails - */ - @Test - public void getCurrentUserPrivilegesTest() throws ApiException { - Integer pageOffset = null; - Integer pageSize = null; - PrivilegePage response = api.getCurrentUserPrivileges(pageOffset, pageSize); - - // TODO: test validations - } - - /** - * Gets a device. - * - * - * - * @throws ApiException - * if the Api call fails - */ - @Test - public void getDeviceTest() throws ApiException { - Long id = null; - Device response = api.getDevice(id); - - // TODO: test validations - } - - /** - * Gets the last device location. - * - * - * - * @throws ApiException - * if the Api call fails - */ - @Test - public void getDeviceLocationTest() throws ApiException { - Long id = null; - Location response = api.getDeviceLocation(id); - - // TODO: test validations - } - - /** - * Gets the last device location. - * - * - * - * @throws ApiException - * if the Api call fails - */ - @Test - public void getDeviceVisitsTest() throws ApiException { - Long id = null; - Long start = null; - Long duration = null; - List response = api.getDeviceVisits(id, start, duration); - - // TODO: test validations - } - - /** - * Returns all devices. - * - * - * - * @throws ApiException - * if the Api call fails - */ - @Test - public void getDevicesTest() throws ApiException { - Integer pageOffset = null; - Integer pageSize = null; - DevicePage response = api.getDevices(pageOffset, pageSize); - - // TODO: test validations - } - - /** - * Returns a list of entity statistics. - * - * - * - * @throws ApiException - * if the Api call fails - */ - @Test - public void getEntityStatisticsTest() throws ApiException { - List response = api.getEntityStatistics(); - - // TODO: test validations - } - - /** - * Returns the current load statistic. - * - * - * - * @throws ApiException - * if the Api call fails - */ - @Test - public void getLoadStatisticTest() throws ApiException { - LoadStatistic response = api.getLoadStatistic(); - - // TODO: test validations - } - - /** - * Returns a list of log messages starting from a particular id. - * - * - * - * @throws ApiException - * if the Api call fails - */ - @Test - public void getLogMessagesTest() throws ApiException { - Long from = null; - List response = api.getLogMessages(from); - - // TODO: test validations - } - - /** - * Returns the notice with the specified id. - * - * - * - * @throws ApiException - * if the Api call fails - */ - @Test - public void getNoticeTest() throws ApiException { - Long id = null; - Notice response = api.getNotice(id); - - // TODO: test validations - } - - /** - * Returns a page of notices. - * - * - * - * @throws ApiException - * if the Api call fails - */ - @Test - public void getNoticesTest() throws ApiException { - Integer pageOffset = null; - Integer pageSize = null; - NoticePage response = api.getNotices(pageOffset, pageSize); - - // TODO: test validations - } - - /** - * Returns the place with the specified id. - * - * - * - * @throws ApiException - * if the Api call fails - */ - @Test - public void getPlaceTest() throws ApiException { - Long id = null; - Place response = api.getPlace(id); - - // TODO: test validations - } - - /** - * Returns the visits for a particular place. - * - * - * - * @throws ApiException - * if the Api call fails - */ - @Test - public void getPlaceVisitsTest() throws ApiException { - Long id = null; - Integer pageOffset = null; - Integer pageSize = null; - VisitPage response = api.getPlaceVisits(id, pageOffset, pageSize); - - // TODO: test validations - } - - /** - * Returns the privileges for a particular user. - * - * - * - * @throws ApiException - * if the Api call fails - */ - @Test - public void getPrivilegeTest() throws ApiException { - Long id = null; - Privilege response = api.getPrivilege(id); - - // TODO: test validations - } - - /** - * Returns the location for a particular privilege. - * - * - * - * @throws ApiException - * if the Api call fails - */ - @Test - public void getPrivilegeLocationTest() throws ApiException { - Long id = null; - Location response = api.getPrivilegeLocation(id); - - // TODO: test validations - } - - /** - * Returns a share. - * - * - * - * @throws ApiException - * if the Api call fails - */ - @Test - public void getShareTest() throws ApiException { - Long id = null; - Share response = api.getShare(id); - - // TODO: test validations - } - - /** - * Get a share info by its secret token. - * - * - * - * @throws ApiException - * if the Api call fails - */ - @Test - public void getShareInfoTest() throws ApiException { - String token = null; - ShareInfo response = api.getShareInfo(token); - - // TODO: test validations - } - - /** - * Get a shared location by its secret token. - * - * - * - * @throws ApiException - * if the Api call fails - */ - @Test - public void getShareLocationTest() throws ApiException { - String token = null; - Location response = api.getShareLocation(token); - - // TODO: test validations - } - - /** - * Returns the system statistic. - * - * - * - * @throws ApiException - * if the Api call fails - */ - @Test - public void getSystemStatisticTest() throws ApiException { - LoadStatistic response = api.getSystemStatistic(); - - // TODO: test validations - } - - /** - * Returns all active notices modified after the date. - * - * - * - * @throws ApiException - * if the Api call fails - */ - @Test - public void getUpdatedNoticesTest() throws ApiException { - Long since = null; - List response = api.getUpdatedNotices(since); - - // TODO: test validations - } - - /** - * Returns the user account with the specified id. - * - * - * - * @throws ApiException - * if the Api call fails - */ - @Test - public void getUserTest() throws ApiException { - Long id = null; - User response = api.getUser(id); - - // TODO: test validations - } - - /** - * Returns the places for a particular user. - * - * - * - * @throws ApiException - * if the Api call fails - */ - @Test - public void getUserPlacesTest() throws ApiException { - Long id = null; - Integer pageOffset = null; - Integer pageSize = null; - PlacePage response = api.getUserPlaces(id, pageOffset, pageSize); - - // TODO: test validations - } - - /** - * Returns the privileges for a particular user. - * - * - * - * @throws ApiException - * if the Api call fails - */ - @Test - public void getUserPrivilegesTest() throws ApiException { - Long id = null; - Integer pageOffset = null; - Integer pageSize = null; - PrivilegePage response = api.getUserPrivileges(id, pageOffset, pageSize); - - // TODO: test validations - } - - /** - * Returns a list of users. - * - * - * - * @throws ApiException - * if the Api call fails - */ - @Test - public void getUsersTest() throws ApiException { - Integer pageOffset = null; - Integer pageSize = null; - UserPage response = api.getUsers(pageOffset, pageSize); - - // TODO: test validations - } - - /** - * Registers a new user and sends an email account verification. - * - * - * - * @throws ApiException - * if the Api call fails - */ - @Test - public void registerUserTest() throws ApiException { - UserRegistration body = null; - User response = api.registerUser(body); - - // TODO: test validations - } - - /** - * Sends a password reset email to the correspondence email account of a user. - * - * - * - * @throws ApiException - * if the Api call fails - */ - @Test - public void resetUserTest() throws ApiException { - String login = null; - api.resetUser(login); - - // TODO: test validations - } - - /** - * Sets the password of a user account using a token received via email. - * - * - * - * @throws ApiException - * if the Api call fails - */ - @Test - public void resetUserPasswordTest() throws ApiException { - String token = null; - UserPassword body = null; - User response = api.resetUserPassword(token, body); - - // TODO: test validations - } - - /** - * Returns a list of users whose login name or name contains the term. - * - * - * - * @throws ApiException - * if the Api call fails - */ - @Test - public void searchUsersTest() throws ApiException { - String term = null; - Integer pageOffset = null; - Integer pageSize = null; - UserPage response = api.searchUsers(term, pageOffset, pageSize); - - // TODO: test validations - } - - /** - * Sets the password of the currently authorized user. - * - * - * - * @throws ApiException - * if the Api call fails - */ - @Test - public void setCurrentPasswordTest() throws ApiException { - UserPassword body = null; - User response = api.setCurrentPassword(body); - - // TODO: test validations - } - - /** - * Updates the currently authorized user. - * - * - * - * @throws ApiException - * if the Api call fails - */ - @Test - public void setCurrentUserTest() throws ApiException { - User body = null; - User response = api.setCurrentUser(body); - - // TODO: test validations - } - - /** - * Sets the values of a device. - * - * - * - * @throws ApiException - * if the Api call fails - */ - @Test - public void setDeviceTest() throws ApiException { - Long id = null; - Device body = null; - Device response = api.setDevice(id, body); - - // TODO: test validations - } - - /** - * Updates an existing notice. - * - * - * - * @throws ApiException - * if the Api call fails - */ - @Test - public void setNoticeTest() throws ApiException { - Long id = null; - Notice body = null; - Notice response = api.setNotice(id, body); - - // TODO: test validations - } - - /** - * Updates the place with the specified id. - * - * - * - * @throws ApiException - * if the Api call fails - */ - @Test - public void setPlaceTest() throws ApiException { - Long id = null; - Place body = null; - Place response = api.setPlace(id, body); - - // TODO: test validations - } - - /** - * Updates an existing share. - * - * - * - * @throws ApiException - * if the Api call fails - */ - @Test - public void setShareTest() throws ApiException { - Long id = null; - Share body = null; - Share response = api.setShare(id, body); - - // TODO: test validations - } - - /** - * Updates the values of a particular user account. - * - * - * - * @throws ApiException - * if the Api call fails - */ - @Test - public void setUserTest() throws ApiException { - Long id = null; - User body = null; - User response = api.setUser(id, body); - - // TODO: test validations - } - - /** - * Sets the password of a user. - * - * - * - * @throws ApiException - * if the Api call fails - */ - @Test - public void setUserPasswordTest() throws ApiException { - Long id = null; - UserPassword body = null; - User response = api.setUserPassword(id, body); - - // TODO: test validations - } - - /** - * Verifies an email address using a token received via email. - * - * - * - * @throws ApiException - * if the Api call fails - */ - @Test - public void verifyUserEmailTest() throws ApiException { - String token = null; - api.verifyUserEmail(token); - - // TODO: test validations - } - -} diff --git a/testing/api-client/src/test/java/io/swagger/client/api/DeviceApiTest.java b/testing/api-client/src/test/java/io/swagger/client/api/DeviceApiTest.java deleted file mode 100644 index 90edc76..0000000 --- a/testing/api-client/src/test/java/io/swagger/client/api/DeviceApiTest.java +++ /dev/null @@ -1,220 +0,0 @@ -/* - * Maptology Service - * Maptology Service - * - * OpenAPI spec version: 0.0.1-SNAPSHOT - * Contact: nes-admin@uni-due.de - * - * NOTE: This class is auto generated by the swagger code generator program. - * https://github.com/swagger-api/swagger-codegen.git - * Do not edit the class manually. - */ - - -package io.swagger.client.api; - -import io.swagger.client.ApiException; -import io.swagger.client.model.Device; -import io.swagger.client.model.DeviceHandle; -import io.swagger.client.model.DeviceInfo; -import io.swagger.client.model.DevicePage; -import io.swagger.client.model.Location; -import io.swagger.client.model.LocationUpdate; -import io.swagger.client.model.Visit; -import org.junit.Test; -import org.junit.Ignore; - -import java.util.ArrayList; -import java.util.HashMap; -import java.util.List; -import java.util.Map; - -/** - * API tests for DeviceApi - */ -@Ignore -public class DeviceApiTest { - - private final DeviceApi api = new DeviceApi(); - - - /** - * Updates the locations of the current device. - * - * - * - * @throws ApiException - * if the Api call fails - */ - @Test - public void addLocationsTest() throws ApiException { - LocationUpdate body = null; - api.addLocations(body); - - // TODO: test validations - } - - /** - * Creates a new device and returns its handle. - * - * The response will include the auth token to be stored on the device and supplied as authentication on all subsequent api calls. Note that the auth token can not be requested after creation, so when losing the auth token you may lose access to the device data. - * - * @throws ApiException - * if the Api call fails - */ - @Test - public void createDeviceTest() throws ApiException { - DeviceInfo body = null; - DeviceHandle response = api.createDevice(body); - - // TODO: test validations - } - - /** - * Deletes the current device. - * - * - * - * @throws ApiException - * if the Api call fails - */ - @Test - public void deleteCurrentDeviceTest() throws ApiException { - api.deleteCurrentDevice(); - - // TODO: test validations - } - - /** - * Deletes a device. - * - * - * - * @throws ApiException - * if the Api call fails - */ - @Test - public void deleteDeviceTest() throws ApiException { - Long id = null; - api.deleteDevice(id); - - // TODO: test validations - } - - /** - * Returns the current device. - * - * - * - * @throws ApiException - * if the Api call fails - */ - @Test - public void getCurrentDeviceTest() throws ApiException { - Device response = api.getCurrentDevice(); - - // TODO: test validations - } - - /** - * Returns the list of devices for the current user. - * - * - * - * @throws ApiException - * if the Api call fails - */ - @Test - public void getCurrentUserDevicesTest() throws ApiException { - Integer pageOffset = null; - Integer pageSize = null; - DevicePage response = api.getCurrentUserDevices(pageOffset, pageSize); - - // TODO: test validations - } - - /** - * Gets a device. - * - * - * - * @throws ApiException - * if the Api call fails - */ - @Test - public void getDeviceTest() throws ApiException { - Long id = null; - Device response = api.getDevice(id); - - // TODO: test validations - } - - /** - * Gets the last device location. - * - * - * - * @throws ApiException - * if the Api call fails - */ - @Test - public void getDeviceLocationTest() throws ApiException { - Long id = null; - Location response = api.getDeviceLocation(id); - - // TODO: test validations - } - - /** - * Gets the last device location. - * - * - * - * @throws ApiException - * if the Api call fails - */ - @Test - public void getDeviceVisitsTest() throws ApiException { - Long id = null; - Long start = null; - Long duration = null; - List response = api.getDeviceVisits(id, start, duration); - - // TODO: test validations - } - - /** - * Returns all devices. - * - * - * - * @throws ApiException - * if the Api call fails - */ - @Test - public void getDevicesTest() throws ApiException { - Integer pageOffset = null; - Integer pageSize = null; - DevicePage response = api.getDevices(pageOffset, pageSize); - - // TODO: test validations - } - - /** - * Sets the values of a device. - * - * - * - * @throws ApiException - * if the Api call fails - */ - @Test - public void setDeviceTest() throws ApiException { - Long id = null; - Device body = null; - Device response = api.setDevice(id, body); - - // TODO: test validations - } - -} diff --git a/testing/api-client/src/test/java/io/swagger/client/api/PlaceApiTest.java b/testing/api-client/src/test/java/io/swagger/client/api/PlaceApiTest.java deleted file mode 100644 index f58a089..0000000 --- a/testing/api-client/src/test/java/io/swagger/client/api/PlaceApiTest.java +++ /dev/null @@ -1,87 +0,0 @@ -/* - * Maptology Service - * Maptology Service - * - * OpenAPI spec version: 0.0.1-SNAPSHOT - * Contact: nes-admin@uni-due.de - * - * NOTE: This class is auto generated by the swagger code generator program. - * https://github.com/swagger-api/swagger-codegen.git - * Do not edit the class manually. - */ - - -package io.swagger.client.api; - -import io.swagger.client.ApiException; -import io.swagger.client.model.Place; -import io.swagger.client.model.VisitPage; -import org.junit.Test; -import org.junit.Ignore; - -import java.util.ArrayList; -import java.util.HashMap; -import java.util.List; -import java.util.Map; - -/** - * API tests for PlaceApi - */ -@Ignore -public class PlaceApiTest { - - private final PlaceApi api = new PlaceApi(); - - - /** - * Returns the place with the specified id. - * - * - * - * @throws ApiException - * if the Api call fails - */ - @Test - public void getPlaceTest() throws ApiException { - Long id = null; - Place response = api.getPlace(id); - - // TODO: test validations - } - - /** - * Returns the visits for a particular place. - * - * - * - * @throws ApiException - * if the Api call fails - */ - @Test - public void getPlaceVisitsTest() throws ApiException { - Long id = null; - Integer pageOffset = null; - Integer pageSize = null; - VisitPage response = api.getPlaceVisits(id, pageOffset, pageSize); - - // TODO: test validations - } - - /** - * Updates the place with the specified id. - * - * - * - * @throws ApiException - * if the Api call fails - */ - @Test - public void setPlaceTest() throws ApiException { - Long id = null; - Place body = null; - Place response = api.setPlace(id, body); - - // TODO: test validations - } - -} diff --git a/testing/api-client/src/test/java/io/swagger/client/api/PrivilegeApiTest.java b/testing/api-client/src/test/java/io/swagger/client/api/PrivilegeApiTest.java deleted file mode 100644 index 67613b1..0000000 --- a/testing/api-client/src/test/java/io/swagger/client/api/PrivilegeApiTest.java +++ /dev/null @@ -1,84 +0,0 @@ -/* - * Maptology Service - * Maptology Service - * - * OpenAPI spec version: 0.0.1-SNAPSHOT - * Contact: nes-admin@uni-due.de - * - * NOTE: This class is auto generated by the swagger code generator program. - * https://github.com/swagger-api/swagger-codegen.git - * Do not edit the class manually. - */ - - -package io.swagger.client.api; - -import io.swagger.client.ApiException; -import io.swagger.client.model.Location; -import io.swagger.client.model.Privilege; -import org.junit.Test; -import org.junit.Ignore; - -import java.util.ArrayList; -import java.util.HashMap; -import java.util.List; -import java.util.Map; - -/** - * API tests for PrivilegeApi - */ -@Ignore -public class PrivilegeApiTest { - - private final PrivilegeApi api = new PrivilegeApi(); - - - /** - * Deletes a particular privilege. - * - * - * - * @throws ApiException - * if the Api call fails - */ - @Test - public void deletePrivilegeTest() throws ApiException { - Long id = null; - api.deletePrivilege(id); - - // TODO: test validations - } - - /** - * Returns the privileges for a particular user. - * - * - * - * @throws ApiException - * if the Api call fails - */ - @Test - public void getPrivilegeTest() throws ApiException { - Long id = null; - Privilege response = api.getPrivilege(id); - - // TODO: test validations - } - - /** - * Returns the location for a particular privilege. - * - * - * - * @throws ApiException - * if the Api call fails - */ - @Test - public void getPrivilegeLocationTest() throws ApiException { - Long id = null; - Location response = api.getPrivilegeLocation(id); - - // TODO: test validations - } - -} diff --git a/testing/api-client/src/test/java/io/swagger/client/api/ServiceApiTest.java b/testing/api-client/src/test/java/io/swagger/client/api/ServiceApiTest.java deleted file mode 100644 index ae996f2..0000000 --- a/testing/api-client/src/test/java/io/swagger/client/api/ServiceApiTest.java +++ /dev/null @@ -1,215 +0,0 @@ -/* - * Maptology Service - * Maptology Service - * - * OpenAPI spec version: 0.0.1-SNAPSHOT - * Contact: nes-admin@uni-due.de - * - * NOTE: This class is auto generated by the swagger code generator program. - * https://github.com/swagger-api/swagger-codegen.git - * Do not edit the class manually. - */ - - -package io.swagger.client.api; - -import io.swagger.client.ApiException; -import io.swagger.client.model.BuildVersion; -import io.swagger.client.model.EntityStatistic; -import io.swagger.client.model.LoadStatistic; -import io.swagger.client.model.LogMessage; -import io.swagger.client.model.Notice; -import io.swagger.client.model.NoticePage; -import org.junit.Test; -import org.junit.Ignore; - -import java.util.ArrayList; -import java.util.HashMap; -import java.util.List; -import java.util.Map; - -/** - * API tests for ServiceApi - */ -@Ignore -public class ServiceApiTest { - - private final ServiceApi api = new ServiceApi(); - - - /** - * Adds a new notice and returns the notice as well as its location. - * - * - * - * @throws ApiException - * if the Api call fails - */ - @Test - public void addNoticeTest() throws ApiException { - Notice body = null; - Notice response = api.addNotice(body); - - // TODO: test validations - } - - /** - * Returns a page of notices. - * - * - * - * @throws ApiException - * if the Api call fails - */ - @Test - public void getActiveNoticesTest() throws ApiException { - Integer pageOffset = null; - Integer pageSize = null; - NoticePage response = api.getActiveNotices(pageOffset, pageSize); - - // TODO: test validations - } - - /** - * Returns the build version. - * - * - * - * @throws ApiException - * if the Api call fails - */ - @Test - public void getBuildVersionTest() throws ApiException { - BuildVersion response = api.getBuildVersion(); - - // TODO: test validations - } - - /** - * Returns a list of entity statistics. - * - * - * - * @throws ApiException - * if the Api call fails - */ - @Test - public void getEntityStatisticsTest() throws ApiException { - List response = api.getEntityStatistics(); - - // TODO: test validations - } - - /** - * Returns the current load statistic. - * - * - * - * @throws ApiException - * if the Api call fails - */ - @Test - public void getLoadStatisticTest() throws ApiException { - LoadStatistic response = api.getLoadStatistic(); - - // TODO: test validations - } - - /** - * Returns a list of log messages starting from a particular id. - * - * - * - * @throws ApiException - * if the Api call fails - */ - @Test - public void getLogMessagesTest() throws ApiException { - Long from = null; - List response = api.getLogMessages(from); - - // TODO: test validations - } - - /** - * Returns the notice with the specified id. - * - * - * - * @throws ApiException - * if the Api call fails - */ - @Test - public void getNoticeTest() throws ApiException { - Long id = null; - Notice response = api.getNotice(id); - - // TODO: test validations - } - - /** - * Returns a page of notices. - * - * - * - * @throws ApiException - * if the Api call fails - */ - @Test - public void getNoticesTest() throws ApiException { - Integer pageOffset = null; - Integer pageSize = null; - NoticePage response = api.getNotices(pageOffset, pageSize); - - // TODO: test validations - } - - /** - * Returns the system statistic. - * - * - * - * @throws ApiException - * if the Api call fails - */ - @Test - public void getSystemStatisticTest() throws ApiException { - LoadStatistic response = api.getSystemStatistic(); - - // TODO: test validations - } - - /** - * Returns all active notices modified after the date. - * - * - * - * @throws ApiException - * if the Api call fails - */ - @Test - public void getUpdatedNoticesTest() throws ApiException { - Long since = null; - List response = api.getUpdatedNotices(since); - - // TODO: test validations - } - - /** - * Updates an existing notice. - * - * - * - * @throws ApiException - * if the Api call fails - */ - @Test - public void setNoticeTest() throws ApiException { - Long id = null; - Notice body = null; - Notice response = api.setNotice(id, body); - - // TODO: test validations - } - -} diff --git a/testing/api-client/src/test/java/io/swagger/client/api/ShareApiTest.java b/testing/api-client/src/test/java/io/swagger/client/api/ShareApiTest.java deleted file mode 100644 index bab0f76..0000000 --- a/testing/api-client/src/test/java/io/swagger/client/api/ShareApiTest.java +++ /dev/null @@ -1,134 +0,0 @@ -/* - * Maptology Service - * Maptology Service - * - * OpenAPI spec version: 0.0.1-SNAPSHOT - * Contact: nes-admin@uni-due.de - * - * NOTE: This class is auto generated by the swagger code generator program. - * https://github.com/swagger-api/swagger-codegen.git - * Do not edit the class manually. - */ - - -package io.swagger.client.api; - -import io.swagger.client.ApiException; -import io.swagger.client.model.Location; -import io.swagger.client.model.Share; -import io.swagger.client.model.ShareInfo; -import org.junit.Test; -import org.junit.Ignore; - -import java.util.ArrayList; -import java.util.HashMap; -import java.util.List; -import java.util.Map; - -/** - * API tests for ShareApi - */ -@Ignore -public class ShareApiTest { - - private final ShareApi api = new ShareApi(); - - - /** - * Creates a new share. - * - * - * - * @throws ApiException - * if the Api call fails - */ - @Test - public void createShareTest() throws ApiException { - ShareInfo body = null; - Share response = api.createShare(body); - - // TODO: test validations - } - - /** - * Delete a share. - * - * - * - * @throws ApiException - * if the Api call fails - */ - @Test - public void deleteShareTest() throws ApiException { - Long id = null; - api.deleteShare(id); - - // TODO: test validations - } - - /** - * Returns a share. - * - * - * - * @throws ApiException - * if the Api call fails - */ - @Test - public void getShareTest() throws ApiException { - Long id = null; - Share response = api.getShare(id); - - // TODO: test validations - } - - /** - * Get a share info by its secret token. - * - * - * - * @throws ApiException - * if the Api call fails - */ - @Test - public void getShareInfoTest() throws ApiException { - String token = null; - ShareInfo response = api.getShareInfo(token); - - // TODO: test validations - } - - /** - * Get a shared location by its secret token. - * - * - * - * @throws ApiException - * if the Api call fails - */ - @Test - public void getShareLocationTest() throws ApiException { - String token = null; - Location response = api.getShareLocation(token); - - // TODO: test validations - } - - /** - * Updates an existing share. - * - * - * - * @throws ApiException - * if the Api call fails - */ - @Test - public void setShareTest() throws ApiException { - Long id = null; - Share body = null; - Share response = api.setShare(id, body); - - // TODO: test validations - } - -} diff --git a/testing/api-client/src/test/java/io/swagger/client/api/UserApiTest.java b/testing/api-client/src/test/java/io/swagger/client/api/UserApiTest.java deleted file mode 100644 index e501db8..0000000 --- a/testing/api-client/src/test/java/io/swagger/client/api/UserApiTest.java +++ /dev/null @@ -1,357 +0,0 @@ -/* - * Maptology Service - * Maptology Service - * - * OpenAPI spec version: 0.0.1-SNAPSHOT - * Contact: nes-admin@uni-due.de - * - * NOTE: This class is auto generated by the swagger code generator program. - * https://github.com/swagger-api/swagger-codegen.git - * Do not edit the class manually. - */ - - -package io.swagger.client.api; - -import io.swagger.client.ApiException; -import io.swagger.client.model.PlacePage; -import io.swagger.client.model.Privilege; -import io.swagger.client.model.PrivilegePage; -import io.swagger.client.model.User; -import io.swagger.client.model.UserPage; -import io.swagger.client.model.UserPassword; -import io.swagger.client.model.UserRegistration; -import org.junit.Test; -import org.junit.Ignore; - -import java.util.ArrayList; -import java.util.HashMap; -import java.util.List; -import java.util.Map; - -/** - * API tests for UserApi - */ -@Ignore -public class UserApiTest { - - private final UserApi api = new UserApi(); - - - /** - * Add a privilege for the specified user. - * - * - * - * @throws ApiException - * if the Api call fails - */ - @Test - public void addCurrentUserPrivilegeTest() throws ApiException { - String share = null; - Privilege response = api.addCurrentUserPrivilege(share); - - // TODO: test validations - } - - /** - * Adds a user account with the specified roles and emails. - * - * - * - * @throws ApiException - * if the Api call fails - */ - @Test - public void addUserTest() throws ApiException { - User body = null; - User response = api.addUser(body); - - // TODO: test validations - } - - /** - * Returns the privileges for a particular user. - * - * - * - * @throws ApiException - * if the Api call fails - */ - @Test - public void addUserPrivilegeTest() throws ApiException { - Long id = null; - String share = null; - Privilege response = api.addUserPrivilege(id, share); - - // TODO: test validations - } - - /** - * Returns the user currently authorized. - * - * - * - * @throws ApiException - * if the Api call fails - */ - @Test - public void getCurrentUserTest() throws ApiException { - User response = api.getCurrentUser(); - - // TODO: test validations - } - - /** - * Returns the places for the current user. - * - * - * - * @throws ApiException - * if the Api call fails - */ - @Test - public void getCurrentUserPlacesTest() throws ApiException { - Integer pageOffset = null; - Integer pageSize = null; - PlacePage response = api.getCurrentUserPlaces(pageOffset, pageSize); - - // TODO: test validations - } - - /** - * Returns the privileges for the current user. - * - * - * - * @throws ApiException - * if the Api call fails - */ - @Test - public void getCurrentUserPrivilegesTest() throws ApiException { - Integer pageOffset = null; - Integer pageSize = null; - PrivilegePage response = api.getCurrentUserPrivileges(pageOffset, pageSize); - - // TODO: test validations - } - - /** - * Returns the user account with the specified id. - * - * - * - * @throws ApiException - * if the Api call fails - */ - @Test - public void getUserTest() throws ApiException { - Long id = null; - User response = api.getUser(id); - - // TODO: test validations - } - - /** - * Returns the places for a particular user. - * - * - * - * @throws ApiException - * if the Api call fails - */ - @Test - public void getUserPlacesTest() throws ApiException { - Long id = null; - Integer pageOffset = null; - Integer pageSize = null; - PlacePage response = api.getUserPlaces(id, pageOffset, pageSize); - - // TODO: test validations - } - - /** - * Returns the privileges for a particular user. - * - * - * - * @throws ApiException - * if the Api call fails - */ - @Test - public void getUserPrivilegesTest() throws ApiException { - Long id = null; - Integer pageOffset = null; - Integer pageSize = null; - PrivilegePage response = api.getUserPrivileges(id, pageOffset, pageSize); - - // TODO: test validations - } - - /** - * Returns a list of users. - * - * - * - * @throws ApiException - * if the Api call fails - */ - @Test - public void getUsersTest() throws ApiException { - Integer pageOffset = null; - Integer pageSize = null; - UserPage response = api.getUsers(pageOffset, pageSize); - - // TODO: test validations - } - - /** - * Registers a new user and sends an email account verification. - * - * - * - * @throws ApiException - * if the Api call fails - */ - @Test - public void registerUserTest() throws ApiException { - UserRegistration body = null; - User response = api.registerUser(body); - - // TODO: test validations - } - - /** - * Sends a password reset email to the correspondence email account of a user. - * - * - * - * @throws ApiException - * if the Api call fails - */ - @Test - public void resetUserTest() throws ApiException { - String login = null; - api.resetUser(login); - - // TODO: test validations - } - - /** - * Sets the password of a user account using a token received via email. - * - * - * - * @throws ApiException - * if the Api call fails - */ - @Test - public void resetUserPasswordTest() throws ApiException { - String token = null; - UserPassword body = null; - User response = api.resetUserPassword(token, body); - - // TODO: test validations - } - - /** - * Returns a list of users whose login name or name contains the term. - * - * - * - * @throws ApiException - * if the Api call fails - */ - @Test - public void searchUsersTest() throws ApiException { - String term = null; - Integer pageOffset = null; - Integer pageSize = null; - UserPage response = api.searchUsers(term, pageOffset, pageSize); - - // TODO: test validations - } - - /** - * Sets the password of the currently authorized user. - * - * - * - * @throws ApiException - * if the Api call fails - */ - @Test - public void setCurrentPasswordTest() throws ApiException { - UserPassword body = null; - User response = api.setCurrentPassword(body); - - // TODO: test validations - } - - /** - * Updates the currently authorized user. - * - * - * - * @throws ApiException - * if the Api call fails - */ - @Test - public void setCurrentUserTest() throws ApiException { - User body = null; - User response = api.setCurrentUser(body); - - // TODO: test validations - } - - /** - * Updates the values of a particular user account. - * - * - * - * @throws ApiException - * if the Api call fails - */ - @Test - public void setUserTest() throws ApiException { - Long id = null; - User body = null; - User response = api.setUser(id, body); - - // TODO: test validations - } - - /** - * Sets the password of a user. - * - * - * - * @throws ApiException - * if the Api call fails - */ - @Test - public void setUserPasswordTest() throws ApiException { - Long id = null; - UserPassword body = null; - User response = api.setUserPassword(id, body); - - // TODO: test validations - } - - /** - * Verifies an email address using a token received via email. - * - * - * - * @throws ApiException - * if the Api call fails - */ - @Test - public void verifyUserEmailTest() throws ApiException { - String token = null; - api.verifyUserEmail(token); - - // TODO: test validations - } - -} diff --git a/testing/performance/pom.xml b/testing/performance/pom.xml deleted file mode 100644 index c321e78..0000000 --- a/testing/performance/pom.xml +++ /dev/null @@ -1,36 +0,0 @@ - - - - testing - com.maptology - 0.0.1-SNAPSHOT - - 4.0.0 - - performance - Maptology Testing Performance - - - - org.apache.maven.plugins - maven-compiler-plugin - - 1.8 - 1.8 - - - - - - - - com.maptology - api-client - ${project.version} - - - - - \ No newline at end of file diff --git a/testing/performance/src/main/java/com/maptology/testing/performance/Main.java b/testing/performance/src/main/java/com/maptology/testing/performance/Main.java deleted file mode 100644 index 65aba91..0000000 --- a/testing/performance/src/main/java/com/maptology/testing/performance/Main.java +++ /dev/null @@ -1,90 +0,0 @@ -package com.maptology.testing.performance; - -import io.swagger.client.ApiClient; -import io.swagger.client.ApiException; -import io.swagger.client.Configuration; -import io.swagger.client.api.DeviceApi; -import io.swagger.client.api.ShareApi; -import io.swagger.client.model.*; - -import java.util.Random; -import java.util.concurrent.Executors; -import java.util.concurrent.ScheduledExecutorService; -import java.util.concurrent.TimeUnit; -import java.util.stream.IntStream; - -public class Main { - public static void main(String[] args){ - Configuration.getDefaultApiClient().setBasePath("http://maptology.com/api"); - - ScheduledExecutorService scheduledExecutorService=Executors.newScheduledThreadPool(Runtime.getRuntime().availableProcessors()); - - DeviceApi deviceApi=new DeviceApi(); - DeviceInfo deviceInfo=new DeviceInfo(); - deviceInfo.setOs(DeviceInfo.OsEnum.ANDROID); - - ShareInfo shareInfo=new ShareInfo(); - shareInfo.setExpirationTime(System.currentTimeMillis()+1000*60*60); - - Random random=new Random(); - - IntStream.range(0,100).parallel().mapToObj(i->{ //Create 100 devices - try { - DeviceHandle deviceHandle=deviceApi.createDevice(deviceInfo); - DeviceApi authenticatedDeviceApi=new DeviceApi(getDeviceAuthenticatedApiClient(deviceHandle)); - scheduledExecutorService.scheduleAtFixedRate(()->{ //Update the location using a random interval between 5 and 25 seconds - LocationUpdate locationUpdate=new LocationUpdate(); - ReleasedLocation location=new ReleasedLocation(); - location.setTimestamp(System.currentTimeMillis()); - location.setAnalyzable(true); - location.setSharable(true); - location.setAvailability(ReleasedLocation.AvailabilityEnum.FRESH); - location.setVersion(1); - Coordinate coordinate=new Coordinate(); - coordinate.setLatitude(Math.random()*90); - coordinate.setLongitude(Math.random()*90); - location.setCoordinate(coordinate); - locationUpdate.addLocationsItem(location); - try { - authenticatedDeviceApi.addLocations(locationUpdate); - } catch (ApiException e) { - e.printStackTrace(); - } - },random.nextInt(20),5+random.nextInt(20), TimeUnit.SECONDS); - return deviceHandle; - } catch (ApiException e) { - throw new RuntimeException(e); - } - }).forEach(deviceHandle -> { - ShareApi shareApi=new ShareApi(getDeviceAuthenticatedApiClient(deviceHandle)); - IntStream.range(1,random.nextInt(5)).parallel().forEach(i->{ //For every device create a random set of shares - try { - Share share=shareApi.createShare(shareInfo); - System.out.println(share); - IntStream.range(1,random.nextInt(5)).parallel().forEach(j->{ //Simulation the request of a random set of consumers - scheduledExecutorService.scheduleAtFixedRate(()->{ - try { - Location location=shareApi.getShareLocation(share.getToken()); - } catch (ApiException e) { - e.printStackTrace(); - } - },random.nextInt(20),5+random.nextInt(20), TimeUnit.SECONDS); - }); - } catch (ApiException e) { - throw new RuntimeException(e); - } - }); - }); - - - - } - - public static ApiClient getDeviceAuthenticatedApiClient(DeviceHandle deviceHandle){ - ApiClient apiClient=new ApiClient(); - apiClient.setBasePath(Configuration.getDefaultApiClient().getBasePath()); - apiClient.setApiKey(deviceHandle.getToken()); - apiClient.setApiKeyPrefix("Bearer"); - return apiClient; - } -} diff --git a/testing/pom.xml b/testing/pom.xml deleted file mode 100644 index 73d3eb1..0000000 --- a/testing/pom.xml +++ /dev/null @@ -1,21 +0,0 @@ - - - - all - com.maptology - 0.0.1-SNAPSHOT - - 4.0.0 - - testing - Maptology Testing - pom - - api-client - performance - - - - \ No newline at end of file diff --git a/web/angular/.editorconfig b/web-angular/.editorconfig similarity index 100% rename from web/angular/.editorconfig rename to web-angular/.editorconfig diff --git a/web/angular/.gitignore b/web-angular/.gitignore similarity index 100% rename from web/angular/.gitignore rename to web-angular/.gitignore diff --git a/web/angular/README.md b/web-angular/README.md similarity index 100% rename from web/angular/README.md rename to web-angular/README.md diff --git a/web/angular/angular.json b/web-angular/angular.json similarity index 100% rename from web/angular/angular.json rename to web-angular/angular.json diff --git a/web/angular/browserslist b/web-angular/browserslist similarity index 100% rename from web/angular/browserslist rename to web-angular/browserslist diff --git a/web-angular/build.gradle b/web-angular/build.gradle new file mode 100644 index 0000000..1612d52 --- /dev/null +++ b/web-angular/build.gradle @@ -0,0 +1,47 @@ +plugins { + id "com.moowork.node" version "1.3.1" +} + +description = 'Maptology Web Angular' + +node { + version = '10.16.0' + npmVersion = '6.9.0' + download = true +} + +class IoNodeTask extends com.moowork.gradle.node.task.NodeTask { + @Input + File inputFile; + @OutputDirectory + File outputDir; +} + + +task genApi(type: IoNodeTask) { + script = file('node_modules/angular4-swagger-client-generator/bin/a4apigen.js') + args = ['-s', '../common-api/build/swagger/maptology.json', '-o', './src/api'] + inputFile = project.file('../common-api/build/swagger/maptology.json') + outputDir = project.file('./src/api/') +} + +task cleanApi(type: Delete) { + delete './src/api', './dist' +} + +task ngBuild(type: IoNodeTask) { + script = file('node_modules/@angular/cli/bin/ng') + args = ['build', '--prod'] + inputFile = project.file('./src/') + outputDir = project.file('./dist/') +} + +// make sure that common api is built before generating the api +genApi.dependsOn(project(":common-api").tasks['build']) +// generate the api before running ng build +ngBuild.dependsOn("genApi") +// run ng build whenever the project is built +build.dependsOn("ngBuild") + +// clean the api folder upon clean +clean.dependsOn("cleanApi") \ No newline at end of file diff --git a/web/angular/e2e/app.e2e-spec.ts b/web-angular/e2e/app.e2e-spec.ts similarity index 100% rename from web/angular/e2e/app.e2e-spec.ts rename to web-angular/e2e/app.e2e-spec.ts diff --git a/web/angular/e2e/app.po.ts b/web-angular/e2e/app.po.ts similarity index 100% rename from web/angular/e2e/app.po.ts rename to web-angular/e2e/app.po.ts diff --git a/web/angular/e2e/tsconfig.e2e.json b/web-angular/e2e/tsconfig.e2e.json similarity index 100% rename from web/angular/e2e/tsconfig.e2e.json rename to web-angular/e2e/tsconfig.e2e.json diff --git a/web/angular/karma.conf.js b/web-angular/karma.conf.js similarity index 100% rename from web/angular/karma.conf.js rename to web-angular/karma.conf.js diff --git a/web/angular/package.json b/web-angular/package.json similarity index 100% rename from web/angular/package.json rename to web-angular/package.json diff --git a/web/angular/pom.xml b/web-angular/pom.xml similarity index 94% rename from web/angular/pom.xml rename to web-angular/pom.xml index 04076bb..c43563e 100644 --- a/web/angular/pom.xml +++ b/web-angular/pom.xml @@ -2,13 +2,13 @@ - web + project com.maptology 0.0.1-SNAPSHOT 4.0.0 - com.maptology.web - angular + com.maptology + web-angular Maptology Web Angular Source code of the angular user interface. jar @@ -27,7 +27,7 @@ com.maptology - api + common-api ${project.version} swagger maptology.json @@ -113,7 +113,7 @@ com.maptology - api + common-api ${project.version}
diff --git a/web/angular/protractor.conf.js b/web-angular/protractor.conf.js similarity index 100% rename from web/angular/protractor.conf.js rename to web-angular/protractor.conf.js diff --git a/web/angular/proxy.conf.json b/web-angular/proxy.conf.json similarity index 100% rename from web/angular/proxy.conf.json rename to web-angular/proxy.conf.json diff --git a/web/angular/src/app/app.component.html b/web-angular/src/app/app.component.html old mode 100755 new mode 100644 similarity index 100% rename from web/angular/src/app/app.component.html rename to web-angular/src/app/app.component.html diff --git a/web/angular/src/app/app.component.ts b/web-angular/src/app/app.component.ts old mode 100755 new mode 100644 similarity index 100% rename from web/angular/src/app/app.component.ts rename to web-angular/src/app/app.component.ts diff --git a/web/angular/src/app/app.module.ts b/web-angular/src/app/app.module.ts old mode 100755 new mode 100644 similarity index 100% rename from web/angular/src/app/app.module.ts rename to web-angular/src/app/app.module.ts diff --git a/web/angular/src/app/app.routing.ts b/web-angular/src/app/app.routing.ts old mode 100755 new mode 100644 similarity index 100% rename from web/angular/src/app/app.routing.ts rename to web-angular/src/app/app.routing.ts diff --git a/web/angular/src/app/directives/use-parent-form.directive.ts b/web-angular/src/app/directives/use-parent-form.directive.ts similarity index 100% rename from web/angular/src/app/directives/use-parent-form.directive.ts rename to web-angular/src/app/directives/use-parent-form.directive.ts diff --git a/web/angular/src/app/guards/auth.guard.ts b/web-angular/src/app/guards/auth.guard.ts similarity index 100% rename from web/angular/src/app/guards/auth.guard.ts rename to web-angular/src/app/guards/auth.guard.ts diff --git a/web/angular/src/app/interceptors/auth.interceptor.ts b/web-angular/src/app/interceptors/auth.interceptor.ts similarity index 100% rename from web/angular/src/app/interceptors/auth.interceptor.ts rename to web-angular/src/app/interceptors/auth.interceptor.ts diff --git a/web/angular/src/app/interceptors/delay.interceptor.ts b/web-angular/src/app/interceptors/delay.interceptor.ts similarity index 100% rename from web/angular/src/app/interceptors/delay.interceptor.ts rename to web-angular/src/app/interceptors/delay.interceptor.ts diff --git a/web/angular/src/app/layouts/drawer.component.html b/web-angular/src/app/layouts/drawer.component.html similarity index 100% rename from web/angular/src/app/layouts/drawer.component.html rename to web-angular/src/app/layouts/drawer.component.html diff --git a/web/angular/src/app/layouts/drawer.component.ts b/web-angular/src/app/layouts/drawer.component.ts similarity index 100% rename from web/angular/src/app/layouts/drawer.component.ts rename to web-angular/src/app/layouts/drawer.component.ts diff --git a/web/angular/src/app/layouts/footer.component.html b/web-angular/src/app/layouts/footer.component.html similarity index 100% rename from web/angular/src/app/layouts/footer.component.html rename to web-angular/src/app/layouts/footer.component.html diff --git a/web/angular/src/app/layouts/footer.component.ts b/web-angular/src/app/layouts/footer.component.ts similarity index 100% rename from web/angular/src/app/layouts/footer.component.ts rename to web-angular/src/app/layouts/footer.component.ts diff --git a/web/angular/src/app/layouts/inside.component.html b/web-angular/src/app/layouts/inside.component.html similarity index 100% rename from web/angular/src/app/layouts/inside.component.html rename to web-angular/src/app/layouts/inside.component.html diff --git a/web/angular/src/app/layouts/inside.component.ts b/web-angular/src/app/layouts/inside.component.ts similarity index 100% rename from web/angular/src/app/layouts/inside.component.ts rename to web-angular/src/app/layouts/inside.component.ts diff --git a/web/angular/src/app/layouts/outside.component.html b/web-angular/src/app/layouts/outside.component.html similarity index 100% rename from web/angular/src/app/layouts/outside.component.html rename to web-angular/src/app/layouts/outside.component.html diff --git a/web/angular/src/app/layouts/outside.component.ts b/web-angular/src/app/layouts/outside.component.ts similarity index 100% rename from web/angular/src/app/layouts/outside.component.ts rename to web-angular/src/app/layouts/outside.component.ts diff --git a/web/angular/src/app/providers/paginator.provider.ts b/web-angular/src/app/providers/paginator.provider.ts similarity index 100% rename from web/angular/src/app/providers/paginator.provider.ts rename to web-angular/src/app/providers/paginator.provider.ts diff --git a/web/angular/src/app/services/console.service.ts b/web-angular/src/app/services/console.service.ts similarity index 100% rename from web/angular/src/app/services/console.service.ts rename to web-angular/src/app/services/console.service.ts diff --git a/web/angular/src/app/services/credential.service.ts b/web-angular/src/app/services/credential.service.ts similarity index 100% rename from web/angular/src/app/services/credential.service.ts rename to web-angular/src/app/services/credential.service.ts diff --git a/web/angular/src/app/services/device-visit.service.ts b/web-angular/src/app/services/device-visit.service.ts similarity index 100% rename from web/angular/src/app/services/device-visit.service.ts rename to web-angular/src/app/services/device-visit.service.ts diff --git a/web/angular/src/app/services/device.service.ts b/web-angular/src/app/services/device.service.ts similarity index 100% rename from web/angular/src/app/services/device.service.ts rename to web-angular/src/app/services/device.service.ts diff --git a/web/angular/src/app/services/manage-log.service.ts b/web-angular/src/app/services/manage-log.service.ts similarity index 100% rename from web/angular/src/app/services/manage-log.service.ts rename to web-angular/src/app/services/manage-log.service.ts diff --git a/web/angular/src/app/services/manage-notice.service.ts b/web-angular/src/app/services/manage-notice.service.ts similarity index 100% rename from web/angular/src/app/services/manage-notice.service.ts rename to web-angular/src/app/services/manage-notice.service.ts diff --git a/web/angular/src/app/services/manage-user.service.ts b/web-angular/src/app/services/manage-user.service.ts similarity index 100% rename from web/angular/src/app/services/manage-user.service.ts rename to web-angular/src/app/services/manage-user.service.ts diff --git a/web/angular/src/app/services/notice.service.ts b/web-angular/src/app/services/notice.service.ts similarity index 100% rename from web/angular/src/app/services/notice.service.ts rename to web-angular/src/app/services/notice.service.ts diff --git a/web/angular/src/app/services/place-visit.service.ts b/web-angular/src/app/services/place-visit.service.ts similarity index 100% rename from web/angular/src/app/services/place-visit.service.ts rename to web-angular/src/app/services/place-visit.service.ts diff --git a/web/angular/src/app/services/place.service.ts b/web-angular/src/app/services/place.service.ts similarity index 100% rename from web/angular/src/app/services/place.service.ts rename to web-angular/src/app/services/place.service.ts diff --git a/web/angular/src/app/services/privilege.service.ts b/web-angular/src/app/services/privilege.service.ts similarity index 100% rename from web/angular/src/app/services/privilege.service.ts rename to web-angular/src/app/services/privilege.service.ts diff --git a/web/angular/src/app/services/resource.service.ts b/web-angular/src/app/services/resource.service.ts similarity index 100% rename from web/angular/src/app/services/resource.service.ts rename to web-angular/src/app/services/resource.service.ts diff --git a/web/angular/src/app/services/user.service.ts b/web-angular/src/app/services/user.service.ts similarity index 100% rename from web/angular/src/app/services/user.service.ts rename to web-angular/src/app/services/user.service.ts diff --git a/web/angular/src/app/services/version.service.ts b/web-angular/src/app/services/version.service.ts similarity index 100% rename from web/angular/src/app/services/version.service.ts rename to web-angular/src/app/services/version.service.ts diff --git a/web/angular/src/app/utils/formcodes.ts b/web-angular/src/app/utils/formcodes.ts similarity index 100% rename from web/angular/src/app/utils/formcodes.ts rename to web-angular/src/app/utils/formcodes.ts diff --git a/web/angular/src/app/utils/httpcodes.ts b/web-angular/src/app/utils/httpcodes.ts similarity index 100% rename from web/angular/src/app/utils/httpcodes.ts rename to web-angular/src/app/utils/httpcodes.ts diff --git a/web/angular/src/app/utils/pagination.ts b/web-angular/src/app/utils/pagination.ts similarity index 100% rename from web/angular/src/app/utils/pagination.ts rename to web-angular/src/app/utils/pagination.ts diff --git a/web/angular/src/app/utils/snackbars.ts b/web-angular/src/app/utils/snackbars.ts similarity index 100% rename from web/angular/src/app/utils/snackbars.ts rename to web-angular/src/app/utils/snackbars.ts diff --git a/web/angular/src/app/utils/tables.ts b/web-angular/src/app/utils/tables.ts similarity index 100% rename from web/angular/src/app/utils/tables.ts rename to web-angular/src/app/utils/tables.ts diff --git a/web/angular/src/app/views/activate.component.html b/web-angular/src/app/views/activate.component.html similarity index 100% rename from web/angular/src/app/views/activate.component.html rename to web-angular/src/app/views/activate.component.html diff --git a/web/angular/src/app/views/activate.component.ts b/web-angular/src/app/views/activate.component.ts similarity index 100% rename from web/angular/src/app/views/activate.component.ts rename to web-angular/src/app/views/activate.component.ts diff --git a/web/angular/src/app/views/change.component.html b/web-angular/src/app/views/change.component.html similarity index 100% rename from web/angular/src/app/views/change.component.html rename to web-angular/src/app/views/change.component.html diff --git a/web/angular/src/app/views/change.component.ts b/web-angular/src/app/views/change.component.ts similarity index 100% rename from web/angular/src/app/views/change.component.ts rename to web-angular/src/app/views/change.component.ts diff --git a/web/angular/src/app/views/device-location.component.html b/web-angular/src/app/views/device-location.component.html similarity index 100% rename from web/angular/src/app/views/device-location.component.html rename to web-angular/src/app/views/device-location.component.html diff --git a/web/angular/src/app/views/device-location.component.ts b/web-angular/src/app/views/device-location.component.ts similarity index 100% rename from web/angular/src/app/views/device-location.component.ts rename to web-angular/src/app/views/device-location.component.ts diff --git a/web/angular/src/app/views/device-visits.component.html b/web-angular/src/app/views/device-visits.component.html similarity index 100% rename from web/angular/src/app/views/device-visits.component.html rename to web-angular/src/app/views/device-visits.component.html diff --git a/web/angular/src/app/views/device-visits.component.ts b/web-angular/src/app/views/device-visits.component.ts similarity index 100% rename from web/angular/src/app/views/device-visits.component.ts rename to web-angular/src/app/views/device-visits.component.ts diff --git a/web/angular/src/app/views/devices.component.html b/web-angular/src/app/views/devices.component.html similarity index 100% rename from web/angular/src/app/views/devices.component.html rename to web-angular/src/app/views/devices.component.html diff --git a/web/angular/src/app/views/devices.component.ts b/web-angular/src/app/views/devices.component.ts similarity index 100% rename from web/angular/src/app/views/devices.component.ts rename to web-angular/src/app/views/devices.component.ts diff --git a/web/angular/src/app/views/edit-notice.component.html b/web-angular/src/app/views/edit-notice.component.html similarity index 100% rename from web/angular/src/app/views/edit-notice.component.html rename to web-angular/src/app/views/edit-notice.component.html diff --git a/web/angular/src/app/views/edit-notice.component.ts b/web-angular/src/app/views/edit-notice.component.ts similarity index 100% rename from web/angular/src/app/views/edit-notice.component.ts rename to web-angular/src/app/views/edit-notice.component.ts diff --git a/web/angular/src/app/views/login.component.html b/web-angular/src/app/views/login.component.html similarity index 100% rename from web/angular/src/app/views/login.component.html rename to web-angular/src/app/views/login.component.html diff --git a/web/angular/src/app/views/login.component.ts b/web-angular/src/app/views/login.component.ts similarity index 100% rename from web/angular/src/app/views/login.component.ts rename to web-angular/src/app/views/login.component.ts diff --git a/web/angular/src/app/views/manage-log.component.html b/web-angular/src/app/views/manage-log.component.html similarity index 100% rename from web/angular/src/app/views/manage-log.component.html rename to web-angular/src/app/views/manage-log.component.html diff --git a/web/angular/src/app/views/manage-log.component.ts b/web-angular/src/app/views/manage-log.component.ts similarity index 100% rename from web/angular/src/app/views/manage-log.component.ts rename to web-angular/src/app/views/manage-log.component.ts diff --git a/web/angular/src/app/views/manage-notices.component.html b/web-angular/src/app/views/manage-notices.component.html similarity index 100% rename from web/angular/src/app/views/manage-notices.component.html rename to web-angular/src/app/views/manage-notices.component.html diff --git a/web/angular/src/app/views/manage-notices.component.ts b/web-angular/src/app/views/manage-notices.component.ts similarity index 100% rename from web/angular/src/app/views/manage-notices.component.ts rename to web-angular/src/app/views/manage-notices.component.ts diff --git a/web/angular/src/app/views/manage-system.component.html b/web-angular/src/app/views/manage-system.component.html similarity index 100% rename from web/angular/src/app/views/manage-system.component.html rename to web-angular/src/app/views/manage-system.component.html diff --git a/web/angular/src/app/views/manage-system.component.ts b/web-angular/src/app/views/manage-system.component.ts similarity index 100% rename from web/angular/src/app/views/manage-system.component.ts rename to web-angular/src/app/views/manage-system.component.ts diff --git a/web/angular/src/app/views/manage-users.component.html b/web-angular/src/app/views/manage-users.component.html similarity index 100% rename from web/angular/src/app/views/manage-users.component.html rename to web-angular/src/app/views/manage-users.component.html diff --git a/web/angular/src/app/views/manage-users.component.ts b/web-angular/src/app/views/manage-users.component.ts similarity index 100% rename from web/angular/src/app/views/manage-users.component.ts rename to web-angular/src/app/views/manage-users.component.ts diff --git a/web/angular/src/app/views/notices.component.html b/web-angular/src/app/views/notices.component.html similarity index 100% rename from web/angular/src/app/views/notices.component.html rename to web-angular/src/app/views/notices.component.html diff --git a/web/angular/src/app/views/notices.component.ts b/web-angular/src/app/views/notices.component.ts similarity index 100% rename from web/angular/src/app/views/notices.component.ts rename to web-angular/src/app/views/notices.component.ts diff --git a/web/angular/src/app/views/place-visits.component.html b/web-angular/src/app/views/place-visits.component.html similarity index 100% rename from web/angular/src/app/views/place-visits.component.html rename to web-angular/src/app/views/place-visits.component.html diff --git a/web/angular/src/app/views/place-visits.component.ts b/web-angular/src/app/views/place-visits.component.ts similarity index 100% rename from web/angular/src/app/views/place-visits.component.ts rename to web-angular/src/app/views/place-visits.component.ts diff --git a/web/angular/src/app/views/places.component.html b/web-angular/src/app/views/places.component.html similarity index 100% rename from web/angular/src/app/views/places.component.html rename to web-angular/src/app/views/places.component.html diff --git a/web/angular/src/app/views/places.component.ts b/web-angular/src/app/views/places.component.ts similarity index 100% rename from web/angular/src/app/views/places.component.ts rename to web-angular/src/app/views/places.component.ts diff --git a/web/angular/src/app/views/privileges.component.html b/web-angular/src/app/views/privileges.component.html similarity index 100% rename from web/angular/src/app/views/privileges.component.html rename to web-angular/src/app/views/privileges.component.html diff --git a/web/angular/src/app/views/privileges.component.ts b/web-angular/src/app/views/privileges.component.ts similarity index 100% rename from web/angular/src/app/views/privileges.component.ts rename to web-angular/src/app/views/privileges.component.ts diff --git a/web/angular/src/app/views/register.component.html b/web-angular/src/app/views/register.component.html similarity index 100% rename from web/angular/src/app/views/register.component.html rename to web-angular/src/app/views/register.component.html diff --git a/web/angular/src/app/views/register.component.ts b/web-angular/src/app/views/register.component.ts similarity index 100% rename from web/angular/src/app/views/register.component.ts rename to web-angular/src/app/views/register.component.ts diff --git a/web/angular/src/app/views/reset.component.html b/web-angular/src/app/views/reset.component.html similarity index 100% rename from web/angular/src/app/views/reset.component.html rename to web-angular/src/app/views/reset.component.html diff --git a/web/angular/src/app/views/reset.component.ts b/web-angular/src/app/views/reset.component.ts similarity index 100% rename from web/angular/src/app/views/reset.component.ts rename to web-angular/src/app/views/reset.component.ts diff --git a/web/angular/src/app/views/share.component.html b/web-angular/src/app/views/share.component.html similarity index 100% rename from web/angular/src/app/views/share.component.html rename to web-angular/src/app/views/share.component.html diff --git a/web/angular/src/app/views/share.component.ts b/web-angular/src/app/views/share.component.ts similarity index 100% rename from web/angular/src/app/views/share.component.ts rename to web-angular/src/app/views/share.component.ts diff --git a/web/angular/src/app/views/user.component.html b/web-angular/src/app/views/user.component.html similarity index 100% rename from web/angular/src/app/views/user.component.html rename to web-angular/src/app/views/user.component.html diff --git a/web/angular/src/app/views/user.component.ts b/web-angular/src/app/views/user.component.ts similarity index 100% rename from web/angular/src/app/views/user.component.ts rename to web-angular/src/app/views/user.component.ts diff --git a/web/angular/src/app/widgets/confirmation-dialog.component.html b/web-angular/src/app/widgets/confirmation-dialog.component.html similarity index 100% rename from web/angular/src/app/widgets/confirmation-dialog.component.html rename to web-angular/src/app/widgets/confirmation-dialog.component.html diff --git a/web/angular/src/app/widgets/confirmation-dialog.component.ts b/web-angular/src/app/widgets/confirmation-dialog.component.ts similarity index 100% rename from web/angular/src/app/widgets/confirmation-dialog.component.ts rename to web-angular/src/app/widgets/confirmation-dialog.component.ts diff --git a/web/angular/src/app/widgets/decision-panel.component.html b/web-angular/src/app/widgets/decision-panel.component.html similarity index 100% rename from web/angular/src/app/widgets/decision-panel.component.html rename to web-angular/src/app/widgets/decision-panel.component.html diff --git a/web/angular/src/app/widgets/decision-panel.component.ts b/web-angular/src/app/widgets/decision-panel.component.ts similarity index 100% rename from web/angular/src/app/widgets/decision-panel.component.ts rename to web-angular/src/app/widgets/decision-panel.component.ts diff --git a/web/angular/src/app/widgets/email-field.component.html b/web-angular/src/app/widgets/email-field.component.html similarity index 100% rename from web/angular/src/app/widgets/email-field.component.html rename to web-angular/src/app/widgets/email-field.component.html diff --git a/web/angular/src/app/widgets/email-field.component.ts b/web-angular/src/app/widgets/email-field.component.ts similarity index 100% rename from web/angular/src/app/widgets/email-field.component.ts rename to web-angular/src/app/widgets/email-field.component.ts diff --git a/web/angular/src/app/widgets/language-select.component.html b/web-angular/src/app/widgets/language-select.component.html similarity index 100% rename from web/angular/src/app/widgets/language-select.component.html rename to web-angular/src/app/widgets/language-select.component.html diff --git a/web/angular/src/app/widgets/language-select.component.ts b/web-angular/src/app/widgets/language-select.component.ts similarity index 100% rename from web/angular/src/app/widgets/language-select.component.ts rename to web-angular/src/app/widgets/language-select.component.ts diff --git a/web/angular/src/app/widgets/log-dialog.component.html b/web-angular/src/app/widgets/log-dialog.component.html similarity index 100% rename from web/angular/src/app/widgets/log-dialog.component.html rename to web-angular/src/app/widgets/log-dialog.component.html diff --git a/web/angular/src/app/widgets/log-dialog.component.ts b/web-angular/src/app/widgets/log-dialog.component.ts similarity index 100% rename from web/angular/src/app/widgets/log-dialog.component.ts rename to web-angular/src/app/widgets/log-dialog.component.ts diff --git a/web/angular/src/app/widgets/login-field.component.html b/web-angular/src/app/widgets/login-field.component.html similarity index 100% rename from web/angular/src/app/widgets/login-field.component.html rename to web-angular/src/app/widgets/login-field.component.html diff --git a/web/angular/src/app/widgets/login-field.component.ts b/web-angular/src/app/widgets/login-field.component.ts similarity index 100% rename from web/angular/src/app/widgets/login-field.component.ts rename to web-angular/src/app/widgets/login-field.component.ts diff --git a/web/angular/src/app/widgets/marker-map.component.html b/web-angular/src/app/widgets/marker-map.component.html similarity index 100% rename from web/angular/src/app/widgets/marker-map.component.html rename to web-angular/src/app/widgets/marker-map.component.html diff --git a/web/angular/src/app/widgets/marker-map.component.ts b/web-angular/src/app/widgets/marker-map.component.ts similarity index 100% rename from web/angular/src/app/widgets/marker-map.component.ts rename to web-angular/src/app/widgets/marker-map.component.ts diff --git a/web/angular/src/app/widgets/message-dialog.component.html b/web-angular/src/app/widgets/message-dialog.component.html similarity index 100% rename from web/angular/src/app/widgets/message-dialog.component.html rename to web-angular/src/app/widgets/message-dialog.component.html diff --git a/web/angular/src/app/widgets/message-dialog.component.ts b/web-angular/src/app/widgets/message-dialog.component.ts similarity index 100% rename from web/angular/src/app/widgets/message-dialog.component.ts rename to web-angular/src/app/widgets/message-dialog.component.ts diff --git a/web/angular/src/app/widgets/name-field.component.html b/web-angular/src/app/widgets/name-field.component.html similarity index 100% rename from web/angular/src/app/widgets/name-field.component.html rename to web-angular/src/app/widgets/name-field.component.html diff --git a/web/angular/src/app/widgets/name-field.component.ts b/web-angular/src/app/widgets/name-field.component.ts similarity index 100% rename from web/angular/src/app/widgets/name-field.component.ts rename to web-angular/src/app/widgets/name-field.component.ts diff --git a/web/angular/src/app/widgets/nickname-dialog.component.html b/web-angular/src/app/widgets/nickname-dialog.component.html similarity index 100% rename from web/angular/src/app/widgets/nickname-dialog.component.html rename to web-angular/src/app/widgets/nickname-dialog.component.html diff --git a/web/angular/src/app/widgets/nickname-dialog.component.ts b/web-angular/src/app/widgets/nickname-dialog.component.ts similarity index 100% rename from web/angular/src/app/widgets/nickname-dialog.component.ts rename to web-angular/src/app/widgets/nickname-dialog.component.ts diff --git a/web/angular/src/app/widgets/notice-card.component.html b/web-angular/src/app/widgets/notice-card.component.html similarity index 100% rename from web/angular/src/app/widgets/notice-card.component.html rename to web-angular/src/app/widgets/notice-card.component.html diff --git a/web/angular/src/app/widgets/notice-card.component.ts b/web-angular/src/app/widgets/notice-card.component.ts similarity index 100% rename from web/angular/src/app/widgets/notice-card.component.ts rename to web-angular/src/app/widgets/notice-card.component.ts diff --git a/web/angular/src/app/widgets/password-field.component.html b/web-angular/src/app/widgets/password-field.component.html similarity index 100% rename from web/angular/src/app/widgets/password-field.component.html rename to web-angular/src/app/widgets/password-field.component.html diff --git a/web/angular/src/app/widgets/password-field.component.ts b/web-angular/src/app/widgets/password-field.component.ts similarity index 100% rename from web/angular/src/app/widgets/password-field.component.ts rename to web-angular/src/app/widgets/password-field.component.ts diff --git a/web/angular/src/app/widgets/profile-button.component.html b/web-angular/src/app/widgets/profile-button.component.html similarity index 100% rename from web/angular/src/app/widgets/profile-button.component.html rename to web-angular/src/app/widgets/profile-button.component.html diff --git a/web/angular/src/app/widgets/profile-button.component.ts b/web-angular/src/app/widgets/profile-button.component.ts similarity index 100% rename from web/angular/src/app/widgets/profile-button.component.ts rename to web-angular/src/app/widgets/profile-button.component.ts diff --git a/web/angular/src/app/widgets/share-dialog.component.html b/web-angular/src/app/widgets/share-dialog.component.html similarity index 100% rename from web/angular/src/app/widgets/share-dialog.component.html rename to web-angular/src/app/widgets/share-dialog.component.html diff --git a/web/angular/src/app/widgets/share-dialog.component.ts b/web-angular/src/app/widgets/share-dialog.component.ts similarity index 100% rename from web/angular/src/app/widgets/share-dialog.component.ts rename to web-angular/src/app/widgets/share-dialog.component.ts diff --git a/web/angular/src/app/widgets/tile-map.component.html b/web-angular/src/app/widgets/tile-map.component.html similarity index 100% rename from web/angular/src/app/widgets/tile-map.component.html rename to web-angular/src/app/widgets/tile-map.component.html diff --git a/web/angular/src/app/widgets/tile-map.component.ts b/web-angular/src/app/widgets/tile-map.component.ts similarity index 100% rename from web/angular/src/app/widgets/tile-map.component.ts rename to web-angular/src/app/widgets/tile-map.component.ts diff --git a/web/angular/src/app/widgets/toolbar-button.component.html b/web-angular/src/app/widgets/toolbar-button.component.html similarity index 100% rename from web/angular/src/app/widgets/toolbar-button.component.html rename to web-angular/src/app/widgets/toolbar-button.component.html diff --git a/web/angular/src/app/widgets/toolbar-button.component.ts b/web-angular/src/app/widgets/toolbar-button.component.ts similarity index 100% rename from web/angular/src/app/widgets/toolbar-button.component.ts rename to web-angular/src/app/widgets/toolbar-button.component.ts diff --git a/web/angular/src/assets/.gitkeep b/web-angular/src/assets/.gitkeep old mode 100755 new mode 100644 similarity index 100% rename from web/angular/src/assets/.gitkeep rename to web-angular/src/assets/.gitkeep diff --git a/web/angular/src/assets/flags/de.svg b/web-angular/src/assets/flags/de.svg similarity index 100% rename from web/angular/src/assets/flags/de.svg rename to web-angular/src/assets/flags/de.svg diff --git a/web/angular/src/assets/flags/en.svg b/web-angular/src/assets/flags/en.svg similarity index 100% rename from web/angular/src/assets/flags/en.svg rename to web-angular/src/assets/flags/en.svg diff --git a/web/angular/src/assets/flags/es.svg b/web-angular/src/assets/flags/es.svg similarity index 100% rename from web/angular/src/assets/flags/es.svg rename to web-angular/src/assets/flags/es.svg diff --git a/web/angular/src/assets/flags/fr.svg b/web-angular/src/assets/flags/fr.svg similarity index 100% rename from web/angular/src/assets/flags/fr.svg rename to web-angular/src/assets/flags/fr.svg diff --git a/web/angular/src/assets/flags/it.svg b/web-angular/src/assets/flags/it.svg similarity index 100% rename from web/angular/src/assets/flags/it.svg rename to web-angular/src/assets/flags/it.svg diff --git a/web/angular/src/assets/fonts/MaterialIcons-Regular.eot b/web-angular/src/assets/fonts/MaterialIcons-Regular.eot similarity index 100% rename from web/angular/src/assets/fonts/MaterialIcons-Regular.eot rename to web-angular/src/assets/fonts/MaterialIcons-Regular.eot diff --git a/web/angular/src/assets/fonts/MaterialIcons-Regular.ttf b/web-angular/src/assets/fonts/MaterialIcons-Regular.ttf similarity index 100% rename from web/angular/src/assets/fonts/MaterialIcons-Regular.ttf rename to web-angular/src/assets/fonts/MaterialIcons-Regular.ttf diff --git a/web/angular/src/assets/fonts/MaterialIcons-Regular.woff b/web-angular/src/assets/fonts/MaterialIcons-Regular.woff similarity index 100% rename from web/angular/src/assets/fonts/MaterialIcons-Regular.woff rename to web-angular/src/assets/fonts/MaterialIcons-Regular.woff diff --git a/web/angular/src/assets/fonts/MaterialIcons-Regular.woff2 b/web-angular/src/assets/fonts/MaterialIcons-Regular.woff2 similarity index 100% rename from web/angular/src/assets/fonts/MaterialIcons-Regular.woff2 rename to web-angular/src/assets/fonts/MaterialIcons-Regular.woff2 diff --git a/web/angular/src/assets/fonts/RobotoLatin-Regular.eot b/web-angular/src/assets/fonts/RobotoLatin-Regular.eot similarity index 100% rename from web/angular/src/assets/fonts/RobotoLatin-Regular.eot rename to web-angular/src/assets/fonts/RobotoLatin-Regular.eot diff --git a/web/angular/src/assets/fonts/RobotoLatin-Regular.ttf b/web-angular/src/assets/fonts/RobotoLatin-Regular.ttf similarity index 100% rename from web/angular/src/assets/fonts/RobotoLatin-Regular.ttf rename to web-angular/src/assets/fonts/RobotoLatin-Regular.ttf diff --git a/web/angular/src/assets/fonts/RobotoLatin-Regular.woff b/web-angular/src/assets/fonts/RobotoLatin-Regular.woff similarity index 100% rename from web/angular/src/assets/fonts/RobotoLatin-Regular.woff rename to web-angular/src/assets/fonts/RobotoLatin-Regular.woff diff --git a/web/angular/src/assets/fonts/RobotoLatin-Regular.woff2 b/web-angular/src/assets/fonts/RobotoLatin-Regular.woff2 similarity index 100% rename from web/angular/src/assets/fonts/RobotoLatin-Regular.woff2 rename to web-angular/src/assets/fonts/RobotoLatin-Regular.woff2 diff --git a/web/angular/src/assets/fonts/RobotoMonoLatin-Regular.eot b/web-angular/src/assets/fonts/RobotoMonoLatin-Regular.eot similarity index 100% rename from web/angular/src/assets/fonts/RobotoMonoLatin-Regular.eot rename to web-angular/src/assets/fonts/RobotoMonoLatin-Regular.eot diff --git a/web/angular/src/assets/fonts/RobotoMonoLatin-Regular.ttf b/web-angular/src/assets/fonts/RobotoMonoLatin-Regular.ttf similarity index 100% rename from web/angular/src/assets/fonts/RobotoMonoLatin-Regular.ttf rename to web-angular/src/assets/fonts/RobotoMonoLatin-Regular.ttf diff --git a/web/angular/src/assets/fonts/RobotoMonoLatin-Regular.woff b/web-angular/src/assets/fonts/RobotoMonoLatin-Regular.woff similarity index 100% rename from web/angular/src/assets/fonts/RobotoMonoLatin-Regular.woff rename to web-angular/src/assets/fonts/RobotoMonoLatin-Regular.woff diff --git a/web/angular/src/assets/fonts/RobotoMonoLatin-Regular.woff2 b/web-angular/src/assets/fonts/RobotoMonoLatin-Regular.woff2 similarity index 100% rename from web/angular/src/assets/fonts/RobotoMonoLatin-Regular.woff2 rename to web-angular/src/assets/fonts/RobotoMonoLatin-Regular.woff2 diff --git a/web/angular/src/assets/icons/favicon-114x114.png b/web-angular/src/assets/icons/favicon-114x114.png similarity index 100% rename from web/angular/src/assets/icons/favicon-114x114.png rename to web-angular/src/assets/icons/favicon-114x114.png diff --git a/web/angular/src/assets/icons/favicon-120x120.png b/web-angular/src/assets/icons/favicon-120x120.png similarity index 100% rename from web/angular/src/assets/icons/favicon-120x120.png rename to web-angular/src/assets/icons/favicon-120x120.png diff --git a/web/angular/src/assets/icons/favicon-144x144.png b/web-angular/src/assets/icons/favicon-144x144.png similarity index 100% rename from web/angular/src/assets/icons/favicon-144x144.png rename to web-angular/src/assets/icons/favicon-144x144.png diff --git a/web/angular/src/assets/icons/favicon-152x152.png b/web-angular/src/assets/icons/favicon-152x152.png similarity index 100% rename from web/angular/src/assets/icons/favicon-152x152.png rename to web-angular/src/assets/icons/favicon-152x152.png diff --git a/web/angular/src/assets/icons/favicon-16x16.png b/web-angular/src/assets/icons/favicon-16x16.png similarity index 100% rename from web/angular/src/assets/icons/favicon-16x16.png rename to web-angular/src/assets/icons/favicon-16x16.png diff --git a/web/angular/src/assets/icons/favicon-180x180.png b/web-angular/src/assets/icons/favicon-180x180.png similarity index 100% rename from web/angular/src/assets/icons/favicon-180x180.png rename to web-angular/src/assets/icons/favicon-180x180.png diff --git a/web/angular/src/assets/icons/favicon-192x192.png b/web-angular/src/assets/icons/favicon-192x192.png similarity index 100% rename from web/angular/src/assets/icons/favicon-192x192.png rename to web-angular/src/assets/icons/favicon-192x192.png diff --git a/web/angular/src/assets/icons/favicon-32x32.png b/web-angular/src/assets/icons/favicon-32x32.png similarity index 100% rename from web/angular/src/assets/icons/favicon-32x32.png rename to web-angular/src/assets/icons/favicon-32x32.png diff --git a/web/angular/src/assets/icons/favicon-57x57.png b/web-angular/src/assets/icons/favicon-57x57.png similarity index 100% rename from web/angular/src/assets/icons/favicon-57x57.png rename to web-angular/src/assets/icons/favicon-57x57.png diff --git a/web/angular/src/assets/icons/favicon-60x60.png b/web-angular/src/assets/icons/favicon-60x60.png similarity index 100% rename from web/angular/src/assets/icons/favicon-60x60.png rename to web-angular/src/assets/icons/favicon-60x60.png diff --git a/web/angular/src/assets/icons/favicon-72x72.png b/web-angular/src/assets/icons/favicon-72x72.png similarity index 100% rename from web/angular/src/assets/icons/favicon-72x72.png rename to web-angular/src/assets/icons/favicon-72x72.png diff --git a/web/angular/src/assets/icons/favicon-76x76.png b/web-angular/src/assets/icons/favicon-76x76.png similarity index 100% rename from web/angular/src/assets/icons/favicon-76x76.png rename to web-angular/src/assets/icons/favicon-76x76.png diff --git a/web/angular/src/assets/icons/favicon-96x96.png b/web-angular/src/assets/icons/favicon-96x96.png similarity index 100% rename from web/angular/src/assets/icons/favicon-96x96.png rename to web-angular/src/assets/icons/favicon-96x96.png diff --git a/web/angular/src/assets/icons/home.svg b/web-angular/src/assets/icons/home.svg similarity index 100% rename from web/angular/src/assets/icons/home.svg rename to web-angular/src/assets/icons/home.svg diff --git a/web/angular/src/assets/images/frontpage.png b/web-angular/src/assets/images/frontpage.png similarity index 100% rename from web/angular/src/assets/images/frontpage.png rename to web-angular/src/assets/images/frontpage.png diff --git a/web/angular/src/assets/markers/marker_dark.png b/web-angular/src/assets/markers/marker_dark.png similarity index 100% rename from web/angular/src/assets/markers/marker_dark.png rename to web-angular/src/assets/markers/marker_dark.png diff --git a/web/angular/src/assets/markers/marker_normal.png b/web-angular/src/assets/markers/marker_normal.png similarity index 100% rename from web/angular/src/assets/markers/marker_normal.png rename to web-angular/src/assets/markers/marker_normal.png diff --git a/web/angular/src/assets/markers/marker_pin.png b/web-angular/src/assets/markers/marker_pin.png similarity index 100% rename from web/angular/src/assets/markers/marker_pin.png rename to web-angular/src/assets/markers/marker_pin.png diff --git a/web/angular/src/assets/markers/marker_shadow.png b/web-angular/src/assets/markers/marker_shadow.png similarity index 100% rename from web/angular/src/assets/markers/marker_shadow.png rename to web-angular/src/assets/markers/marker_shadow.png diff --git a/web/angular/src/environments/environment.prod.ts b/web-angular/src/environments/environment.prod.ts old mode 100755 new mode 100644 similarity index 100% rename from web/angular/src/environments/environment.prod.ts rename to web-angular/src/environments/environment.prod.ts diff --git a/web/angular/src/environments/environment.ts b/web-angular/src/environments/environment.ts old mode 100755 new mode 100644 similarity index 100% rename from web/angular/src/environments/environment.ts rename to web-angular/src/environments/environment.ts diff --git a/web/angular/src/favicon.ico b/web-angular/src/favicon.ico similarity index 100% rename from web/angular/src/favicon.ico rename to web-angular/src/favicon.ico diff --git a/web/angular/src/fonts.scss b/web-angular/src/fonts.scss similarity index 100% rename from web/angular/src/fonts.scss rename to web-angular/src/fonts.scss diff --git a/web/angular/src/index.html b/web-angular/src/index.html old mode 100755 new mode 100644 similarity index 100% rename from web/angular/src/index.html rename to web-angular/src/index.html diff --git a/web/angular/src/main.ts b/web-angular/src/main.ts similarity index 100% rename from web/angular/src/main.ts rename to web-angular/src/main.ts diff --git a/web/angular/src/polyfills.ts b/web-angular/src/polyfills.ts similarity index 100% rename from web/angular/src/polyfills.ts rename to web-angular/src/polyfills.ts diff --git a/web/angular/src/styles.scss b/web-angular/src/styles.scss similarity index 100% rename from web/angular/src/styles.scss rename to web-angular/src/styles.scss diff --git a/web/angular/src/test.ts b/web-angular/src/test.ts similarity index 100% rename from web/angular/src/test.ts rename to web-angular/src/test.ts diff --git a/web/angular/src/theme.scss b/web-angular/src/theme.scss similarity index 100% rename from web/angular/src/theme.scss rename to web-angular/src/theme.scss diff --git a/web/angular/src/tsconfig.app.json b/web-angular/src/tsconfig.app.json similarity index 100% rename from web/angular/src/tsconfig.app.json rename to web-angular/src/tsconfig.app.json diff --git a/web/angular/src/tsconfig.spec.json b/web-angular/src/tsconfig.spec.json similarity index 100% rename from web/angular/src/tsconfig.spec.json rename to web-angular/src/tsconfig.spec.json diff --git a/web/angular/src/typings.d.ts b/web-angular/src/typings.d.ts similarity index 100% rename from web/angular/src/typings.d.ts rename to web-angular/src/typings.d.ts diff --git a/web/angular/tsconfig.json b/web-angular/tsconfig.json similarity index 100% rename from web/angular/tsconfig.json rename to web-angular/tsconfig.json diff --git a/web/angular/tslint.json b/web-angular/tslint.json similarity index 100% rename from web/angular/tslint.json rename to web-angular/tslint.json diff --git a/web-war/build.gradle b/web-war/build.gradle new file mode 100644 index 0000000..53042b5 --- /dev/null +++ b/web-war/build.gradle @@ -0,0 +1,26 @@ +plugins { + id 'war' +} + +description = 'Maptology Web Webapp' + +dependencies { + providedCompile "javax:javaee-api:${versionJavaee}" + testCompile "junit:junit:${versionJunit}" +} + + +jar { + enabled = true +} + + +war { + println project(":web-angular").projectDir.path + "/dist/" + from( file(project(":web-angular").projectDir.path + "/dist/") ) { + include '**/*' + } +} + +// depend on wildfly task for testing +tasks['war'].dependsOn(project(":web-angular").tasks["build"]) \ No newline at end of file diff --git a/web/webapp/pom.xml b/web-war/pom.xml similarity index 88% rename from web/webapp/pom.xml rename to web-war/pom.xml index 185c795..7b1d449 100644 --- a/web/webapp/pom.xml +++ b/web-war/pom.xml @@ -4,11 +4,11 @@ 4.0.0 com.maptology - web + project 0.0.1-SNAPSHOT - com.maptology.web - webapp + com.maptology + web-war Maptology Web Webapp War of the maptology webapp. war @@ -27,8 +27,8 @@ - com.maptology.web - angular + com.maptology + web-angular ${project.build.directory}/generated-sources/angular META-INF/** @@ -67,8 +67,8 @@
- com.maptology.web - angular + com.maptology + web-angular ${project.version} provided diff --git a/web/webapp/src/main/java/.keep b/web-war/src/main/java/.keep similarity index 100% rename from web/webapp/src/main/java/.keep rename to web-war/src/main/java/.keep diff --git a/web/webapp/src/main/java/com/maptology/web/webapp/AngularRouterServlet.java b/web-war/src/main/java/com/maptology/web/webapp/AngularRouterServlet.java similarity index 100% rename from web/webapp/src/main/java/com/maptology/web/webapp/AngularRouterServlet.java rename to web-war/src/main/java/com/maptology/web/webapp/AngularRouterServlet.java diff --git a/web/webapp/src/main/webapp/WEB-INF/jboss-web.xml b/web-war/src/main/webapp/WEB-INF/jboss-web.xml similarity index 100% rename from web/webapp/src/main/webapp/WEB-INF/jboss-web.xml rename to web-war/src/main/webapp/WEB-INF/jboss-web.xml diff --git a/web/webapp/src/main/webapp/WEB-INF/web.xml b/web-war/src/main/webapp/WEB-INF/web.xml similarity index 100% rename from web/webapp/src/main/webapp/WEB-INF/web.xml rename to web-war/src/main/webapp/WEB-INF/web.xml diff --git a/web/webapp/src/test/java/.keep b/web-war/src/test/java/.keep similarity index 100% rename from web/webapp/src/test/java/.keep rename to web-war/src/test/java/.keep diff --git a/web/webapp/src/test/resources/.keep b/web-war/src/test/resources/.keep similarity index 100% rename from web/webapp/src/test/resources/.keep rename to web-war/src/test/resources/.keep diff --git a/web/pom.xml b/web/pom.xml deleted file mode 100644 index a39aeba..0000000 --- a/web/pom.xml +++ /dev/null @@ -1,22 +0,0 @@ - - - 4.0.0 - - com.maptology - all - 0.0.1-SNAPSHOT - - web - Maptology Web - Webapp frontend for maptology. - pom - - v10.16.0 - 6.9.0 - - - angular - webapp - -