# HikageView

@ Target (allowedTargets = [ AnnotationTarget.CLASS ])
annotation class HikageView (val lparams: KClass <*> = Any::class, val alias: String = "", val requireInit: Boolean = false, val requirePerformer: Boolean = false, val final: Boolean = false)

Declare annotations to generate the Hikage.Performer function for the specified View at compile time.

Usage:

    @HikageView(lparams = FrameLayout.LayoutParams::class, alias = "MyView")
    class MyView(context: Context, attrs: AttributeSet?) : FrameLayout(context, attrs) {
        // ...
    }

Content copied to clipboard

#### Parameters

lparams

the layout params class, only ViewGroup can be specified, after specifying, the `performer` parameter will be generated for the function. The parameters must be a class inherited from ViewGroup.LayoutParams, if the current View does not inherit from ViewGroup, this parameter will be ignored and warned.

alias

the view's class name alias will naming the function, default is the class name.

requireInit

whether to force the `init` parameter to be called, default is false.

requirePerformer

whether to force the `performer` parameter to be called, default is false, this parameter will be ignored when no `performer` parameter is needed here.

final

whether to declare this layout as "final layout", default is false, that is, whether this layout inherits from or is ViewGroup, the `performer` parameter will not be generated. After set to `true`, lparams and requirePerformer will no longer be valid.

## Properties

alias
Link copied to clipboard
val alias : String
final
Link copied to clipboard
val final : Boolean = false
lparams
Link copied to clipboard
val lparams : KClass <*>
requireInit
Link copied to clipboard
val requireInit : Boolean = false
requirePerformer
Link copied to clipboard
val requirePerformer : Boolean = false