Package software.amazon.smithy.utils
Interface CodeSection
-
- All Known Implementing Classes:
ClassSection
,EnumVariantSection
,GetterSection
,JavaDocSection
public interface CodeSection
Interface used for strongly typedAbstractCodeWriter
section values.
-
-
Method Summary
All Methods Static Methods Instance Methods Default Methods Modifier and Type Method Description static CodeSection
forName(java.lang.String sectionName)
Creates a CodeSection that returns the givensectionName
.default java.lang.String
sectionName()
Gets the name of the section.
-
-
-
Method Detail
-
sectionName
default java.lang.String sectionName()
Gets the name of the section.This class will return the canonical class of the implementing class by default.
- Returns:
- Returns the section name.
-
forName
static CodeSection forName(java.lang.String sectionName)
Creates a CodeSection that returns the givensectionName
.- Parameters:
sectionName
- Section name to provide whensectionName
is called on the created CodeSection.- Returns:
- Returns CodeSection that uses the provided name.
-
-