Home | History | Annotate | Download | only in content

Lines Matching refs:account

19 import android.accounts.Account;
54 final Account account = new Account("a@example.com", "example.type");
64 account, 0, SyncOperation.REASON_PERIODIC, authority, time0,
75 final Account account1 = new Account("a@example.com", "example.type");
76 final Account account2 = new Account("b@example.com", "example.type.2");
100 engine.addPeriodicSync(sync1.account, 0, sync1.authority, sync1.extras, sync1.period);
101 engine.addPeriodicSync(sync2.account, 0, sync2.authority, sync2.extras, sync2.period);
102 engine.addPeriodicSync(sync3.account, 0, sync3.authority, sync3.extras, sync3.period);
103 engine.addPeriodicSync(sync4.account, 0, sync4.authority, sync4.extras, sync4.period);
105 engine.addPeriodicSync(sync2.account, 1, sync2.authority, sync2.extras, sync2.period);
114 engine.removePeriodicSync(sync1.account, 0, sync1.authority, sync1.extras);
124 syncs = engine.getPeriodicSyncs(sync2.account, 1, sync2.authority);
129 private void removePeriodicSyncs(SyncStorageEngine engine, Account account, int userId,
131 engine.setIsSyncable(account, userId, authority,
132 engine.getIsSyncable(account, 0, authority));
133 List<PeriodicSync> syncs = engine.getPeriodicSyncs(account, userId, authority);
135 engine.removePeriodicSync(sync.account, userId, sync.authority, sync.extras);
141 final Account account1 = new Account("a@example.com", "example.type");
142 final Account account2 = new Account("b@example.com", "example.type.2");
188 engine.addPeriodicSync(sync1.account, 0, sync1.authority, sync1.extras, sync1.period);
189 engine.addPeriodicSync(sync2.account, 0, sync2.authority, sync2.extras, sync2.period);
190 engine.addPeriodicSync(sync3.account, 0, sync3.authority, sync3.extras, sync3.period);
191 engine.addPeriodicSync(sync4.account, 0, sync4.authority, sync4.extras, sync4.period);
192 engine.addPeriodicSync(sync5.account, 0, sync5.authority, sync5.extras, sync5.period);
224 final Account account = new Account("account1", "type1");
229 PeriodicSync sync1 = new PeriodicSync(account, authority1, extras, (long) (60 * 60 * 24));
230 PeriodicSync sync2 = new PeriodicSync(account, authority2, extras, (long) (60 * 60 * 24));
231 PeriodicSync sync3 = new PeriodicSync(account, authority3, extras, (long) (60 * 60 * 24));
232 PeriodicSync sync1s = new PeriodicSync(account, authority1, extras, 1000);
233 PeriodicSync sync2s = new PeriodicSync(account, authority2, extras, 1000);
234 PeriodicSync sync3s = new PeriodicSync(account, authority3, extras, 1000);
242 + "<authority id=\"0\" user=\"0\" account=\"account1\" type=\"type1\" authority=\"auth1\" />\n"
243 + "<authority id=\"1\" user=\"0\" account=\"account1\" type=\"type1\" authority=\"auth2\" />\n"
244 + "<authority id=\"2\" account=\"account1\" type=\"type1\" authority=\"auth3\" />\n"
245 + "<authority id=\"3\" user=\"1\" account=\"account1\" type=\"type1\" authority=\"auth3\" />\n"
257 List<PeriodicSync> syncs = engine.getPeriodicSyncs(account, 0, authority1);
261 syncs = engine.getPeriodicSyncs(account, 0, authority2);
265 syncs = engine.getPeriodicSyncs(account, 0, authority3);
269 syncs = engine.getPeriodicSyncs(account, 1, authority3);
275 + "<authority id=\"0\" account=\"account1\" type=\"type1\" authority=\"auth1\" />\n"
276 + "<authority id=\"1\" account=\"account1\" type=\"type1\" authority=\"auth2\" />\n"
277 + "<authority id=\"2\" account=\"account1\" type=\"type1\" authority=\"auth3\" />\n"
287 syncs = engine.getPeriodicSyncs(account, 0, authority1);
290 syncs = engine.getPeriodicSyncs(account, 0, authority2);
293 syncs = engine.getPeriodicSyncs(account, 0, authority3);
298 + "<authority id=\"0\" account=\"account1\" type=\"type1\" authority=\"auth1\">\n"
301 + "<authority id=\"1\" account=\"account1\" type=\"type1\" authority=\"auth2\">\n"
304 + "<authority id=\"2\" account=\"account1\" type=\"type1\" authority=\"auth3\">\n"
316 syncs = engine.getPeriodicSyncs(account, 0, authority1);
320 syncs = engine.getPeriodicSyncs(account, 0, authority2);
324 syncs = engine.getPeriodicSyncs(account, 0, authority3);
335 + "<authority id=\"0\" user=\"0\" account=\"account1\" type=\"type1\" authority=\"auth1\" />\n"
336 + "<authority id=\"1\" user=\"1\" account=\"account1\" type=\"type1\" authority=\"auth1\" />\n"
359 final Account account1 = new Account("acc1", "type1");
360 final AccountAccount("acc2", "type2");
373 + "<authority id=\"0\" account=\"acc1\" type=\"type1\" authority=\"contacts\" />\n"
374 + "<authority id=\"1\" account=\"acc1\" type=\"type1\" authority=\"calendar\" />\n"
375 + "<authority id=\"2\" account=\"acc1\" type=\"type1\" authority=\"other\" />\n"
376 + "<authority id=\"3\" account=\"acc2\" type=\"type2\" authority=\"contacts\" />\n"
377 + "<authority id=\"4\" account=\"acc2\" type=\"type2\" authority=\"calendar\" />\n"
378 + "<authority id=\"5\" account=\"acc2\" type=\"type2\" authority=\"other\" />\n"
379 + "<authority id=\"6\" account=\"acc2\" type=\"type2\" enabled=\"false\""
381 + "<authority id=\"7\" account=\"acc2\" type=\"type2\" enabled=\"false\""
409 final Account account = new Account("acc", "type");
417 + "<authority id=\"0\" account=\"acc\" authority=\"other1\" />\n"
418 + "<authority id=\"1\" account=\"acc\" type=\"type\" authority=\"other2\" />\n"
419 + "<authority id=\"2\" account=\"acc\" type=\"type\" syncable=\"false\""
421 + "<authority id=\"3\" account=\"acc\" type=\"type\" syncable=\"true\""
434 assertEquals(-1, engine.getIsSyncable(account, 0, "other1"));
435 assertEquals(1, engine.getIsSyncable(account, 0, "other2"));
436 assertEquals(0, engine.getIsSyncable(account, 0, "other3"));
437 assertEquals(1, engine.getIsSyncable(account, 0, "other4"));