• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1 /*
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 
17 package com.android.bedstead.nene;
18 
19 import com.android.bedstead.nene.accessibility.Accessibility;
20 import com.android.bedstead.nene.accounts.Accounts;
21 import com.android.bedstead.nene.activities.Activities;
22 import com.android.bedstead.nene.annotations.Experimental;
23 import com.android.bedstead.nene.bluetooth.Bluetooth;
24 import com.android.bedstead.nene.broadcasts.Broadcasts;
25 import com.android.bedstead.nene.context.Context;
26 import com.android.bedstead.nene.content.Content;
27 import com.android.bedstead.nene.credentials.Credentials;
28 import com.android.bedstead.nene.device.Device;
29 import com.android.bedstead.nene.devicepolicy.DevicePolicy;
30 import com.android.bedstead.nene.flags.Flags;
31 import com.android.bedstead.nene.inputmethods.InputMethods;
32 import com.android.bedstead.nene.instrumentation.Instrumentation;
33 import com.android.bedstead.nene.location.Locations;
34 import com.android.bedstead.nene.logcat.Logcat;
35 import com.android.bedstead.nene.notifications.Notifications;
36 import com.android.bedstead.nene.packages.Packages;
37 import com.android.bedstead.nene.permissions.Permissions;
38 import com.android.bedstead.nene.resources.Resources;
39 import com.android.bedstead.nene.roles.Roles;
40 import com.android.bedstead.nene.services.Services;
41 import com.android.bedstead.nene.settings.Settings;
42 import com.android.bedstead.nene.systemproperties.SystemProperties;
43 import com.android.bedstead.nene.ui.Ui;
44 import com.android.bedstead.nene.users.Users;
45 import com.android.bedstead.nene.wifi.Wifi;
46 
47 /**
48  * Entry point to Nene Test APIs.
49  */
50 public final class TestApis {
51 
52     /** Access Test APIs related to Users. */
users()53     public static Users users() {
54         return Users.sInstance;
55     }
56 
57     /** Access Test APIs related to Packages. */
packages()58     public static Packages packages() {
59         return Packages.sInstance;
60     }
61 
62     /** Access Test APIs related to device policy. */
devicePolicy()63     public static DevicePolicy devicePolicy() {
64         return DevicePolicy.sInstance;
65     }
66 
67     /** Access Test APIs related to permissions. */
permissions()68     public static Permissions permissions() {
69         return Permissions.sInstance;
70     }
71 
72     /** Access Test APIs related to context. */
context()73     public static Context context() {
74         return Context.sInstance;
75     }
76 
77     /** Access Test APIs relating to Settings. */
settings()78     public static Settings settings() {
79         return Settings.sInstance;
80     }
81 
82     /** Access Test APIs related to System Properties. */
systemProperties()83     public static SystemProperties systemProperties() {
84         return SystemProperties.sInstance;
85     }
86 
87     /** Access Test APIs related to activities. */
88     @Experimental
activities()89     public static Activities activities() {
90         return Activities.sInstance;
91     }
92 
93     /** Access Test APIs related to notifications. */
notifications()94     public static Notifications notifications() {
95         return Notifications.sInstance;
96     }
97 
98     /** Access Test APIs related to the device. */
device()99     public static Device device() {
100         return Device.sInstance;
101     }
102 
103     /** Access Test APIs related to location. */
104     @Experimental
location()105     public static Locations location() {
106         return Locations.sInstance;
107     }
108 
109     /** Access Test APIs related to accessibility. */
110     @Experimental
accessibility()111     public static Accessibility accessibility() {
112         return Accessibility.sInstance;
113     }
114 
115     /** Access Test APIs related to bluetooth. */
116     @Experimental
bluetooth()117     public static Bluetooth bluetooth() {
118         return Bluetooth.sInstance;
119     }
120 
121     /** Access Test APIs related to wifi. */
wifi()122     public static Wifi wifi() {
123         return Wifi.sInstance;
124     }
125 
126     /** Access Test APIs related to input methods. */
127     @Experimental
inputMethods()128     public static InputMethods inputMethods() {
129         return InputMethods.sInstance;
130     }
131 
132     /** Access Test APIs related to instrumentation. */
133     @Experimental
instrumentation()134     public static Instrumentation instrumentation() {
135         return Instrumentation.sInstance;
136     }
137 
138     /** Access Test APIs related to roles. */
139     @Experimental
roles()140     public static Roles roles() {
141         return Roles.sInstance;
142     }
143 
144     /** Access Test APIs related to accounts. */
145     @Experimental
accounts()146     public static Accounts accounts() {
147         return Accounts.sInstance;
148     }
149 
150     /** Access Test APIs related to ui. */
151     @Experimental
ui()152     public static Ui ui() {
153         return Ui.sInstance;
154     }
155 
156     /** Access Test APIs related to flags. */
flags()157     public static Flags flags() {
158         return Flags.sInstance;
159     }
160 
161     /** Access Test APIs related to resources. */
resources()162     public static Resources resources() {
163         return Resources.sInstance;
164     }
165 
166     /** Access Test APIs related to broadcasts. */
broadcasts()167     public static Broadcasts broadcasts() {
168         return Broadcasts.sInstance;
169     }
170 
171     /** Access Test APIs related to telecom */
172     @Experimental
telecom()173     public static Telecom telecom() {
174         return Telecom.sInstance;
175     }
176 
177     /** Access Test APIs related to logcat */
178     @Experimental
logcat()179     public static Logcat logcat() {
180         return Logcat.sInstance;
181     }
182 
183     /** Access Test APIs related to credential manager. */
credentials()184     public static Credentials credentials() {
185         return Credentials.sInstance;
186     }
187 
188     /** Access Test APIs related to content. */
content()189     public static Content content() {
190         return Content.sInstance;
191     }
192 
193     /** Access Test APIs related to system services. */
services()194     public static Services services() {
195         return Services.sInstance;
196     }
197 
198     /** @deprecated Use statically */
199     @Deprecated()
TestApis()200     public TestApis() {
201 
202     }
203 }
204