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

com.backbase.oss.boat.bay.client.ParamExpander Maven / Gradle / Ivy

There is a newer version: 0.17.37
Show newest version
package com.backbase.oss.boat.bay.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