Class TraitCodegenWriter.Factory
- java.lang.Object
-
- software.amazon.smithy.traitcodegen.writer.TraitCodegenWriter.Factory
-
- All Implemented Interfaces:
java.util.function.BiFunction<java.lang.String,java.lang.String,TraitCodegenWriter>
,SymbolWriter.Factory<TraitCodegenWriter>
- Enclosing class:
- TraitCodegenWriter
public static final class TraitCodegenWriter.Factory extends java.lang.Object implements SymbolWriter.Factory<TraitCodegenWriter>
A factory class to createTraitCodegenWriter
s.
-
-
Constructor Summary
Constructors Constructor Description Factory(TraitCodegenSettings settings)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description TraitCodegenWriter
apply(java.lang.String filename, java.lang.String namespace)
Creates aSymbolWriter
of typeW
for the given filename and namespace.
-
-
-
Constructor Detail
-
Factory
public Factory(TraitCodegenSettings settings)
- Parameters:
settings
- The Trait codegen plugin settings.
-
-
Method Detail
-
apply
public TraitCodegenWriter apply(java.lang.String filename, java.lang.String namespace)
Description copied from interface:SymbolWriter.Factory
Creates aSymbolWriter
of typeW
for the given filename and namespace.- Specified by:
apply
in interfacejava.util.function.BiFunction<java.lang.String,java.lang.String,TraitCodegenWriter>
- Specified by:
apply
in interfaceSymbolWriter.Factory<TraitCodegenWriter>
- Parameters:
filename
- Non-null filename of the writer being created.namespace
- Non-null namespace associated with the file (possibly empty string).- Returns:
- Returns the created writer of type
W
.
-
-