com.scriptel.easyscript.example

## Class Example

- java.lang.Object
- - javax.servlet.GenericServlet
  - - javax.servlet.http.HttpServlet
    - - com.scriptel.easyscript.example.Example

- All Implemented Interfaces:
    java.io.Serializable, javax.servlet.Servlet, javax.servlet.ServletConfig

      @WebServlet(name="Example",
                  urlPatterns="/")
      public class Example
      extends javax.servlet.http.HttpServlet

  A quick example showing how to use the EasyScript device in Java in a Servlet environment.
  See Also:
    Serialized Form

- - ### Constructor Summary

    Constructors
    Constructor and Description
    `Example()`

  - ### Method Summary

    All Methods Instance Methods Concrete Methods
    Modifier and Type | Method and Description
    --- | ---
    `protected void` | `doGet(javax.servlet.http.HttpServletRequest request, javax.servlet.http.HttpServletResponse response)` Handles the normal browser "GET" method and returns a web page.
    `protected void` | `doPost(javax.servlet.http.HttpServletRequest request, javax.servlet.http.HttpServletResponse response)` Handles the "POST" method where we're handing an EasyScript string submitted through a form.
    `java.lang.String` | `getServletInfo()` Returns a short description of the servlet.

    - ### Methods inherited from class javax.servlet.http.HttpServlet

      `doDelete, doHead, doOptions, doPut, doTrace, getLastModified, service, service`

    - ### Methods inherited from class javax.servlet.GenericServlet

      `destroy, getInitParameter, getInitParameterNames, getServletConfig, getServletContext, getServletName, init, init, log, log`

    - ### Methods inherited from class java.lang.Object

      `clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

- - ### Constructor Detail

    - #### Example

          public Example()

  - ### Method Detail

    - #### doGet

          protected void doGet(javax.servlet.http.HttpServletRequest request,
                               javax.servlet.http.HttpServletResponse response)
                        throws javax.servlet.ServletException,
                               java.io.IOException

      Handles the normal browser "GET" method and returns a web page. Just loads "index.html".
      Overrides:
        `doGet` in class `javax.servlet.http.HttpServlet`
      Parameters:
        `request` - servlet request
        `response` - servlet response
      Throws:
        `javax.servlet.ServletException` - if a servlet-specific error occurs
        `java.io.IOException` - if an I/O error occurs

    - #### doPost

          protected void doPost(javax.servlet.http.HttpServletRequest request,
                                javax.servlet.http.HttpServletResponse response)
                         throws javax.servlet.ServletException,
                                java.io.IOException

      Handles the "POST" method where we're handing an EasyScript string submitted through a form.
      Overrides:
        `doPost` in class `javax.servlet.http.HttpServlet`
      Parameters:
        `request` - servlet request
        `response` - servlet response
      Throws:
        `javax.servlet.ServletException` - if a servlet-specific error occurs
        `java.io.IOException` - if an I/O error occurs

    - #### getServletInfo

          public java.lang.String getServletInfo()

      Returns a short description of the servlet.
      Specified by:
        `getServletInfo` in interface `javax.servlet.Servlet`
      Overrides:
        `getServletInfo` in class `javax.servlet.GenericServlet`
      Returns:
        a String containing servlet description