ScalarType

sealed class ScalarType

A scalar type for a field in a Prisma schema.

Types defined here are more precise than Prisma's own types. Because Kotlin has more precise typing, we can use Prisma's "basic" type (e.g. String, Int...) and the @db. attributes (e.g. @db.Text) to retrieve the fully accurate type.

Inheritors

Types

Link copied to clipboard
data class TBinary(val maxSize: Int?) : ScalarType
Link copied to clipboard
Link copied to clipboard
object TByte : ScalarType
Link copied to clipboard
data class TChar(val n: Int) : ScalarType
Link copied to clipboard
data class TDecimal(precisionAndScale: Pair<Int, Int>?) : ScalarType
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
object TInt : ScalarType
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
object TLong : ScalarType
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
object TText : ScalarType
Link copied to clipboard
Link copied to clipboard
object TUInt : ScalarType
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
object TUuid : ScalarType
Link copied to clipboard
data class TVarChar(val n: Int) : ScalarType

Functions

Link copied to clipboard

Create an accurate ScalarTypeWithAccuracy with this being the scalar type.

Link copied to clipboard

Create an inaccurate ScalarTypeWithAccuracy with this being the scalar type and the given reason.