• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1 /*
2  * Copyright (C) 2017 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.dialer.preferredsim.suggestion.stub;
18 
19 import android.content.Context;
20 import android.support.annotation.NonNull;
21 import android.support.annotation.WorkerThread;
22 import android.telecom.PhoneAccountHandle;
23 import com.android.dialer.preferredsim.suggestion.SuggestionProvider;
24 import com.google.common.base.Optional;
25 import javax.inject.Inject;
26 
27 /** {@link SuggestionProvider} that does nothing. */
28 public class StubSuggestionProvider implements SuggestionProvider {
29 
30   @Inject
StubSuggestionProvider()31   public StubSuggestionProvider() {}
32 
33   @WorkerThread
34   @Override
getSuggestion(Context context, String number)35   public Optional<Suggestion> getSuggestion(Context context, String number) {
36     return Optional.absent();
37   }
38 
39   @Override
reportUserSelection( @onNull Context context, @NonNull String number, @NonNull PhoneAccountHandle phoneAccountHandle, boolean rememberSelection)40   public void reportUserSelection(
41       @NonNull Context context,
42       @NonNull String number,
43       @NonNull PhoneAccountHandle phoneAccountHandle,
44       boolean rememberSelection) {}
45 
46   @Override
reportIncorrectSuggestion( @onNull Context context, @NonNull String number, PhoneAccountHandle newAccount)47   public void reportIncorrectSuggestion(
48       @NonNull Context context, @NonNull String number, PhoneAccountHandle newAccount) {}
49 }
50