Package io.ebeaninternal.server.type
Class ScalarTypeInet
- java.lang.Object
-
- io.ebeaninternal.server.type.ScalarTypeBase<T>
-
- io.ebeaninternal.server.type.ScalarTypeBaseVarchar<io.ebean.types.Inet>
-
- io.ebeaninternal.server.type.ScalarTypeInet
-
- All Implemented Interfaces:
StringFormatter
,StringParser
,ScalarDataReader<io.ebean.types.Inet>
,ScalarType<io.ebean.types.Inet>
- Direct Known Subclasses:
ScalarTypeInet.Postgres
,ScalarTypeInet.Varchar
public abstract class ScalarTypeInet extends ScalarTypeBaseVarchar<io.ebean.types.Inet>
ScalarType for Inet to Varchar or Postgres INET.
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static class
ScalarTypeInet.Postgres
Inet to Postgres INET.static class
ScalarTypeInet.Varchar
Inet to Varchar.
-
Method Summary
All Methods Instance Methods Abstract Methods Concrete Methods Modifier and Type Method Description abstract void
bind(DataBind b, io.ebean.types.Inet value)
Convert (if necessary) and bind the value to the preparedStatement.io.ebean.types.Inet
convertFromDbString(String dbValue)
Convert from DB string value to the target type.String
convertToDbString(io.ebean.types.Inet beanValue)
Convert to DB string from the target type.String
formatValue(io.ebean.types.Inet value)
Format the target type to a string.io.ebean.types.Inet
parse(String value)
Parse from a formatted string value.-
Methods inherited from class io.ebeaninternal.server.type.ScalarTypeBaseVarchar
convertFromMillis, format, getDocType, isDateTimeCapable, jsonRead, jsonWrite, read, readData, toBeanType, toJdbcType, writeData
-
Methods inherited from class io.ebeaninternal.server.type.ScalarTypeBase
asVersion, getJdbcType, getLength, getType, isBinaryType, isDirty, isJdbcNative, isMutable, loadIgnore
-
-
-
-
Method Detail
-
bind
public abstract void bind(DataBind b, io.ebean.types.Inet value) throws SQLException
Description copied from interface:ScalarType
Convert (if necessary) and bind the value to the preparedStatement.value may need to be converted from the logical bean property type to the JDBC type.
- Specified by:
bind
in interfaceScalarType<io.ebean.types.Inet>
- Overrides:
bind
in classScalarTypeBaseVarchar<io.ebean.types.Inet>
- Throws:
SQLException
-
convertFromDbString
public io.ebean.types.Inet convertFromDbString(String dbValue)
Description copied from class:ScalarTypeBaseVarchar
Convert from DB string value to the target type.- Specified by:
convertFromDbString
in classScalarTypeBaseVarchar<io.ebean.types.Inet>
-
convertToDbString
public String convertToDbString(io.ebean.types.Inet beanValue)
Description copied from class:ScalarTypeBaseVarchar
Convert to DB string from the target type.- Specified by:
convertToDbString
in classScalarTypeBaseVarchar<io.ebean.types.Inet>
-
formatValue
public String formatValue(io.ebean.types.Inet value)
Description copied from class:ScalarTypeBaseVarchar
Format the target type to a string.- Specified by:
formatValue
in interfaceScalarType<io.ebean.types.Inet>
- Specified by:
formatValue
in classScalarTypeBaseVarchar<io.ebean.types.Inet>
-
parse
public io.ebean.types.Inet parse(String value)
Description copied from class:ScalarTypeBaseVarchar
Parse from a formatted string value.- Specified by:
parse
in interfaceScalarType<io.ebean.types.Inet>
- Specified by:
parse
in interfaceStringParser
- Specified by:
parse
in classScalarTypeBaseVarchar<io.ebean.types.Inet>
-
-