SearchIndexerDataContainer.java

  1. // Copyright (c) Microsoft Corporation. All rights reserved.
  2. // Licensed under the MIT License.
  3. //
  4. // Code generated by Microsoft (R) AutoRest Code Generator.
  5. // Changes may cause incorrect behavior and will be lost if the code is
  6. // regenerated.

  7. package com.azure.search.documents.indexes.models;

  8. import com.azure.core.annotation.Fluent;
  9. import com.fasterxml.jackson.annotation.JsonCreator;
  10. import com.fasterxml.jackson.annotation.JsonProperty;

  11. /** Represents information about the entity (such as Azure SQL table or CosmosDB collection) that will be indexed. */
  12. @Fluent
  13. public final class SearchIndexerDataContainer {
  14.     /*
  15.      * The name of the table or view (for Azure SQL data source) or collection
  16.      * (for CosmosDB data source) that will be indexed.
  17.      */
  18.     @JsonProperty(value = "name", required = true)
  19.     private String name;

  20.     /*
  21.      * A query that is applied to this data container. The syntax and meaning
  22.      * of this parameter is datasource-specific. Not supported by Azure SQL
  23.      * datasources.
  24.      */
  25.     @JsonProperty(value = "query")
  26.     private String query;

  27.     /**
  28.      * Creates an instance of SearchIndexerDataContainer class.
  29.      *
  30.      * @param name the name value to set.
  31.      */
  32.     @JsonCreator
  33.     public SearchIndexerDataContainer(@JsonProperty(value = "name", required = true) String name) {
  34.         this.name = name;
  35.     }

  36.     /**
  37.      * Get the name property: The name of the table or view (for Azure SQL data source) or collection (for CosmosDB data
  38.      * source) that will be indexed.
  39.      *
  40.      * @return the name value.
  41.      */
  42.     public String getName() {
  43.         return this.name;
  44.     }

  45.     /**
  46.      * Get the query property: A query that is applied to this data container. The syntax and meaning of this parameter
  47.      * is datasource-specific. Not supported by Azure SQL datasources.
  48.      *
  49.      * @return the query value.
  50.      */
  51.     public String getQuery() {
  52.         return this.query;
  53.     }

  54.     /**
  55.      * Set the query property: A query that is applied to this data container. The syntax and meaning of this parameter
  56.      * is datasource-specific. Not supported by Azure SQL datasources.
  57.      *
  58.      * @param query the query value to set.
  59.      * @return the SearchIndexerDataContainer object itself.
  60.      */
  61.     public SearchIndexerDataContainer setQuery(String query) {
  62.         this.query = query;
  63.         return this;
  64.     }
  65. }