com.databasesandlife.util.jooq.CleartextPasswordConverter Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of java-common Show documentation
Show all versions of java-common Show documentation
Utility classes developed at Adrian Smith Software (A.S.S.)
package com.databasesandlife.util.jooq;
import com.databasesandlife.util.gwtsafe.CleartextPassword;
import org.jooq.Converter;
public class CleartextPasswordConverter implements Converter {
@Override public Class fromType() { return String.class; }
@Override public Class toType() { return CleartextPassword.class; }
@Override
public CleartextPassword from(String x) {
if (x == null) return null;
return new CleartextPassword(x);
}
@Override
public String to(CleartextPassword x) {
if (x == null) return null;
return x.getCleartext();
}
}