geofire

multiple markers on google maps from firebase database

烈酒焚心 提交于 2019-12-02 08:39:54
<!DOCTYPE html> <html> <head> <title>Geolocation</title> <meta name="viewport" content="initial-scale=1.0, user-scalable=no"> <meta charset="utf-8"> <style> /* Always set the map height explicitly to define the size of the div * element that contains the map. */ #map { height: 100%; } /* Optional: Makes the sample page fill the window. */ html, body { height: 100%; margin: 0; padding: 0; } </style> <!-- Place this inside the HTML head; don't use async defer for now --> <script src="https://www.gstatic.com/firebasejs/4.12.1/firebase.js"></script> <script src="https://cdn.firebase.com/libs

When do I know GeoFire is finished loading as it is Event based trigger

半世苍凉 提交于 2019-12-02 08:34:03
So I used GeoFire and AngularFire for populate my ng-repeat item lists. There is an ionic pull to refresh list. So user pull it and get the current updated location and refresh the list (recall the GeoFire to re-populate the list). $scope.doRefresh = function() { if ($scope.doneLoading) { $scope.useCurrentLocation().then(function() { $scope.userCurrentLocation = { lat: geoLocation.getGeolocation().lat, lng: geoLocation.getGeolocation().lng } angular.forEach($scope.tasks, function(child) { child.$destroy(); }); setupTaskListing(); $scope.$broadcast('scroll.refreshComplete'); }) } } function

How To Display Multiple Markers Coordinates Stored In Firebase Database On Google Maps

好久不见. 提交于 2019-12-02 07:49:05
I am trying to get the coordinates that are saved in the firebase real-time database and display them on a map using the google maps API. This is the code I have so far. Right now it opens and shows the users current location using the html5 geolocation API and it syncs the lat and long coordinates to the firebase real-time database using Geofire. I don't know how to retrieve these points and have multiple points on the google map at the same time showing different users locations. If anyone could help me with this I would really appreciate it. <script src="https://cdn.firebase.com/libs

I have inserted location using geofire in firebase

懵懂的女人 提交于 2019-12-02 07:47:24
I have inserted location using geofire in firebase from one of the activity in android studio now I want to retrieve all the location in single google map activity with marker. I have created map activity, but I don't know how to retrieve the location from the firebase . Please help I am stuck in this. With some source code. Here is my code for sending location to firebase GeoFire geoFire = new GeoFire(databaseReference.child("Location").child(user.getUid())); geoFire.setLocation("location", new GeoLocation(location.getLatitude(), location.getLongitude()), new GeoFire.CompletionListener() {

Using GeoFire queries in Swift does not give useful output

此生再无相见时 提交于 2019-12-01 21:55:36
I'm pretty desperate right now because I'm trying to use GeoFire on my Firebase Database to find nearby users. I'm pretty much stuck for two days now. I searched Google and stackoverflow a lot and tried everything I found there but without any success. Now my last hope is to create this thread myself and hope someone can help me. My database pretty much looks like this: users user_id1 email: xxx@gmail.com username: xxx user_id2 email: yyy@gmail.com username: yyy users_locations user_id1 location g: xxxx l 0: 30.0000 1: 5.0000 user_id2 location g: yyyy l 0: 30.0010 1: 5.0010 I don't know if it

How to remove a GeoFire handle for the following observe in Swift?

纵然是瞬间 提交于 2019-12-01 14:10:09
This is a question for Swift, Firebase and Geofire. I would like to know how to remove a GeoFire handle for the following observer in Swift. locationsEnd!.query(at: location, withRadius: 16.0).observe(GFEventType.init(rawValue: 0)!, with: {(key, location) in The following works fine (in viewDidDisappear): locationsEnd?.firebaseRef.removeAllObservers() However with handle it does not: var locationHandle: UInt = 0 override func viewDidDisappear(_ animated: Bool) { super.viewDidDisappear(animated) //following does not work: locationsEnd?.firebaseRef.removeObserver(withHandle: locationHandle) }

Firebase/GeoFire - Most popular item at location

≯℡__Kan透↙ 提交于 2019-12-01 14:06:36
I am currently in the evaluation process for a database that should serve as a backend for a mobile application. Right now I am looking at Firebase , and for now I like it really much. It is a requirement to have the possibility to fetch the most popular items at a certain location (possibly in the future: additionally for a certain time range that would be an attribute of the item) from the database. So naturally I stumbled upon GeoFire that provides location based query possibilities for Firebase. Unfortunately - at least as far as I understood - there is no possibility to order the results

Firebase/GeoFire - Most popular item at location

寵の児 提交于 2019-12-01 12:48:58
问题 I am currently in the evaluation process for a database that should serve as a backend for a mobile application. Right now I am looking at Firebase , and for now I like it really much. It is a requirement to have the possibility to fetch the most popular items at a certain location (possibly in the future: additionally for a certain time range that would be an attribute of the item) from the database. So naturally I stumbled upon GeoFire that provides location based query possibilities for

Limit the number of queried items from GeoFire

耗尽温柔 提交于 2019-12-01 09:38:25
问题 I have a lot of entry in the same location. I would like only to get the 10 latest added items using Geofire. I know that it can be done easily with firebase using Query.limitToLast() but I don't know how to do it with Geofire. If it is not possible, do you have any workaround that I can apply ? 回答1: There is only one solution for this : you should begin a query with a small radius, and each time you reach onGeoQueryReady() ("All data has been loaded"), you increase the radius by a small

Geofire - not found locations

筅森魡賤 提交于 2019-12-01 03:42:54
How can I get the all locations that are near to a passed GeoLocation(double lat, double lng) using Geo Queries . I have the following code (and it happens nothing): public void setCurrentLatLng(double lat, double lng){ this.lat = lat; this.lng = lng; GeoLocation geoLocation = new GeoLocation(lat, lng); updateCurrenLocation(geoLocation); GeoQuery geoQuery = geoFire.queryAtLocation(geoLocation, 8f); geoQuery.addGeoQueryDataEventListener(new GeoQueryDataEventListener() { @Override public void onDataEntered(DataSnapshot dataSnapshot, GeoLocation location) { Log.d("geoQuery","onDataEntered "