All Packages  Class Hierarchy  This Package  Previous  Next  Index

Class ch.swisslife.ibgm.mc2.OutputChannel

java.lang.Object
   |
   +----ch.swisslife.ibgm.mc2.OutputChannel

public class OutputChannel
extends Object
Implements an output channel as an interface between applet and cgi script. It sends line by line to the cgi. It uses a URLConnection for the communication, which means that the data is transfered as plain text from the web server. This class parses it, creates a Cfg object an fills the data in.


Variable Index

 o connectionIsOpen
 o URL_OF_CGI

Constructor Index

 o OutputChannel(String, String, String, String)
Opens a connection to the cgi which feeds it into cfg file

Method Index

 o closeConnection()
Closes the connection and gives back the feedback from cgi.
 o sendLine(String)
Sends a line to the cgi script.

Variables

 o URL_OF_CGI
 public String URL_OF_CGI
 o connectionIsOpen
 public boolean connectionIsOpen

Constructors

 o OutputChannel
 public OutputChannel(String cmd,
                      String url,
                      String backupUrl,
                      String cgiURL)
Opens a connection to the cgi which feeds it into cfg file

Parameters:
cmd - String to determine if it should be written or deleted
url - url of the file
backupUrl - url of the backup file
Returns:
true if successful. falseotherwise

Methods

 o sendLine
 public boolean sendLine(String line)
Sends a line to the cgi script.

Parameters:
line - String with line to send in it
Returns:
true if successful, falseotherwise.
 o closeConnection
 public boolean closeConnection()
Closes the connection and gives back the feedback from cgi.

Returns:
true if successful, false otherwise.

All Packages  Class Hierarchy  This Package  Previous  Next  Index