- Timestamp:
- 04/08/09 17:05:17 (15 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/sources/HeuristicLab.Persistence/3.3/Core/DeSerializer.cs
r1494 r1542 2 2 using System; 3 3 using HeuristicLab.Persistence.Interfaces; 4 using HeuristicLab.Persistence.Interfaces.Tokens; 4 5 5 6 namespace HeuristicLab.Persistence.Core { 6 7 7 public structParentReference {}8 public class ParentReference {} 8 9 9 10 class CompositeObject { … … 18 19 19 20 public void AddValue(string name, object value, List<Thunk> finalFixes) { 20 Tag t = new Tag(name, value) { finalFixes = finalFixes};21 Tag t = new Tag(name, value) {globalFinalFixes = finalFixes}; 21 22 customValues.Add(t); 22 23 } … … 30 31 public delegate void Thunk(); 31 32 32 public class De Serializer {33 public class Deserializer { 33 34 34 35 private readonly Dictionary<int, object> id2obj; … … 38 39 private List<Thunk> finalFixes; 39 40 40 public De Serializer(41 public Deserializer( 41 42 IEnumerable<TypeMapping> typeCache) { 42 43 id2obj = new Dictionary<int, object>(); 43 44 parentStack = new Stack<CompositeObject>(); 44 45 typeIds = new Dictionary<int, Type>(); 45 serializerMapping = createSerializers(typeCache);46 serializerMapping = CreateSerializers(typeCache); 46 47 } 47 48 48 private Dictionary<Type, object> createSerializers(IEnumerable<TypeMapping> typeCache) {49 private Dictionary<Type, object> CreateSerializers(IEnumerable<TypeMapping> typeCache) { 49 50 var map = new Dictionary<Type, object>(); 50 51 foreach (var typeMapping in typeCache) { … … 59 60 } 60 61 61 public object De Serialize(IEnumerable<ISerializationToken> tokens) {62 public object Deserialize(IEnumerable<ISerializationToken> tokens) { 62 63 finalFixes = new List<Thunk>(); 63 64 foreach (ISerializationToken token in tokens) {
Note: See TracChangeset
for help on using the changeset viewer.