public static void CreateContext() { if (context == null) { lock (_lockSync) { if (context == null) { context = new databaseContext(); } } } }
public repository() { db = repositoryBase.context; _objectSet = db.Set <T>(); }