class ObjectWriterImplLocalTime
        extends DateTimeCodec
        implements ObjectWriter {
    static final ObjectWriterImplLocalTime INSTANCE = new ObjectWriterImplLocalTime(null, null);

    public ObjectWriterImplLocalTime(String format, Locale locale) {
        super(format, locale);
    }

    @Override
    public void writeJSONB(JSONWriter jsonWriter, Object object, Object fieldName, Type fieldType, long features) {
        jsonWriter.writeLocalTime((LocalTime) object);
    }

    @Override
    public void write(JSONWriter jsonWriter, Object object, Object fieldName, Type fieldType, long features) {<FILL_FUNCTION_BODY>}
}

        if (object == null) {
            jsonWriter.writeNull();
            return;
        }

        JSONWriter.Context ctx = jsonWriter.context;

        LocalTime time = (LocalTime) object;

        if (formatMillis || (format == null && ctx.isDateFormatMillis())) {
            LocalDateTime dateTime = LocalDateTime.of(
                    LocalDate.of(1970, 1, 1),
                    time
            );
            Instant instant = dateTime.atZone(ctx.getZoneId()).toInstant();
            long millis = instant.toEpochMilli();
            jsonWriter.writeInt64(millis);
            return;
        }

        if (formatUnixTime || (format == null && ctx.isDateFormatUnixTime())) {
            LocalDateTime dateTime = LocalDateTime.of(
                    LocalDate.of(1970, 1, 1),
                    time
            );
            Instant instant = dateTime.atZone(ctx.getZoneId()).toInstant();
            int seconds = (int) (instant.toEpochMilli() / 1000);
            jsonWriter.writeInt32(seconds);
            return;
        }

        DateTimeFormatter formatter = this.getDateFormatter();
        if (formatter == null) {
            formatter = ctx.getDateFormatter();
        }

        if (formatter == null) {
            int hour = time.getHour();
            int minute = time.getMinute();
            int second = time.getSecond();
            int nano = time.getNano();
            if (nano == 0) {
                jsonWriter.writeTimeHHMMSS8(hour, minute, second);
            } else {
                jsonWriter.writeLocalTime(time);
            }
            return;
        }

        String str;
        if (formatHasDay || ctx.isDateFormatHasDay()) {
            str = formatter.format(LocalDateTime.of(LocalDate.of(1970, 1, 1), time));
        } else {
            str = formatter.format(time);
        }
        jsonWriter.writeString(str);
    
<methods>public void <init>(java.lang.String) ,public void <init>(java.lang.String, java.util.Locale) ,public java.time.format.DateTimeFormatter getDateFormatter() ,public java.time.format.DateTimeFormatter getDateFormatter(java.util.Locale) <variables>java.time.format.DateTimeFormatter dateFormatter,public final non-sealed java.lang.String format,protected final non-sealed boolean formatHasDay,protected final non-sealed boolean formatHasHour,public final non-sealed boolean formatISO8601,public final non-sealed boolean formatMillis,public final non-sealed boolean formatUnixTime,public final non-sealed java.util.Locale locale,protected final non-sealed boolean useSimpleDateFormat,public final non-sealed boolean useSimpleFormatter,protected final non-sealed boolean yyyyMMdd10,protected final non-sealed boolean yyyyMMdd8,protected final non-sealed boolean yyyyMMddhhmm16,protected final non-sealed boolean yyyyMMddhhmmss14,protected final non-sealed boolean yyyyMMddhhmmss19