Free cookie consent management tool by TermsFeed Policy Generator

source: tags/3.3.10/HeuristicLab.ExtLibs/HeuristicLab.Netron/3.0.2672.12446/Netron.Diagramming.Core-3.0.2672.12446/Serialization/ClickableLabelMaterial.Serialization.cs

Last change on this file was 4068, checked in by swagner, 14 years ago

Sorted usings and removed unused usings in entire solution (#1094)

File size: 5.0 KB
Line 
1using System;
2using System.Diagnostics;
3using System.Runtime.Serialization;
4using System.Xml.Schema;
5using System.Xml.Serialization;
6namespace Netron.Diagramming.Core {
7  /// <summary>
8  /// Complementary partial class related to (de)serialization.
9  /// </summary>
10  [Serializable]
11  public partial class ClickableLabelMaterial : ISerializable, IXmlSerializable, IDeserializationCallback {
12    #region Deserialization constructor
13    /// <summary>
14    /// Deserialization constructor
15    /// </summary>
16    /// <param name="info">The info.</param>
17    /// <param name="context">The context.</param>
18    protected ClickableLabelMaterial(SerializationInfo info, StreamingContext context)
19      : base(info, context) {
20      if (Tracing.BinaryDeserializationSwitch.Enabled)
21        Trace.WriteLine("Deserializing the fields of 'ClickableLabelMaterial'.");
22
23      double version = info.GetDouble("ClickableLabelMaterialVersion");
24    }
25    #endregion
26
27    #region Serialization events
28    /*
29        [OnSerializing]
30        void OnSerializing(StreamingContext context)
31        {
32            Trace.Indent();
33            Trace.WriteLine("Starting to serializing the 'ClickableLabelMaterial' class...");
34        }
35        [OnSerialized]
36        void OnSerialized(StreamingContext context)
37        {
38            Trace.WriteLine("...serialization of 'ClickableLabelMaterial' finished");
39            Trace.Unindent();
40        }
41        */
42    #endregion
43
44    #region Deserialization events
45    /*
46        [OnDeserializing]     
47        void OnDeserializing(StreamingContext context)
48        {
49            Trace.Indent();
50            Trace.WriteLine("IDeserializationCallback of 'ClickableLabelMaterial' called.");
51        }
52        [OnDeserialized]
53        void OnDeserialized(StreamingContext context)
54         {
55             Trace.WriteLine("...deserialization of 'ClickableLabelMaterial' finished");
56             Trace.Unindent();
57         }
58       */
59    #endregion
60
61    #region Serialization
62    /// <summary>
63    /// Populates a <see cref="T:System.Runtime.Serialization.SerializationInfo"></see> with the data needed to serialize the target object.
64    /// </summary>
65    /// <param name="info">The <see cref="T:System.Runtime.Serialization.SerializationInfo"></see> to populate with data.</param>
66    /// <param name="context">The destination (see <see cref="T:System.Runtime.Serialization.StreamingContext"></see>) for this serialization.</param>
67    /// <exception cref="T:System.Security.SecurityException">The caller does not have the required permission. </exception>
68    public override void GetObjectData(SerializationInfo info, StreamingContext context) {
69      if (Tracing.BinarySerializationSwitch.Enabled)
70        Trace.WriteLine("Serializing the fields of 'ClickableLabelMaterial'.");
71      base.GetObjectData(info, context);
72
73      info.AddValue(
74          "ClickableLabelMaterialVersion",
75          clickableLabelMaterialVersion);
76
77    }
78    #endregion
79
80    #region Xml serialization
81    /// <summary>
82    /// This property is reserved, apply the <see cref="T:System.Xml.Serialization.XmlSchemaProviderAttribute"></see> to the class instead.
83    /// </summary>
84    /// <returns>
85    /// An <see cref="T:System.Xml.Schema.XmlSchema"></see> that describes the XML representation of the object that is produced by the <see cref="M:System.Xml.Serialization.IXmlSerializable.WriteXml(System.Xml.XmlWriter)"></see> method and consumed by the <see cref="M:System.Xml.Serialization.IXmlSerializable.ReadXml(System.Xml.XmlReader)"></see> method.
86    /// </returns>
87    public override XmlSchema GetSchema() {
88      throw new NotImplementedException("The method or operation is not implemented.");
89    }
90
91    /// <summary>
92    /// Generates an object from its XML representation.
93    /// </summary>
94    /// <param name="reader">The <see cref="T:System.Xml.XmlReader"></see> stream from which the object is deserialized.</param>
95    public override void ReadXml(System.Xml.XmlReader reader) {
96      throw new NotImplementedException("The method or operation is not implemented.");
97    }
98
99    /// <summary>
100    /// Converts an object into its XML representation.
101    /// </summary>
102    /// <param name="writer">The <see cref="T:System.Xml.XmlWriter"></see> stream to which the object is serialized.</param>
103    public override void WriteXml(System.Xml.XmlWriter writer) {
104      throw new NotImplementedException("The method or operation is not implemented.");
105    }
106    #endregion
107
108
109
110    /// <summary>
111    /// Runs when the entire object graph has been deserialized.
112    /// </summary>
113    /// <param name="sender">The object that initiated the callback. The functionality for this parameter is not currently implemented.</param>
114    public override void OnDeserialization(object sender) {
115      base.OnDeserialization(sender);
116      if (Tracing.BinaryDeserializationSwitch.Enabled)
117        Trace.WriteLine("IDeserializationCallback of 'ClickableLabelMaterial' called.");
118
119
120    }
121  }
122}
Note: See TracBrowser for help on using the repository browser.