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

commonMain.sh.christian.ozone.api.xrpc.XrpcSerializersModule.kt Maven / Gradle / Ivy

The newest version!
package sh.christian.ozone.api.xrpc

import app.bsky.actor.PreferencesUnion
import app.bsky.actor.ProfileLabelsUnion
import app.bsky.embed.RecordViewRecordEmbedUnion
import app.bsky.embed.RecordViewRecordUnion
import app.bsky.embed.RecordWithMediaMediaUnion
import app.bsky.embed.RecordWithMediaViewMediaUnion
import app.bsky.feed.FeedViewPostReasonUnion
import app.bsky.feed.GeneratorLabelsUnion
import app.bsky.feed.GetPostThreadResponseThreadUnion
import app.bsky.feed.PostEmbedUnion
import app.bsky.feed.PostLabelsUnion
import app.bsky.feed.PostViewEmbedUnion
import app.bsky.feed.PostgateEmbeddingRuleUnion
import app.bsky.feed.ReplyRefParentUnion
import app.bsky.feed.ReplyRefRootUnion
import app.bsky.feed.SkeletonFeedPostReasonUnion
import app.bsky.feed.ThreadViewPostParentUnion
import app.bsky.feed.ThreadViewPostReplieUnion
import app.bsky.feed.ThreadgateAllowUnion
import app.bsky.graph.GetRelationshipsResponseRelationshipUnion
import app.bsky.graph.ListLabelsUnion
import app.bsky.labeler.GetServicesResponseViewUnion
import app.bsky.labeler.ServiceLabelsUnion
import app.bsky.richtext.FacetFeatureUnion
import chat.bsky.convo.ConvoViewLastMessageUnion
import chat.bsky.convo.GetLogResponseLogUnion
import chat.bsky.convo.GetMessagesResponseMessageUnion
import chat.bsky.convo.LogCreateMessageMessageUnion
import chat.bsky.convo.LogDeleteMessageMessageUnion
import chat.bsky.convo.MessageInputEmbedUnion
import chat.bsky.convo.MessageViewEmbedUnion
import chat.bsky.moderation.GetMessageContextResponseMessageUnion
import com.atproto.admin.GetSubjectStatusResponseSubjectUnion
import com.atproto.admin.UpdateSubjectStatusRequestSubjectUnion
import com.atproto.admin.UpdateSubjectStatusResponseSubjectUnion
import com.atproto.label.SubscribeLabelsMessageUnion
import com.atproto.moderation.CreateReportRequestSubjectUnion
import com.atproto.moderation.CreateReportResponseSubjectUnion
import com.atproto.repo.ApplyWritesRequestWriteUnion
import com.atproto.repo.ApplyWritesResponseResultUnion
import com.atproto.sync.SubscribeReposMessageUnion
import kotlinx.serialization.modules.SerializersModule
import kotlinx.serialization.modules.polymorphic
import tools.ozone.moderation.BlobViewDetailsUnion
import tools.ozone.moderation.EmitEventRequestEventUnion
import tools.ozone.moderation.EmitEventRequestSubjectUnion
import tools.ozone.moderation.GetRecordsResponseRecordUnion
import tools.ozone.moderation.GetReposResponseRepoUnion
import tools.ozone.moderation.ModEventViewDetailEventUnion
import tools.ozone.moderation.ModEventViewDetailSubjectUnion
import tools.ozone.moderation.ModEventViewEventUnion
import tools.ozone.moderation.ModEventViewSubjectUnion
import tools.ozone.moderation.SubjectStatusViewHostingUnion
import tools.ozone.moderation.SubjectStatusViewSubjectUnion

/**
 * SerializersModule to decode unknown values for union reference types.
 */
