## org.w3c.jigsaw.ssi.jdbc
Class jdbcCommand

    java.lang.Object
      |
      +--org.w3c.jigsaw.ssi.jdbc.jdbcCommand

public class jdbcCommand
extends java.lang.Object
implements Command

Implementation of the SSI `jdbc` command.

Constructor Summary
`jdbcCommand()`

Method Summary
`boolean` `acceptCaching()` return true if reply can be cached.
`protected void` `addSet(java.util.Dictionary d, java.lang.String name, Request request, java.sql.ResultSet set)`
`Reply` `execute(SSIFrame ssiframe, Request request, ArrayDictionary parameters, java.util.Dictionary variables)` Executes this command.
`protected java.sql.Connection` `getConnection(java.lang.String driver, java.lang.String url, java.lang.String user, java.lang.String password)`
`java.lang.String` `getName()` Returns the name of this command.
`protected java.sql.ResultSet` `getSet(java.util.Dictionary d, java.lang.String name, Request request)`
`java.lang.String` `getValue(java.util.Dictionary variables, java.lang.String var, Request request)` Returns the (String) value of the given variable.
`protected boolean` `hasMoreValue(java.util.Dictionary d, java.lang.String name, Request request)`
`protected java.sql.ResultSet` `performSelect(java.sql.Connection conn, java.lang.String cmd)`
`protected void` `sethasMoreValueFlag(java.util.Dictionary d, java.lang.String name, Request request, boolean flag)`

Methods inherited from class java.lang.Object
`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

Constructor Detail

### jdbcCommand

    public jdbcCommand()

Method Detail

### acceptCaching

    public boolean acceptCaching()

  return true if reply can be cached.
  Specified by:
    acceptCaching in interface Command
  Returns:
    a boolean.

### getConnection

    protected java.sql.Connection getConnection(java.lang.String driver,
                                                java.lang.String url,
                                                java.lang.String user,
                                                java.lang.String password)

### performSelect

    protected java.sql.ResultSet performSelect(java.sql.Connection conn,
                                               java.lang.String cmd)

### addSet

    protected void addSet(java.util.Dictionary d,
                          java.lang.String name,
                          Request request,
                          java.sql.ResultSet set)

### getSet

    protected java.sql.ResultSet getSet(java.util.Dictionary d,
                                        java.lang.String name,
                                        Request request)

### getName

    public java.lang.String getName()

  Description copied from interface: Command
  Returns the name of this command. (Case sensitivity is up to the `lookupCommand` method in the command registry.)
  Specified by:
    getName in interface Command
  Tags copied from interface: Command
  Returns:
    the name of the command
  See Also:
    `CommandRegistry.lookupCommand(java.lang.String)`

### getValue

    public java.lang.String getValue(java.util.Dictionary variables,
                                     java.lang.String var,
                                     Request request)

  Description copied from interface: Command
  Returns the (String) value of the given variable.
  Specified by:
    getValue in interface Command
  Tags copied from interface: Command
  Returns:
    a String instance.

### sethasMoreValueFlag

    protected void sethasMoreValueFlag(java.util.Dictionary d,
                                       java.lang.String name,
                                       Request request,
                                       boolean flag)

### hasMoreValue

    protected boolean hasMoreValue(java.util.Dictionary d,
                                   java.lang.String name,
                                   Request request)

### execute

    public Reply execute(SSIFrame ssiframe,
                         Request request,
                         ArrayDictionary parameters,
                         java.util.Dictionary variables)

  Description copied from interface: Command
  Executes this command. Might modify variables. Must not modify the parameters.

  It may handle conditional requests, except that if it replies with a status of HTTP.NOT_MODIFIED, it must still reply with a content (the same content that it would have returned for an inconditional request). This is because further SSI commands down the line may decide thay they have been modified, and then a content must be emitted by SSIFrame.

  Specified by:
    execute in interface Command
  Tags copied from interface: Command
  Parameters:
    `request` - the original HTTP request
    `parameters` - The parameters for this command
    `variables` - The global variables for the parse
  Returns:
    a Reply with the output from the command