Example #1
0
 private void BuildDomains(TemplateContainer node)
 {
     foreach (MetaDomain domain in model.Domains)
     {
         TemplateContainer arrnode = node.AddArrayValue(domain.Id.ToString());
         arrnode.AddFromObject(domain);
     }
 }
Example #2
0
 private void BuildTables(TemplateContainer node)
 {
     foreach (MetaTable table in model.Tables)
     {
         TemplateContainer arrnode = node.AddArrayValue(table.Id.ToString());
         arrnode.AddFromObject(table);
         TemplateLink listLink = arrnode.AddListLink("Columns", "/Columns");
         foreach (MetaColumn column in table.Columns)
         {
             listLink.AddListValue(table.Id.ToString() + "!" + column.Ix.ToString());
         }
     }
 }
Example #3
0
 public void BuildColumns(TemplateContainer node)
 {
     foreach (MetaTable table in model.Tables)
     {
         foreach (MetaColumn column in table.Columns)
         {
             TemplateContainer arrnode = node.AddArrayValue(table.Id.ToString() + "!" + column.Ix.ToString());
             arrnode.AddFromObject(column);
             arrnode.AddLink("Table", "Tables[" + column.TableId.ToString() + "]");
             MetaColumn currentcolumn = column;
             while (currentcolumn.TargetColumn != null)
             {
                 currentcolumn = currentcolumn.TargetColumn;
             }
             node.AddLink("Domain", "/Domains[" + currentcolumn.Domain.Id.ToString() + "]");
         }
     }
 }