1 /* 2 * Copyright 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 17 package com.android.server.nearby.common.bluetooth.fastpair; 18 19 import android.bluetooth.BluetoothDevice; 20 import android.content.Context; 21 22 import com.android.server.nearby.common.bluetooth.fastpair.Preferences.ExtraLoggingInformation; 23 import com.android.server.nearby.intdefs.NearbyEventIntDefs.EventCode; 24 25 import javax.annotation.Nullable; 26 27 /** 28 * Convenience wrapper around EventLogger. 29 */ 30 // TODO(b/202559985): cleanup EventLoggerWrapper. 31 class EventLoggerWrapper { 32 EventLoggerWrapper(@ullable EventLogger eventLogger)33 EventLoggerWrapper(@Nullable EventLogger eventLogger) { 34 } 35 36 /** 37 * Binds to the logging service. This operation blocks until binding has completed or timed 38 * out. 39 */ bind( Context context, String address, @Nullable ExtraLoggingInformation extraLoggingInformation)40 void bind( 41 Context context, String address, 42 @Nullable ExtraLoggingInformation extraLoggingInformation) { 43 } 44 isBound()45 boolean isBound() { 46 return false; 47 } 48 unbind(Context context)49 void unbind(Context context) { 50 } 51 setCurrentEvent(@ventCode int code)52 void setCurrentEvent(@EventCode int code) { 53 } 54 setCurrentProfile(short profile)55 void setCurrentProfile(short profile) { 56 } 57 logCurrentEventFailed(Exception e)58 void logCurrentEventFailed(Exception e) { 59 } 60 logCurrentEventSucceeded()61 void logCurrentEventSucceeded() { 62 } 63 setDevice(@ullable BluetoothDevice device)64 void setDevice(@Nullable BluetoothDevice device) { 65 } 66 isCurrentEvent()67 boolean isCurrentEvent() { 68 return false; 69 } 70 } 71