I am trying to save location (so latitide and longitude) as one of the keys/fields in Firebase. In their example [**SFVehicles**](https://github.com/firebase/geofire-java/blob/master/examples/SFVehicles/SF%20Vehicles/src/main/java/com/firebase/sfvehicles/SFVehiclesActivity.java), they do show how to query once the information is stored but my problem is how do i save in the first place.

In their blog post, [GeoFire goes Mobile](https://www.firebase.com/blog/2014-08-26-geofire-goes-mobile.html), they are showing how the data would look like - but how do I get that `location` field populated?

[![enter image description here](https://i.stack.imgur.com/oCUV5.png)](https://i.stack.imgur.com/oCUV5.png)

I am able to save other types of strings to the Firebase though. I just use the code below.
Question is **What data type should the `location` field be?**

```
        Firebase ref = new Firebase("https://myfirebaselink.firebaseio.com/");

       //User 
       alan = new User("Alan Turing", 1912);

        alanRef.setValue(obj);

```

I tried `location` to be a `List<String>`, but that did not work -- the location field looked like below:

[![enter image description here](https://i.stack.imgur.com/iTUYi.png)](https://i.stack.imgur.com/iTUYi.png)

Edit: On more research, found [this blog post by Google](http://googlegeodevelopers.blogspot.com/2015/06/code-road-android-app-store-your.html) but they are also saving as keys `latitude1 and` longitude`. This probably was written before` GeoFire` was introduced.