Package io.trino.plugin.redis
Enum RedisInternalFieldDescription
- java.lang.Object
-
- java.lang.Enum<RedisInternalFieldDescription>
-
- io.trino.plugin.redis.RedisInternalFieldDescription
-
- All Implemented Interfaces:
Serializable,Comparable<RedisInternalFieldDescription>
public enum RedisInternalFieldDescription extends Enum<RedisInternalFieldDescription>
Describes an internal (managed by the connector) field which is added to each table row. The definition itself makes the row show up in the tables (the columns are hidden by default, so they must be explicitly selected) but unless the field is hooked in using the forBooleanValue/forLongValue/forBytesValue methods and the resulting FieldValueProvider is then passed into the appropriate row decoder, the fields will be null. Most values are assigned in theRedisRecordSet.
-
-
Enum Constant Summary
Enum Constants Enum Constant Description KEY_CORRUPT_FIELD_key_corrupt - True if the row converter could not read the key.KEY_FIELD_key - Represents the key as a text column.KEY_LENGTH_FIELD_key_length - length in bytes of the key.VALUE_CORRUPT_FIELD_value_corrupt - True if the row converter could not read the value.VALUE_FIELD_value - Represents the value as a text column.VALUE_LENGTH_FIELD_value_length - length in bytes of the value.
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description static RedisInternalFieldDescriptionforColumnName(String columnName)StringgetColumnName()TypegetType()static RedisInternalFieldDescriptionvalueOf(String name)Returns the enum constant of this type with the specified name.static RedisInternalFieldDescription[]values()Returns an array containing the constants of this enum type, in the order they are declared.
-
-
-
Enum Constant Detail
-
KEY_FIELD
public static final RedisInternalFieldDescription KEY_FIELD
_key - Represents the key as a text column.
-
VALUE_FIELD
public static final RedisInternalFieldDescription VALUE_FIELD
_value - Represents the value as a text column. Format is UTF-8
-
VALUE_CORRUPT_FIELD
public static final RedisInternalFieldDescription VALUE_CORRUPT_FIELD
_value_corrupt - True if the row converter could not read the value. May be null if the row converter does not set a value (e.g. the dummy row converter does not).
-
VALUE_LENGTH_FIELD
public static final RedisInternalFieldDescription VALUE_LENGTH_FIELD
_value_length - length in bytes of the value.
-
KEY_CORRUPT_FIELD
public static final RedisInternalFieldDescription KEY_CORRUPT_FIELD
_key_corrupt - True if the row converter could not read the key. May be null if the row converter does not set a value (e.g. the dummy row converter does not).
-
KEY_LENGTH_FIELD
public static final RedisInternalFieldDescription KEY_LENGTH_FIELD
_key_length - length in bytes of the key.
-
-
Method Detail
-
values
public static RedisInternalFieldDescription[] values()
Returns an array containing the constants of this enum type, in the order they are declared. This method may be used to iterate over the constants as follows:for (RedisInternalFieldDescription c : RedisInternalFieldDescription.values()) System.out.println(c);
- Returns:
- an array containing the constants of this enum type, in the order they are declared
-
valueOf
public static RedisInternalFieldDescription valueOf(String name)
Returns the enum constant of this type with the specified name. The string must match exactly an identifier used to declare an enum constant in this type. (Extraneous whitespace characters are not permitted.)- Parameters:
name- the name of the enum constant to be returned.- Returns:
- the enum constant with the specified name
- Throws:
IllegalArgumentException- if this enum type has no constant with the specified nameNullPointerException- if the argument is null
-
forColumnName
public static RedisInternalFieldDescription forColumnName(String columnName)
-
getColumnName
public String getColumnName()
-
getType
public Type getType()
-
-