Guide

@Target(allowedTargets = [AnnotationTarget.VALUE_PARAMETERAnnotationTarget.FIELD])
annotation Guide


Annotates a field to provide a additional information when generating the field.

This is an experimental feature.

Summary

Public constructors

Guide(
    description: String,
    maxItems: Int,
    minItems: Int,
    maximum: Double,
    minimum: Double,
    enumValues: Array<String>
)

Public properties

String

Description of the field.

Array<String>

If the field is a String, this is the list of possible values for the field.

Int

If the field is a list, this is the maximum number of items to generate for a list.

Double

If the field is a Int, Long, Float, or Double, this is the maximum value of the field.

Int

If the field is a list, this is the minimum number of items to generate for a list.

Double

If the field is a Int, Long, Float, or Double, this is the minimum value of the field.

Public constructors

Guide

Guide(
    description: String = "",
    maxItems: Int = -1,
    minItems: Int = -1,
    maximum: Double = Double.NaN,
    minimum: Double = Double.NaN,
    enumValues: Array<String> = []
)

Public properties

description

val descriptionString

Description of the field.

enumValues

val enumValuesArray<String>

If the field is a String, this is the list of possible values for the field.

maxItems

val maxItemsInt

If the field is a list, this is the maximum number of items to generate for a list. This must be greater than or equal to 0. A negative value will be ignored.

maximum

val maximumDouble

If the field is a Int, Long, Float, or Double, this is the maximum value of the field.

minItems

val minItemsInt

If the field is a list, this is the minimum number of items to generate for a list. This must be greater than or equal to 0. A negative value will be ignored.

minimum

val minimumDouble

If the field is a Int, Long, Float, or Double, this is the minimum value of the field.