src/Misc/EFTools/EntityDesignEntityDesigner/GeneratedCode/SerializationHelper.cs
/// <summary>
/// Checks the version of the file being read.
/// </summary>
/// <param name="serializationContext">Serialization context.</param>
/// <param name="reader">Reader for the file being read. The reader is positioned at the open tag of the root element being read.</param>
Checks the version of the file being read.
Checks the version of the file being read .
protected virtual void CheckVersion(DslModeling::SerializationContext serializationContext, global::System.Xml.XmlReader reader)
		{
			#region Check Parameters
			global::System.Diagnostics.Debug.Assert(serializationContext != null);
			if (serializationContext == null)
				throw new global::System.ArgumentNullException("serializationContext");
			global::System.Diagnostics.Debug.Assert(reader != null);
			if (reader == null)
				throw new global::System.ArgumentNullException("reader");
			#endregion
			global::System.Version expectedVersion = new global::System.Version("1.0.0.0");
			string dslVersionStr = reader.GetAttribute("dslVersion");
			if (dslVersionStr != null)
			{
				try
				{
					global::System.Version actualVersion = new global::System.Version(dslVersionStr);
					if (actualVersion != expectedVersion)
					{
						MicrosoftDataEntityDesignSerializationBehaviorSerializationMessages.VersionMismatch(serializationContext, reader, expectedVersion, actualVersion);
					}
				}
				catch (global::System.ArgumentException)
				{
					MicrosoftDataEntityDesignSerializationBehaviorSerializationMessages.InvalidPropertyValue(serializationContext, reader, "dslVersion", typeof(global::System.Version), dslVersionStr);
				}
				catch (global::System.FormatException)
				{
					MicrosoftDataEntityDesignSerializationBehaviorSerializationMessages.InvalidPropertyValue(serializationContext, reader, "dslVersion", typeof(global::System.Version), dslVersionStr);
				}
				catch (global::System.OverflowException)
				{
					MicrosoftDataEntityDesignSerializationBehaviorSerializationMessages.InvalidPropertyValue(serializationContext, reader, "dslVersion", typeof(global::System.Version), dslVersionStr);
				}
			}
		}
protected virtual void CheckVersion ( DslModeling :: SerializationContext serializationContext , global :: System . Xml . XmlReader reader ) { region  Check Parameters global :: System . Diagnostics . Debug . Assert ( serializationContext != null ) ; if ( serializationContext == null ) throw new global :: System . ArgumentNullException ( " " ) ; global :: System . Diagnostics . Debug . Assert ( reader != null ) ; if ( reader == null ) throw new global :: System . ArgumentNullException ( " " ) ; endregion global :: System . Version expectedVersion = new global :: System . Version ( " " ) ; string dslVersionStr = reader . GetAttribute ( " " ) ; if ( dslVersionStr != null ) { try { global :: System . Version actualVersion = new global :: System . Version ( dslVersionStr ) ; if ( actualVersion != expectedVersion ) { MicrosoftDataEntityDesignSerializationBehaviorSerializationMessages . VersionMismatch ( serializationContext , reader , expectedVersion , actualVersion ) ; } } catch ( global :: System . ArgumentException ) { MicrosoftDataEntityDesignSerializationBehaviorSerializationMessages . InvalidPropertyValue ( serializationContext , reader , " " , typeof ( global :: System . Version ) , dslVersionStr ) ; } catch ( global :: System . FormatException ) { MicrosoftDataEntityDesignSerializationBehaviorSerializationMessages . InvalidPropertyValue ( serializationContext , reader , " " , typeof ( global :: System . Version ) , dslVersionStr ) ; } catch ( global :: System . OverflowException ) { MicrosoftDataEntityDesignSerializationBehaviorSerializationMessages . InvalidPropertyValue ( serializationContext , reader , " " , typeof ( global :: System . Version ) , dslVersionStr ) ; } } }
Checks the version of the file being read.
Checks the version of the file being read .
serializationContext
DslModeling::SerializationContext
None
reader
global::System.Xml.XmlReader
Reader for the file being read. The reader is positioned at the open tag of the root element being read.
Reader for the file being read . The reader is positioned at the open tag of the root element being read .