# pylint: disable=W0613
+
+# pylint: disable=W0212
+class OSVersion(str):
+ def __new__(cls, friendly_name, sortable_name, *args, **kwargs):
+ version = str.__new__(cls, friendly_name)
+ version._sortable_name = sortable_name
+ return version
+
+ def __lt__(self, other):
+ return self._sortable_name < other._sortable_name
+
+ def __gt__(self, other):
+ return self._sortable_name > other._sortable_name
+
+ def __le__(self, other):
+ return self._sortable_name <= other._sortable_name
+
+ def __ge__(self, other):
+ return self._sortable_name >= other._sortable_name
+
+
class PlatformBackend(object):
def IsRawDisplayFrameRateSupported(self):
return False
def GetSystemCommitCharge(self):
raise NotImplementedError()
+ def GetSystemTotalPhysicalMemory(self):
+ raise NotImplementedError()
+
def GetCpuStats(self, pid):
return {}
raise NotImplementedError()
def GetOSVersionName(self):
- return None
+ raise NotImplementedError()
def CanFlushIndividualFilesFromSystemCache(self):
raise NotImplementedError()
def FlushSystemCacheForDirectory(self, directory, ignoring=None):
raise NotImplementedError()
- def LaunchApplication(self, application, parameters=None):
+ def LaunchApplication(
+ self, application, parameters=None, elevate_privilege=False):
raise NotImplementedError()
def IsApplicationRunning(self, application):