Class Example.Builder

java.lang.Object
com.ibm.watson.assistant.v1.model.Example.Builder
Enclosing class:
Example

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

    • Builder

      public Builder()
      Instantiates a new builder.
    • Builder

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

    • build

      public Example build()
      Builds a Example.
      Returns:
      the new Example instance
    • addMentions

      public Example.Builder addMentions​(Mention mentions)
      Adds an mentions to mentions.
      Parameters:
      mentions - the new mentions
      Returns:
      the Example builder
    • text

      public Example.Builder text​(String text)
      Set the text.
      Parameters:
      text - the text
      Returns:
      the Example builder
    • mentions

      public Example.Builder mentions​(List<Mention> mentions)
      Set the mentions. Existing mentions will be replaced.
      Parameters:
      mentions - the mentions
      Returns:
      the Example builder