blob: d34f84ef6376f8269f56d0fc4c57bb9707d9bf76 [file] [log] [blame]
Jon Miranda16ea1b12017-12-12 14:52:48 -08001/*
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 */
16package com.android.wallpaper.module;
17
18import android.content.Context;
19
20import com.android.wallpaper.compat.WallpaperManagerCompat;
21import com.android.wallpaper.model.CategoryProvider;
Clément Julliardea1638d2018-05-21 19:15:17 -070022import com.android.wallpaper.model.WallpaperInfo;
Jon Miranda16ea1b12017-12-12 14:52:48 -080023import com.android.wallpaper.monitor.PerformanceMonitor;
24import com.android.wallpaper.network.Requester;
Clément Julliardea1638d2018-05-21 19:15:17 -070025import com.android.wallpaper.picker.PreviewFragment.PreviewMode;
Jon Miranda16ea1b12017-12-12 14:52:48 -080026
Sunny Goyal8600a3f2018-08-15 12:48:01 -070027import androidx.fragment.app.Fragment;
28
Jon Miranda16ea1b12017-12-12 14:52:48 -080029/**
30 * Interface for a provider of "injected dependencies." (NOTE: The term "injector" is somewhat of a
31 * misnomer; this is more aptly a service registry as part of a service locator design pattern.)
32 */
33public interface Injector {
34 AlarmManagerWrapper getAlarmManagerWrapper(Context context);
35
36 BitmapCropper getBitmapCropper();
37
38 CategoryProvider getCategoryProvider(Context context);
39
40 CurrentWallpaperInfoFactory getCurrentWallpaperFactory(Context context);
41
42 ExploreIntentChecker getExploreIntentChecker(Context context);
43
44 FormFactorChecker getFormFactorChecker(Context context);
45
46 LiveWallpaperStatusChecker getLiveWallpaperStatusChecker(Context context);
47
48 LoggingOptInStatusProvider getLoggingOptInStatusProvider(Context context);
49
50 NetworkStatusNotifier getNetworkStatusNotifier(Context context);
51
52 PartnerProvider getPartnerProvider(Context context);
53
54 PerformanceMonitor getPerformanceMonitor();
55
56 Requester getRequester(Context context);
57
58 RotatingWallpaperComponentChecker getRotatingWallpaperComponentChecker();
59
60 SystemFeatureChecker getSystemFeatureChecker();
61
62 UserEventLogger getUserEventLogger(Context context);
63
64 WallpaperManagerCompat getWallpaperManagerCompat(Context context);
65
66 WallpaperPersister getWallpaperPersister(Context context);
67
68 WallpaperPreferences getPreferences(Context context);
69
70 WallpaperRefresher getWallpaperRefresher(Context context);
71
72 WallpaperRotationRefresher getWallpaperRotationRefresher();
Clément Julliardea1638d2018-05-21 19:15:17 -070073
74 Fragment getPreviewFragment(
75 WallpaperInfo wallpaperInfo,
76 @PreviewMode int mode,
77 boolean testingModeEnabled);
Santiago Etchebehere1ee76a22018-05-15 15:02:24 -070078
79 PackageStatusNotifier getPackageStatusNotifier(Context context);
Jon Miranda16ea1b12017-12-12 14:52:48 -080080}