Lines Matching refs:trans
239 syncable::ReadTransaction trans(FROM_HERE, directory());
241 directory()->GetChildHandlesById(&trans, trans.root_id(), &children);
257 void WriteTestDataToEntry(WriteTransaction* trans, MutableEntry* entry) {
266 void VerifyTestDataInEntry(BaseTransaction* trans, Entry* entry) {
340 WriteTransaction trans(FROM_HERE, UNITTEST, directory());
350 MutableEntry entry(&trans, CREATE, BOOKMARKS, test->parent_id, name);
382 entry.PutServerParentId(trans.root_id());
464 Cryptographer* GetCryptographer(syncable::BaseTransaction* trans) {
465 return directory()->GetCryptographer(trans);
521 syncable::ReadTransaction trans(FROM_HERE, directory());
522 GetUnsyncedEntries(&trans, &handles);
1562 WriteTransaction trans(FROM_HERE, UNITTEST, directory());
1563 Entry entry(&trans, GET_BY_ID,
1630 WriteTransaction trans(FROM_HERE, UNITTEST, directory());
1632 Entry name_clash(&trans, GET_BY_ID, ids_.FromNumber(2));
1637 Entry bad_parent(&trans, GET_BY_ID, ids_.FromNumber(3));
1642 Entry bad_parent_child(&trans, GET_BY_ID, ids_.FromNumber(9));
1647 Entry bad_parent_child2(&trans, GET_BY_ID, ids_.FromNumber(100));
1671 syncable::ReadTransaction trans(FROM_HERE, directory());
1673 Entry still_a_dir(&trans, GET_BY_ID, ids_.FromNumber(10));
1680 Entry rename(&trans, GET_BY_ID, ids_.FromNumber(1));
1688 Entry name_clash(&trans, GET_BY_ID, ids_.FromNumber(2));
1695 Entry ignored_old_version(&trans, GET_BY_ID, ids_.FromNumber(4));
1702 Entry circular_parent_issue(&trans, GET_BY_ID, ids_.FromNumber(5));
1711 Entry circular_parent_target(&trans, GET_BY_ID, ids_.FromNumber(6));
1730 WriteTransaction trans(FROM_HERE, UNITTEST, directory());
1732 &trans, CREATE, BOOKMARKS, trans.root_id(), "new_folder");
1744 syncable::ReadTransaction trans(FROM_HERE, directory());
1745 Entry entry(&trans, GET_BY_HANDLE, metahandle_folder);
1753 WriteTransaction trans(FROM_HERE, UNITTEST, directory());
1754 MutableEntry entry(&trans, CREATE, BOOKMARKS, folder_id, "new_entry");
1757 WriteTestDataToEntry(&trans, &entry);
1763 syncable::ReadTransaction trans(FROM_HERE, directory());
1764 Entry entry(&trans, syncable::GET_BY_HANDLE, metahandle_entry);
1770 VerifyTestDataInEntry(&trans, &entry);
1792 syncable::ReadTransaction trans(FROM_HERE, directory());
1793 Entry folder(&trans, GET_BY_HANDLE, metahandle_folder);
1799 EXPECT_EQ(trans.root_id(), folder.GetParentId());
1802 Entry old_dead_folder(&trans, GET_BY_ID, folder_id);
1806 Entry entry(&trans, syncable::GET_BY_HANDLE, metahandle_entry);
1811 VerifyTestDataInEntry(&trans, &entry);
1821 WriteTransaction trans(FROM_HERE, UNITTEST, directory());
1822 MutableEntry entry(&trans, CREATE, BOOKMARKS, trans.root_id(), "new_entry");
1825 WriteTestDataToEntry(&trans, &entry);
1831 syncable::ReadTransaction trans(FROM_HERE, directory());
1833 Entry entry(&trans, GET_BY_HANDLE, entry_metahandle);
1837 VerifyTestDataInEntry(&trans, &entry);
1856 syncable::ReadTransaction trans(FROM_HERE, directory());
1857 Entry entry(&trans, GET_BY_HANDLE, entry_metahandle);
1874 WriteTransaction trans(FROM_HERE, UNITTEST, directory());
1875 MutableEntry entry(&trans, CREATE, BOOKMARKS, trans.root_id(), "new_entry");
1878 WriteTestDataToEntry(&trans, &entry);
1883 syncable::ReadTransaction trans(FROM_HERE, directory());
1884 Entry entry(&trans, GET_BY_HANDLE, entry_metahandle);
1888 VerifyTestDataInEntry(&trans, &entry);
1906 WriteTransaction trans(FROM_HERE, UNITTEST, directory());
1908 &trans, trans.root_id(), "new_entry");
1909 MutableEntry entry(&trans, GET_BY_ID, new_entry_id);
1917 syncable::ReadTransaction trans(FROM_HERE, directory());
1919 &trans, trans.root_id(), "new_entry");
1920 Entry entry(&trans, GET_BY_ID, new_entry_id);
1924 Entry old_entry(&trans, GET_BY_ID, entry_id);
1957 syncable::ReadTransaction trans(FROM_HERE, directory());
1959 Entry A(&trans, GET_BY_ID, ids_.FromNumber(1));
1965 Entry B(&trans, GET_BY_ID, ids_.FromNumber(2));
1999 syncable::ReadTransaction trans(FROM_HERE, directory());
2001 Entry A(&trans, GET_BY_ID, ids_.FromNumber(1));
2007 Entry B(&trans, GET_BY_ID, ids_.FromNumber(2));
2027 syncable::ReadTransaction trans(FROM_HERE, directory());
2030 &trans, ids_.FromNumber(4), "gggchild");
2031 Entry child(&trans, GET_BY_ID, child_id);
2038 WriteTransaction trans(FROM_HERE, UNITTEST, directory());
2039 MutableEntry bob(&trans,
2041 GetOnlyEntryWithName(&trans,
2047 &trans, CREATE, BOOKMARKS, bob.GetId(), "bob");
2057 WriteTransaction trans(FROM_HERE, UNITTEST, directory());
2058 MutableEntry entry(&trans, CREATE, BOOKMARKS, trans.root_id(), "bob");
2072 syncable::ReadTransaction trans(FROM_HERE, directory());
2073 Entry parent_entry(&trans, syncable::GET_BY_ID,
2074 GetOnlyEntryWithName(&trans, TestIdFactory::root(), "bob"));
2078 GetOnlyEntryWithName(&trans, parent_entry.GetId(), "bob");
2079 Entry child(&trans, syncable::GET_BY_ID, child_id);
2097 WriteTransaction trans(FROM_HERE, UNITTEST, directory());
2098 MutableEntry fred_match(&trans, CREATE, BOOKMARKS, trans.root_id(),
2103 WriteTestDataToEntry(&trans, &fred_match);
2112 WriteTransaction trans(FROM_HERE, UNITTEST, directory());
2113 MutableEntry fred_match(&trans, GET_BY_HANDLE, metahandle_fred);
2117 mock_server_->AddUpdateBookmark(fred_match_id, trans.root_id(),
2155 syncable::ReadTransaction trans(FROM_HERE, directory());
2156 directory()->GetChildHandlesById(&trans, parent_id_, &children);
2158 Entry child(&trans, syncable::GET_BY_ID, child_id_);
2194 syncable::ReadTransaction trans(FROM_HERE, directory());
2195 Entry entry(&trans, syncable::GET_BY_HANDLE, entry_metahandle);
2210 syncable::ReadTransaction trans(FROM_HERE, directory());
2211 Entry entry(&trans, syncable::GET_BY_ID, id);
2255 syncable::ReadTransaction trans(FROM_HERE, directory());
2257 directory()->GetChildHandlesById(&trans, root_id_, &children);
2259 directory()->GetChildHandlesById(&trans, parent_id, &children);
2262 directory()->GetUnappliedUpdateMetaHandles(&trans, all_types, &unapplied);
2265 directory()->GetUnsyncedMetaHandles(&trans, &unsynced);
2273 WriteTransaction trans(FROM_HERE, UNITTEST, directory());
2274 MutableEntry entry(&trans, CREATE, BOOKMARKS, trans.root_id(), "bob");
2294 WriteTransaction trans(FROM_HERE, UNITTEST, directory());
2295 MutableEntry entry(&trans, CREATE, BOOKMARKS, trans.root_id(), "bob");
2325 WriteTransaction trans(FROM_HERE, UNITTEST, directory());
2326 MutableEntry entry(&trans, CREATE, BOOKMARKS, trans.root_id(), "existing");
2335 WriteTransaction trans(FROM_HERE, UNITTEST, directory());
2336 MutableEntry newfolder(&trans, CREATE, BOOKMARKS, trans.root_id(), "new");
2342 MutableEntry existing(&trans, GET_BY_HANDLE, existing_metahandle);
2362 WriteTransaction trans(FROM_HERE, UNITTEST, directory());
2364 &trans, CREATE, BOOKMARKS, ids_.FromNumber(1), "local");
2376 syncable::ReadTransaction trans(FROM_HERE, directory());
2377 Entry entry(&trans, syncable::GET_BY_HANDLE, newfolder_metahandle);
2394 syncable::ReadTransaction trans(FROM_HERE, directory());
2395 Entry id1(&trans, GET_BY_ID, ids_.FromNumber(7801));
2399 Entry id2(&trans, GET_BY_ID, ids_.FromNumber(1024));
2416 syncable::ReadTransaction trans(FROM_HERE, directory());
2417 Entry id1(&trans, GET_BY_ID, ids_.FromNumber(7801));
2421 Entry id2(&trans, GET_BY_ID, ids_.FromNumber(1024));
2425 Entry id3(&trans, GET_BY_ID, ids_.FromNumber(4096));
2438 syncable::ReadTransaction trans(FROM_HERE, directory());
2439 Entry id1(&trans, GET_BY_ID, ids_.FromNumber(7801));
2443 Entry id2(&trans, GET_BY_ID, ids_.FromNumber(1024));
2447 Entry id3(&trans, GET_BY_ID, ids_.FromNumber(4096));
2462 WriteTransaction trans(FROM_HERE, UNITTEST, directory());
2466 MutableEntry e(&trans, CREATE, BOOKMARKS, trans.root_id(), name);
2485 WriteTransaction trans(FROM_HERE, UNITTEST, directory());
2489 MutableEntry e(&trans, CREATE, BOOKMARKS, trans.root_id(), name);
2515 WriteTransaction trans(FROM_HERE, UNITTEST, directory());
2519 MutableEntry e(&trans, CREATE, BOOKMARKS, trans.root_id(), name);
2672 WriteTransaction trans(FROM_HERE, UNITTEST, directory());
2687 syncable::ReadTransaction trans(FROM_HERE, directory());
2689 Entry e(&trans, GET_BY_ID, tree_ids[i]);
2704 syncable::ReadTransaction trans(FROM_HERE, directory());
2706 Entry e(&trans, GET_BY_ID, tree_ids[i]);
2719 WriteTransaction trans(FROM_HERE, UNITTEST, directory());
2720 MutableEntry e(&trans, GET_BY_ID, ids_.FromNumber(1));
2944 WriteTransaction trans(FROM_HERE, UNITTEST, directory());
2945 MutableEntry B(&trans, GET_BY_ID, ids_.FromNumber(2));
2947 WriteTestDataToEntry(&trans, &B);
2955 syncable::ReadTransaction trans(FROM_HERE, directory());
2956 Entry B(&trans, GET_BY_ID, ids_.FromNumber(2));
2974 WriteTransaction trans(FROM_HERE, UNITTEST, directory());
2975 MutableEntry bob(&trans, GET_BY_ID, ids_.FromNumber(1));
2978 WriteTestDataToEntry(&trans, &bob);
2987 syncable::ReadTransaction trans(FROM_HERE, directory());
2988 Entry bob(&trans, GET_BY_HANDLE, bob_metahandle);
3004 WriteTransaction trans(FROM_HERE, UNITTEST, directory());
3005 MutableEntry folder(&trans, CREATE, BOOKMARKS, trans.root_id(), "bob");
3010 MutableEntry folder2(&trans, CREATE, BOOKMARKS, trans.root_id(), "fred");
3033 WriteTransaction trans(FROM_HERE, UNITTEST, directory());
3034 MutableEntry bob(&trans, GET_BY_ID, ids_.FromNumber(1));
3050 WriteTransaction trans(FROM_HERE, UNITTEST, directory());
3053 &trans, CREATE, BOOKMARKS, trans.root_id(), "name");
3072 syncable::ReadTransaction trans(FROM_HERE, directory());
3073 Entry local_deleted(&trans, GET_BY_ID, ids_.FromNumber(1));
3087 WriteTransaction trans(FROM_HERE, UNITTEST, directory());
3090 &trans, CREATE, BOOKMARKS, trans.root_id(), "name");
3111 syncable::ReadTransaction trans(FROM_HERE, directory());
3112 Entry local_deleted(&trans, GET_BY_ID, ids_.FromNumber(1));
3130 WriteTransaction trans(FROM_HERE, UNITTEST, directory());
3132 &trans, CREATE, BOOKMARKS, trans.root_id(), "Copy of base");
3133 WriteTestDataToEntry(&trans, &entry);
3169 syncable::ReadTransaction trans(FROM_HERE, directory());
3170 Entry child(&trans, GET_BY_ID, stuck_entry_id);
3186 syncable::ReadTransaction trans(FROM_HERE, directory());
3187 Entry entry(&trans, GET_BY_ID, folder_id);
3189 Entry child(&trans, GET_BY_ID, stuck_entry_id);
3204 WriteTransaction trans(FROM_HERE, UNITTEST, directory());
3205 MutableEntry entry(&trans, GET_BY_ID, ids_.FromNumber(2));
3214 syncable::ReadTransaction trans(FROM_HERE, directory());
3215 Entry entry1(&trans, GET_BY_ID, ids_.FromNumber(1));
3219 Entry entry2(&trans, GET_BY_ID, ids_.FromNumber(2));
3241 syncable::ReadTransaction trans(FROM_HERE, directory());
3242 Entry entry(&trans, GET_BY_ID, ids_.FromNumber(2));
3257 syncable::ReadTransaction trans(FROM_HERE, directory());
3258 Entry entry(&trans, GET_BY_ID, ids_.FromNumber(2));
3274 WriteTransaction trans(FROM_HERE, UNITTEST, directory());
3275 MutableEntry entry(&trans, GET_BY_ID, ids_.FromNumber(2));
3318 syncable::ReadTransaction trans(FROM_HERE, directory());
3319 Entry in_root(&trans, GET_BY_ID, in_root_id);
3324 Entry in_in_root(&trans, GET_BY_ID, in_in_root_id);
3356 syncable::ReadTransaction trans(FROM_HERE, directory());
3357 Entry fail_by_old_id_entry(&trans, GET_BY_ID, in_root_id);
3360 Entry foo_entry(&trans, GET_BY_HANDLE, foo_metahandle);
3365 Entry bar_entry(&trans, GET_BY_HANDLE, bar_metahandle);
3462 WriteTransaction trans(FROM_HERE, UNITTEST, directory());
3463 MutableEntry entry(&trans, GET_BY_ID, folder_one_id);
3469 &trans, CREATE, BOOKMARKS, trans.root_id(), "new_folder");
3524 syncable::ReadTransaction trans(FROM_HERE, directory());
3525 Entry entry(&trans, GET_BY_ID, id);
3540 syncable::ReadTransaction trans(FROM_HERE, directory());
3541 Entry entry(&trans, GET_BY_ID, id);
3554 syncable::ReadTransaction trans(FROM_HERE, directory());
3555 Entry entry(&trans, GET_BY_ID, id);
3585 syncable::ReadTransaction trans(FROM_HERE, directory());
3586 Entry entry(&trans, GET_BY_ID, id);
3601 syncable::ReadTransaction trans(FROM_HERE, directory());
3602 Entry entry(&trans, GET_BY_ID, id);
3634 syncable::ReadTransaction trans(FROM_HERE, directory());
3635 Entry perm_folder(&trans, GET_BY_CLIENT_TAG, "permfolder");
3650 syncable::ReadTransaction trans(FROM_HERE, directory());
3652 Entry perm_folder(&trans, GET_BY_CLIENT_TAG, "permfolder");
3670 syncable::ReadTransaction trans(FROM_HERE, directory());
3671 Entry perm_folder(&trans, GET_BY_CLIENT_TAG, "permfolder");
3686 syncable::ReadTransaction trans(FROM_HERE, directory());
3691 Entry rejected_update(&trans, GET_BY_CLIENT_TAG, "wrongtag");
3694 Entry perm_folder(&trans, GET_BY_CLIENT_TAG, "permfolder");
3706 WriteTransaction trans(FROM_HERE, UNITTEST, directory());
3708 &trans, CREATE, PREFERENCES, ids_.root(), "name");
3726 syncable::ReadTransaction trans(FROM_HERE, directory());
3728 Entry pref(&trans, GET_BY_CLIENT_TAG, "tag");
3746 syncable::ReadTransaction trans(FROM_HERE, directory());
3748 Entry pref(&trans, GET_BY_CLIENT_TAG, "tag");
3765 WriteTransaction trans(FROM_HERE, UNITTEST, directory());
3767 &trans, CREATE, PREFERENCES, ids_.root(), "name");
3788 syncable::ReadTransaction trans(FROM_HERE, directory());
3790 Entry pref(&trans, GET_BY_CLIENT_TAG, "tag");
3822 syncable::ReadTransaction trans(FROM_HERE, directory());
3824 Entry tag1(&trans, GET_BY_CLIENT_TAG, "tag1");
3835 Entry tag2(&trans, GET_BY_CLIENT_TAG, "tag2");
3847 trans, trans.root_id(), &children);
3860 syncable::ReadTransaction trans(FROM_HERE, directory());
3862 Entry tag1(&trans, GET_BY_CLIENT_TAG, "tag1");
3874 Entry tag2(&trans, GET_BY_CLIENT_TAG, "tag2");
3887 directory()->GetChildHandlesById(&trans, trans.root_id(), &children);
3933 syncable::ReadTransaction trans(FROM_HERE, directory());
3935 Entry tag_a(&trans, GET_BY_CLIENT_TAG, "tag a");
3945 Entry tag_b(&trans, GET_BY_CLIENT_TAG, "tag b");
3955 Entry tag_c(&trans, GET_BY_CLIENT_TAG, "tag c");
3966 directory()->GetChildHandlesById(&trans, trans.root_id(), &children);
3976 syncable::ReadTransaction trans(FROM_HERE, directory());
3977 Entry hurdle(&trans, GET_BY_HANDLE, hurdle_handle);
3984 Entry tag_alpha(&trans, GET_BY_SERVER_TAG, "alpha");
3986 Entry tag_bob(&trans, GET_BY_SERVER_TAG, "bob");
4000 syncable::ReadTransaction trans(FROM_HERE, directory());
4004 Entry tag_alpha(&trans, GET_BY_SERVER_TAG, "alpha");
4009 Entry tag_bob(&trans, GET_BY_SERVER_TAG, "bob");
4015 Entry hurdle(&trans, GET_BY_HANDLE, hurdle_handle);
4070 syncable::ReadTransaction trans(FROM_HERE, directory());
4072 Entry received(&trans, GET_BY_ID, to_receive);
4077 Entry committed(&trans, GET_BY_HANDLE, commit_handle);
4096 syncable::ReadTransaction trans(FROM_HERE, directory());
4099 Entry received(&trans, GET_BY_ID, to_receive);
4103 Entry committed(&trans, GET_BY_HANDLE, commit_handle);
4130 syncable::ReadTransaction trans(FROM_HERE, directory());
4133 Entry n1(&trans, GET_BY_ID, node1);
4137 Entry n2(&trans, GET_BY_ID, node2);
4165 syncable::ReadTransaction trans(FROM_HERE, directory());
4168 Entry n1(&trans, GET_BY_ID, node1);
4173 Entry n2(&trans, GET_BY_ID, node2);
4238 WriteTransaction trans(FROM_HERE, UNITTEST, directory());
4240 &trans, CREATE, BOOKMARKS, ids_.root(), "clientname");
4253 WriteTransaction trans(FROM_HERE, UNITTEST, directory());
4254 MutableEntry entry(&trans, GET_BY_CLIENT_TAG, client_tag_);
4263 WriteTransaction trans(FROM_HERE, UNITTEST, directory());
4264 MutableEntry entry(&trans, GET_BY_CLIENT_TAG, client_tag_);
4274 syncable::ReadTransaction trans(FROM_HERE, directory());
4275 Entry entry(&trans, GET_BY_CLIENT_TAG, client_tag_);
4284 syncable::ReadTransaction trans(FROM_HERE, directory());
4285 Entry entry(&trans, GET_BY_CLIENT_TAG, client_tag_);
4296 syncable::ReadTransaction trans(FROM_HERE, directory());
4297 Entry entry(&trans, GET_BY_CLIENT_TAG, client_tag_);
4309 syncable::ReadTransaction trans(FROM_HERE, directory());
4310 Entry entry(&trans, GET_BY_CLIENT_TAG, client_tag_);
4322 syncable::ReadTransaction trans(FROM_HERE, directory());
4323 Entry entry(&trans, GET_BY_CLIENT_TAG, client_tag_);
4335 syncable::ReadTransaction trans(FROM_HERE, directory());
4336 Entry entry(&trans, GET_BY_CLIENT_TAG, client_tag_);
4348 syncable::ReadTransaction trans(FROM_HERE, directory());
4349 Entry entry(&trans, GET_BY_CLIENT_TAG, client_tag_);
4390 syncable::ReadTransaction trans(FROM_HERE, directory());
4391 Entry entry(&trans, GET_BY_HANDLE, metahandle_);
4438 syncable::ReadTransaction trans(FROM_HERE, directory());
4439 Entry entry(&trans, GET_BY_HANDLE, metahandle_);
4554 syncable::ReadTransaction trans(FROM_HERE, directory());
4555 Entry entry(&trans, GET_BY_HANDLE, metahandle_);
4596 syncable::ReadTransaction trans(FROM_HERE, directory());
4597 Entry entry(&trans, GET_BY_HANDLE, metahandle_);
4664 syncable::ReadTransaction trans(FROM_HERE, directory());
4665 Entry entry(&trans, GET_BY_HANDLE, metahandle_);
4678 syncable::ReadTransaction trans(FROM_HERE, directory());
4679 Entry entry(&trans, GET_BY_HANDLE, metahandle_);
4697 syncable::ReadTransaction trans(FROM_HERE, directory());
4698 Entry entry(&trans, GET_BY_HANDLE, metahandle_);
4719 syncable::ReadTransaction trans(FROM_HERE, directory());
4720 Entry entry(&trans, GET_BY_HANDLE, metahandle_);
4733 syncable::ReadTransaction trans(FROM_HERE, directory());
4734 Entry entry(&trans, GET_BY_HANDLE, metahandle_);