Add empty AdbManagerInternal for system server
This will allow the call of internal-only AdbService functions from within the system server. Bug: 63820489 Test: make Change-Id: Ic761b513a8c10ce0173ddb6bc761a6372799f15c
This commit is contained in:
26
core/java/android/debug/AdbManagerInternal.java
Normal file
26
core/java/android/debug/AdbManagerInternal.java
Normal file
@@ -0,0 +1,26 @@
|
||||
/*
|
||||
* Copyright (C) 2018 The Android Open Source Project
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
package android.debug;
|
||||
|
||||
/**
|
||||
* This class allows the control of ADB-related functions that should only be called from the system
|
||||
* server.
|
||||
*
|
||||
* @hide Only should be called from the system server.
|
||||
*/
|
||||
public abstract class AdbManagerInternal {
|
||||
}
|
||||
@@ -16,11 +16,13 @@
|
||||
package com.android.server.adb;
|
||||
|
||||
import android.content.Context;
|
||||
import android.debug.AdbManagerInternal;
|
||||
import android.debug.IAdbManager;
|
||||
import android.os.Binder;
|
||||
|
||||
import com.android.internal.util.DumpUtils;
|
||||
import com.android.internal.util.IndentingPrintWriter;
|
||||
import com.android.server.LocalServices;
|
||||
import com.android.server.SystemService;
|
||||
|
||||
import java.io.FileDescriptor;
|
||||
@@ -48,12 +50,17 @@ public class AdbService extends IAdbManager.Stub {
|
||||
}
|
||||
}
|
||||
|
||||
private class AdbManagerInternalImpl extends AdbManagerInternal {
|
||||
}
|
||||
|
||||
private static final String TAG = "AdbService";
|
||||
|
||||
private final Context mContext;
|
||||
|
||||
private AdbService(Context context) {
|
||||
mContext = context;
|
||||
|
||||
LocalServices.addService(AdbManagerInternal.class, new AdbManagerInternalImpl());
|
||||
}
|
||||
|
||||
@Override
|
||||
|
||||
Reference in New Issue
Block a user