public final class

AirplaneModeSettings

extends Object
implements Parcelable
java.lang.Object
   ↳ lineageos.profiles.AirplaneModeSettings

Class Overview

The AirplaneModeSettings class allows for overriding and setting the airplane mode.

Example for setting the airplane mode to enabled:

 AirplaneModeSettings airplaneMode = new AirplaneModeSettings(BooleanState.STATE_ENABLED, true)
 profile.setAirplaneMode(airplaneMode);
 

Summary

Nested Classes
class AirplaneModeSettings.BooleanState BooleanStates for specific AirplaneModeSettings  
[Expand]
Inherited Constants
From interface android.os.Parcelable
Public Constructors
AirplaneModeSettings(Parcel parcel)
Unwrap AirplaneModeSettings from a parcel.
AirplaneModeSettings()
Construct a AirplaneModeSettings with a default value of STATE_DISALED.
AirplaneModeSettings(int value, boolean override)
Construct a AirplaneModeSettings with a default value and whether or not it should override user settings.
Public Methods
int describeContents()
int getValue()
Get the default value for the AirplaneModeSettings
boolean isOverride()
Check whether or not the AirplaneModeSettings overrides user settings.
void setOverride(boolean override)
Set whether or not the AirplaneModeSettings should override default user values
void setValue(int value)
Set the default value for the AirplaneModeSettings
[Expand]
Inherited Methods
From class java.lang.Object
From interface android.os.Parcelable

Public Constructors

public AirplaneModeSettings (Parcel parcel)

added in API level 2

Unwrap AirplaneModeSettings from a parcel.

public AirplaneModeSettings ()

added in API level 2

Construct a AirplaneModeSettings with a default value of STATE_DISALED.

public AirplaneModeSettings (int value, boolean override)

added in API level 2

Construct a AirplaneModeSettings with a default value and whether or not it should override user settings.

Parameters
value int: ex: STATE_DISALED
override boolean: whether or not the setting should override user settings

Public Methods

public int describeContents ()

added in API level 2

Returns
int

public int getValue ()

added in API level 2

Get the default value for the AirplaneModeSettings

Returns
int integer value corresponding with its brightness value

public boolean isOverride ()

added in API level 2

Check whether or not the AirplaneModeSettings overrides user settings.

Returns
boolean true if override

public void setOverride (boolean override)

added in API level 2

Set whether or not the AirplaneModeSettings should override default user values

Parameters
override boolean: boolean override

public void setValue (int value)

added in API level 2

Set the default value for the AirplaneModeSettings

Parameters
value int: STATE_DISALED