com.facebook.presto.jdbc.internal.jackson.datatype.jsr310.deser.JSR310StringParsableDeserializer Maven / Gradle / Ivy
/*
* Copyright 2013 FasterXML.com
*
* Licensed under the Apache License, Version 2.0 (the "License"); you may
* not use this file except in compliance with the License. You may obtain
* a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the license for the specific language governing permissions and
* limitations under the license.
*/
package com.facebook.presto.jdbc.internal.jackson.datatype.jsr310.deser;
import java.io.IOException;
import java.time.DateTimeException;
import java.time.Period;
import java.time.ZoneId;
import java.time.ZoneOffset;
import com.facebook.presto.jdbc.internal.jackson.core.JsonParser;
import com.facebook.presto.jdbc.internal.jackson.core.JsonToken;
import com.facebook.presto.jdbc.internal.jackson.databind.DeserializationContext;
import com.facebook.presto.jdbc.internal.jackson.databind.JsonDeserializer;
import com.facebook.presto.jdbc.internal.jackson.databind.jsontype.TypeDeserializer;
/**
* Deserializer for all Java 8 temporal {@link java.time} types that cannot be represented
* with numbers and that have parse functions that can take {@link String}s,
* and where format is not configurable.
*
* @author Nick Williams
* @author Tatu Saloranta
*
* @since 2.2
*/
public class JSR310StringParsableDeserializer
extends JSR310DeserializerBase