blob: 8e32ffdb0297e2ae73c274ea7541f1857712383d [file] [log] [blame]
Remi NGUYEN VAN22ea8772021-12-16 15:17:28 +00001/*
2 * Copyright (C) 2021 The Android Open Source Project
3 *
4 * Licensed under the Apache License, Version 2.0 (the "License");
5 * you may not use this file except in compliance with the License.
6 * You may obtain a copy of the License at
7 *
8 * http://www.apache.org/licenses/LICENSE-2.0
9 *
10 * Unless required by applicable law or agreed to in writing, software
11 * distributed under the License is distributed on an "AS IS" BASIS,
12 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 * See the License for the specific language governing permissions and
14 * limitations under the License.
15 */
16
17package com.android.server;
18
19import android.content.Context;
20import android.os.IBinder;
21import android.os.IInterface;
22import android.os.Parcel;
23import android.os.RemoteException;
24
25import java.io.FileDescriptor;
26
27/**
28 * Fake NsdService class for sc-mainline-prod,
29 * to allow building the T service-connectivity before sources
30 * are moved to the branch
31 */
32public final class NsdService implements IBinder {
33 /** Create instance */
34 public static NsdService create(Context ctx) throws InterruptedException {
35 throw new RuntimeException("This is a stub class");
36 }
37
38 @Override
39 public String getInterfaceDescriptor() throws RemoteException {
40 return null;
41 }
42
43 @Override
44 public boolean pingBinder() {
45 return false;
46 }
47
48 @Override
49 public boolean isBinderAlive() {
50 return false;
51 }
52
53 @Override
54 public IInterface queryLocalInterface(String descriptor) {
55 return null;
56 }
57
58 @Override
59 public void dump(FileDescriptor fd, String[] args) throws RemoteException {}
60
61 @Override
62 public void dumpAsync(FileDescriptor fd, String[] args) throws RemoteException {}
63
64 @Override
65 public boolean transact(int code, Parcel data, Parcel reply, int flags) throws RemoteException {
66 return false;
67 }
68
69 @Override
70 public void linkToDeath(DeathRecipient recipient, int flags) throws RemoteException {}
71
72 @Override
73 public boolean unlinkToDeath(DeathRecipient recipient, int flags) {
74 return false;
75 }
76}