Changeset 2669 for trunk/sources/HeuristicLab.Data/3.3/StringData.cs
- Timestamp:
- 01/22/10 03:29:02 (15 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/sources/HeuristicLab.Data/3.3/StringData.cs
r2665 r2669 31 31 [Item("String", "Represents a string.")] 32 32 [Creatable("Test")] 33 public sealed class StringData : ReferenceTypeData<string>, IStringConvertibleData { 34 public StringData() : base() { 35 Value = string.Empty; 33 public sealed class StringData : Item, IStringConvertibleData { 34 [Storable] 35 private string value; 36 public string Value { 37 get { return value; } 38 set { 39 if (value != this.value) { 40 if ((value != null) || (this.value != string.Empty)) { 41 this.value = value != null ? value : string.Empty; 42 OnChanged(); 43 } 44 } 45 } 36 46 } 37 public StringData(string value) 38 : base() { 39 Value = value; 47 48 public StringData() { 49 this.value = string.Empty; 50 } 51 public StringData(string value) { 52 this.value = value != null ? value : string.Empty; 40 53 } 41 54 … … 44 57 cloner.RegisterClonedObject(this, clone); 45 58 return clone; 59 } 60 61 public override string ToString() { 62 return value; 46 63 } 47 64
Note: See TracChangeset
for help on using the changeset viewer.