Skip to content

Commit

Permalink
Tidy some compiler errors.
Browse files Browse the repository at this point in the history
  • Loading branch information
pdvrieze committed Nov 28, 2024
1 parent fdf7042 commit 8ab99d3
Showing 1 changed file with 12 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@

package nl.adaptivity.xmlutil.serialization.impl

import kotlinx.serialization.ExperimentalSerializationApi
import kotlinx.serialization.KSerializer
import kotlinx.serialization.descriptors.SerialDescriptor
import kotlinx.serialization.descriptors.SerialKind
Expand Down Expand Up @@ -63,14 +64,20 @@ internal class ShadowPolicy(basePolicy: XmlSerializationPolicy, internal val cac
return basePolicy.polymorphicDiscriminatorName(serializerParent, tagParent)
}

@Suppress("DEPRECATION")
@Deprecated("It is recommended to override serialTypeNameToQName and serialUseNameToQName instead")
override fun serialNameToQName(serialName: String, parentNamespace: Namespace): QName {
return basePolicy.serialNameToQName(serialName, parentNamespace)
}

@Suppress("DEPRECATION")
@Deprecated("Don't use or implement this, use the 3 parameter version")
override fun effectiveOutputKind(serializerParent: SafeParentInfo, tagParent: SafeParentInfo): OutputKind {
return basePolicy.effectiveOutputKind(serializerParent, tagParent)
}

@Suppress("DEPRECATION")
@Deprecated("Use the recoverable version that allows returning a value")
override fun handleUnknownContent(
input: XmlReader,
inputKind: InputKind,
Expand All @@ -88,8 +95,12 @@ internal class ShadowPolicy(basePolicy: XmlSerializationPolicy, internal val cac
get() = basePolicy.defaultPrimitiveOutputKind
override val defaultObjectOutputKind: OutputKind
get() = basePolicy.defaultObjectOutputKind

@Suppress("DEPRECATION")
@Deprecated("Use isStrictAttributeNames instead")
override val isStrictNames: Boolean
get() = basePolicy.isStrictNames

override val isStrictAttributeNames: Boolean
get() = basePolicy.isStrictAttributeNames
override val isStrictBoolean: Boolean
Expand All @@ -101,6 +112,7 @@ internal class ShadowPolicy(basePolicy: XmlSerializationPolicy, internal val cac
override val verifyElementOrder: Boolean
get() = basePolicy.verifyElementOrder

@OptIn(ExperimentalSerializationApi::class)
@ExperimentalXmlUtilApi
override fun defaultOutputKind(serialKind: SerialKind): OutputKind {
return basePolicy.defaultOutputKind(serialKind)
Expand Down

0 comments on commit 8ab99d3

Please sign in to comment.