Package com.apama.correlator.memstore
Class ConverterConfig<K,V>
- java.lang.Object
-
- com.apama.correlator.memstore.ConverterConfig<K,V>
-
public class ConverterConfig<K,V> extends java.lang.Object
A configuration bean for deciding what RowKeyValueConverter to apply to each table. All converters supported by this class deal in subclasses of K and V.- See Also:
RowKeyValueConverter
-
-
Constructor Summary
Constructors Constructor Description ConverterConfig()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description java.util.Map<java.lang.String,RowKeyValueConverter<K,V>>
getByTable()
Get per-table RowKeyValueConverter map.RowKeyValueConverter<K,V>
getConverter(java.lang.String tableName)
Return a converter object for the specified table.RowKeyValueConverter<K,V>
getDefault()
Get default RowKeyValueConverter used for tables which does not specify any converter.void
setByTable(java.util.Map<java.lang.String,RowKeyValueConverter<K,V>> map)
Set per-table RowKeyValueConverter map.void
setDefault(RowKeyValueConverter<K,V> def)
Set default RowKeyValueConverter used for tables which does not specify any converter.
-
-
-
Method Detail
-
getDefault
public RowKeyValueConverter<K,V> getDefault()
Get default RowKeyValueConverter used for tables which does not specify any converter.- Returns:
-
setDefault
public void setDefault(RowKeyValueConverter<K,V> def)
Set default RowKeyValueConverter used for tables which does not specify any converter.- Parameters:
def
-
-
getByTable
public java.util.Map<java.lang.String,RowKeyValueConverter<K,V>> getByTable()
Get per-table RowKeyValueConverter map. For any tables not names, the value of default property is used.- Returns:
-
setByTable
public void setByTable(java.util.Map<java.lang.String,RowKeyValueConverter<K,V>> map)
Set per-table RowKeyValueConverter map. For any tables not names, the value of default property is used.- Parameters:
map
-
-
getConverter
public RowKeyValueConverter<K,V> getConverter(java.lang.String tableName)
Return a converter object for the specified table. If the converter is not thread-safe (e.g. if it statefully caches stuff), then this method should be overridden to construct and return a new unique instance.- Parameters:
tableName
-- Returns:
-
-