Skip to content

Instantly share code, notes, and snippets.

View Antaris's full-sized avatar
🎯
Focusing

Matthew Abbott Antaris

🎯
Focusing
View GitHub Profile
@divega
divega / MyContext.cs
Last active May 18, 2020 04:35
Simple builder class for creating TVPs that work in .NET Core 1.0
using Microsoft.EntityFrameworkCore;
namespace TvpSampleApp
{
public class MyContext : DbContext
{
public DbSet<Person> People { get; set; }
protected override void OnConfiguring(DbContextOptionsBuilder optionsBuilder)
{
@Antaris
Antaris / DependencyList.cs
Created February 6, 2012 14:17
Sorting dependencies using DependencyList
using System;
using System.Collections;
using System.Collections.Generic;
using System.ComponentModel;
using System.Linq;
/// <summary>
/// Represents a list whose items can be dependant on each other, and enumerating the list will sort the items
/// as per their dependency requirements.
/// </summary>