From e97a3e9e9629e199dac041a732e4442c6481da2f Mon Sep 17 00:00:00 2001 From: usbharu <64310155+usbharu@users.noreply.github.com> Date: Thu, 30 Mar 2023 19:36:19 +0900 Subject: [PATCH] =?UTF-8?q?feat:=20=E3=81=A7=E3=82=B7=E3=83=AA=E3=82=A2?= =?UTF-8?q?=E3=83=A9=E3=82=A4=E3=82=B6=E3=83=BC=E3=82=92=E5=A4=89=E6=9B=B4?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/main/kotlin/dev/usbharu/hideout/ap/JsonLd.kt | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/src/main/kotlin/dev/usbharu/hideout/ap/JsonLd.kt b/src/main/kotlin/dev/usbharu/hideout/ap/JsonLd.kt index 951bf00f..2cda262c 100644 --- a/src/main/kotlin/dev/usbharu/hideout/ap/JsonLd.kt +++ b/src/main/kotlin/dev/usbharu/hideout/ap/JsonLd.kt @@ -3,10 +3,14 @@ package dev.usbharu.hideout.ap import com.fasterxml.jackson.annotation.JsonAutoDetect import com.fasterxml.jackson.annotation.JsonCreator import com.fasterxml.jackson.annotation.JsonProperty +import com.fasterxml.jackson.core.TreeNode +import com.fasterxml.jackson.databind.JsonDeserializer +import com.fasterxml.jackson.databind.annotation.JsonDeserialize @JsonAutoDetect(fieldVisibility = JsonAutoDetect.Visibility.ANY) open class JsonLd { @JsonProperty("@context") + @JsonDeserialize(using = ContextDeserializer::class) var context:List = emptyList() @JsonCreator @@ -16,3 +20,9 @@ open class JsonLd { protected constructor() } + +public class ContextDeserializer : JsonDeserializer>() { + override fun deserialize(p0: com.fasterxml.jackson.core.JsonParser?, p1: com.fasterxml.jackson.databind.DeserializationContext?): List { + return emptyList() + } +}