public class SingletonSerDeFactory<T> extends java.lang.Object implements SerDeFactory<T>
| Constructor and Description |
|---|
SingletonSerDeFactory(SerDe<T> serde) |
| Modifier and Type | Method and Description |
|---|---|
SerDe<T> |
createSerDe(java.lang.String encodingName)
Returns a new SerDe
|
java.lang.String |
getLocation(T record)
Returns the external location of the given record; this is used when a
record is moved away from WALI or is being re-introduced to WALI.
|
java.lang.Object |
getRecordIdentifier(T record)
Returns the unique ID for the given record
|
UpdateType |
getUpdateType(T record)
Returns the UpdateType for the given record
|
public SerDe<T> createSerDe(java.lang.String encodingName)
SerDeFactorycreateSerDe in interface SerDeFactory<T>encodingName - the name of encoding that was used when writing the serialized data, or null if
the SerDe is to be used for serialization purposespublic java.lang.Object getRecordIdentifier(T record)
SerDeFactorygetRecordIdentifier in interface SerDeFactory<T>record - to obtain identifier forpublic UpdateType getUpdateType(T record)
SerDeFactorygetUpdateType in interface SerDeFactory<T>record - to retrieve update type forpublic java.lang.String getLocation(T record)
SerDeFactoryUpdateType.SWAP_OUT that indicates a Location of
file://tmp/external1 and can then be re-introduced to WALI by updating
WALI with a record of type UpdateType.CREATE that indicates a
Location of file://tmp/external1getLocation in interface SerDeFactory<T>record - to get location of