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

commonMain.app.bsky.unspecced.searchPostsSkeletonToken.kt Maven / Gradle / Ivy

The newest version!
package app.bsky.unspecced

import kotlin.String
import kotlinx.serialization.KSerializer
import kotlinx.serialization.Serializable
import sh.christian.ozone.api.model.AtpEnum
import sh.christian.ozone.api.runtime.stringEnumSerializer

public class SearchPostsSkeletonSortSerializer : KSerializer by stringEnumSerializer(SearchPostsSkeletonSort::safeValueOf)

/**
 * Specifies the ranking order of results.
 */
@Serializable(with = SearchPostsSkeletonSortSerializer::class)
public sealed class SearchPostsSkeletonSort(
  override val `value`: String,
) : AtpEnum() {
  public data object Top : SearchPostsSkeletonSort("top")

  public data object Latest : SearchPostsSkeletonSort("latest")

  public data class Unknown(
    public val rawValue: String,
  ) : SearchPostsSkeletonSort(rawValue)

  public companion object {
    public fun safeValueOf(`value`: String): SearchPostsSkeletonSort = when (value) {
      "top" -> Top
      "latest" -> Latest
      else -> Unknown(value)
    }
  }
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy