< A B C D E F G H I K L M N O P R S T U V W

<

() - Static method in class Chat.Chat
Initializes defaultHost with resolved value.

A

actionPerformed(ActionEvent) - Method in class Chat.AWTConsole
Handles buttons pressed, invokes dialogs and console commands.
actionPerformed(ActionEvent) - Method in class Chat.AWTConsole.Setup
When O.K. button is pressed, stores the field values.
actionPerformed(ActionEvent) - Method in class Chat.AWTConsole.Connect
When O.K. button is pressed, stores the field values.
add(String, String, int) - Method in class Chat.HostList
Adds a remote user to hostlist.
addCheckbox(Checkbox) - Method in class Chat.StandardDialog
Adds a checkbox to a gridbag layout.
addLabeledField(Label, TextField) - Method in class Chat.StandardDialog
Adds a file dwith label to a gridbag layout.
addOkAndCancel() - Method in class Chat.StandardDialog
Adds default buttons to a gridbag layout, on a separate Panel.
array - Variable in class Chat.HostList.HostIterator
Cached array of list members, used for iterating.
AWTConsole - class Chat.AWTConsole.
Implementation of AWT based console.
AWTConsole.Connect - class Chat.AWTConsole.Connect.
A dialog for connecting to the network.
AWTConsole.Connect(AWTConsole, Frame) - Constructor for class Chat.AWTConsole.Connect
Creates and initalizes the dialog.
AWTConsole.Setup - class Chat.AWTConsole.Setup.
A dialog for setting up the local user identity - nickname, host and port.
AWTConsole.Setup(AWTConsole, Frame) - Constructor for class Chat.AWTConsole.Setup
Creates and initalizes the dialog.
AWTConsole() - Constructor for class Chat.AWTConsole
Creates and initalizes the window, places the controls into a GridBag layout.

B

BasicWindow - class Chat.BasicWindow.
A class derived from Frame implementing the WindowListener interface by empty methods.
BasicWindow() - Constructor for class Chat.BasicWindow
 

C

clear() - Method in class Chat.HostList
Clears the hostlist.
clearButton - Variable in class Chat.AWTConsole
A button for appropriate console command.
close() - Method in interface Chat.Console
Closes the console window.
close() - Method in class Chat.TextConsole
Implementation is empty in this class.
close() - Method in class Chat.AWTConsole
 
connect(String, int, boolean) - Method in class Chat.Sender
Connects to host specified and fills the hostlist with the data returned.
connect(String, String) - Method in class Chat.Sender
Registers this host on the server, and tries to connect to one of the hosts on the list returned.
connectButton - Variable in class Chat.AWTConsole
A button for appropriate console command.
console - Variable in class Chat.HostList
A link to the console - used solely for updating the user list.
console - Variable in class Chat.Receiver
The link to common console.
console - Variable in class Chat.Sender
The link to common console.
Console - interface Chat.Console.
The interface which defines a console for worker classes.
CreateChat(Console) - Static method in class Chat.Chat
Create a new chat instance with no identity set up.
CreateChat(Console, String, String, int) - Static method in class Chat.Chat
Create a new chat instance with given identity.
CreateChat(Console, String, String, int, String, String) - Static method in class Chat.Chat
Create a new chat instance with given identity and connect to network via server.
Chat - class Chat.Chat.
A main application class with several static methods used to start the application.
Chat() - Constructor for class Chat.Chat
 

D

decode(String, BufferedReader, int) - Static method in class Chat.FileTransfer
Decodes the stream in and writes the data to file.
defaultHost - Static variable in class Chat.Chat
A default local host IP, resolved at startup.
defaultPort - Static variable in class Chat.Chat
A default local listening port, set to 6060.
defaultURL - Static variable in class Chat.Chat
A default URL for server directed connection.
delete(String) - Method in class Chat.HostList
Deletes a remote user from hostlist.
disconnect() - Method in class Chat.Sender
Disconnects from the network.
disconnectButton - Variable in class Chat.AWTConsole
A button for appropriate console command.

E

encode(String, PrintWriter) - Static method in class Chat.FileTransfer
Reads contents of file specified, encodes it and writes it out to the out stream.
err - Variable in class Chat.TextConsole
STDERR output stream stored as a PrintWriter.
error(String) - Method in interface Chat.Console
Writes an error message to the console.
error(String) - Method in class Chat.TextConsole
 
error(String) - Method in class Chat.AWTConsole
Writes an error message to the console - TextArea control.

F

file(String) - Method in class Chat.Sender
Sends a file to all the users from the hostlist, but not myself.
FileTransfer - class Chat.FileTransfer.
Encodes/decodes disk files using a BASE64 encoding.
FileTransfer() - Constructor for class Chat.FileTransfer
 

G

