From 42c96c134d41711f1100efae57bc2361325bfaca Mon Sep 17 00:00:00 2001 From: Kieran Wallbanks Date: Wed, 18 Sep 2024 13:36:19 +0100 Subject: [PATCH] chore: Remove two unused classes --- .../posthog/internal/InstantSerializer.kt | 26 ------------------- .../posthog/internal/PostHogConstants.kt | 4 --- 2 files changed, 30 deletions(-) delete mode 100644 src/main/kotlin/com/noxcrew/posthog/internal/InstantSerializer.kt delete mode 100644 src/main/kotlin/com/noxcrew/posthog/internal/PostHogConstants.kt diff --git a/src/main/kotlin/com/noxcrew/posthog/internal/InstantSerializer.kt b/src/main/kotlin/com/noxcrew/posthog/internal/InstantSerializer.kt deleted file mode 100644 index 6b10a19..0000000 --- a/src/main/kotlin/com/noxcrew/posthog/internal/InstantSerializer.kt +++ /dev/null @@ -1,26 +0,0 @@ -package com.noxcrew.posthog.internal - -import kotlinx.serialization.KSerializer -import kotlinx.serialization.descriptors.PrimitiveKind -import kotlinx.serialization.descriptors.PrimitiveSerialDescriptor -import kotlinx.serialization.descriptors.SerialDescriptor -import kotlinx.serialization.encoding.Decoder -import kotlinx.serialization.encoding.Encoder -import java.time.Instant - -/** Serializer for Java Instant objects using ISO8601. */ -internal object InstantSerializer : KSerializer { - override val descriptor: SerialDescriptor = - PrimitiveSerialDescriptor(InstantSerializer::class.qualifiedName!!, PrimitiveKind.STRING) - - override fun serialize( - encoder: Encoder, - value: Instant, - ) { - encoder.encodeString(value.toString()) - } - - override fun deserialize(decoder: Decoder): Instant { - return Instant.parse(decoder.decodeString()) - } -} diff --git a/src/main/kotlin/com/noxcrew/posthog/internal/PostHogConstants.kt b/src/main/kotlin/com/noxcrew/posthog/internal/PostHogConstants.kt deleted file mode 100644 index 8a11652..0000000 --- a/src/main/kotlin/com/noxcrew/posthog/internal/PostHogConstants.kt +++ /dev/null @@ -1,4 +0,0 @@ -package com.noxcrew.posthog.internal - -/** A collection of PostHog constants. */ -internal object PostHogConstants