SplitSkill.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.JsonTypeId;
  12. import com.fasterxml.jackson.annotation.JsonTypeInfo;
  13. import com.fasterxml.jackson.annotation.JsonTypeName;
  14. import java.util.List;

  15. /** A skill to split a string into chunks of text. */
  16. @JsonTypeInfo(
  17.         use = JsonTypeInfo.Id.NAME,
  18.         include = JsonTypeInfo.As.EXISTING_PROPERTY,
  19.         property = "@odata.type",
  20.         visible = true)
  21. @JsonTypeName("#Microsoft.Skills.Text.SplitSkill")
  22. @Fluent
  23. public final class SplitSkill extends SearchIndexerSkill {

  24.     /*
  25.      * Identifies the concrete type of the skill.
  26.      */
  27.     @JsonTypeId
  28.     @JsonProperty(value = "@odata.type", required = true)
  29.     private String odataType = "#Microsoft.Skills.Text.SplitSkill";

  30.     /*
  31.      * A value indicating which language code to use. Default is en.
  32.      */
  33.     @JsonProperty(value = "defaultLanguageCode")
  34.     private SplitSkillLanguage defaultLanguageCode;

  35.     /*
  36.      * A value indicating which split mode to perform.
  37.      */
  38.     @JsonProperty(value = "textSplitMode")
  39.     private TextSplitMode textSplitMode;

  40.     /*
  41.      * The desired maximum page length. Default is 10000.
  42.      */
  43.     @JsonProperty(value = "maximumPageLength")
  44.     private Integer maximumPageLength;

  45.     /**
  46.      * Creates an instance of SplitSkill class.
  47.      *
  48.      * @param inputs the inputs value to set.
  49.      * @param outputs the outputs value to set.
  50.      */
  51.     @JsonCreator
  52.     public SplitSkill(
  53.             @JsonProperty(value = "inputs", required = true) List<InputFieldMappingEntry> inputs,
  54.             @JsonProperty(value = "outputs", required = true) List<OutputFieldMappingEntry> outputs) {
  55.         super(inputs, outputs);
  56.     }

  57.     /**
  58.      * Get the defaultLanguageCode property: A value indicating which language code to use. Default is en.
  59.      *
  60.      * @return the defaultLanguageCode value.
  61.      */
  62.     public SplitSkillLanguage getDefaultLanguageCode() {
  63.         return this.defaultLanguageCode;
  64.     }

  65.     /**
  66.      * Set the defaultLanguageCode property: A value indicating which language code to use. Default is en.
  67.      *
  68.      * @param defaultLanguageCode the defaultLanguageCode value to set.
  69.      * @return the SplitSkill object itself.
  70.      */
  71.     public SplitSkill setDefaultLanguageCode(SplitSkillLanguage defaultLanguageCode) {
  72.         this.defaultLanguageCode = defaultLanguageCode;
  73.         return this;
  74.     }

  75.     /**
  76.      * Get the textSplitMode property: A value indicating which split mode to perform.
  77.      *
  78.      * @return the textSplitMode value.
  79.      */
  80.     public TextSplitMode getTextSplitMode() {
  81.         return this.textSplitMode;
  82.     }

  83.     /**
  84.      * Set the textSplitMode property: A value indicating which split mode to perform.
  85.      *
  86.      * @param textSplitMode the textSplitMode value to set.
  87.      * @return the SplitSkill object itself.
  88.      */
  89.     public SplitSkill setTextSplitMode(TextSplitMode textSplitMode) {
  90.         this.textSplitMode = textSplitMode;
  91.         return this;
  92.     }

  93.     /**
  94.      * Get the maximumPageLength property: The desired maximum page length. Default is 10000.
  95.      *
  96.      * @return the maximumPageLength value.
  97.      */
  98.     public Integer getMaximumPageLength() {
  99.         return this.maximumPageLength;
  100.     }

  101.     /**
  102.      * Set the maximumPageLength property: The desired maximum page length. Default is 10000.
  103.      *
  104.      * @param maximumPageLength the maximumPageLength value to set.
  105.      * @return the SplitSkill object itself.
  106.      */
  107.     public SplitSkill setMaximumPageLength(Integer maximumPageLength) {
  108.         this.maximumPageLength = maximumPageLength;
  109.         return this;
  110.     }
  111. }