org.omnaest.utils.structure.element.converter
Class ElementConverterIdentity<T>
java.lang.Object
org.omnaest.utils.structure.element.converter.ElementConverterIdentity<T>
- All Implemented Interfaces:
- Serializable, ElementBidirectionalConverter<T,T>, ElementBidirectionalConverterSerializable<T,T>, ElementConverter<T,T>
public class ElementConverterIdentity<T>
- extends Object
- implements ElementBidirectionalConverterSerializable<T,T>
Does not change the type of the element and the value of the element being converted.
- Author:
- Omnaest
- See Also:
ElementBidirectionalConverter,
Serialized Form
|
Method Summary |
T |
convert(T from)
Transforms a single element from one type into another. |
T |
convertBackwards(T element)
Converts an element in backwards way |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
ElementConverterIdentity
public ElementConverterIdentity()
convert
public T convert(T from)
- Description copied from interface:
ElementConverter
- Transforms a single element from one type into another.
- Specified by:
convert in interface ElementConverter<T,T>
- Returns:
- converted element
convertBackwards
public T convertBackwards(T element)
- Description copied from interface:
ElementBidirectionalConverter
- Converts an element in backwards way
- Specified by:
convertBackwards in interface ElementBidirectionalConverter<T,T>
- Returns:
Copyright © 2013. All Rights Reserved.