コード例 #1
0
        public static string DataToYaml(DataDictionaryList datatable, SeedYamlFormat format = SeedYamlFormat.Hash, YamlColumnNamesType yamlColumnNames = null)
        {
            var writer = new StringWriter();

            DataToYaml(writer, datatable, format, yamlColumnNames);
            return(writer.ToString());
        }
コード例 #2
0
ファイル: YamlData.cs プロジェクト: enpel/seedtable
        public static string DataToYaml(DataDictionaryList datatable, IEnumerable <string> yamlColumnNames = null)
        {
            var writer = new StringWriter();

            DataToYaml(writer, datatable, yamlColumnNames);
            return(writer.ToString());
        }
コード例 #3
0
 public static void DataToYaml(TextWriter writer, DataDictionaryList datatable, SeedYamlFormat format = SeedYamlFormat.Hash, YamlColumnNamesType yamlColumnNames = null)
 {
     if (format == SeedYamlFormat.Hash)
     {
         DataToYaml(writer, datatable.ToDictionaryDictionary(), yamlColumnNames);
     }
     else
     {
         DataToYaml(writer, datatable.Table, yamlColumnNames);
     }
 }
コード例 #4
0
 public YamlData(
     DataDictionaryList data,
     bool needSubdivide                   = false,
     int preCut                           = 0,
     int postCut                          = 0,
     string subdivideFilename             = null,
     SeedYamlFormat format                = SeedYamlFormat.Hash,
     bool deletePrevious                  = false,
     IEnumerable <string> yamlColumnNames = null
     )
 {
     Data              = data;
     NeedSubdivide     = needSubdivide;
     PreCut            = preCut;
     PostCut           = postCut;
     SubdivideFilename = subdivideFilename;
     Format            = format;
     DeletePrevious    = deletePrevious;
     YamlColumnNames   =
         yamlColumnNames == null ?
         new YamlColumnNamesType() :
         new YamlColumnNamesType(yamlColumnNames.Select(yamlColumnName => new Wildcard(yamlColumnName)));
 }
コード例 #5
0
ファイル: YamlData.cs プロジェクト: enpel/seedtable
 public static void DataToYaml(TextWriter writer, DataDictionaryList datatable, IEnumerable <string> yamlColumnNames = null)
 {
     DataToYaml(writer, datatable.ToDictionaryDictionary(), yamlColumnNames);
 }
コード例 #6
0
ファイル: YamlData.cs プロジェクト: enpel/seedtable
 public YamlData(DataDictionaryList data)
 {
     this.data = data;
 }
コード例 #7
0
 public abstract void DataToExcel(DataDictionaryList data, bool delete = false);