org.ldaptive.beans.spring.convert.StringToDurationConverter Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of ldaptive-beans Show documentation
Show all versions of ldaptive-beans Show documentation
Mapping, persistence, and code generation API for reading and writing POJOs to an LDAP directory
The newest version!
/* See LICENSE for licensing and NOTICE for copyright. */
package org.ldaptive.beans.spring.convert;
import java.time.Duration;
import org.springframework.core.convert.converter.Converter;
/**
* Convert a String to a {@link Duration}.
*
* @author Middleware Services
*/
public class StringToDurationConverter implements Converter
{
@Override
public Duration convert(final String s)
{
return Duration.parse(s);
}
}