Пример #1
0
 public static XmlWriter Create(XmlWriter output, XmlWriterSettings settings, bool overrideAsync = false, bool async = false)
 {
     if (ShouldEnableAsync(overrideAsync, async))
     {
         return(XmlWriterAsync.Create(output, settings));
     }
     else
     {
         return(XmlWriter.Create(output, settings));
     }
 }
Пример #2
0
 public static XmlWriter Create(StringBuilder output, bool overrideAsync = false, bool async = false)
 {
     if (ShouldEnableAsync(overrideAsync, async))
     {
         return(XmlWriterAsync.Create(output));
     }
     else
     {
         return(XmlWriter.Create(output));
     }
 }
Пример #3
0
 public static XmlWriter Create(XmlWriter output, XmlWriterSettings settings)
 {
     if (AsyncUtil.IsAsyncEnabled)
     {
         return(XmlWriterAsync.Create(output, settings));
     }
     else
     {
         return(XmlWriter.Create(output, settings));
     }
 }
Пример #4
0
 public static XmlWriter Create(XmlWriter output)
 {
     if (AsyncUtil.IsAsyncEnabled)
     {
         return(XmlWriterAsync.Create(output));
     }
     else
     {
         return(XmlWriter.Create(output));
     }
 }
Пример #5
0
 public static XmlWriter Create(string outputFileName, XmlWriterSettings settings, bool overrideAsync = false, bool async = false)
 {
     FilePathUtil.addStream(outputFileName, new MemoryStream());
     if (ShouldEnableAsync(overrideAsync, async))
     {
         return(XmlWriterAsync.Create(FilePathUtil.getStream(outputFileName), settings));
     }
     else
     {
         return(XmlWriter.Create(FilePathUtil.getStream(outputFileName), settings));
     }
 }
Пример #6
0
 public static XmlWriter Create(string outputFileName, XmlWriterSettings settings)
 {
     FilePathUtil.addStream(outputFileName, new MemoryStream());
     if (AsyncUtil.IsAsyncEnabled)
     {
         return(XmlWriterAsync.Create(FilePathUtil.getStream(outputFileName), settings));
     }
     else
     {
         return(XmlWriter.Create(FilePathUtil.getStream(outputFileName), settings));
     }
 }