Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit c114eb55 authored by Christopher Tate's avatar Christopher Tate
Browse files

Hide the backup stuff for now

Also adjust based on comments:
+ changed service intent string to conform to usage guidelines
+ only publish the IBackupService binder when invoked with the right
  intent action
+ docs tweaks
parent 021dce41
Loading
Loading
Loading
Loading
+0 −106
Original line number Diff line number Diff line
@@ -21740,112 +21740,6 @@
</field>
</class>
</package>
<package name="android.backup"
>
<class name="BackupManager"
 extends="java.lang.Object"
 abstract="false"
 static="false"
 final="false"
 deprecated="not deprecated"
 visibility="public"
>
<constructor name="BackupManager"
 type="android.backup.BackupManager"
 static="false"
 final="false"
 deprecated="not deprecated"
 visibility="public"
>
<parameter name="context" type="android.content.Context">
</parameter>
</constructor>
<method name="dataChanged"
 return="void"
 abstract="false"
 native="false"
 synchronized="false"
 static="false"
 final="false"
 deprecated="not deprecated"
 visibility="public"
>
</method>
</class>
<class name="BackupService"
 extends="android.app.Service"
 abstract="true"
 static="false"
 final="false"
 deprecated="not deprecated"
 visibility="public"
>
<constructor name="BackupService"
 type="android.backup.BackupService"
 static="false"
 final="false"
 deprecated="not deprecated"
 visibility="public"
>
</constructor>
<method name="onBackup"
 return="void"
 abstract="true"
 native="false"
 synchronized="false"
 static="false"
 final="false"
 deprecated="not deprecated"
 visibility="public"
>
<parameter name="oldStateFd" type="int">
</parameter>
<parameter name="dataFd" type="int">
</parameter>
<parameter name="newStateFd" type="int">
</parameter>
</method>
<method name="onBind"
 return="android.os.IBinder"
 abstract="false"
 native="false"
 synchronized="false"
 static="false"
 final="false"
 deprecated="not deprecated"
 visibility="public"
>
<parameter name="intent" type="android.content.Intent">
</parameter>
</method>
<method name="onRestore"
 return="void"
 abstract="true"
 native="false"
 synchronized="false"
 static="false"
 final="false"
 deprecated="not deprecated"
 visibility="public"
>
<parameter name="dataFd" type="int">
</parameter>
<parameter name="newStateFd" type="int">
</parameter>
</method>
<field name="SERVICE_ACTION"
 type="java.lang.String"
 transient="false"
 volatile="false"
 value="&quot;android.service.action.BACKUP&quot;"
 static="true"
 final="true"
 deprecated="not deprecated"
 visibility="public"
>
</field>
</class>
</package>
<package name="android.content"
>
<class name="ActivityNotFoundException"
+5 −3
Original line number Diff line number Diff line
@@ -34,6 +34,8 @@ import android.os.ServiceManager;
 * <p>The backup operation itself begins with the system launching the
 * {@link BackupService} subclass declared in your manifest.  See the documentation
 * for {@link BackupService} for a detailed description of how the backup then proceeds.
 *
 * @hide pending API solidification
 */
public class BackupManager {
    private Context mContext;
+12 −5
Original line number Diff line number Diff line
@@ -42,7 +42,7 @@ import android.util.Log;
 *          &lt;/intent-filter&gt;
 *      &lt;/service&gt;</pre>
 * 
 * <p><em>Not hidden but API subject to change and should not be published</em>
 * @hide pending API solidification
 */

public abstract class BackupService extends Service {
@@ -53,7 +53,7 @@ public abstract class BackupService extends Service {
     * IntentFilter} that accepts this action. 
     */
    @SdkConstant(SdkConstantType.SERVICE_ACTION)
    public static final String SERVICE_ACTION = "android.service.action.BACKUP";
    public static final String SERVICE_ACTION = "android.backup.BackupService";

    /**
     * The application is being asked to write any data changed since the
@@ -95,9 +95,16 @@ public abstract class BackupService extends Service {

    // ----- Core implementation -----
    
    /**
     * Returns the private interface called by the backup system.  Applications will
     * not typically override this.
     */
    public IBinder onBind(Intent intent) {
        if (intent.getAction().equals(SERVICE_ACTION)) {
            return mBinder;
        }
        return null;
    }

    private final IBinder mBinder = new BackupServiceBinder().asBinder();