Exemplo n.º 1
0
        private Workspace(string path, bool exists)
        {
            if (!exists)
            {
                CreateDB(path);
            }
            else
            {
                FileInfo fi = new FileInfo(path);

                if (!fi.Exists)
                {
                    throw new Exception("File not found: " + path);
                }
            }

            this.Path      = path;
            this.Directory = (new FileInfo(path)).DirectoryName;

            db = WorkspaceContext.GetContext(path);
        }