/// <summary> /// Serialization constructor. /// </summary> /// <param name="info"></param> /// <param name="context"></param> private Ab1Metadata(SerializationInfo info, StreamingContext context) { if (info == null) { throw new ArgumentNullException("info"); } ConfidenceData = Ab1ColorData.FromByteArray((byte[])info.GetValue(Constants.ConfidenceDataKey, typeof(byte[]))); PeakLocations = Ab1ColorData.FromByteArray((byte[])info.GetValue(Constants.PeakLocationDataKey, typeof(byte[]))); AdenineColorData = new Ab1ColorData(PeakLocations, Ab1ColorData.FromByteArray( (byte[])info.GetValue(Constants.AdenineColorDataKey, typeof(byte[])))); CytosineColorData = new Ab1ColorData(PeakLocations, Ab1ColorData.FromByteArray( (byte[])info.GetValue(Constants.CytosineColorDataKey, typeof(byte[])))); ThymineColorData = new Ab1ColorData(PeakLocations, Ab1ColorData.FromByteArray( (byte[])info.GetValue(Constants.ThymineColorDataKey, typeof(byte[])))); GuanineColorData = new Ab1ColorData(PeakLocations, Ab1ColorData.FromByteArray( (byte[])info.GetValue(Constants.GuanineColorDataKey, typeof(byte[])))); }