As Dr.Molle advised:
- Use the first if you need the metadata (i.e. info window)
- Use the second if all you need is the geometry.
Question
I am building a Google Maps application with realtime data. I am aware of 2 workarounds to refresh a Fusion Table Layer (below).
Is there an API for that- maybe something like the 'reference' that the PlaceResult has? If not, which workaround is considered to be a better practice?
Workarounds:
Manipulatting the location filter (source):
fusionTable.setOptions({
query: {
select: 'Location',
from: 'fusion-table-id',
where: "location not equal to" + (Math.floor(Math.random() * 10000000)).toString()
},
map: _map
});
Manipulating the URLs of the tiles (source):
$("img[src*='fusion-table-id']").each(function () {
$(this).attr("src", $(this).attr("src") + "&" + (new Date()).getTime());
});
Thanks,
HW
Solution
As Dr.Molle advised: