예제 #1
0
파일: NouchDB.cs 프로젝트: Kirosoft/NouchDB
        public string AllDocs()
        {
            string result = "";

            LevelDB.Iterator sequenceList = sequenceStore.NewIterator(ReadOptions.Default);

            while (sequenceList.Valid())
            {
                result += sequenceList.Value();
            }

            // We have to close the iterator
            sequenceList = null;

            return(result);
        }
예제 #2
0
        public void IsValid()
        {
            Database.Put(null, "key1", "value1");

            var iter = new Iterator(Database, null);
            iter.SeekToLast();
            Assert.IsTrue(iter.IsValid);

            iter.Next();
            Assert.IsFalse(iter.IsValid);
        }