public val XrpcSerializersModule: SerializersModule = SerializersModule {
  polymorphic(CreateReportRequestSubjectUnion::class) {
    defaultDeserializer { CreateReportRequestSubjectUnion.Unknown.serializer() }
  }
  polymorphic(CreateReportResponseSubjectUnion::class) {
    defaultDeserializer { CreateReportResponseSubjectUnion.Unknown.serializer() }
  }
  polymorphic(ApplyWritesRequestWriteUnion::class) {
    defaultDeserializer { ApplyWritesRequestWriteUnion.Unknown.serializer() }
  }
  polymorphic(ApplyWritesResponseResultUnion::class) {
    defaultDeserializer { ApplyWritesResponseResultUnion.Unknown.serializer() }
  }
  polymorphic(SubscribeReposMessageUnion::class) {
    defaultDeserializer { SubscribeReposMessageUnion.Unknown.serializer() }
  }
  polymorphic(SubscribeLabelsMessageUnion::class) {
    defaultDeserializer { SubscribeLabelsMessageUnion.Unknown.serializer() }
  }
  polymorphic(UpdateSubjectStatusRequestSubjectUnion::class) {
    defaultDeserializer { UpdateSubjectStatusRequestSubjectUnion.Unknown.serializer() }
  }
  polymorphic(UpdateSubjectStatusResponseSubjectUnion::class) {
    defaultDeserializer { UpdateSubjectStatusResponseSubjectUnion.Unknown.serializer() }
  }
  polymorphic(GetSubjectStatusResponseSubjectUnion::class) {
    defaultDeserializer { GetSubjectStatusResponseSubjectUnion.Unknown.serializer() }
  }
  polymorphic(GetMessageContextResponseMessageUnion::class) {
    defaultDeserializer { GetMessageContextResponseMessageUnion.Unknown.serializer() }
  }
  polymorphic(GetMessagesResponseMessageUnion::class) {
    defaultDeserializer { GetMessagesResponseMessageUnion.Unknown.serializer() }
  }
  polymorphic(GetLogResponseLogUnion::class) {
    defaultDeserializer { GetLogResponseLogUnion.Unknown.serializer() }
  }
  polymorphic(MessageInputEmbedUnion::class) {
    defaultDeserializer { MessageInputEmbedUnion.Unknown.serializer() }
  }
  polymorphic(MessageViewEmbedUnion::class) {
    defaultDeserializer { MessageViewEmbedUnion.Unknown.serializer() }
  }
  polymorphic(ConvoViewLastMessageUnion::class) {
    defaultDeserializer { ConvoViewLastMessageUnion.Unknown.serializer() }
  }
  polymorphic(LogCreateMessageMessageUnion::class) {
    defaultDeserializer { LogCreateMessageMessageUnion.Unknown.serializer() }
  }
  polymorphic(LogDeleteMessageMessageUnion::class) {
    defaultDeserializer { LogDeleteMessageMessageUnion.Unknown.serializer() }
  }
  polymorphic(GetServicesResponseViewUnion::class) {
    defaultDeserializer { GetServicesResponseViewUnion.Unknown.serializer() }
  }
  polymorphic(ServiceLabelsUnion::class) {
    defaultDeserializer { ServiceLabelsUnion.Unknown.serializer() }
  }
  polymorphic(ProfileLabelsUnion::class) {
    defaultDeserializer { ProfileLabelsUnion.Unknown.serializer() }
  }
  polymorphic(PreferencesUnion::class) {
    defaultDeserializer { PreferencesUnion.Unknown.serializer() }
  }
  polymorphic(FacetFeatureUnion::class) {
    defaultDeserializer { FacetFeatureUnion.Unknown.serializer() }
  }
  polymorphic(PostEmbedUnion::class) {
    defaultDeserializer { PostEmbedUnion.Unknown.serializer() }
  }
  polymorphic(PostLabelsUnion::class) {
    defaultDeserializer { PostLabelsUnion.Unknown.serializer() }
  }
  polymorphic(GetPostThreadResponseThreadUnion::class) {
    defaultDeserializer { GetPostThreadResponseThreadUnion.Unknown.serializer() }
  }
  polymorphic(ThreadgateAllowUnion::class) {
    defaultDeserializer { ThreadgateAllowUnion.Unknown.serializer() }
  }
  polymorphic(PostgateEmbeddingRuleUnion::class) {
    defaultDeserializer { PostgateEmbeddingRuleUnion.Unknown.serializer() }
  }
  polymorphic(PostViewEmbedUnion::class) {
    defaultDeserializer { PostViewEmbedUnion.Unknown.serializer() }
  }
  polymorphic(FeedViewPostReasonUnion::class) {
    defaultDeserializer { FeedViewPostReasonUnion.Unknown.serializer() }
  }
  polymorphic(ReplyRefRootUnion::class) {
    defaultDeserializer { ReplyRefRootUnion.Unknown.serializer() }
  }
  polymorphic(ReplyRefParentUnion::class) {
    defaultDeserializer { ReplyRefParentUnion.Unknown.serializer() }
  }
  polymorphic(ThreadViewPostParentUnion::class) {
    defaultDeserializer { ThreadViewPostParentUnion.Unknown.serializer() }
  }
  polymorphic(ThreadViewPostReplieUnion::class) {
    defaultDeserializer { ThreadViewPostReplieUnion.Unknown.serializer() }
  }
  polymorphic(SkeletonFeedPostReasonUnion::class) {
    defaultDeserializer { SkeletonFeedPostReasonUnion.Unknown.serializer() }
  }
  polymorphic(GeneratorLabelsUnion::class) {
    defaultDeserializer { GeneratorLabelsUnion.Unknown.serializer() }
  }
  polymorphic(GetRelationshipsResponseRelationshipUnion::class) {
    defaultDeserializer { GetRelationshipsResponseRelationshipUnion.Unknown.serializer() }
  }
  polymorphic(ListLabelsUnion::class) {
    defaultDeserializer { ListLabelsUnion.Unknown.serializer() }
  }
  polymorphic(RecordWithMediaMediaUnion::class) {
    defaultDeserializer { RecordWithMediaMediaUnion.Unknown.serializer() }
  }
  polymorphic(RecordWithMediaViewMediaUnion::class) {
    defaultDeserializer { RecordWithMediaViewMediaUnion.Unknown.serializer() }
  }
  polymorphic(RecordViewRecordUnion::class) {
    defaultDeserializer { RecordViewRecordUnion.Unknown.serializer() }
  }
  polymorphic(RecordViewRecordEmbedUnion::class) {
    defaultDeserializer { RecordViewRecordEmbedUnion.Unknown.serializer() }
  }
  polymorphic(GetReposResponseRepoUnion::class) {
    defaultDeserializer { GetReposResponseRepoUnion.Unknown.serializer() }
  }
  polymorphic(EmitEventRequestEventUnion::class) {
    defaultDeserializer { EmitEventRequestEventUnion.Unknown.serializer() }
  }
  polymorphic(EmitEventRequestSubjectUnion::class) {
    defaultDeserializer { EmitEventRequestSubjectUnion.Unknown.serializer() }
  }
  polymorphic(GetRecordsResponseRecordUnion::class) {
    defaultDeserializer { GetRecordsResponseRecordUnion.Unknown.serializer() }
  }
  polymorphic(ModEventViewEventUnion::class) {
    defaultDeserializer { ModEventViewEventUnion.Unknown.serializer() }
  }
  polymorphic(ModEventViewSubjectUnion::class) {
    defaultDeserializer { ModEventViewSubjectUnion.Unknown.serializer() }
  }
  polymorphic(ModEventViewDetailEventUnion::class) {
    defaultDeserializer { ModEventViewDetailEventUnion.Unknown.serializer() }
  }
  polymorphic(ModEventViewDetailSubjectUnion::class) {
    defaultDeserializer { ModEventViewDetailSubjectUnion.Unknown.serializer() }
  }
  polymorphic(SubjectStatusViewSubjectUnion::class) {
    defaultDeserializer { SubjectStatusViewSubjectUnion.Unknown.serializer() }
  }
  polymorphic(SubjectStatusViewHostingUnion::class) {
    defaultDeserializer { SubjectStatusViewHostingUnion.Unknown.serializer() }
  }
  polymorphic(BlobViewDetailsUnion::class) {
    defaultDeserializer { BlobViewDetailsUnion.Unknown.serializer() }
  }
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy