Class SymbolReference.Builder
java.lang.Object
software.amazon.smithy.codegen.core.SymbolReference.Builder
- All Implemented Interfaces:
SmithyBuilder<SymbolReference>
- Enclosing class:
- SymbolReference
public static final class SymbolReference.Builder
extends Object
implements SmithyBuilder<SymbolReference>
Builds a SymbolReference.
-
Method Summary
Modifier and TypeMethodDescriptionAdds an alias to the SymbolReference.build()
Creates an immutable object that is created from the properties that have been set on the builder.options
(Set<SymbolReference.Option> options) Replaces the Set of Options to the SymbolReference.options
(SymbolReference.Option... options) Replaces the array of Options in the SymbolReference.properties
(Map<String, Object> properties) Replaces all of the custom properties.putProperty
(String key, Object value) Sets a specific custom property.removeProperty
(String key) Removes a specific custom property.Sets the Symbol referenced by the SymbolReference.
-
Method Details
-
build
Description copied from interface:SmithyBuilder
Creates an immutable object that is created from the properties that have been set on the builder.- Specified by:
build
in interfaceSmithyBuilder<SymbolReference>
- Returns:
- an instance of T
-
symbol
Sets the Symbol referenced by the SymbolReference.- Parameters:
symbol
- Symbol to reference.- Returns:
- Returns the builder.
-
options
Replaces the Set of Options to the SymbolReference.- Parameters:
options
- Options to add.- Returns:
- Returns the builder.
-
options
Replaces the array of Options in the SymbolReference.- Parameters:
options
- Options to add.- Returns:
- Returns the builder.
-
alias
Adds an alias to the SymbolReference.An alias is used in some programming languages to change the way a symbol is referenced in a source file. Aliases are often used for de-conflicting symbols.
- Parameters:
alias
- Alias to assign the symbol.- Returns:
- Returns the builder.
-
putProperty
Sets a specific custom property.- Parameters:
key
- Key to set.value
- Value to set.- Returns:
- Returns the builder.
-
removeProperty
Removes a specific custom property.- Parameters:
key
- Key to remove.- Returns:
- Returns the builder.
-
properties
Replaces all of the custom properties.- Parameters:
properties
- Custom properties to replace with.- Returns:
- Returns the builder.
-