ISyncMasterEntity Convert(ISyncSlaveEntity entity) { var rs = Master.Create(); foreach (var item in Names) { rs[item] = entity[item]; } return(rs); }
ISyncSlaveEntity[] Convert(ISyncMasterEntity[] arr) { var rs = new ISyncSlaveEntity[arr.Length]; for (Int32 i = 0; i < arr.Length; i++) { rs[i] = Convert(arr[i]); } return(rs); }
ISyncSlaveEntity[] GetAll(Expression where, Int32 start, Int32 max) { var list = Factory.FindAll(where, null, null, start, max); if (list == null || list.Count < 1) { return(null); } var rs = new ISyncSlaveEntity[list.Count]; for (var i = 0; i < list.Count; i++) { rs[i] = list[i] as ISyncSlaveEntity; } return(rs); }
ISyncSlaveEntity[] GetAll(String where, Int32 start, Int32 max) { var list = Factory.FindAll(where, null, null, start, max); if (list == null || list.Count < 1) return null; var rs = new ISyncSlaveEntity[list.Count]; for (int i = 0; i < list.Count; i++) { rs[i] = list[i] as ISyncSlaveEntity; } return rs; }
ISyncMasterEntity Convert(ISyncSlaveEntity entity) { var rs = Master.Create(); foreach (var item in Names) { rs[item] = entity[item]; } return rs; }
ISyncSlaveEntity[] Convert(ISyncMasterEntity[] arr) { var rs = new ISyncSlaveEntity[arr.Length]; for (int i = 0; i < arr.Length; i++) { rs[i] = Convert(arr[i]); } return rs; }