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

org.openmetadata.client.ParamExpander Maven / Gradle / Ivy

There is a newer version: 1.5.11
Show newest version
package org.openmetadata.client;

import feign.Param;

import java.text.DateFormat;
import java.util.Date;

/**
 * Param Expander to convert {@link Date} to RFC3339
 */
public class ParamExpander implements Param.Expander {

  private static final DateFormat dateformat = new RFC3339DateFormat();

  @Override
  public String expand(Object value) {
    if (value instanceof Date) {
      return dateformat.format(value);
    }
    return value.toString();
  }
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy