init
This commit is contained in:
@@ -0,0 +1,59 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
using System.Threading.Tasks;
|
||||
|
||||
namespace DTS.Serialization.FIAT_ASC
|
||||
{
|
||||
///
|
||||
/// <summary>
|
||||
/// Basic representation of a FIAT .asc file.
|
||||
/// </summary>
|
||||
///
|
||||
public partial class File
|
||||
: Serialization.File, IWritable<Test>
|
||||
{
|
||||
|
||||
public bool UseFlatExportFolders { get; set; } = false;
|
||||
///
|
||||
/// <summary>
|
||||
/// Initialize an instance of the FIAT_ASC.File class.
|
||||
/// </summary>
|
||||
///
|
||||
public File()
|
||||
: base("ASC")
|
||||
{
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Get this file format's extension.
|
||||
/// </summary>
|
||||
public static string Extension => ".asc";
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// Get the file writer for this file type.
|
||||
/// </summary>
|
||||
public IWriter<Test> Exporter
|
||||
{
|
||||
get
|
||||
{
|
||||
try
|
||||
{
|
||||
if (_Exporter == null)
|
||||
{
|
||||
_Exporter = new Writer(this, DefaultEncoding) { UseFlatExportFolder = UseFlatExportFolders };
|
||||
}
|
||||
return _Exporter;
|
||||
}
|
||||
|
||||
catch (System.Exception ex)
|
||||
{
|
||||
throw new Exception("encountered problem getting exporter", ex);
|
||||
}
|
||||
}
|
||||
}
|
||||
private IWriter<Test> _Exporter = null;
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user