Possible to add allowed packages
This commit is contained in:
@@ -222,6 +222,10 @@ public class KeychainContract {
|
||||
|
||||
/** Use if a single item is returned */
|
||||
public static final String CONTENT_ITEM_TYPE = "vnd.android.cursor.item/vnd.thialfihar.apg.crypto_consumers";
|
||||
|
||||
public static Uri buildIdUri(String rowId) {
|
||||
return CONTENT_URI.buildUpon().appendPath(rowId).build();
|
||||
}
|
||||
}
|
||||
|
||||
public static class DataStream {
|
||||
|
||||
@@ -600,10 +600,10 @@ public class KeychainProvider extends ContentProvider {
|
||||
qb.appendWhereEscapeString(uri.getLastPathSegment());
|
||||
|
||||
break;
|
||||
|
||||
|
||||
case CRYPTO_CONSUMERS:
|
||||
qb.setTables(Tables.CRYPTO_CONSUMERS);
|
||||
|
||||
|
||||
break;
|
||||
|
||||
default:
|
||||
@@ -685,6 +685,11 @@ public class KeychainProvider extends ContentProvider {
|
||||
rowId = db.insertOrThrow(Tables.USER_IDS, null, values);
|
||||
rowUri = UserIds.buildSecretUserIdsUri(Long.toString(rowId));
|
||||
|
||||
break;
|
||||
case CRYPTO_CONSUMERS:
|
||||
rowId = db.insertOrThrow(Tables.CRYPTO_CONSUMERS, null, values);
|
||||
rowUri = CryptoConsumers.buildIdUri(Long.toString(rowId));
|
||||
|
||||
break;
|
||||
default:
|
||||
throw new UnsupportedOperationException("Unknown uri: " + uri);
|
||||
|
||||
Reference in New Issue
Block a user