blob: 6e2f9b4480e0c407aa176b1a0726c51f30ef62e3 [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
Clément Julliardea1638d2018-05-21 19:15:17 -070020import android.support.v4.app.Fragment;
Jon Miranda16ea1b12017-12-12 14:52:48 -080021import com.android.wallpaper.compat.WallpaperManagerCompat;
22import com.android.wallpaper.model.CategoryProvider;
Clément Julliardea1638d2018-05-21 19:15:17 -070023import com.android.wallpaper.model.WallpaperInfo;
Jon Miranda16ea1b12017-12-12 14:52:48 -080024import com.android.wallpaper.monitor.PerformanceMonitor;
25import com.android.wallpaper.network.Requester;
Clément Julliardea1638d2018-05-21 19:15:17 -070026import com.android.wallpaper.picker.PreviewFragment.PreviewMode;
Jon Miranda16ea1b12017-12-12 14:52:48 -080027
28/**
29 * Interface for a provider of "injected dependencies." (NOTE: The term "injector" is somewhat of a
30 * misnomer; this is more aptly a service registry as part of a service locator design pattern.)
31 */
32public interface Injector {
33 AlarmManagerWrapper getAlarmManagerWrapper(Context context);
34
35 BitmapCropper getBitmapCropper();
36
37 CategoryProvider getCategoryProvider(Context context);
38
39 CurrentWallpaperInfoFactory getCurrentWallpaperFactory(Context context);
40
41 ExploreIntentChecker getExploreIntentChecker(Context context);
42
43 FormFactorChecker getFormFactorChecker(Context context);
44
45 LiveWallpaperStatusChecker getLiveWallpaperStatusChecker(Context context);
46
47 LoggingOptInStatusProvider getLoggingOptInStatusProvider(Context context);
48
49 NetworkStatusNotifier getNetworkStatusNotifier(Context context);
50
51 PartnerProvider getPartnerProvider(Context context);
52
53 PerformanceMonitor getPerformanceMonitor();
54
55 Requester getRequester(Context context);
56
57 RotatingWallpaperComponentChecker getRotatingWallpaperComponentChecker();
58
59 SystemFeatureChecker getSystemFeatureChecker();
60
61 UserEventLogger getUserEventLogger(Context context);
62
63 WallpaperManagerCompat getWallpaperManagerCompat(Context context);
64
65 WallpaperPersister getWallpaperPersister(Context context);
66
67 WallpaperPreferences getPreferences(Context context);
68
69 WallpaperRefresher getWallpaperRefresher(Context context);
70
71 WallpaperRotationRefresher getWallpaperRotationRefresher();
Clément Julliardea1638d2018-05-21 19:15:17 -070072
73 Fragment getPreviewFragment(
74 WallpaperInfo wallpaperInfo,
75 @PreviewMode int mode,
76 boolean testingModeEnabled);
Santiago Etchebehere1ee76a22018-05-15 15:02:24 -070077
78 PackageStatusNotifier getPackageStatusNotifier(Context context);
Jon Miranda16ea1b12017-12-12 14:52:48 -080079}