public final class FacetProperty extends GeneratedMessageV3 implements FacetPropertyOrBuilder
Central configuration for a facet.
Protobuf type google.cloud.visionai.v1.FacetProperty
Inherited Members
com.google.protobuf.GeneratedMessageV3.<ListT>makeMutableCopy(ListT)
com.google.protobuf.GeneratedMessageV3.<ListT>makeMutableCopy(ListT,int)
com.google.protobuf.GeneratedMessageV3.<T>emptyList(java.lang.Class<T>)
com.google.protobuf.GeneratedMessageV3.internalGetMapFieldReflection(int)
Static Fields
BUCKET_TYPE_FIELD_NUMBER
public static final int BUCKET_TYPE_FIELD_NUMBER
Field Value |
Type |
Description |
int |
|
CUSTOM_RANGE_BUCKET_SPEC_FIELD_NUMBER
public static final int CUSTOM_RANGE_BUCKET_SPEC_FIELD_NUMBER
Field Value |
Type |
Description |
int |
|
DATETIME_BUCKET_SPEC_FIELD_NUMBER
public static final int DATETIME_BUCKET_SPEC_FIELD_NUMBER
Field Value |
Type |
Description |
int |
|
DISPLAY_NAME_FIELD_NUMBER
public static final int DISPLAY_NAME_FIELD_NUMBER
Field Value |
Type |
Description |
int |
|
FIXED_RANGE_BUCKET_SPEC_FIELD_NUMBER
public static final int FIXED_RANGE_BUCKET_SPEC_FIELD_NUMBER
Field Value |
Type |
Description |
int |
|
MAPPED_FIELDS_FIELD_NUMBER
public static final int MAPPED_FIELDS_FIELD_NUMBER
Field Value |
Type |
Description |
int |
|
RESULT_SIZE_FIELD_NUMBER
public static final int RESULT_SIZE_FIELD_NUMBER
Field Value |
Type |
Description |
int |
|
Static Methods
getDefaultInstance()
public static FacetProperty getDefaultInstance()
getDescriptor()
public static final Descriptors.Descriptor getDescriptor()
newBuilder()
public static FacetProperty.Builder newBuilder()
newBuilder(FacetProperty prototype)
public static FacetProperty.Builder newBuilder(FacetProperty prototype)
public static FacetProperty parseDelimitedFrom(InputStream input)
public static FacetProperty parseDelimitedFrom(InputStream input, ExtensionRegistryLite extensionRegistry)
parseFrom(byte[] data)
public static FacetProperty parseFrom(byte[] data)
Parameter |
Name |
Description |
data |
byte[]
|
parseFrom(byte[] data, ExtensionRegistryLite extensionRegistry)
public static FacetProperty parseFrom(byte[] data, ExtensionRegistryLite extensionRegistry)
parseFrom(ByteString data)
public static FacetProperty parseFrom(ByteString data)
parseFrom(ByteString data, ExtensionRegistryLite extensionRegistry)
public static FacetProperty parseFrom(ByteString data, ExtensionRegistryLite extensionRegistry)
public static FacetProperty parseFrom(CodedInputStream input)
public static FacetProperty parseFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)
public static FacetProperty parseFrom(InputStream input)
public static FacetProperty parseFrom(InputStream input, ExtensionRegistryLite extensionRegistry)
parseFrom(ByteBuffer data)
public static FacetProperty parseFrom(ByteBuffer data)
parseFrom(ByteBuffer data, ExtensionRegistryLite extensionRegistry)
public static FacetProperty parseFrom(ByteBuffer data, ExtensionRegistryLite extensionRegistry)
parser()
public static Parser<FacetProperty> parser()
Methods
equals(Object obj)
public boolean equals(Object obj)
Parameter |
Name |
Description |
obj |
Object
|
Overrides
getBucketType()
public FacetBucketType getBucketType()
Facet bucket type e.g. value, range.
.google.cloud.visionai.v1.FacetBucketType bucket_type = 4;
getBucketTypeValue()
public int getBucketTypeValue()
Facet bucket type e.g. value, range.
.google.cloud.visionai.v1.FacetBucketType bucket_type = 4;
Returns |
Type |
Description |
int |
The enum numeric value on the wire for bucketType.
|
getCustomRangeBucketSpec()
public FacetProperty.CustomRangeBucketSpec getCustomRangeBucketSpec()
Custom range facet bucket config.
.google.cloud.visionai.v1.FacetProperty.CustomRangeBucketSpec custom_range_bucket_spec = 6;
getCustomRangeBucketSpecOrBuilder()
public FacetProperty.CustomRangeBucketSpecOrBuilder getCustomRangeBucketSpecOrBuilder()
Custom range facet bucket config.
.google.cloud.visionai.v1.FacetProperty.CustomRangeBucketSpec custom_range_bucket_spec = 6;
getDatetimeBucketSpec()
public FacetProperty.DateTimeBucketSpec getDatetimeBucketSpec()
Datetime range facet bucket config.
.google.cloud.visionai.v1.FacetProperty.DateTimeBucketSpec datetime_bucket_spec = 7;
getDatetimeBucketSpecOrBuilder()
public FacetProperty.DateTimeBucketSpecOrBuilder getDatetimeBucketSpecOrBuilder()
Datetime range facet bucket config.
.google.cloud.visionai.v1.FacetProperty.DateTimeBucketSpec datetime_bucket_spec = 7;
getDefaultInstanceForType()
public FacetProperty getDefaultInstanceForType()
getDisplayName()
public String getDisplayName()
Display name of the facet. To be used by UI for facet rendering.
string display_name = 2;
Returns |
Type |
Description |
String |
The displayName.
|
getDisplayNameBytes()
public ByteString getDisplayNameBytes()
Display name of the facet. To be used by UI for facet rendering.
string display_name = 2;
Returns |
Type |
Description |
ByteString |
The bytes for displayName.
|
getFixedRangeBucketSpec()
public FacetProperty.FixedRangeBucketSpec getFixedRangeBucketSpec()
Fixed range facet bucket config.
.google.cloud.visionai.v1.FacetProperty.FixedRangeBucketSpec fixed_range_bucket_spec = 5;
getFixedRangeBucketSpecOrBuilder()
public FacetProperty.FixedRangeBucketSpecOrBuilder getFixedRangeBucketSpecOrBuilder()
Fixed range facet bucket config.
.google.cloud.visionai.v1.FacetProperty.FixedRangeBucketSpec fixed_range_bucket_spec = 5;
getMappedFields(int index)
public String getMappedFields(int index)
Name of the facets, which are the dimensions users want to use to refine
search results. mapped_fields
will match UserSpecifiedDataSchema keys.
For example, user can add a bunch of UGAs with the same key, such as
player:adam, player:bob, player:charles. When multiple mapped_fields are
specified, will merge their value together as final facet value. E.g.
home_team: a, home_team:b, away_team:a, away_team:c, when facet_field =
[home_team, away_team], facet_value will be [a, b, c].
UNLESS this is a 1:1 facet dimension (mapped_fields.size() == 1) AND the
mapped_field equals the parent SearchConfig.name, the parent must
also contain a SearchCriteriaProperty that maps to the same fields.
mapped_fields must not be empty.
repeated string mapped_fields = 1;
Parameter |
Name |
Description |
index |
int
The index of the element to return.
|
Returns |
Type |
Description |
String |
The mappedFields at the given index.
|
getMappedFieldsBytes(int index)
public ByteString getMappedFieldsBytes(int index)
Name of the facets, which are the dimensions users want to use to refine
search results. mapped_fields
will match UserSpecifiedDataSchema keys.
For example, user can add a bunch of UGAs with the same key, such as
player:adam, player:bob, player:charles. When multiple mapped_fields are
specified, will merge their value together as final facet value. E.g.
home_team: a, home_team:b, away_team:a, away_team:c, when facet_field =
[home_team, away_team], facet_value will be [a, b, c].
UNLESS this is a 1:1 facet dimension (mapped_fields.size() == 1) AND the
mapped_field equals the parent SearchConfig.name, the parent must
also contain a SearchCriteriaProperty that maps to the same fields.
mapped_fields must not be empty.
repeated string mapped_fields = 1;
Parameter |
Name |
Description |
index |
int
The index of the value to return.
|
Returns |
Type |
Description |
ByteString |
The bytes of the mappedFields at the given index.
|
getMappedFieldsCount()
public int getMappedFieldsCount()
Name of the facets, which are the dimensions users want to use to refine
search results. mapped_fields
will match UserSpecifiedDataSchema keys.
For example, user can add a bunch of UGAs with the same key, such as
player:adam, player:bob, player:charles. When multiple mapped_fields are
specified, will merge their value together as final facet value. E.g.
home_team: a, home_team:b, away_team:a, away_team:c, when facet_field =
[home_team, away_team], facet_value will be [a, b, c].
UNLESS this is a 1:1 facet dimension (mapped_fields.size() == 1) AND the
mapped_field equals the parent SearchConfig.name, the parent must
also contain a SearchCriteriaProperty that maps to the same fields.
mapped_fields must not be empty.
repeated string mapped_fields = 1;
Returns |
Type |
Description |
int |
The count of mappedFields.
|
getMappedFieldsList()
public ProtocolStringList getMappedFieldsList()
Name of the facets, which are the dimensions users want to use to refine
search results. mapped_fields
will match UserSpecifiedDataSchema keys.
For example, user can add a bunch of UGAs with the same key, such as
player:adam, player:bob, player:charles. When multiple mapped_fields are
specified, will merge their value together as final facet value. E.g.
home_team: a, home_team:b, away_team:a, away_team:c, when facet_field =
[home_team, away_team], facet_value will be [a, b, c].
UNLESS this is a 1:1 facet dimension (mapped_fields.size() == 1) AND the
mapped_field equals the parent SearchConfig.name, the parent must
also contain a SearchCriteriaProperty that maps to the same fields.
mapped_fields must not be empty.
repeated string mapped_fields = 1;
getParserForType()
public Parser<FacetProperty> getParserForType()
Overrides
getRangeFacetConfigCase()
public FacetProperty.RangeFacetConfigCase getRangeFacetConfigCase()
getResultSize()
public long getResultSize()
Maximum number of unique bucket to return for one facet. Bucket number can
be large for high-cardinality facet such as "player". We only return top-n
most related ones to user. If it's <= 0, the server will decide the
appropriate result_size.
int64 result_size = 3;
Returns |
Type |
Description |
long |
The resultSize.
|
getSerializedSize()
public int getSerializedSize()
Returns |
Type |
Description |
int |
|
Overrides
hasCustomRangeBucketSpec()
public boolean hasCustomRangeBucketSpec()
Custom range facet bucket config.
.google.cloud.visionai.v1.FacetProperty.CustomRangeBucketSpec custom_range_bucket_spec = 6;
Returns |
Type |
Description |
boolean |
Whether the customRangeBucketSpec field is set.
|
hasDatetimeBucketSpec()
public boolean hasDatetimeBucketSpec()
Datetime range facet bucket config.
.google.cloud.visionai.v1.FacetProperty.DateTimeBucketSpec datetime_bucket_spec = 7;
Returns |
Type |
Description |
boolean |
Whether the datetimeBucketSpec field is set.
|
hasFixedRangeBucketSpec()
public boolean hasFixedRangeBucketSpec()
Fixed range facet bucket config.
.google.cloud.visionai.v1.FacetProperty.FixedRangeBucketSpec fixed_range_bucket_spec = 5;
Returns |
Type |
Description |
boolean |
Whether the fixedRangeBucketSpec field is set.
|
hashCode()
Returns |
Type |
Description |
int |
|
Overrides
internalGetFieldAccessorTable()
protected GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()
Overrides
isInitialized()
public final boolean isInitialized()
Overrides
newBuilderForType()
public FacetProperty.Builder newBuilderForType()
newBuilderForType(GeneratedMessageV3.BuilderParent parent)
protected FacetProperty.Builder newBuilderForType(GeneratedMessageV3.BuilderParent parent)
Overrides
newInstance(GeneratedMessageV3.UnusedPrivateParameter unused)
protected Object newInstance(GeneratedMessageV3.UnusedPrivateParameter unused)
Returns |
Type |
Description |
Object |
|
Overrides
toBuilder()
public FacetProperty.Builder toBuilder()
writeTo(CodedOutputStream output)
public void writeTo(CodedOutputStream output)
Overrides