Пример #1
0
def get_single_sensor(r_a, urn):
    """
    DOCSTRING
    """
    #Get single station description as GeoJSON
    #simple text output
    print gcoos_describe_sensor(r_a, urn)
Пример #2
0
def get_all_sensors(r_a):
    """
    DOCSTRING
    """
    #Get all sensor descriptions as GeoJSON features
    #simple text output
    for station in gcoos_get_all_stations(r_a):
        print "Fetching data for %s..." % station
        print gcoos_describe_sensor(r_a, station)
Пример #3
0
def get_all_sensors_fc(r_a):
    """
    DOCSTRING
    """
    #Get all sensor descriptions as GeoJSON features
    #and make into GeoJSON feature collection that can
    #be dropped into Leaflet map
    the_collection = []
    for station in gcoos_get_all_stations(r_a):
        the_collection.append(gcoos_describe_sensor(r_a, station))
    the_fc = FeatureCollection(the_collection)
    print the_fc