IrModelType

@Serializable
@SerialName(value = "model")
data class IrModelType(val path: String, val nullable: Boolean = false, val optional: Boolean = false, val catchTo: IrCatchTo = IrCatchTo.NoCatch, val maybeError: Boolean = false) : IrNamedType

Parameters

path

a unique path identifying a given model.

  • responseBased: Each dot is a dot in the Json response operationData.$operationName.Data.DroidHero fragmentData.$fragmentName.Data.Hero // interface fragmentData.$fragmentName.Data.OtherHero fragmentData.$fragmentName.Data.DroidHero fragmentData.$fragmentName.Data.HumanHero fragmentData.$fragmentName.Data.HumanHero.CharacterFriend fragmentInterface.$fragmentName.Data.CharacterHero

  • experimental_operationBasedWithInterfaces: operationData.$operationName.Data.Hero // interface operationData.$operationName.Data.DroidHero.OnDroid.HumanFriend.onHuman operationData.$operationName.Data.OtherHero.Starship

Constructors

Link copied to clipboard
constructor(path: String, nullable: Boolean = false, optional: Boolean = false, catchTo: IrCatchTo = IrCatchTo.NoCatch, maybeError: Boolean = false)

Properties

Link copied to clipboard
open override val catchTo: IrCatchTo

reading this type must catch exceptions during parsing

Link copied to clipboard
open override val maybeError: Boolean = false

This type may be an error true if the type is nullable in the server schema. Used to generate error aware adapters

Link copied to clipboard
open override val name: String
Link copied to clipboard
open override val nullable: Boolean = false

This type is nullable in Kotlin

Link copied to clipboard
open override val optional: Boolean = false

This type is optional in Kotlin

Link copied to clipboard

Functions

Link copied to clipboard
open override fun copyWith(maybeError: Boolean, nullable: Boolean, optional: Boolean, catchTo: IrCatchTo): IrType
Link copied to clipboard
fun IrType.nullable(nullable: Boolean): IrType
Link copied to clipboard
fun IrType.optional(optional: Boolean): IrType
Link copied to clipboard
open override fun rawType(): IrModelType