Enum Class SymbolReference.ContextOption
java.lang.Object
java.lang.Enum<SymbolReference.ContextOption>
software.amazon.smithy.codegen.core.SymbolReference.ContextOption
- All Implemented Interfaces:
Serializable
,Comparable<SymbolReference.ContextOption>
,Constable
,SymbolReference.Option
- Enclosing class:
- SymbolReference
public static enum SymbolReference.ContextOption
extends Enum<SymbolReference.ContextOption>
implements SymbolReference.Option
Options used to control the context of when the symbol reference is needed.
These context options are used to define the context in which one symbol refers to another. For example, if a reference is only needed when the symbol is defined and not needed when the symbol is used, then code generators can automatically add the necessary imports for each circumstance.
-
Nested Class Summary
Nested classes/interfaces inherited from class java.lang.Enum
Enum.EnumDesc<E extends Enum<E>>
-
Enum Constant Summary
-
Method Summary
Modifier and TypeMethodDescriptionReturns the enum constant of this class with the specified name.static SymbolReference.ContextOption[]
values()
Returns an array containing the constants of this enum class, in the order they are declared.
-
Enum Constant Details
-
DECLARE
Indicates that the referenced symbol is needed when declaring the symbol. -
USE
Indicates that the referenced symbol is needed when importing/using the symbol.
-
-
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
-