Free cookie consent management tool by TermsFeed Policy Generator

Ignore:
Timestamp:
04/08/09 17:05:17 (15 years ago)
Author:
epitzer
Message:

Numerous small changes, coding conventions, renames, mini refactoring (#548)

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/sources/HeuristicLab.Persistence/3.3/Core/Serializer.cs

    r1454 r1542  
    33using System;
    44using HeuristicLab.Persistence.Interfaces;
     5using HeuristicLab.Persistence.Interfaces.Tokens;
    56
    67namespace HeuristicLab.Persistence.Core {
     
    4950
    5051    public IEnumerator<ISerializationToken> GetEnumerator() {
    51       DataMemberAccessor rootAccessor = new DataMemberAccessor(
    52         rootName, null, () => obj, null);
    53       IEnumerator<ISerializationToken> iterator = Serialize(rootAccessor);
    54       while (iterator.MoveNext())
    55         yield return iterator.Current;     
     52      return Serialize(new DataMemberAccessor(rootName, null, () => obj, null));
    5653    }
    5754   
     
    7572      IDecomposer decomposer = configuration.GetDecomposer(value.GetType());
    7673      if (decomposer != null)
    77         return CompositeEnumerator(accessor.Name, decomposer.DeCompose(value), id, typeId);                 
     74        return CompositeEnumerator(accessor.Name, decomposer.Decompose(value), id, typeId);                 
    7875      throw new ApplicationException(
    7976          String.Format(
     
    9289    private IEnumerator<ISerializationToken> PrimitiveEnumerator(string name,
    9390        int typeId, object serializedValue, int? id) {
    94       yield return new PrimitiveToken(name, typeId, serializedValue, id);
     91      yield return new PrimitiveToken(name, typeId, id, serializedValue);
    9592    }
    9693
Note: See TracChangeset for help on using the changeset viewer.