(cls, proxy_json)
| 31 | |
| 32 | @classmethod |
| 33 | def createFromJson(cls, proxy_json): |
| 34 | _dict = json.loads(proxy_json) |
| 35 | return cls(proxy=_dict.get("proxy", ""), |
| 36 | fail_count=_dict.get("fail_count", 0), |
| 37 | region=_dict.get("region", ""), |
| 38 | anonymous=_dict.get("anonymous", ""), |
| 39 | source=_dict.get("source", ""), |
| 40 | check_count=_dict.get("check_count", 0), |
| 41 | last_status=_dict.get("last_status", ""), |
| 42 | last_time=_dict.get("last_time", ""), |
| 43 | https=_dict.get("https", False) |
| 44 | ) |
| 45 | |
| 46 | @property |
| 47 | def proxy(self): |