コード例 #1
0
 protected virtual List<RowObject> MergeRows(RowObject rowObject, List<RowObject> list)
 {
     var newRows = new List<RowObject>();
     if (rowObject == null)
         return newRows;
     newRows.Add(rowObject);
     newRows.AddRange(list);
     return newRows;
 }
コード例 #2
0
 public RowObject TransformToRowObject(CustomRowObject customRowObject)
 {
     var rowObject = new RowObject();
     rowObject.ParentRowId = customRowObject.ParentRowId;
     rowObject.RowId = customRowObject.RowId;
     rowObject.RowAction = customRowObject.RowAction == null ? null : customRowObject.RowAction.Value;
     rowObject.Fields = TransformCustomFields(customRowObject.Fields);
     return rowObject;
 }
コード例 #3
0
 public CustomRowObject TransformToCustomRowObject(RowObject rowObject)
 {
     var CustomRowObject = new CustomRowObject();
     CustomRowObject.ParentRowId = rowObject.ParentRowId;
     CustomRowObject.RowAction = ConvertToRowAction(rowObject.RowAction);
     CustomRowObject.RowId = rowObject.RowId;
     CustomRowObject.RowType = GetRowType(rowObject);
     CustomRowObject.Fields = TransformFields(rowObject.Fields);
     return CustomRowObject;
 }
コード例 #4
0
 protected virtual bool IsMultipleIteration(RowObject rowObject)
 {
     if (rowObject.ParentRowId != null && rowObject.ParentRowId.IndexOf(MULTIPLE_ITERATION_ROW_IDENTIFIER) > 0)
         return true;
     return false;
 }
コード例 #5
0
 protected virtual RowType GetRowType(RowObject rowObject)
 {
     return IsMultipleIteration(rowObject) ? RowType.Other : RowType.Current;
 }
コード例 #6
0
 private RowObject MockBasicRowObject()
 {
     var rowObject = new RowObject();
     rowObject.ParentRowId = "1";
     rowObject.RowAction = "EDIT";
     rowObject.RowId = "3";
     return rowObject;
 }
コード例 #7
0
 private void ChangeParentRowId(RowObject rowObject, string ParentRowId)
 {
     rowObject.ParentRowId = ParentRowId;
 }
コード例 #8
0
 private void AddFieldObjects(RowObject rowObject, int NumberOfObjects)
 {
     for (int i = 0; i < NumberOfObjects; i++)
     {
         rowObject.Fields.Add(CreateFieldObject());
     }
 }
コード例 #9
0
 protected virtual CustomRowObject TransformRow(RowObject row)
 {
     return new RowObjectTransform().TransformToCustomRowObject(row);
 }