Class QueryProfileFieldType
- java.lang.Object
-
- com.yahoo.search.query.profile.types.FieldType
-
- com.yahoo.search.query.profile.types.QueryProfileFieldType
-
public class QueryProfileFieldType extends FieldType
Represents a query profile field type which is a reference to a query profile. The reference may optionally specify the type of the referred query profile.- Author:
- bratseth
-
-
Field Summary
-
Fields inherited from class com.yahoo.search.query.profile.types.FieldType
booleanType, doubleType, floatType, genericQueryProfileType, integerType, longType, queryType, stringType
-
-
Constructor Summary
Constructors Constructor Description QueryProfileFieldType()
QueryProfileFieldType(QueryProfileType type)
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description CompiledQueryProfile
convertFrom(java.lang.Object object, CompiledQueryProfileRegistry registry)
Converts the given type to an instance of this type, if possible.QueryProfile
convertFrom(java.lang.Object object, QueryProfileRegistry registry)
Converts the given type to an instance of this type, if possible.boolean
equals(java.lang.Object o)
static QueryProfileFieldType
fromString(java.lang.String queryProfileName, QueryProfileTypeRegistry registry)
QueryProfileType
getQueryProfileType()
Returns the query profile type of this, or null if any type worksjava.lang.Class<?>
getValueClass()
Returns the class of instance values of this field typeint
hashCode()
java.lang.String
stringValue()
Returns a string representation of this type which can be converted back to a type class byFieldType.fromString(java.lang.String, com.yahoo.search.query.profile.types.QueryProfileTypeRegistry)
java.lang.String
toInstanceDescription()
Returns a string describing possible instances of this type, suitable for user error messagesjava.lang.String
toString()
-
Methods inherited from class com.yahoo.search.query.profile.types.FieldType
asTensorType, isLegalFieldValue
-
-
-
-
Constructor Detail
-
QueryProfileFieldType
public QueryProfileFieldType()
-
QueryProfileFieldType
public QueryProfileFieldType(QueryProfileType type)
-
-
Method Detail
-
fromString
public static QueryProfileFieldType fromString(java.lang.String queryProfileName, QueryProfileTypeRegistry registry)
-
getQueryProfileType
public QueryProfileType getQueryProfileType()
Returns the query profile type of this, or null if any type works
-
getValueClass
public java.lang.Class<?> getValueClass()
Description copied from class:FieldType
Returns the class of instance values of this field type- Specified by:
getValueClass
in classFieldType
-
stringValue
public java.lang.String stringValue()
Description copied from class:FieldType
Returns a string representation of this type which can be converted back to a type class byFieldType.fromString(java.lang.String, com.yahoo.search.query.profile.types.QueryProfileTypeRegistry)
- Specified by:
stringValue
in classFieldType
-
toInstanceDescription
public java.lang.String toInstanceDescription()
Description copied from class:FieldType
Returns a string describing possible instances of this type, suitable for user error messages- Specified by:
toInstanceDescription
in classFieldType
-
convertFrom
public CompiledQueryProfile convertFrom(java.lang.Object object, CompiledQueryProfileRegistry registry)
Description copied from class:FieldType
Converts the given type to an instance of this type, if possible. Returns null if not possible.- Specified by:
convertFrom
in classFieldType
-
convertFrom
public QueryProfile convertFrom(java.lang.Object object, QueryProfileRegistry registry)
Description copied from class:FieldType
Converts the given type to an instance of this type, if possible. Returns null if not possible.- Specified by:
convertFrom
in classFieldType
-
hashCode
public int hashCode()
- Overrides:
hashCode
in classjava.lang.Object
-
equals
public boolean equals(java.lang.Object o)
- Overrides:
equals
in classjava.lang.Object
-
-