internal SqliteCatalogStoreItem(SqliteCatalogStore store, long itemId) { _store = store; _id = itemId; _loaded = false; _persisting = false; _uri = null; _title = null; _type = null; _tags = new StringCollection(); _parent = null; _aliasOf = null; _aliases = new SqliteCatalogStoreItemCollection(); _children = new SqliteCatalogStoreItemCollection(); }
public ItemPersistor(SqliteCatalogStore store, SQLiteConnection conn) { _store = store; _conn = conn; _wordIdHash = new Hashtable(); }
public void RemoveStore() { String storePath = _store.Uri; _store.Dispose(); _store = null; _store2.Dispose(); _store2 = null; File.Delete(storePath); }
public void CreateStore() { SqliteCatalogStoreManager mgr = new SqliteCatalogStoreManager(); _store = mgr.CreateCatalogStore(Path.GetTempFileName(), true); _store2 = mgr.OpenCatalogStore(_store.Uri); }
public SqliteCatalogStore OpenCatalogStore(String catalogPath) { //Make sure the catalog exists if (!File.Exists(catalogPath)) { throw new FileNotFoundException("Catalog file not found", catalogPath); } //Connect to the catalog SQLiteConnection conn = SqliteCatalogStoreManager.OpenConnection(catalogPath, false); SqliteCatalogStore store = new SqliteCatalogStore(this, conn, catalogPath); return store; }
internal SqliteCatalogStoreItem(SqliteCatalogStore store) : this(store, NULL_ID) { }