private void AddSimpleDataTypeDefaultValue(CDataDefaultValuesList newDefValuesList, String baseName, Boolean IsArray, String FieldName, int arraySize) { String additionalInfo = ""; if ((IsArray)) { if (arraySize > 0) { additionalInfo = "[" + arraySize.ToString() + "]"; } else { additionalInfo = "*"; } } CDataDefaultValue defValue = CDataFabric.GetInstance().CreateCDataDefaultValue(); defValue.DefaultValue = ""; defValue.FieldGuid = Guid.Empty; if (baseName.Length > 0) { defValue.Name = baseName + "." + FieldName + additionalInfo; } else { defValue.Name = FieldName + additionalInfo; } newDefValuesList.Add(defValue); }
private void AddComplexDataTypeFieldDefaultValue(CDataDefaultValuesList newDefValuesList, String baseName, ComplexDataTypeField cmplfield) { String additionalInfo = ""; if ((cmplfield.IsPointer)) { additionalInfo = "*"; } CDataDefaultValue defValue = CDataFabric.GetInstance().CreateCDataDefaultValue(); defValue.DefaultValue = ""; defValue.FieldGuid = cmplfield.GUID; if (baseName.Length > 0) { defValue.Name = baseName + "." + cmplfield.Name + additionalInfo; } else { defValue.Name = cmplfield.Name + additionalInfo; } newDefValuesList.Add(defValue); }