Class AddTrainingDataOptions.Builder

java.lang.Object
com.ibm.watson.discovery.v1.model.AddTrainingDataOptions.Builder
Enclosing class:
AddTrainingDataOptions

public static class AddTrainingDataOptions.Builder
extends Object
Builder.
  • Constructor Details

    • Builder

      public Builder()
      Instantiates a new builder.
    • Builder

      public Builder​(String environmentId, String collectionId)
      Instantiates a new builder with required properties.
      Parameters:
      environmentId - the environmentId
      collectionId - the collectionId
  • Method Details

    • build

      public AddTrainingDataOptions build()
      Builds a AddTrainingDataOptions.
      Returns:
      the new AddTrainingDataOptions instance
    • addExamples

      public AddTrainingDataOptions.Builder addExamples​(TrainingExample examples)
      Adds an examples to examples.
      Parameters:
      examples - the new examples
      Returns:
      the AddTrainingDataOptions builder
    • environmentId

      public AddTrainingDataOptions.Builder environmentId​(String environmentId)
      Set the environmentId.
      Parameters:
      environmentId - the environmentId
      Returns:
      the AddTrainingDataOptions builder
    • collectionId

      public AddTrainingDataOptions.Builder collectionId​(String collectionId)
      Set the collectionId.
      Parameters:
      collectionId - the collectionId
      Returns:
      the AddTrainingDataOptions builder
    • naturalLanguageQuery

      public AddTrainingDataOptions.Builder naturalLanguageQuery​(String naturalLanguageQuery)
      Set the naturalLanguageQuery.
      Parameters:
      naturalLanguageQuery - the naturalLanguageQuery
      Returns:
      the AddTrainingDataOptions builder
    • filter

      public AddTrainingDataOptions.Builder filter​(String filter)
      Set the filter.
      Parameters:
      filter - the filter
      Returns:
      the AddTrainingDataOptions builder
    • examples

      public AddTrainingDataOptions.Builder examples​(List<TrainingExample> examples)
      Set the examples. Existing examples will be replaced.
      Parameters:
      examples - the examples
      Returns:
      the AddTrainingDataOptions builder