javapoet-dsl / com.mostlycertain.javapoetdsl / fieldSpec
fieldSpec
fun fieldSpec(type: TypeName, name: String, modifiers: List<Modifier> = emptyList(), annotations: List<AnnotationSpec> = emptyList(), initializer: CodeExpression? = null): FieldSpec
fun fieldSpec(type: Type, name: String, modifiers: List<Modifier> = emptyList(), annotations: List<AnnotationSpec> = emptyList(), initializer: CodeExpression? = null): FieldSpec
fun fieldSpec(type: KClass<*>, name: String, modifiers: List<Modifier> = emptyList(), annotations: List<AnnotationSpec> = emptyList(), initializer: CodeExpression? = null): FieldSpec