Package com.google.cloud.retail.v2
Interface ControlOrBuilder
-
- All Superinterfaces:
com.google.protobuf.MessageLiteOrBuilder,com.google.protobuf.MessageOrBuilder
- All Known Implementing Classes:
Control,Control.Builder
public interface ControlOrBuilder extends com.google.protobuf.MessageOrBuilder
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description StringgetAssociatedServingConfigIds(int index)Output only.com.google.protobuf.ByteStringgetAssociatedServingConfigIdsBytes(int index)Output only.intgetAssociatedServingConfigIdsCount()Output only.List<String>getAssociatedServingConfigIdsList()Output only.Control.ControlCasegetControlCase()StringgetDisplayName()Required.com.google.protobuf.ByteStringgetDisplayNameBytes()Required.StringgetName()Immutable.com.google.protobuf.ByteStringgetNameBytes()Immutable.RulegetRule()A rule control - a condition-action pair.RuleOrBuildergetRuleOrBuilder()A rule control - a condition-action pair.SearchSolutionUseCasegetSearchSolutionUseCase(int index)Specifies the use case for the control.intgetSearchSolutionUseCaseCount()Specifies the use case for the control.List<SearchSolutionUseCase>getSearchSolutionUseCaseList()Specifies the use case for the control.intgetSearchSolutionUseCaseValue(int index)Specifies the use case for the control.List<Integer>getSearchSolutionUseCaseValueList()Specifies the use case for the control.SolutionTypegetSolutionTypes(int index)Required.intgetSolutionTypesCount()Required.List<SolutionType>getSolutionTypesList()Required.intgetSolutionTypesValue(int index)Required.List<Integer>getSolutionTypesValueList()Required.booleanhasRule()A rule control - a condition-action pair.-
Methods inherited from interface com.google.protobuf.MessageOrBuilder
findInitializationErrors, getAllFields, getDefaultInstanceForType, getDescriptorForType, getField, getInitializationErrorString, getOneofFieldDescriptor, getRepeatedField, getRepeatedFieldCount, getUnknownFields, hasField, hasOneof
-
-
-
-
Method Detail
-
hasRule
boolean hasRule()
A rule control - a condition-action pair. Enacts a set action when the condition is triggered. For example: Boost "gShoe" when query full matches "Running Shoes".
.google.cloud.retail.v2.Rule rule = 4;- Returns:
- Whether the rule field is set.
-
getRule
Rule getRule()
A rule control - a condition-action pair. Enacts a set action when the condition is triggered. For example: Boost "gShoe" when query full matches "Running Shoes".
.google.cloud.retail.v2.Rule rule = 4;- Returns:
- The rule.
-
getRuleOrBuilder
RuleOrBuilder getRuleOrBuilder()
A rule control - a condition-action pair. Enacts a set action when the condition is triggered. For example: Boost "gShoe" when query full matches "Running Shoes".
.google.cloud.retail.v2.Rule rule = 4;
-
getName
String getName()
Immutable. Fully qualified name `projects/*/locations/global/catalogs/*/controls/*`
string name = 1 [(.google.api.field_behavior) = IMMUTABLE];- Returns:
- The name.
-
getNameBytes
com.google.protobuf.ByteString getNameBytes()
Immutable. Fully qualified name `projects/*/locations/global/catalogs/*/controls/*`
string name = 1 [(.google.api.field_behavior) = IMMUTABLE];- Returns:
- The bytes for name.
-
getDisplayName
String getDisplayName()
Required. The human readable control display name. Used in Retail UI. This field must be a UTF-8 encoded string with a length limit of 128 characters. Otherwise, an INVALID_ARGUMENT error is thrown.
string display_name = 2 [(.google.api.field_behavior) = REQUIRED];- Returns:
- The displayName.
-
getDisplayNameBytes
com.google.protobuf.ByteString getDisplayNameBytes()
Required. The human readable control display name. Used in Retail UI. This field must be a UTF-8 encoded string with a length limit of 128 characters. Otherwise, an INVALID_ARGUMENT error is thrown.
string display_name = 2 [(.google.api.field_behavior) = REQUIRED];- Returns:
- The bytes for displayName.
-
getAssociatedServingConfigIdsList
List<String> getAssociatedServingConfigIdsList()
Output only. List of [serving config][google.cloud.retail.v2.ServingConfig] ids that are associated with this control in the same [Catalog][google.cloud.retail.v2.Catalog]. Note the association is managed via the [ServingConfig][google.cloud.retail.v2.ServingConfig], this is an output only denormalized view.
repeated string associated_serving_config_ids = 5 [(.google.api.field_behavior) = OUTPUT_ONLY];- Returns:
- A list containing the associatedServingConfigIds.
-
getAssociatedServingConfigIdsCount
int getAssociatedServingConfigIdsCount()
Output only. List of [serving config][google.cloud.retail.v2.ServingConfig] ids that are associated with this control in the same [Catalog][google.cloud.retail.v2.Catalog]. Note the association is managed via the [ServingConfig][google.cloud.retail.v2.ServingConfig], this is an output only denormalized view.
repeated string associated_serving_config_ids = 5 [(.google.api.field_behavior) = OUTPUT_ONLY];- Returns:
- The count of associatedServingConfigIds.
-
getAssociatedServingConfigIds
String getAssociatedServingConfigIds(int index)
Output only. List of [serving config][google.cloud.retail.v2.ServingConfig] ids that are associated with this control in the same [Catalog][google.cloud.retail.v2.Catalog]. Note the association is managed via the [ServingConfig][google.cloud.retail.v2.ServingConfig], this is an output only denormalized view.
repeated string associated_serving_config_ids = 5 [(.google.api.field_behavior) = OUTPUT_ONLY];- Parameters:
index- The index of the element to return.- Returns:
- The associatedServingConfigIds at the given index.
-
getAssociatedServingConfigIdsBytes
com.google.protobuf.ByteString getAssociatedServingConfigIdsBytes(int index)
Output only. List of [serving config][google.cloud.retail.v2.ServingConfig] ids that are associated with this control in the same [Catalog][google.cloud.retail.v2.Catalog]. Note the association is managed via the [ServingConfig][google.cloud.retail.v2.ServingConfig], this is an output only denormalized view.
repeated string associated_serving_config_ids = 5 [(.google.api.field_behavior) = OUTPUT_ONLY];- Parameters:
index- The index of the value to return.- Returns:
- The bytes of the associatedServingConfigIds at the given index.
-
getSolutionTypesList
List<SolutionType> getSolutionTypesList()
Required. Immutable. The solution types that the control is used for. Currently we support setting only one type of solution at creation time. Only `SOLUTION_TYPE_SEARCH` value is supported at the moment. If no solution type is provided at creation time, will default to [SOLUTION_TYPE_SEARCH][google.cloud.retail.v2.SolutionType.SOLUTION_TYPE_SEARCH].
repeated .google.cloud.retail.v2.SolutionType solution_types = 6 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = IMMUTABLE];- Returns:
- A list containing the solutionTypes.
-
getSolutionTypesCount
int getSolutionTypesCount()
Required. Immutable. The solution types that the control is used for. Currently we support setting only one type of solution at creation time. Only `SOLUTION_TYPE_SEARCH` value is supported at the moment. If no solution type is provided at creation time, will default to [SOLUTION_TYPE_SEARCH][google.cloud.retail.v2.SolutionType.SOLUTION_TYPE_SEARCH].
repeated .google.cloud.retail.v2.SolutionType solution_types = 6 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = IMMUTABLE];- Returns:
- The count of solutionTypes.
-
getSolutionTypes
SolutionType getSolutionTypes(int index)
Required. Immutable. The solution types that the control is used for. Currently we support setting only one type of solution at creation time. Only `SOLUTION_TYPE_SEARCH` value is supported at the moment. If no solution type is provided at creation time, will default to [SOLUTION_TYPE_SEARCH][google.cloud.retail.v2.SolutionType.SOLUTION_TYPE_SEARCH].
repeated .google.cloud.retail.v2.SolutionType solution_types = 6 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = IMMUTABLE];- Parameters:
index- The index of the element to return.- Returns:
- The solutionTypes at the given index.
-
getSolutionTypesValueList
List<Integer> getSolutionTypesValueList()
Required. Immutable. The solution types that the control is used for. Currently we support setting only one type of solution at creation time. Only `SOLUTION_TYPE_SEARCH` value is supported at the moment. If no solution type is provided at creation time, will default to [SOLUTION_TYPE_SEARCH][google.cloud.retail.v2.SolutionType.SOLUTION_TYPE_SEARCH].
repeated .google.cloud.retail.v2.SolutionType solution_types = 6 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = IMMUTABLE];- Returns:
- A list containing the enum numeric values on the wire for solutionTypes.
-
getSolutionTypesValue
int getSolutionTypesValue(int index)
Required. Immutable. The solution types that the control is used for. Currently we support setting only one type of solution at creation time. Only `SOLUTION_TYPE_SEARCH` value is supported at the moment. If no solution type is provided at creation time, will default to [SOLUTION_TYPE_SEARCH][google.cloud.retail.v2.SolutionType.SOLUTION_TYPE_SEARCH].
repeated .google.cloud.retail.v2.SolutionType solution_types = 6 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = IMMUTABLE];- Parameters:
index- The index of the value to return.- Returns:
- The enum numeric value on the wire of solutionTypes at the given index.
-
getSearchSolutionUseCaseList
List<SearchSolutionUseCase> getSearchSolutionUseCaseList()
Specifies the use case for the control. Affects what condition fields can be set. Only settable by search controls. Will default to [SEARCH_SOLUTION_USE_CASE_SEARCH][google.cloud.retail.v2.SearchSolutionUseCase.SEARCH_SOLUTION_USE_CASE_SEARCH] if not specified. Currently only allow one search_solution_use_case per control.
repeated .google.cloud.retail.v2.SearchSolutionUseCase search_solution_use_case = 7;- Returns:
- A list containing the searchSolutionUseCase.
-
getSearchSolutionUseCaseCount
int getSearchSolutionUseCaseCount()
Specifies the use case for the control. Affects what condition fields can be set. Only settable by search controls. Will default to [SEARCH_SOLUTION_USE_CASE_SEARCH][google.cloud.retail.v2.SearchSolutionUseCase.SEARCH_SOLUTION_USE_CASE_SEARCH] if not specified. Currently only allow one search_solution_use_case per control.
repeated .google.cloud.retail.v2.SearchSolutionUseCase search_solution_use_case = 7;- Returns:
- The count of searchSolutionUseCase.
-
getSearchSolutionUseCase
SearchSolutionUseCase getSearchSolutionUseCase(int index)
Specifies the use case for the control. Affects what condition fields can be set. Only settable by search controls. Will default to [SEARCH_SOLUTION_USE_CASE_SEARCH][google.cloud.retail.v2.SearchSolutionUseCase.SEARCH_SOLUTION_USE_CASE_SEARCH] if not specified. Currently only allow one search_solution_use_case per control.
repeated .google.cloud.retail.v2.SearchSolutionUseCase search_solution_use_case = 7;- Parameters:
index- The index of the element to return.- Returns:
- The searchSolutionUseCase at the given index.
-
getSearchSolutionUseCaseValueList
List<Integer> getSearchSolutionUseCaseValueList()
Specifies the use case for the control. Affects what condition fields can be set. Only settable by search controls. Will default to [SEARCH_SOLUTION_USE_CASE_SEARCH][google.cloud.retail.v2.SearchSolutionUseCase.SEARCH_SOLUTION_USE_CASE_SEARCH] if not specified. Currently only allow one search_solution_use_case per control.
repeated .google.cloud.retail.v2.SearchSolutionUseCase search_solution_use_case = 7;- Returns:
- A list containing the enum numeric values on the wire for searchSolutionUseCase.
-
getSearchSolutionUseCaseValue
int getSearchSolutionUseCaseValue(int index)
Specifies the use case for the control. Affects what condition fields can be set. Only settable by search controls. Will default to [SEARCH_SOLUTION_USE_CASE_SEARCH][google.cloud.retail.v2.SearchSolutionUseCase.SEARCH_SOLUTION_USE_CASE_SEARCH] if not specified. Currently only allow one search_solution_use_case per control.
repeated .google.cloud.retail.v2.SearchSolutionUseCase search_solution_use_case = 7;- Parameters:
index- The index of the value to return.- Returns:
- The enum numeric value on the wire of searchSolutionUseCase at the given index.
-
getControlCase
Control.ControlCase getControlCase()
-
-