コード例 #1
0
        public void     DeleteObject(string sName)
        {
            using (AutoTransaction oTx = new AutoTransaction(m_storage))
            {
                m_storage.DeleteStorage(
                    "",
                    new string[] { AddExtensionIfNeeded(sName) }
                    );

                // Success
                oTx.SetCommit();
            }
        }
コード例 #2
0
        public void     StoreObject(object obj, string name)
        {
            // Begin transaction if needed
            using (AutoTransaction oTx = new AutoTransaction(m_storage))
            {
                // Store object
                m_objectStorage.StoreObject(
                    m_storage,
                    AddExtensionIfNeeded(name),
                    obj);

                // Success
                oTx.SetCommit();
            }
        }