def _writeRecordValueConstantCode(self, value, localvars):
    ws = localvars['ws']
    assert isinstance(value, autosar.constant.RecordValue)
    params = []
    for elem in value.elements:
        if isinstance(elem, autosar.constant.ArrayValue):
            initValue = self._writeArrayValueConstantCode(elem, localvars)
        elif isinstance(elem, autosar.constant.IntegerValue):
            initValue = self._writeIntegerValueConstantCode(elem, localvars)
        elif isinstance(elem, autosar.constant.StringValue):
            initValue = self._writeStringValueConstantCode(elem, localvars)
        elif isinstance(elem, autosar.constant.BooleanValue):
            initValue = self._writeBooleanValueConstantCode(elem, localvars)
        elif isinstance(elem, autosar.constant.RecordValue):
            initValue = self._writeRecordValueConstantCode(elem, localvars)
            if isinstance(initValue, list):
                initValue = ('{%s}' % ', '.join(initValue))
        else:
            raise ValueError(('unknown value type: ' + type(constant.value)))
        params.append(('"%s": %s' % (elem.name, initValue)))
    if (len(params) > 0):
        text = ('{%s}' % ', '.join(params))
        if (len(text) > 200):
            return params
        else:
            return text
    return None
def _writeRecordValueConstantCode(self, value, localvars):
    ws = localvars['ws']
    assert isinstance(value, autosar.constant.RecordValue)
    params = []
    for elem in value.elements:
        if isinstance(elem, autosar.constant.ArrayValue):
            initValue = self._writeArrayValueConstantCode(elem, localvars)
        elif isinstance(elem, autosar.constant.IntegerValue):
            initValue = self._writeIntegerValueConstantCode(elem, localvars)
        elif isinstance(elem, autosar.constant.StringValue):
            initValue = self._writeStringValueConstantCode(elem, localvars)
        elif isinstance(elem, autosar.constant.BooleanValue):
            initValue = self._writeBooleanValueConstantCode(elem, localvars)
        elif isinstance(elem, autosar.constant.RecordValue):
            initValue = self._writeRecordValueConstantCode(elem, localvars)
            if isinstance(initValue, list):
                initValue = ('{%s}' % ', '.join(initValue))
        else:
            raise ValueError(('unknown value type: ' + type(constant.value)))
        params.append(('"%s": %s' % (elem.name, initValue)))
    if (len(params) > 0):
        text = ('{%s}' % ', '.join(params))
        if (len(text) > 200):
            return params
        else:
            return text
    return None