All Downloads are FREE. Search and download functionalities are using the official Maven repository.

commonMain.tools.ozone.set.Set.kt Maven / Gradle / Ivy

The newest version!
@file:Suppress("DEPRECATION")

package tools.ozone.`set`

import kotlin.String
import kotlin.Suppress
import kotlinx.serialization.Serializable

@Serializable
public data class Set(
  public val name: String,
  public val description: String? = null,
) {
  init {
    require(name.count() >= 3) {
      "name.count() must be >= 3, but was ${name.count()}"
    }
    require(name.count() <= 128) {
      "name.count() must be <= 128, but was ${name.count()}"
    }
    require(description == null || description.count() <= 10_240) {
      "description.count() must be <= 10_240, but was ${description?.count()}"
    }
  }
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy