protected static final class Tuples.Tuple2TypeFactory<T1,T2> extends Object implements TypeSystem.TypeFactory<Tuples.Tuple2<T1,T2>>, Tuples.TupleFactory<Tuples.Tuple2<T1,T2>>
| Modifier | Constructor and Description |
|---|---|
protected |
Tuples.Tuple2TypeFactory(TypeSystem.TypeFactory<T1> type1,
TypeSystem.TypeFactory<T2> type2) |
| Modifier and Type | Method and Description |
|---|---|
String |
asReadableString(Object value)
Get a readable and potentially shorter string representation of the supplied value.
|
String |
asString(Object value)
Get the string representation of the supplied value.
|
Tuples.Tuple2<T1,T2> |
create(Object value)
Create the typed representation of the value given the supplied object representation.
|
Tuples.Tuple2<T1,T2> |
create(String value)
Create the typed representation of the value given the supplied string representation.
|
Comparator<Tuples.Tuple2<T1,T2>> |
getComparator()
Get a comparator that can be used to store the values of this type.
|
org.mapdb.Serializer<Tuples.Tuple2<T1,T2>> |
getSerializer(BufferManager bufferMgr) |
Class<Tuples.Tuple2<T1,T2>> |
getType()
Get the class representing the value type.
|
String |
getTypeName()
Get the name of the type created by this factory.
|
long |
length(Object value)
Get the length of the supplied value.
|
protected Tuples.Tuple2TypeFactory(TypeSystem.TypeFactory<T1> type1, TypeSystem.TypeFactory<T2> type2)
public org.mapdb.Serializer<Tuples.Tuple2<T1,T2>> getSerializer(BufferManager bufferMgr)
getSerializer in interface Tuples.TupleFactory<Tuples.Tuple2<T1,T2>>public Class<Tuples.Tuple2<T1,T2>> getType()
TypeSystem.TypeFactorygetType in interface TypeSystem.TypeFactory<Tuples.Tuple2<T1,T2>>public Comparator<Tuples.Tuple2<T1,T2>> getComparator()
TypeSystem.TypeFactorygetComparator in interface TypeSystem.TypeFactory<Tuples.Tuple2<T1,T2>>public String getTypeName()
TypeSystem.TypeFactorygetTypeName in interface TypeSystem.TypeFactory<Tuples.Tuple2<T1,T2>>public Tuples.Tuple2<T1,T2> create(String value) throws ValueFormatException
TypeSystem.TypeFactorycreate in interface TypeSystem.TypeFactory<Tuples.Tuple2<T1,T2>>value - the string representation of the valuetypeValueFormatException - if the string cannot be converted to a typed valuepublic Tuples.Tuple2<T1,T2> create(Object value) throws ValueFormatException
TypeSystem.TypeFactorycreate in interface TypeSystem.TypeFactory<Tuples.Tuple2<T1,T2>>value - the object representation of the valuetypeValueFormatException - if the object cannot be converted to a typed valuepublic String asString(Object value)
TypeSystem.TypeFactoryasString in interface TypeSystem.TypeFactory<Tuples.Tuple2<T1,T2>>value - the valuepublic long length(Object value)
TypeSystem.TypeFactorylength in interface TypeSystem.TypeFactory<Tuples.Tuple2<T1,T2>>value - the valuepublic String asReadableString(Object value)
TypeSystem.TypeFactoryasReadableString in interface TypeSystem.TypeFactory<Tuples.Tuple2<T1,T2>>value - the valueCopyright © 2008-2014 JBoss, a division of Red Hat. All Rights Reserved.