Esempio n. 1
0
  public Document TextGetTargetedSentiment(
      String text, String target, AlchemyAPI_TargetedSentimentParams params)
      throws IOException, SAXException, ParserConfigurationException, XPathExpressionException {
    CheckText(text);
    CheckText(target);

    params.setText(text);
    params.setTarget(target);

    return POST("TextGetTargetedSentiment", "text", params);
  }
Esempio n. 2
0
  public Document TextGetRelations(String text, AlchemyAPI_RelationParams params)
      throws IOException, SAXException, ParserConfigurationException, XPathExpressionException {
    CheckText(text);

    params.setText(text);

    return POST("TextGetRelations", "text", params);
  }
Esempio n. 3
0
  public Document URLGetTargetedSentiment(
      String url, String target, AlchemyAPI_TargetedSentimentParams params)
      throws IOException, SAXException, ParserConfigurationException, XPathExpressionException {
    CheckURL(url);
    CheckText(target);

    params.setUrl(url);
    params.setTarget(target);

    return GET("URLGetTargetedSentiment", "url", params);
  }
Esempio n. 4
0
  public Document HTMLGetTargetedSentiment(
      String html, String url, String target, AlchemyAPI_TargetedSentimentParams params)
      throws IOException, SAXException, ParserConfigurationException, XPathExpressionException {
    CheckHTML(html, url);
    CheckText(target);

    params.setHtml(html);
    params.setUrl(url);
    params.setTarget(target);

    return POST("HTMLGetTargetedSentiment", "html", params);
  }