HomeSort by relevance Sort by last modified time
    Searched refs:AccountType (Results 1 - 25 of 52) sorted by null

1 2 3

  /packages/apps/Contacts/tests/src/com/android/contacts/tests/mocks/
MockAccountTypeManager.java 19 import com.android.contacts.common.model.account.AccountType;
35 public AccountType[] mTypes;
38 public MockAccountTypeManager(AccountType[] types, AccountWithDataSet[] accounts) {
44 public AccountType getAccountType(AccountTypeWithDataSet accountTypeWithDataSet) {
45 for (AccountType type : mTypes) {
46 if (Objects.equal(accountTypeWithDataSet.accountType, type.accountType)
65 public Map<AccountTypeWithDataSet, AccountType> getUsableInvitableAccountTypes() {
70 public List<AccountType> getAccountTypes(boolean writableOnly) {
71 final List<AccountType> ret = Lists.newArrayList()
    [all...]
  /packages/apps/ContactsCommon/tests/src/com/android/contacts/common/model/
AccountTypeManagerTest.java 23 import com.android.contacts.common.model.account.AccountType;
46 final AccountType typeA = new MockAccountType("type1", null, null);
47 final AccountType typeB = new MockAccountType("type1", "minus", null);
48 final AccountType typeC = new MockAccountType("type2", null, "c");
49 final AccountType typeD = new MockAccountType("type2", "minus", "d");
58 Map<AccountTypeWithDataSet, AccountType> types =
129 private static AccountWithDataSet createAccountWithDataSet(String name, AccountType type) {
130 return new AccountWithDataSet(name, type.accountType, type.dataSet);
134 * Array of {@link AccountType} -> {@link Map}
136 private static Map<AccountTypeWithDataSet, AccountType> buildAccountTypes(AccountType... types)
    [all...]
  /packages/apps/ContactsCommon/tests/src/com/android/contacts/common/model/account/
AccountTypeTest.java 26 * Test case for {@link AccountType}.
41 assertEquals(DEFAULT, AccountType.getResourceText(c, null, -1, DEFAULT));
44 assertEquals(DEFAULT, AccountType.getResourceText(c, packageName, -1, DEFAULT));
49 AccountType.getResourceText(c, packageName, externalResID, DEFAULT));
54 AccountType.getResourceText(c, null, internalResId, DEFAULT));
58 * Verify if {@link AccountType#getInviteContactActionLabel} correctly gets the resource ID
59 * from {@link AccountType#getInviteContactActionResId}
67 AccountType accountType = new AccountType() {
    [all...]
  /packages/apps/ContactsCommon/src/com/android/contacts/common/model/
AccountTypeManager.java 48 import com.android.contacts.common.model.account.AccountType;
75 * Singleton holder for all parsed {@link AccountType} available on the
124 public abstract AccountType getAccountType(AccountTypeWithDataSet accountTypeWithDataSet);
126 public final AccountType getAccountType(String accountType, String dataSet) {
127 return getAccountType(AccountTypeWithDataSet.get(accountType, dataSet));
130 public final AccountType getAccountTypeForAccount(AccountWithDataSet account) {
135 * @return Unmodifiable map from {@link AccountTypeWithDataSet}s to {@link AccountType}s
147 public abstract Map<AccountTypeWithDataSet, AccountType> getUsableInvitableAccountTypes();
151 * {@link AccountType#accountType}, {@link AccountType#dataSet}, and {@link DataKind#mimeType}
    [all...]
  /packages/apps/Contacts/src/com/android/contacts/group/
GroupDetailDisplayUtils.java 27 import com.android.contacts.common.model.account.AccountType;
44 AccountType accountType = accountTypeManager.getAccountType(accountTypeString, dataSet);
51 label.setText(accountType.getViewGroupLabel(context));
58 accountIcon.setImageDrawable(accountType.getDisplayIcon(context));
  /packages/apps/Contacts/src/com/android/contacts/editor/
BaseRawContactEditorView.java 34 import com.android.contacts.common.model.account.AccountType;
35 import com.android.contacts.common.model.account.AccountType.EditType;
44 * {@link RawContactModifier} to ensure that {@link AccountType} are enforced.
117 * {@link RawContactDelta} state and the {@link AccountType} that
120 public abstract void setState(RawContactDelta state, AccountType source, ViewIdGenerator vig,
AggregationSuggestionView.java 32 import com.android.contacts.common.model.account.AccountType;
117 String accountType = rawContact.accountType;
119 if (accountType == null) {
122 AccountType type = accountTypes.getAccountType(accountType, dataSet);
ContactEditorUtils.java 31 import com.android.contacts.common.model.account.AccountType;
243 for (AccountType type : mAccountTypes.getAccountTypes(true)) {
244 types.add(type.accountType);
286 final String accountType = resultData.getStringExtra(AccountManager.KEY_ACCOUNT_TYPE);
290 if (TextUtils.isEmpty(accountType) || TextUtils.isEmpty(accountName)) return null;
292 return new AccountWithDataSet(accountName, accountType, null);
  /packages/apps/ContactsCommon/src/com/android/contacts/common/model/dataitem/
DataKind.java 23 import com.android.contacts.common.model.account.AccountType.EditField;
24 import com.android.contacts.common.model.account.AccountType.EditType;
25 import com.android.contacts.common.model.account.AccountType.StringInflater;
  /packages/apps/Contacts/tests/src/com/android/contacts/
RawContactModifierTests.java 47 import com.android.contacts.common.model.account.AccountType;
48 import com.android.contacts.common.model.account.AccountType.EditType;
61 * Tests for {@link RawContactModifier} to verify that {@link AccountType}
87 public static class MockContactsSource extends AccountType {
91 this.accountType = TEST_ACCOUNT_TYPE;
155 * Build a {@link AccountType} that has various odd constraints for
158 protected AccountType getAccountType() {
165 protected AccountTypeManager getAccountTypes(AccountType... types) {
207 final AccountType source = getAccountType();
252 final AccountType source = getAccountType()
    [all...]
  /packages/apps/Contacts/src/com/android/contacts/detail/
ContactDetailUpdatesFragment.java 36 import com.android.contacts.common.model.account.AccountType;
64 final AccountType accountType = getAccountTypeForStreamItemEntry(streamItemEntry);
69 intent.setClassName(accountType.syncAdapterPackageName,
70 accountType.getViewStreamItemActivity());
83 final AccountType accountType = getAccountTypeForStreamItemEntry(tag.streamItem);
86 intent.setClassName(accountType.syncAdapterPackageName,
87 accountType.getViewStreamItemPhotoActivity());
92 private AccountType getAccountTypeForStreamItemEntry(StreamItemEntry streamItemEntry)
    [all...]
StreamItemAdapter.java 27 import com.android.contacts.common.model.account.AccountType;
103 final AccountType accountType =
110 (accountType.getViewStreamItemPhotoActivity() == null) ? null : mPhotoClickListener
116 if (accountType.getViewStreamItemActivity() != null) {
  /packages/apps/Contacts/tests/src/com/android/contacts/interactions/
ContactDeletionInteractionTest.java 35 import com.android.contacts.common.model.account.AccountType;
86 AccountType readOnlyAccountType = new BaseAccountType() {
92 readOnlyAccountType.accountType = READONLY_ACCOUNT_TYPE;
94 AccountType writableAccountType = new BaseAccountType() {
100 writableAccountType.accountType = WRITABLE_ACCOUNT_TYPE;
104 new AccountType[] { writableAccountType, readOnlyAccountType }, null);
  /packages/apps/ContactsCommon/src/com/android/contacts/common/model/account/
AccountType.java 50 public abstract class AccountType {
51 private static final String TAG = "AccountType";
56 public String accountType = null;
212 return getResourceText(context, syncAdapterPackageName, titleRes, accountType);
233 return AccountTypeWithDataSet.get(accountType, dataSet);
509 * Compare two {@link AccountType} by their {@link AccountType#getDisplayLabel} with the
512 public static class DisplayLabelComparator implements Comparator<AccountType> {
521 private String getDisplayLabel(AccountType type) {
527 public int compare(AccountType lhs, AccountType rhs)
    [all...]
FallbackAccountType.java 30 this.accountType = null;
70 static AccountType createWithPackageNameForTest(Context context, String resPackageName) {
  /packages/apps/Contacts/tests/src/com/android/contacts/editor/
ContactEditorUtilsTest.java 23 import com.android.contacts.common.model.account.AccountType;
50 "a", TYPE1.accountType, TYPE1.dataSet);
52 "b", TYPE1.accountType, TYPE1.dataSet);
55 "a", TYPE2.accountType, TYPE2.dataSet);
57 "a", TYPE2EX.accountType, TYPE2EX.dataSet);
60 "c", TYPE3.accountType, TYPE3.dataSet);
65 mAccountTypes = new MockAccountTypeManager(new AccountType[] {},
73 private void setAccountTypes(AccountType... types) {
94 MoreAsserts.assertEquals(Sets.newHashSet(TYPE1.accountType), Sets.newHashSet(types));
100 MoreAsserts.assertEquals(Sets.newHashSet(TYPE1.accountType, TYPE2EX.accountType)
    [all...]
  /packages/apps/Contacts/src/com/android/contacts/model/
Contact.java 28 import com.android.contacts.common.model.account.AccountType;
77 private ImmutableList<AccountType> mInvitableAccountTypes;
212 String accountType, String accountName, int exportSupport) {
215 mDirectoryAccountType = accountType;
343 public ImmutableList<AccountType> getInvitableAccountTypes() {
391 AccountType accountType = rawContact.getAccountType(context);
392 if (accountType != null && accountType.areContactsWritable()) {
480 /* package */ void setInvitableAccountTypes(ImmutableList<AccountType> accountTypes)
    [all...]
RawContactModifier.java 55 import com.android.contacts.common.model.account.AccountType;
56 import com.android.contacts.common.model.account.AccountType.EditField;
57 import com.android.contacts.common.model.account.AccountType.EditType;
58 import com.android.contacts.common.model.account.AccountType.EventEditType;
78 * new rows, or enforcing {@link AccountType}.
89 * {@link AccountType}.
115 RawContactDelta state, AccountType accountType, String mimeType) {
116 final DataKind kind = accountType.getKindForMimetype(mimeType);
138 * {@link AccountType}
    [all...]
  /packages/apps/Contacts/src/com/android/contacts/activities/
GroupDetailActivity.java 37 import com.android.contacts.common.model.account.AccountType;
134 final AccountType accountType =
137 || TextUtils.isEmpty(accountType.getViewGroupActivity())) {
150 intent.setClassName(accountType.syncAdapterPackageName,
151 accountType.getViewGroupActivity());
ContactEditorActivity.java 40 import com.android.contacts.common.model.account.AccountType;
206 final AccountType accountType = accountTypes.getAccountType(
210 intent.setClassName(accountType.syncAdapterPackageName,
211 accountType.getCreateContactActivityClassName());
231 final AccountType accountType = accountTypes.getAccountType(
235 intent.setClassName(accountType.syncAdapterPackageName,
236 accountType.getEditContactActivityClassName());
AttachPhotoActivity.java 41 import com.android.contacts.common.model.account.AccountType;
198 AccountType account = raw.getRawContactAccountType(this);
  /packages/apps/ContactsCommon/src/com/android/contacts/common/
MoreContactUtils.java 32 import com.android.contacts.common.model.account.AccountType;
199 * {@link AccountType#getInviteContactActivityClassName()} or
200 * {@link AccountType#syncAdapterPackageName}).
202 public static Intent getInvitableIntent(AccountType accountType, Uri lookupUri) {
203 String syncAdapterPackageName = accountType.syncAdapterPackageName;
204 String className = accountType.getInviteContactActivityClassName();
  /packages/apps/ContactsCommon/src/com/android/contacts/common/list/
ContactListFilterView.java 30 import com.android.contacts.common.model.account.AccountType;
82 mAccountType = (TextView) findViewById(R.id.accountType);
123 final AccountType accountType =
124 accountTypes.getAccountType(mFilter.accountType, mFilter.dataSet);
126 mAccountType.setText(accountType.getDisplayLabel(getContext()));
  /packages/apps/ContactsCommon/src/com/android/contacts/common/util/
AccountsListAdapter.java 30 import com.android.contacts.common.model.account.AccountType;
94 final AccountType accountType = mAccountTypes.getAccountType(account.type, account.dataSet);
96 text1.setText(accountType.getDisplayLabel(mContext));
103 icon.setImageDrawable(accountType.getDisplayIcon(mContext));
  /packages/apps/Contacts/tests/src/com/android/contacts/activities/
PeopleActivityTest.java 45 import com.android.contacts.common.model.account.AccountType;
97 AccountType accountType = new BaseAccountType() {
103 accountType.accountType = TEST_ACCOUNT_TYPE;
109 new AccountType[] { accountType }, new AccountWithDataSet[] { account });

Completed in 159 milliseconds

1 2 3