Example #1
0
        protected override void AddItem(MemoryMetadataPool metadataPool)
        {
            var orderTable = new MemoryTableMetadata()
            {
                TableName = "Table_Order"
            };

            orderTable.Columns = new List <MemoryColumnMetadata>();
            orderTable.Columns.Add(new MemoryColumnMetadata {
                ColumnName = "OId"
            });
            orderTable.Columns.Add(new MemoryColumnMetadata {
                ColumnName = "CustomerId"
            });
            orderTable.Columns.Add(new MemoryColumnMetadata {
                ColumnName = "Address"
            });

            metadataPool.AddPoolItem(new MetadataPoolItem {
                Item = orderTable, Key = typeof(Order).ToString()
            });
        }
Example #2
0
        protected override void AddItem(MemoryMetadataPool metadataPool)
        {
            var itemTable = new MemoryTableMetadata()
            {
                TableName = "Table_OrderItems"
            };

            itemTable.Columns = new List <MemoryColumnMetadata>();
            itemTable.Columns.Add(new MemoryColumnMetadata()
            {
                ColumnName = "ItemId"
            });
            itemTable.Columns.Add(new MemoryColumnMetadata()
            {
                ColumnName = "Pid"
            });
            itemTable.Columns.Add(new MemoryColumnMetadata()
            {
                ColumnName = "Number"
            });
            metadataPool.AddPoolItem(new MetadataPoolItem {
                Item = itemTable, Key = typeof(Item).ToString()
            });
        }