java.lang.Object
io.ebeaninternal.server.query.DefaultSqlRow
- All Implemented Interfaces:
SqlRow,Serializable,Map<String,Object>
Used to return raw SQL query results.
Refer to SqlQuery for examples.
There are convenience methods such as getInteger(), getBigDecimal() etc. The reason for these methods is that the values put into this map often come straight from the JDBC resultSet. Depending on the JDBC driver it may put a different type into a given property. For example an Integer, BigDecimal, Double could all be put into a property depending on the JDBC driver used. These convenience methods automatically convert the value as required returning the type you expect.
- See Also:
-
Nested Class Summary
-
Constructor Summary
ConstructorsConstructorDescriptionDefaultSqlRow(int initialCapacity, float loadFactor, String dbTrueValue, boolean optimizedBinaryUUID) Create with an initialCapacity and loadFactor. -
Method Summary
Modifier and TypeMethodDescriptionvoidclear()booleancontainsKey(Object key) booleancontainsValue(Object value) entrySet()getBigDecimal(String name) getBoolean(String name) getInteger(String name) getTimestamp(String name) getUtilDate(String name) booleanisEmpty()keys()keySet()voidintsize()toString()values()Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitMethods inherited from interface java.util.Map
compute, computeIfAbsent, computeIfPresent, equals, forEach, getOrDefault, hashCode, merge, putIfAbsent, remove, replace, replace, replaceAll
-
Constructor Details
-
DefaultSqlRow
public DefaultSqlRow(int initialCapacity, float loadFactor, String dbTrueValue, boolean optimizedBinaryUUID) Create with an initialCapacity and loadFactor.The defaults of these are 16 and 0.75.
Note that the Map will rehash the contents when the number of keys in this map reaches its threshold (initialCapacity * loadFactor).
-
-
Method Details
-
keys
-
remove
-
get
-
put
-
set
-
getUUID
-
getBoolean
- Specified by:
getBooleanin interfaceSqlRow
-
getInteger
- Specified by:
getIntegerin interfaceSqlRow
-
getBigDecimal
- Specified by:
getBigDecimalin interfaceSqlRow
-
getLong
-
getDouble
-
getFloat
-
getString
-
getUtilDate
- Specified by:
getUtilDatein interfaceSqlRow
-
getDate
-
getTimestamp
- Specified by:
getTimestampin interfaceSqlRow
-
toString
-
clear
public void clear() -
containsKey
- Specified by:
containsKeyin interfaceMap<String,Object> - Specified by:
containsKeyin interfaceSqlRow
-
containsValue
- Specified by:
containsValuein interfaceMap<String,Object> - Specified by:
containsValuein interfaceSqlRow
-
entrySet
-
isEmpty
public boolean isEmpty() -
keySet
-
putAll
-
size
public int size() -
values
-