com.tradeshift.sdk.linelinker.json.IDDeserializer Maven / Gradle / Ivy
The newest version!
/*
* Copyright (c) 2018 Tradeshift Inc. and/or its affiliates. All rights reserved.
*/
package com.tradeshift.sdk.linelinker.json;
import java.io.IOException;
import com.fasterxml.jackson.core.JsonParser;
import com.fasterxml.jackson.core.JsonProcessingException;
import com.fasterxml.jackson.databind.DeserializationContext;
import com.fasterxml.jackson.databind.JsonDeserializer;
import com.tradeshift.sdk.core.domain.ID;
public class IDDeserializer extends JsonDeserializer {
@Override
public ID deserialize(JsonParser jsonParser, DeserializationContext deserializationContext)
throws IOException, JsonProcessingException {
return ID.fromString(jsonParser.getValueAsString());
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy