Skip to content

Commit

Permalink
add kdoc
Browse files Browse the repository at this point in the history
  • Loading branch information
jangalinski committed Sep 11, 2024
1 parent 9f29a89 commit 48119a9
Showing 1 changed file with 10 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -13,12 +13,21 @@ class AnnotationSpecBuilder(
AnnotationSpecSupplier,
PoetTaggableBuilder<AnnotationSpecBuilder> {
companion object {
fun AnnotationSpec.Builder.wrap() = AnnotationSpecBuilder(this)
internal fun AnnotationSpec.Builder.wrap() = AnnotationSpecBuilder(this)

/**
* Creates new builder.
*/
fun builder(type: ClassName): AnnotationSpecBuilder = AnnotationSpec.builder(type).wrap()

/**
* Creates new builder.
*/
fun builder(type: ParameterizedTypeName): AnnotationSpecBuilder = AnnotationSpec.builder(type).wrap()

/**
* Creates new builder.
*/
fun builder(type: KClass<out Annotation>): AnnotationSpecBuilder = builder(type.asClassName())
}

Expand Down

0 comments on commit 48119a9

Please sign in to comment.