public class OpenIEServlet
extends javax.servlet.http.HttpServlet
| Constructor and Description |
|---|
OpenIEServlet() |
| Modifier and Type | Method and Description |
|---|---|
void |
annotate(StanfordCoreNLP pipeline,
Annotation ann)
Annotate a document (which is usually just a sentence).
|
void |
doGet(javax.servlet.http.HttpServletRequest request,
javax.servlet.http.HttpServletResponse response) |
void |
doPost(javax.servlet.http.HttpServletRequest request,
javax.servlet.http.HttpServletResponse response) |
void |
init()
Set the properties to the paths they appear at on the servlet.
|
static void |
main(java.lang.String[] args)
A helper so that we can see how the servlet sees the world, modulo model paths, at least.
|
static java.lang.String |
quote(java.lang.String string)
Originally extracted from Jettison; copied from http://stackoverflow.com/questions/3020094/how-should-i-escape-strings-in-json
|
doDelete, doHead, doOptions, doPut, doTrace, getLastModified, service, servicepublic void init()
throws javax.servlet.ServletException
init in class javax.servlet.GenericServletjavax.servlet.ServletException - Thrown by the implementationpublic void annotate(StanfordCoreNLP pipeline, Annotation ann)
public static java.lang.String quote(java.lang.String string)
string - The string to quote.public void doGet(javax.servlet.http.HttpServletRequest request,
javax.servlet.http.HttpServletResponse response)
throws javax.servlet.ServletException,
java.io.IOException
doGet in class javax.servlet.http.HttpServletjavax.servlet.ServletExceptionjava.io.IOExceptionpublic void doPost(javax.servlet.http.HttpServletRequest request,
javax.servlet.http.HttpServletResponse response)
throws javax.servlet.ServletException,
java.io.IOException
doPost in class javax.servlet.http.HttpServletjavax.servlet.ServletExceptionjava.io.IOExceptionpublic static void main(java.lang.String[] args)
throws javax.servlet.ServletException,
java.io.IOException
javax.servlet.ServletExceptionjava.io.IOException