Class Result

java.lang.Object
com.vivoka.vsdk.nlu.result.Result

public class Result extends Object
Represents the NLU (Natural Language Understanding) result.
  • Constructor Details

    • Result

      public Result(String json)
  • Method Details

    • toString

      public String toString()
      Overrides:
      toString in class Object
      Returns:
      The JSON string representation of the NLU result.
    • toJson

      public org.json.JSONObject toJson() throws Exception
      Returns:
      The JSON object representation of the NLU result.
      Throws:
      Exception - If failed to convert the NLU result to a JSON object.
    • getLang

      public String getLang()
      Returns:
      The language of the NLU result.
    • getOriginalSentence

      public String getOriginalSentence()
      Returns:
      The original sentence of the NLU result.
    • getIntent

      public Intent getIntent()
      Returns:
      The intent of the NLU result.
    • getEntities

      public ArrayList<Entity> getEntities()
      Returns:
      The entities of the NLU result.