InputFieldMappingEntry.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. import com.fasterxml.jackson.annotation.JsonSetter;
  12. import java.util.List;

  13. /** Input field mapping for a skill. */
  14. @Fluent
  15. public final class InputFieldMappingEntry {
  16.     /*
  17.      * The name of the input.
  18.      */
  19.     @JsonProperty(value = "name", required = true)
  20.     private String name;

  21.     /*
  22.      * The source of the input.
  23.      */
  24.     @JsonProperty(value = "source")
  25.     private String source;

  26.     /*
  27.      * The source context used for selecting recursive inputs.
  28.      */
  29.     @JsonProperty(value = "sourceContext")
  30.     private String sourceContext;

  31.     /*
  32.      * The recursive inputs used when creating a complex type.
  33.      */
  34.     @JsonProperty(value = "inputs")
  35.     private List<InputFieldMappingEntry> inputs;

  36.     /**
  37.      * Creates an instance of InputFieldMappingEntry class.
  38.      *
  39.      * @param name the name value to set.
  40.      */
  41.     @JsonCreator
  42.     public InputFieldMappingEntry(@JsonProperty(value = "name", required = true) String name) {
  43.         this.name = name;
  44.     }

  45.     /**
  46.      * Get the name property: The name of the input.
  47.      *
  48.      * @return the name value.
  49.      */
  50.     public String getName() {
  51.         return this.name;
  52.     }

  53.     /**
  54.      * Get the source property: The source of the input.
  55.      *
  56.      * @return the source value.
  57.      */
  58.     public String getSource() {
  59.         return this.source;
  60.     }

  61.     /**
  62.      * Set the source property: The source of the input.
  63.      *
  64.      * @param source the source value to set.
  65.      * @return the InputFieldMappingEntry object itself.
  66.      */
  67.     public InputFieldMappingEntry setSource(String source) {
  68.         this.source = source;
  69.         return this;
  70.     }

  71.     /**
  72.      * Get the sourceContext property: The source context used for selecting recursive inputs.
  73.      *
  74.      * @return the sourceContext value.
  75.      */
  76.     public String getSourceContext() {
  77.         return this.sourceContext;
  78.     }

  79.     /**
  80.      * Set the sourceContext property: The source context used for selecting recursive inputs.
  81.      *
  82.      * @param sourceContext the sourceContext value to set.
  83.      * @return the InputFieldMappingEntry object itself.
  84.      */
  85.     public InputFieldMappingEntry setSourceContext(String sourceContext) {
  86.         this.sourceContext = sourceContext;
  87.         return this;
  88.     }

  89.     /**
  90.      * Get the inputs property: The recursive inputs used when creating a complex type.
  91.      *
  92.      * @return the inputs value.
  93.      */
  94.     public List<InputFieldMappingEntry> getInputs() {
  95.         return this.inputs;
  96.     }

  97.     /**
  98.      * Set the inputs property: The recursive inputs used when creating a complex type.
  99.      *
  100.      * @param inputs the inputs value to set.
  101.      * @return the InputFieldMappingEntry object itself.
  102.      */
  103.     @JsonSetter
  104.     public InputFieldMappingEntry setInputs(List<InputFieldMappingEntry> inputs) {
  105.         this.inputs = inputs;
  106.         return this;
  107.     }

  108.     /**
  109.      * Set the inputs property: The recursive inputs used when creating a complex type.
  110.      *
  111.      * @param inputs the inputs value to set.
  112.      * @return the InputFieldMappingEntry object itself.
  113.      */
  114.     public InputFieldMappingEntry setInputs(InputFieldMappingEntry... inputs) {
  115.         this.inputs = (inputs == null) ? null : java.util.Arrays.asList(inputs);
  116.         return this;
  117.     }
  118. }