Free cookie consent management tool by TermsFeed Policy Generator

Ignore:
Timestamp:
04/16/09 12:40:41 (15 years ago)
Author:
epitzer
Message:

Stronger typing for formatters with the help of generics. Separate format and serial data type. (#548)

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/sources/HeuristicLab.Persistence/3.3/Default/Xml/Compact/IntList2XmlFormatter.cs

    r1542 r1564  
    77
    88  [EmptyStorableClass]
    9   public class IntList2XmlFormatter : NumberEnumeration2XmlFormatterBase {
    10 
    11     public override Type Type {
    12       get {
    13         return typeof(List<int>);
    14       }
    15     }
    16 
     9  public class IntList2XmlFormatter : NumberEnumeration2XmlFormatterBase<List<int>> {
     10   
    1711    protected override void Add(IEnumerable enumeration, object o) {
    1812      ((List<int>)enumeration).Add((int)o);
    1913    }
    2014
    21     protected override object Instantiate() {
     15    protected override IEnumerable Instantiate() {
    2216      return new List<int>();
    2317    }
Note: See TracChangeset for help on using the changeset viewer.