Exemplo n.º 1
0
def get_station():
    for i in range(1,6):
        s=StationDetails(id=i)
        s.get_details()

        #print repr(s.id).rjust(2),
        #print repr(s.available).rjust(5),
        #print repr(s.empty).rjust(5),
        #print str(s.time).rjust(30)
    
        data[s.id].append(DataPoint(s.time, s.available))
Exemplo n.º 2
0
from station_details import StationDetails
import sys        

print 'id' + 5*' ' + 'avail' +5*' ' + 'free' + 5*' ' + 'tot' + 5*' '+ 'time'
for i in range(1,33):
    data=[]
    s=StationDetails(id=i)
    s.get_details()
    data.append(s)

    for station in data:
        print repr(station.id).rjust(2),
        print repr(station.available).rjust(5),
        print repr(station.empty).rjust(5),
        print repr(station.total).rjust(5),
        print str(station.time).rjust(30),
        print station.name

    
Exemplo n.º 3
0
def get_station():
    #print(' --- now in get_station() --- ')
    for i in range(1,33):
        s=StationDetails(id=i)
        s.get_details()
        data[s.id].append(DataPoint(s.time, s.available))