gridbag - Variable in class Chat.StandardDialog
The window layout used by the dialog.

H

hasNext() - Method in class Chat.HostList.HostIterator
 
host - Variable in class Chat.AWTConsole.Setup
Holds a returned value after the dialog is dismissed by OK button.
host - Variable in class Chat.AWTConsole.Connect
Holds a returned value after the dialog is dismissed by OK button.
host - Variable in class Chat.HostList.HostItem
The hostname of the user as a string, either an IP adress or a DNS name.
hostField - Variable in class Chat.AWTConsole.Setup
Stored reference to appropriate textfield.
hostField - Variable in class Chat.AWTConsole.Connect
Stored reference to appropriate textfield.
hostlist - Variable in class Chat.Receiver
The link to common host list.
hostlist - Variable in class Chat.Sender
The link to common host list.
HostList - class Chat.HostList.
Maintains a list of other chat users, as well as local user information.
HostList.HostItem - class Chat.HostList.HostItem.
A data-storage class representing an item in the list of remote users.
HostList.HostItem(HostList, String, String, int) - Constructor for class Chat.HostList.HostItem
Constructs an immutable object representing the host list item.
HostList.HostIterator - class Chat.HostList.HostIterator.
A custom thread-safe iterator over the list.
HostList.HostIterator(HostList, HostList) - Constructor for class Chat.HostList.HostIterator
Constructs a thread-safe iterator.
HostList(Console) - Constructor for class Chat.HostList
Initializes the host list with the link to console.

I

i - Variable in class Chat.HostList.HostIterator
An index of the iteration.
in - Variable in class Chat.TextConsole
STDIN input stream stored as a BufferedReader.
inputField - Variable in class Chat.AWTConsole
The input field for outgoing message to be sent.
integer() - Method in class Chat.MessageParser
Parses an integer token delimited by space.
iterator() - Method in class Chat.HostList
 

K

keyPressed(KeyEvent) - Method in class Chat.StandardDialog
 
keyPressed(KeyEvent) - Method in class Chat.AWTConsole
 
keyReleased(KeyEvent) - Method in class Chat.StandardDialog
 
keyReleased(KeyEvent) - Method in class Chat.AWTConsole
 
keyTyped(KeyEvent) - Method in class Chat.StandardDialog
Checks a key pressed for VK_ENTER and simulates pressing of O.K. button.
keyTyped(KeyEvent) - Method in class Chat.AWTConsole
Checks a key pressed for VK_ENTER and sends the entered message out.

L

line - Variable in class Chat.AWTConsole
Stores a line to be read by Sender thread .
lineToRead(String) - Method in class Chat.AWTConsole
Tries to passes the string on to a Sender thread, waiting on readLine() method.
list - Variable in class Chat.HostList.HostIterator
A link to parent HostList.

M

main(String[]) - Static method in class Chat.Chat
Starts and initializes application according to command line arguments.
MAXSIZE - Static variable in class Chat.FileTransfer
A file size limit, in bytes.
me - Variable in class Chat.HostList
Information about this (local) user.
message(String) - Method in class Chat.Sender
Sends a chat message to all the users, including myself.
MessageParser - class Chat.MessageParser.
Used by Sender and Receiver to parse both internal and external protocol messages.
MessageParser(String) - Constructor for class Chat.MessageParser
Initializes the parser with a message string.
methodGroup - Variable in class Chat.AWTConsole.Connect
A checkbox group representing the two connect methods.

N

name - Variable in class Chat.MessageParser
Stores a name (first string preceding a space) of the message.
next() - Method in class Chat.HostList.HostIterator
 
nick - Variable in class Chat.AWTConsole.Setup
Holds a returned value after the dialog is dismissed by OK button.
nick - Variable in class Chat.AWTConsole.Connect
Holds a returned value after the dialog is dismissed by OK button.
nick - Variable in class Chat.HostList.HostItem
The nickname of the user.
nickField - Variable in class Chat.AWTConsole.Setup
Stored reference to appropriate textfield.
nicks - Variable in class Chat.HostList
A separately maintained list of nicknames for updating the console user list.

O

out - Variable in class Chat.TextConsole
STDOUT output stream stored as a PrintWriter.

P

packCenterAndShow() - Method in class Chat.StandardDialog
Packs the dialog, centers it according to the owner and makes it visible.
port - Variable in class Chat.AWTConsole.Setup
 
port - Variable in class Chat.AWTConsole.Connect
 
port - Variable in class Chat.HostList.HostItem
The port used by the application.
portField - Variable in class Chat.AWTConsole.Setup
Stored reference to appropriate textfield.
portField - Variable in class Chat.AWTConsole.Connect
Stored reference to appropriate textfield.
process(BufferedReader, PrintWriter) - Method in class Chat.Receiver
Process incoming message.
process(String) - Method in class Chat.Sender
Process a command from the console.
processHandled(String) - Method in class Chat.Sender
Process a command from the console and handle caught exceptions

