Loading core/java/android/service/contentcapture/DataShareReadAdapter.java +2 −1 Original line number Diff line number Diff line Loading @@ -20,6 +20,7 @@ import android.annotation.NonNull; import android.annotation.SystemApi; import android.annotation.TestApi; import android.os.ParcelFileDescriptor; import android.view.contentcapture.ContentCaptureManager.DataShareError; /** * Adapter class to be used for the Content Capture Service app to propagate the status of the Loading @@ -46,5 +47,5 @@ public interface DataShareReadAdapter { * these 2 events is not defined, and it's important that the service treats end of stream * correctly in this situation. **/ void onError(int errorCode); void onError(@DataShareError int errorCode); } core/java/android/view/contentcapture/ContentCaptureManager.java +9 −0 Original line number Diff line number Diff line Loading @@ -216,6 +216,15 @@ public final class ContentCaptureManager { /** Request has been interrupted because of data share session timeout. */ public static final int DATA_SHARE_ERROR_TIMEOUT_INTERRUPTED = 3; /** @hide */ @IntDef(flag = false, value = { DATA_SHARE_ERROR_UNKNOWN, DATA_SHARE_ERROR_CONCURRENT_REQUEST, DATA_SHARE_ERROR_TIMEOUT_INTERRUPTED }) @Retention(RetentionPolicy.SOURCE) public @interface DataShareError {} /** @hide */ public static final int RESULT_CODE_OK = 0; /** @hide */ Loading core/java/android/view/contentcapture/DataShareWriteAdapter.java +2 −1 Original line number Diff line number Diff line Loading @@ -18,6 +18,7 @@ package android.view.contentcapture; import android.annotation.NonNull; import android.os.ParcelFileDescriptor; import android.view.contentcapture.ContentCaptureManager.DataShareError; /** Adapter class used by apps to share data with the Content Capture service. */ public interface DataShareWriteAdapter { Loading @@ -42,7 +43,7 @@ public interface DataShareWriteAdapter { * * @param errorCode the error code corresponding to an ERROR_* value. */ default void onError(int errorCode) { default void onError(@DataShareError int errorCode) { /* do nothing - stub */ } } Loading
core/java/android/service/contentcapture/DataShareReadAdapter.java +2 −1 Original line number Diff line number Diff line Loading @@ -20,6 +20,7 @@ import android.annotation.NonNull; import android.annotation.SystemApi; import android.annotation.TestApi; import android.os.ParcelFileDescriptor; import android.view.contentcapture.ContentCaptureManager.DataShareError; /** * Adapter class to be used for the Content Capture Service app to propagate the status of the Loading @@ -46,5 +47,5 @@ public interface DataShareReadAdapter { * these 2 events is not defined, and it's important that the service treats end of stream * correctly in this situation. **/ void onError(int errorCode); void onError(@DataShareError int errorCode); }
core/java/android/view/contentcapture/ContentCaptureManager.java +9 −0 Original line number Diff line number Diff line Loading @@ -216,6 +216,15 @@ public final class ContentCaptureManager { /** Request has been interrupted because of data share session timeout. */ public static final int DATA_SHARE_ERROR_TIMEOUT_INTERRUPTED = 3; /** @hide */ @IntDef(flag = false, value = { DATA_SHARE_ERROR_UNKNOWN, DATA_SHARE_ERROR_CONCURRENT_REQUEST, DATA_SHARE_ERROR_TIMEOUT_INTERRUPTED }) @Retention(RetentionPolicy.SOURCE) public @interface DataShareError {} /** @hide */ public static final int RESULT_CODE_OK = 0; /** @hide */ Loading
core/java/android/view/contentcapture/DataShareWriteAdapter.java +2 −1 Original line number Diff line number Diff line Loading @@ -18,6 +18,7 @@ package android.view.contentcapture; import android.annotation.NonNull; import android.os.ParcelFileDescriptor; import android.view.contentcapture.ContentCaptureManager.DataShareError; /** Adapter class used by apps to share data with the Content Capture service. */ public interface DataShareWriteAdapter { Loading @@ -42,7 +43,7 @@ public interface DataShareWriteAdapter { * * @param errorCode the error code corresponding to an ERROR_* value. */ default void onError(int errorCode) { default void onError(@DataShareError int errorCode) { /* do nothing - stub */ } }