本文整理汇总了C#中XmlReader.Deserialize方法的典型用法代码示例。如果您正苦于以下问题:C# XmlReader.Deserialize方法的具体用法?C# XmlReader.Deserialize怎么用?C# XmlReader.Deserialize使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类XmlReader
的用法示例。
在下文中一共展示了XmlReader.Deserialize方法的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。
示例1: ArgumentNullException
void IXmlSerializable.ReadXml(XmlReader reader)
{
if (null == reader)
{
throw new ArgumentNullException("reader");
}
if (reader.IsEmptyElement)
{
reader.Read();
return;
}
var name = reader.Name;
while (reader.Read())
{
#if NET20
if (XmlReaderExtensionMethods.IsEndElement(reader, name))
#else
if (reader.IsEndElement(name))
#endif
{
reader.Read();
break;
}
while (XmlNodeType.Element == reader.NodeType)
{
switch (reader.Name)
{
case "directories":
#if NET20
Directories = XmlReaderExtensionMethods.Deserialize<DirectoryCollection>(reader);
#else
Directories = reader.Deserialize<DirectoryCollection>();
#endif
break;
case "files":
#if NET20
Files = XmlReaderExtensionMethods.Deserialize<FileCollection>(reader);
#else
Files = reader.Deserialize<FileCollection>();
#endif
break;
}
}
}
}
示例2: Start
void Start()
{
fileLoader = new FileLoader();
xmlReader = new XmlReader();
dialogue = new DialogueReader();
textSpoken.text = "";
string data = fileLoader.Load("TestDialogue.xml");
Dialogue d = xmlReader.Deserialize<Dialogue>(data) as Dialogue;
dialogue.SetDialogue(d);
}
示例3: Deserialize
public static MProphetPeakScoringModel Deserialize(XmlReader reader)
{
return reader.Deserialize(new MProphetPeakScoringModel());
}
示例4: Deserialize
public static Enzyme Deserialize(XmlReader reader)
{
return reader.Deserialize(new Enzyme());
}
示例5: Deserialize
public static IsotopeEnrichments Deserialize(XmlReader reader)
{
return reader.Deserialize(new IsotopeEnrichments());
}
示例6: Deserialize
public static IsolationScheme Deserialize(XmlReader reader)
{
return reader.Deserialize(new IsolationScheme());
}
示例7: Deserialize
public static StaticMod Deserialize(XmlReader reader)
{
return reader.Deserialize(new StaticMod());
}
示例8: Deserialize
public static BiblioSpecSpectrumHeaderInfo Deserialize(XmlReader reader)
{
return reader.Deserialize(new BiblioSpecSpectrumHeaderInfo());
}
示例9: Deserialize
public static PeptideFilter Deserialize(XmlReader reader)
{
return reader.Deserialize(new PeptideFilter());
}
示例10: Deserialize
public static FragmentLoss Deserialize(XmlReader reader)
{
return reader.Deserialize(new FragmentLoss());
}
示例11: Deserialize
public static BackgroundProteomeSpec Deserialize(XmlReader reader)
{
return reader.Deserialize(new BackgroundProteomeSpec());
}
示例12: Deserialize
// ReSharper restore MemberHidesStaticFromOuterClass
// ReSharper disable MemberHidesStaticFromOuterClass
public static FeatureCalculator Deserialize(XmlReader reader)
{
return reader.Deserialize(new FeatureCalculator());
}
示例13: Deserialize
public static IonMobilityLibrary Deserialize(XmlReader reader)
{
return reader.Deserialize(new IonMobilityLibrary());
}
示例14: Deserialize
public static MeasuredIon Deserialize(XmlReader reader)
{
return reader.Deserialize(new MeasuredIon());
}
示例15: Deserialize
public static OptimizationLibrary Deserialize(XmlReader reader)
{
return reader.Deserialize(new OptimizationLibrary());
}