View Issue Details

IDProjectCategoryView StatusLast Update
0000761Ecere SDKedapublic2016-04-19 05:29
Reporterredj Assigned To 
PriorityimmediateSeveritymajorReproducibilityN/A
Status newResolutionopen 
Product Version0.44 Ryoan-ji 
Target Version0.46 eC II 
Summary0000761: eda: too much code is required for type-specific string functionality
DescriptionI think EDA is missing the following APIs
Field::GetString
Field::SetString
Row::GetString
Row::SetString

Steps To Reproduceif the type of the field being set or get is string then Get/SetData should simply be called.
if not, then the OnGetString and OnGetDataFromString should be invoked on the type's data

just like OnGetString is called in the code featured in additional information
Additional Information                  int64 data = 0;
                  Class type = nameField->type;
                  if(type.type == unitClass && !type.typeSize)
                  {
                     Class dataType = eSystem_FindClass(type.module, type.dataTypeString);
                     if(dataType)
                        type = dataType;
                  }
                  if(type.type == structClass)
                     data = (int64)new0 byte[type.structSize];
                  ((bool (*)())(void *)r.GetData)(r, *nameField, type, (type.type == structClass) ? (void *)data : &data);

                  if(type.type == systemClass || type.type == unitClass || type.type == bitClass || type.type == enumClass)
                     name = (String)type._vTbl[__ecereVMethodID_class_OnGetString](type, (void *)&data, tempString, null, null);
                  else
                     name = (String)type._vTbl[__ecereVMethodID_class_OnGetString](type, (void *)data, tempString, null, null);

                  strcpy(tempString, name ? name : "");
                  if(!(type.type == systemClass || type.type == unitClass || type.type == bitClass || type.type == enumClass))
                     type._vTbl[__ecereVMethodID_class_OnFree](type, data);
TagsNo tags attached.

Activities

There are no notes attached to this issue.

Issue History

Date Modified Username Field Change
2012-08-12 00:40 redj New Issue
2012-08-12 00:40 redj Status new => assigned
2012-08-12 00:40 redj Assigned To => jerome
2013-04-24 20:21 jerome Assigned To jerome =>
2013-04-27 06:08 redj Status assigned => new
2016-04-19 05:29 jerome Target Version 0.44.12 Fixes => 0.46 eC II