All Downloads are FREE. Search and download functionalities are using the official Maven repository.

com.facebook.presto.jdbc.internal.jackson.datatype.joda.deser.key.LocalTimeKeyDeserializer Maven / Gradle / Ivy

There is a newer version: 0.286
Show newest version
package com.facebook.presto.jdbc.internal.jackson.datatype.joda.deser.key;

import java.io.IOException;

import com.facebook.presto.jdbc.internal.jackson.databind.DeserializationContext;

import com.facebook.presto.jdbc.internal.joda.time.LocalTime;
import com.facebook.presto.jdbc.internal.joda.time.format.DateTimeFormatter;
import com.facebook.presto.jdbc.internal.joda.time.format.ISODateTimeFormat;

public class LocalTimeKeyDeserializer extends JodaKeyDeserializer {
    private static final long serialVersionUID = 1L;
    private static final DateTimeFormatter parser = ISODateTimeFormat.localTimeParser();

    @Override
    protected LocalTime deserialize(String key, DeserializationContext ctxt) throws IOException {
        return parser.parseLocalTime(key);
    }
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy