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

commonMain.tools.ozone.setting.Option.kt Maven / Gradle / Ivy

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

package tools.ozone.setting

import kotlin.String
import kotlin.Suppress
import kotlinx.serialization.Serializable
import sh.christian.ozone.api.Did
import sh.christian.ozone.api.Nsid
import sh.christian.ozone.api.model.JsonContent
import sh.christian.ozone.api.model.Timestamp

@Serializable
public data class Option(
  public val key: Nsid,
  public val did: Did,
  public val `value`: JsonContent,
  public val description: String? = null,
  public val createdAt: Timestamp? = null,
  public val updatedAt: Timestamp? = null,
  public val managerRole: String? = null,
  public val scope: Scope,
  public val createdBy: Did,
  public val lastUpdatedBy: Did,
) {
  init {
    require(description == null || description.count() <= 10_240) {
      "description.count() must be <= 10_240, but was ${description?.count()}"
    }
  }
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy