| 12345678910111213141516171819202122232425262728293031323334 |
- #!/usr/bin/env python
- # -*- coding: utf-8 -*-
- class OutdoorStats(object):
- #TODO Umstellung auf properties
- Temperature = 20.0
- bWindy = False
- Pressure = 0.0
- Humidity = 0.0
- WindSpeed = 0.0
- WindDegree = 0
- Clouds = 0.0
- bRaining = False
- bSnowing = False
- MoonPhase = {
- "index" : 0,
- "phase" : 0,
- "pos" : 0,
- "name": ""
- }
- def getJson(self):
- return {
- "Temperature": self.Temperature,
- "bWindy": self.bWindy,
- "Pressure": self.Pressure,
- "Humidity": self.Humidity,
- "WindSpeed": self.WindSpeed,
- "WindDegree": self.WindDegree,
- "Clouds": self.Clouds,
- "bRaining": self.bRaining,
- "bSnowing": self.bSnowing,
- "Moon": self.MoonPhase
- }
|