- Timestamp:
- 03/07/16 10:18:05 (9 years ago)
- Location:
- branches/WebJobManager
- Files:
-
- 1 edited
- 1 copied
Legend:
- Unmodified
- Added
- Removed
-
branches/WebJobManager/HeuristicLab.Analysis/3.3/DataVisualization/DataTable.cs
r12012 r13656 38 38 [StorableClass] 39 39 public class DataTable : NamedItem, IStringConvertibleMatrix { 40 public static new Image StaticItemImage { 41 get { return HeuristicLab.Common.Resources.VSImageLibrary.Performance; } 40 public static new Image StaticItemImage 41 { 42 get { return new Bitmap(25, 25); } 42 43 } 43 44 44 45 private DataTableVisualProperties visualProperties; 45 public DataTableVisualProperties VisualProperties { 46 public DataTableVisualProperties VisualProperties 47 { 46 48 get { return visualProperties; } 47 set { 49 set 50 { 48 51 if (visualProperties != value) { 49 52 if (value == null) throw new ArgumentNullException("VisualProperties"); … … 57 60 58 61 private NamedItemCollection<DataRow> rows; 59 public NamedItemCollection<DataRow> Rows { 62 public NamedItemCollection<DataRow> Rows 63 { 60 64 get { return rows; } 61 private set { 65 private set 66 { 62 67 if (rows != null) throw new InvalidOperationException("Rows already set"); 63 68 rows = value; … … 68 73 #region Persistence Properties 69 74 [Storable(Name = "VisualProperties")] 70 private DataTableVisualProperties StorableVisualProperties { 75 private DataTableVisualProperties StorableVisualProperties 76 { 71 77 get { return visualProperties; } 72 set { 78 set 79 { 73 80 visualProperties = value; 74 81 visualProperties.PropertyChanged += new PropertyChangedEventHandler(VisualProperties_PropertyChanged); … … 76 83 } 77 84 [Storable(Name = "rows")] 78 private IEnumerable<DataRow> StorableRows { 85 private IEnumerable<DataRow> StorableRows 86 { 79 87 get { return rows; } 80 88 set { Rows = new NamedItemCollection<DataRow>(value); } … … 206 214 #region IStringConvertibleMatrix Members 207 215 208 int IStringConvertibleMatrix.Rows { 216 int IStringConvertibleMatrix.Rows 217 { 209 218 get { return rows.Count == 0 ? 0 : rows.Max(r => r.Values.Count); } 210 219 set { throw new NotSupportedException(); } 211 220 } 212 int IStringConvertibleMatrix.Columns { 221 int IStringConvertibleMatrix.Columns 222 { 213 223 get { return rows.Count; } 214 224 set { throw new NotSupportedException(); } 215 225 } 216 IEnumerable<string> IStringConvertibleMatrix.ColumnNames { 226 IEnumerable<string> IStringConvertibleMatrix.ColumnNames 227 { 217 228 get { return rows.Select(r => r.Name); } 218 229 set { throw new NotSupportedException(); } 219 230 } 220 IEnumerable<string> IStringConvertibleMatrix.RowNames { 231 IEnumerable<string> IStringConvertibleMatrix.RowNames 232 { 221 233 get { return Enumerable.Empty<string>(); } 222 234 set { throw new NotSupportedException(); } 223 235 } 224 236 225 bool IStringConvertibleMatrix.SortableView { 237 bool IStringConvertibleMatrix.SortableView 238 { 226 239 get { return true; } 227 240 set { throw new NotSupportedException(); } 228 241 } 229 bool IStringConvertibleMatrix.ReadOnly { 242 bool IStringConvertibleMatrix.ReadOnly 243 { 230 244 get { return true; } 231 245 }
Note: See TracChangeset
for help on using the changeset viewer.