1 /* 2 * Copyright 2018 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 androidx.work; 18 19 /** 20 * The type of network required by a unit of work. 21 */ 22 public enum NetworkType { 23 24 /** 25 * A network is not required for this work. 26 */ 27 NOT_REQUIRED, 28 29 /** 30 * Any working network connection is required for this work. 31 */ 32 CONNECTED, 33 34 /** 35 * An unmetered network connection is required for this work. 36 */ 37 UNMETERED, 38 39 /** 40 * A non-roaming network connection is required for this work. 41 */ 42 NOT_ROAMING, 43 44 /** 45 * A metered network connection is required for this work. 46 */ 47 METERED 48 } 49