2022-10-02 23:06:56 +02:00
|
|
|
package android.content;
|
|
|
|
|
|
2024-03-16 18:14:46 +01:00
|
|
|
import java.io.File;
|
|
|
|
|
import java.io.FileNotFoundException;
|
|
|
|
|
|
2024-03-20 23:05:17 +01:00
|
|
|
import android.database.AbstractCursor;
|
2022-11-24 23:10:27 +01:00
|
|
|
import android.database.ContentObserver;
|
2024-03-20 23:05:17 +01:00
|
|
|
import android.database.Cursor;
|
2023-06-22 11:45:46 +02:00
|
|
|
import android.net.Uri;
|
2024-03-29 23:56:28 +01:00
|
|
|
import android.os.CancellationSignal;
|
2024-03-16 18:14:46 +01:00
|
|
|
import android.os.ParcelFileDescriptor;
|
2022-10-02 23:06:56 +02:00
|
|
|
|
2022-11-24 23:10:27 +01:00
|
|
|
public class ContentResolver {
|
|
|
|
|
public final void registerContentObserver(Uri uri, boolean notifyForDescendants, ContentObserver observer) {
|
|
|
|
|
}
|
2023-08-24 12:43:13 +02:00
|
|
|
public final void unregisterContentObserver(ContentObserver observer) {
|
|
|
|
|
}
|
|
|
|
|
public void notifyChange(Uri uri, ContentObserver observer) {
|
|
|
|
|
}
|
|
|
|
|
public int getUserId() {
|
|
|
|
|
return 0;
|
|
|
|
|
}
|
|
|
|
|
public final void registerContentObserver(Uri uri, boolean notifyForDescendants, ContentObserver observer, int userHandle) {
|
|
|
|
|
}
|
2024-03-16 18:14:46 +01:00
|
|
|
|
|
|
|
|
public ParcelFileDescriptor openFileDescriptor(Uri uri, String mode) throws FileNotFoundException {
|
|
|
|
|
return ParcelFileDescriptor.open(new File(uri.uri), ParcelFileDescriptor.parseMode(mode));
|
|
|
|
|
}
|
2024-03-20 23:05:17 +01:00
|
|
|
|
|
|
|
|
public Cursor query(Uri uri, String[] projection, String selection, String[] selectionArgs, String sortOrder) {
|
|
|
|
|
return new AbstractCursor() {
|
|
|
|
|
public int getCount() { return 0; }
|
|
|
|
|
public String[] getColumnNames() { return new String[0]; }
|
|
|
|
|
public String getString(int column) { throw new IndexOutOfBoundsException(); }
|
|
|
|
|
public short getShort(int column) { throw new IndexOutOfBoundsException(); }
|
|
|
|
|
public int getInt(int column) { throw new IndexOutOfBoundsException(); }
|
|
|
|
|
public long getLong(int column) { throw new IndexOutOfBoundsException(); }
|
|
|
|
|
public float getFloat(int column) { throw new IndexOutOfBoundsException(); }
|
|
|
|
|
public double getDouble(int column) { throw new IndexOutOfBoundsException(); }
|
|
|
|
|
public boolean isNull(int column) { throw new IndexOutOfBoundsException(); }
|
|
|
|
|
};
|
|
|
|
|
}
|
2024-03-29 23:56:28 +01:00
|
|
|
|
|
|
|
|
public Cursor query(Uri uri, String[] projection, String selection, String[] selectionArgs, String sortOrder, CancellationSignal cancellationSignal) {
|
|
|
|
|
return query(uri, projection, selection, selectionArgs, sortOrder);
|
|
|
|
|
}
|
2022-10-02 23:06:56 +02:00
|
|
|
}
|