public EsentSession BeginSession() { var session = EsentSession.Begin(this); Sessions.Add(session); return(session); }
internal static EsentTransaction Begin(EsentSession session) { return(new EsentTransaction { Session = session }.Begin()); }
internal static EsentDatabase Open(EsentSession session, string path) { return(new EsentDatabase { Session = session, FilePath = path }.Open()); }
internal static EsentDatabase Create(EsentSession session, string path, bool overwrite) { var db = new EsentDatabase { Session = session, FilePath = path }; Api.JetCreateDatabase(session.JetId, path, null, out db.JetId, overwrite ? CreateDatabaseGrbit.OverwriteExisting : CreateDatabaseGrbit.None); db.Opened = true; return(db); }