def __init__(self, obj): ''' Private constructor, called by L{Symptom.fromJSONObject}. Do not use directly. ''' Symptom.__init__(self, obj) self.output = StringMatch( JSONHelper.getObjectOrStringChecked(obj, "value", True))
def __init__(self, obj): ''' Private constructor, called by L{Symptom.fromJSONObject}. Do not use directly. ''' Symptom.__init__(self, obj) self.output = StringMatch(JSONHelper.getObjectOrStringChecked(obj, "value", True)) self.src = JSONHelper.getStringChecked(obj, "src") if self.src != None: self.src = self.src.lower() if self.src != "stderr" and self.src != "stdout" and self.src != "crashdata": raise RuntimeError("Invalid source specified: %s" % self.src)
def __init__(self, obj): ''' Private constructor, called by L{Symptom.fromJSONObject}. Do not use directly. ''' Symptom.__init__(self, obj) self.registerNames = JSONHelper.getArrayChecked(obj, "registerNames") self.instructionName = JSONHelper.getObjectOrStringChecked(obj, "instructionName") if self.instructionName != None: self.instructionName = StringMatch(self.instructionName) elif self.registerNames == None or len(self.registerNames) == 0: raise RuntimeError("Must provide at least instruction name or register names")
def __init__(self, obj): ''' Private constructor, called by L{Symptom.fromJSONObject}. Do not use directly. ''' Symptom.__init__(self, obj) self.output = StringMatch(JSONHelper.getObjectOrStringChecked(obj, "value", True)) self.src = JSONHelper.getStringChecked(obj, "src") if self.src != None: self.src = self.src.lower() if self.src != "stderr" and self.src != "stdout" and self.src != "crashdata": raise RuntimeError("Invalid source specified: %s" % self.src)
def __init__(self, obj): ''' Private constructor, called by L{Symptom.fromJSONObject}. Do not use directly. ''' Symptom.__init__(self, obj) self.registerNames = JSONHelper.getArrayChecked(obj, "registerNames") self.instructionName = JSONHelper.getObjectOrStringChecked(obj, "instructionName") if self.instructionName != None: self.instructionName = StringMatch(self.instructionName) elif self.registerNames == None or len(self.registerNames) == 0: raise RuntimeError("Must provide at least instruction name or register names")
def __init__(self, obj): ''' Private constructor, called by L{Symptom.fromJSONObject}. Do not use directly. ''' Symptom.__init__(self, obj) self.output = StringMatch(JSONHelper.getObjectOrStringChecked(obj, "value", True))