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

commonMain.app.bsky.feed.getAuthorFeedToken.kt Maven / Gradle / Ivy

The newest version!
package app.bsky.feed

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 GetAuthorFeedFilterSerializer : KSerializer by 
    stringEnumSerializer(GetAuthorFeedFilter::safeValueOf)

@Serializable(with = GetAuthorFeedFilterSerializer::class)
public sealed class GetAuthorFeedFilter(
  override val `value`: String,
) : AtpEnum() {
  public data object PostsWithReplies : GetAuthorFeedFilter("posts_with_replies")

  public data object PostsNoReplies : GetAuthorFeedFilter("posts_no_replies")

  public data object PostsWithMedia : GetAuthorFeedFilter("posts_with_media")

  public data object PostsAndAuthorThreads : GetAuthorFeedFilter("posts_and_author_threads")

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

  public companion object {
    public fun safeValueOf(`value`: String): GetAuthorFeedFilter = when (value) {
      "posts_with_replies" -> PostsWithReplies
      "posts_no_replies" -> PostsNoReplies
      "posts_with_media" -> PostsWithMedia
      "posts_and_author_threads" -> PostsAndAuthorThreads
      else -> Unknown(value)
    }
  }
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy