Enum Class ContextAccessType
- All Implemented Interfaces:
Serializable
,Comparable<ContextAccessType>
,Constable
Define the type of context-access performed by an Android method. The context-access is a
combination of context-sensitivity (for read operations) and side-effect information (for write
operations).
- See Also:
-
Nested Class Summary
Nested classes/interfaces inherited from class java.lang.Enum
Enum.EnumDesc<E extends Enum<E>>
-
Enum Constant Summary
Enum ConstantsEnum ConstantDescriptionContext-insensitive, side-effect-free.Context-sensitive, side-effect-free.Context-sensitive, has side-effects.Unknown.Context-insensitive, has side-effects. -
Method Summary
Modifier and TypeMethodDescriptionaddAccess
(ContextAccessType other) static ContextAccessType
get
(boolean ci, boolean sef) boolean
boolean
isCI()
boolean
isSEF()
boolean
reads()
static ContextAccessType
Returns the enum constant of this class with the specified name.static ContextAccessType[]
values()
Returns an array containing the constants of this enum class, in the order they are declared.boolean
writes()
-
Enum Constant Details
-
NONE
Context-insensitive, side-effect-free. -
READ_ONLY
Context-sensitive, side-effect-free. -
WRITE_ONLY
Context-insensitive, has side-effects. -
READ_WRITE
Context-sensitive, has side-effects. -
UNKNOWN
Unknown. Treated as .
-
-
Method Details
-
values
Returns an array containing the constants of this enum class, in the order they are declared.- Returns:
- an array containing the constants of this enum class, in the order they are declared
-
valueOf
Returns the enum constant of this class with the specified name. The string must match exactly an identifier used to declare an enum constant in this class. (Extraneous whitespace characters are not permitted.)- Parameters:
name
- the name of the enum constant to be returned.- Returns:
- the enum constant with the specified name
- Throws:
IllegalArgumentException
- if this enum class has no constant with the specified nameNullPointerException
- if the argument is null
-
isCI
public boolean isCI()- Returns:
- true if the access type is context-insensitive (does not read)
-
reads
public boolean reads()- Returns:
- the opposite of
isCI
-
isSEF
public boolean isSEF()- Returns:
- true if the access type is side-effect-free (does not write)
-
writes
public boolean writes()- Returns:
- the opposite of
isSEF
-
get
-
addAccess
-
isAllAccess
public boolean isAllAccess()
-