Rev 78 | Go to most recent revision | Blame | Compare with Previous | Last modification | View Log | RSS feed
def getscore(struct):score = 0if struct.has_key("features") :features = struct.get("features")# GPS Type : Integrated GPS-4, Bluetooth GPS-2if features.has_key("GPS Type") :gpstype = features.get("GPS Type")if "Integrated GPS" in gpstype :score += 4if "Bluetooth GPS" in gpstype :score += 2# A-GPS : 2, 0if features.has_key("A-GPS") :score += 2return score