R

readLine() - Method in interface Chat.Console
Reads a line from the console, blocks until it is available.
readLine() - Method in class Chat.TextConsole
 
readLine() - Method in class Chat.AWTConsole
Reads a line from the console, blocks until it is available.
ready - Variable in class Chat.AWTConsole
Shows whether a message/command is ready to be read by Sender thread .
Receiver - class Chat.Receiver.
A receiver, "server" thread.
Receiver(Console, HostList) - Constructor for class Chat.Receiver
Initializes the receiver thread with the link to console and host list.
remainder() - Method in class Chat.MessageParser
Parses an remainder of the string.
remove() - Method in class Chat.HostList.HostIterator
 
room - Variable in class Chat.AWTConsole.Connect
Holds a returned value after the dialog is dismissed by OK button.
roomField - Variable in class Chat.AWTConsole.Connect
Stored reference to appropriate textfield.
run() - Method in class Chat.Receiver
Receiver thread's body.
run() - Method in class Chat.Sender
Sender thread's body.

S

send(HostList.HostItem, String) - Method in class Chat.Sender
Send a prepared message to one remote user.
send2all(String) - Method in class Chat.Sender
Send a prepared message to all users from the host list (excluding myself).
Sender - class Chat.Sender.
A sender thread.
Sender(Console, HostList) - Constructor for class Chat.Sender
Initializes the sender thread with the link to console and host list.
setIdentity(String, String, int) - Method in class Chat.HostList
Sets the identity of local user.
setTitle(String) - Method in interface Chat.Console
Sets a title of the window.
setTitle(String) - Method in class Chat.TextConsole
Implementation is empty in this class.
setTitle(String) - Method in class Chat.AWTConsole
 
setupButton - Variable in class Chat.AWTConsole
A button for appropriate console command.
StandardDialog - class Chat.StandardDialog.
An abstract class, base for simple command dialogs invoked by AWTConsole window.
StandardDialog(Frame, String) - Constructor for class Chat.StandardDialog
Creates and partly initalizes a dialog.
string() - Method in class Chat.MessageParser
Parses a string token of word characters delimited by space.

T

textArea - Variable in class Chat.AWTConsole
The main text area for received messages.
TextConsole - class Chat.TextConsole.
Implementation of text based console.
TextConsole() - Constructor for class Chat.TextConsole
Initializes member variables with system standard streams.
toString() - Method in class Chat.HostList.HostItem
 

U

updateUserList(Collection) - Method in interface Chat.Console
Updates a user list.
updateUserList(Collection) - Method in class Chat.TextConsole
Implementation is empty in this class.
updateUserList(Collection) - Method in class Chat.AWTConsole
 
url - Variable in class Chat.AWTConsole.Connect
Holds a returned value after the dialog is dismissed by OK button.
url() - Method in class Chat.MessageParser
Parses an url token delimited by space.
urlField - Variable in class Chat.AWTConsole.Connect
Stored reference to appropriate textfield.
userList - Variable in class Chat.AWTConsole
The list of other users on the net.

V

valid - Variable in class Chat.HostList.HostItem
Indicates that the object is valid, i.e. enlisted in the HostList.

W

windowActivated(WindowEvent) - Method in class Chat.BasicWindow
 
windowActivated(WindowEvent) - Method in class Chat.StandardDialog
 
windowClosed(WindowEvent) - Method in class Chat.BasicWindow
 
windowClosed(WindowEvent) - Method in class Chat.StandardDialog
 
windowClosing(WindowEvent) - Method in class Chat.BasicWindow
 
windowClosing(WindowEvent) - Method in class Chat.StandardDialog
 
windowClosing(WindowEvent) - Method in class Chat.AWTConsole
 
windowDeactivated(WindowEvent) - Method in class Chat.BasicWindow
 
windowDeactivated(WindowEvent) - Method in class Chat.StandardDialog
 
windowDeiconified(WindowEvent) - Method in class Chat.BasicWindow
 
windowDeiconified(WindowEvent) - Method in class Chat.StandardDialog
 
windowIconified(WindowEvent) - Method in class Chat.BasicWindow
 
windowIconified(WindowEvent) - Method in class Chat.StandardDialog
 
windowOpened(WindowEvent) - Method in class Chat.BasicWindow
 
windowOpened(WindowEvent) - Method in class Chat.StandardDialog
 
writeLine(String) - Method in interface Chat.Console
Writes a line to the console.
writeLine(String) - Method in class Chat.TextConsole
 
writeLine(String) - Method in class Chat.AWTConsole
Writes an error message to the console - TextArea control.

< A B C D E F G H I K L M N O P R S T U V W