Skip navigation links
A B C D E F G H I L M N P R S U W 

A

addFriend(String) - Static method in class CommandProcessor
Adds a new friend.
addFriend(String) - Method in class User
add a friend to this user
addFriendToBcast(String, String) - Static method in class CommandProcessor
adds a friend to a broadcast list.
ALREADY_A_FRIEND - Static variable in class Config
This is shown if the nickname is already a friend
ALREADY_PRESENT - Static variable in class Config
This is shown if the supplied nickname is already present in the broadcast list

B

BCAST_LIST_DOES_NOT_EXIST - Static variable in class Config
This is shown if the broadcast list on which some operation is to be performed does not exist
BroadcastList - Class in <Unnamed>
This is the broadcast list class which captures information of a broadcast list
BroadcastList(String, List<String>) - Constructor for class BroadcastList
Constructs a new instance of this class.

C

CANT_ADD_YOURSELF_TO_BCAST - Static variable in class Config
This is shown if trying to add the user to one of his own broadcast lists
CANT_BE_EMPTY_OR_NULL - Static variable in class Config
Encapsulate this string inside most instances of WhatsAppRuntimeException
CANT_BE_OWN_FRIEND - Static variable in class Config
This is shown if trying to add the user as his own friend
CANT_LOCATE - Static variable in class Config
This is shown if you cannot locate the nickname supplied for various operations.
CANT_SEND_YOURSELF - Static variable in class Config
This is shown if trying to send a message to the same user
CommandProcessor - Class in <Unnamed>
The most important class.
CommandProcessor() - Constructor for class CommandProcessor
 
Config - Class in <Unnamed>
A class implementing the singleton pattern (only one instance of this class can every exist) You cannot instantiate this class from outside by using the new operator.

D

doLogin() - Static method in class CommandProcessor
A method to do login.
doLogout() - Static method in class CommandProcessor
A method to logout the user.

E

ENTER_COMMAND - Static variable in class Config
This is the prompt for the logged in user to enter a command
ERROR_IO - Static variable in class Config
This is shown if some error occurs while reading the input file
EXITING - Static variable in class Config
Show this just before exiting the program when the exit: command is issued

F

FILE_DOES_NOT_EXIST - Static variable in class Config
This is shown if the input file does not exist

G

getAllUsers() - Method in class Config
returns the list of the global contacts
getBroadcastListFromNickname(List<BroadcastList>, String) - Static method in class Helper
Given a nickname as a String return the BroadcastList from the List of BroadcastLists
getBroadcastLists() - Method in class User
A getter for the list of broadcast lists owned by this user
getBroadcastNickname() - Method in class Message
A getter for the broadcastNickname
getConsoleInput() - Method in class Config
returns the only way you can obtain input from the keyboard (its a Scanner)
getConsoleOutput() - Method in class Config
returns the only way you can write output to screen (its a PrintStream)
getCurrentUser() - Method in class Config
returns the currently logged in user object
getFirstName() - Method in class User
A getter for the first name
getFriends() - Method in class User
A getter for the list of friends of this user
getFromNickname() - Method in class Message
A getter for the fromNickname
getInstance() - Static method in class Config
This static method is used to return the only instance existing for the Config class
getLastName() - Method in class User
a getter to return the last name
getMembers() - Method in class BroadcastList
A getter of the list of members of this broadcast list
getMessage() - Method in class Message
A getter for the message string
getMessages() - Method in class User
A getter for the list of all the user messages both sent and received
getNickname() - Method in class BroadcastList
A getter of the nickname
getNickname() - Method in class User
A getter for the nickname
getPassword() - Method in class User
A getter for the user password
getSentTime() - Method in class Message
A getter for the time at which this message was sent
getToNickname() - Method in class Message
A getter for the toNickname
getUserFromNickname(List<User>, String) - Static method in class Helper
Given a nickname as a String return the User object from the List of Users

H

Helper - Class in <Unnamed>
A few helper static methods
Helper() - Constructor for class Helper
 

I

INVALID_COMMAND - Static variable in class Config
This is shown when the entered command is not valid
INVALID_CREDENTIALS - Static variable in class Config
This is shown if the nickname/password pair is incorrect
isBroadcastList(String) - Method in class User
this method check whether supplied nickname is a broadcast list of this user object
isExistingGlobalContact(String) - Static method in class Helper
Given a nickname determine whether a User exists globally with that nickname
isExistingNickname(String) - Method in class User
checks if the supplied nickname is associated with this user object.
isFriend(String) - Method in class User
this method check whether supplied nickname is a friend of this user object
isMemberOfBroadcastList(String, String) - Method in class User
checks whether the supplied nickname is part of the broadcastNickname list both associated with this user object
isRead() - Method in class Message
A getter for the read flag which indicates whether the message has been read

L

LOGIN_PROMPT - Static variable in class Config
This is shown to the logged in user for getting a command

M

main(String[]) - Static method in class WhatsApp
 
Message - Class in <Unnamed>
This is the message class which captures information of a message Every logical message will result in at least two Message objects.
Message(String, String, String, Date, String, boolean) - Constructor for class Message
A constructor to instantiate this class.
MESSAGE_FORMAT - Static variable in class Config
This is the message template to be used in read message commands
MESSAGE_SENT_SUCCESSFULLY - Static variable in class Config
This is shown when a message is sent successfully to the intended receiver(s)

N

NICKNAME_DOES_NOT_EXIST - Static variable in class Config
This is shown if the nickname is not an existing global contact
NO_MESSAGES - Static variable in class Config
This is shown if there are no messages to be shown as a result of any of the read messages commands
NO_RESULTS_FOUND - Static variable in class Config
This is shown for search commands when they show no users that match the search criteria
NOT_A_FRIEND - Static variable in class Config
This is shown if the supplied nickname is not a friend
NOT_PART_OF_BCAST_LIST - Static variable in class Config
This is shown if the user nickname is not a member of the broadcast list nickname

P

PASSWORD_PROMPT - Static variable in class Config
This is shown to get the password while login
populateData(String) - Static method in class Helper
Populate data from the file with the given path
processCommand(String) - Static method in class CommandProcessor
Processes commands issued by the logged in user.

R

readMessage(String, boolean) - Static method in class CommandProcessor
Displays messages from the message list of the user logged in.
removeBroadcastcast(String) - Static method in class CommandProcessor
A method to remove a broadcast list.
removeBroadcastList(String) - Method in class User
this method removes a broadcast list from this user object
removeFriend(String) - Static method in class CommandProcessor
removes an existing friend.
removeFriend(String) - Method in class User
remove a friend from this user object
removeFriendFromBcast(String, String) - Static method in class CommandProcessor
removes a friend from a broadcast list.

S

search(String, boolean) - Static method in class CommandProcessor
Method to do a user search.
sendMessage(String, String) - Static method in class CommandProcessor
A method to send a message.
setAllUsers(List<User>) - Method in class Config
sets the list of global users
setBroadcastLists(List<BroadcastList>) - Method in class User
A setter for the list of broadcast lists owned by this user
setBroadcastNickname(String) - Method in class Message
A setter for the broadcastNickname
setConsoleInput(Scanner) - Method in class Config
a setter for the Scanner object that should be used to obtain input from the keyboard
setConsoleOutput(PrintStream) - Method in class Config
a setter for the PrintStream object that should be used to write to the screen
setCurrentUser(User) - Method in class Config
sets the currently logged in user object.
setFirstName(String) - Method in class User
A setter for the first name
setFriends(List<User>) - Method in class User
A setter for the list of all friends of this user
setFromNickname(String) - Method in class Message
A setter for the fromNickname
setLastName(String) - Method in class User
A setter for the last name
setMembers(List<String>) - Method in class BroadcastList
A setter of the list of members of this broadcast list
setMessage(String) - Method in class Message
A setter for the message string
setMessages(List<Message>) - Method in class User
A setter for the list of all the user messages
setNickname(String) - Method in class BroadcastList
A setter of the nickname of this broadcast list
setNickname(String) - Method in class User
A setter for the nickname
setPassword(String) - Method in class User
A setter for the use password
setRead(boolean) - Method in class Message
A setter for the read flag which indicates whether the message has been read
setSentTime(Date) - Method in class Message
A setter for the time at which this message was sent
setToNickname(String) - Method in class Message
A setter for the toNickname
SOMETHING_EXISTS - Static variable in class Config
This is shown if another user with the same nickname already exists
SUCCESSFULLY_ADDED - Static variable in class Config
This is shown as part of various add operations that may be performed as part of commands
SUCCESSFULLY_LOGGED_IN - Static variable in class Config
This is shown if the user provides valid credentials
SUCCESSFULLY_LOGGED_OUT - Static variable in class Config
This is shown after a logout: command is issued by a logged in user
SUCCESSFULLY_REMOVED - Static variable in class Config
This is shown as part of various removal operations that may be performed as part of commands

U

USAGE - Static variable in class Config
This is the usage string to be shown if the number of command line arguments is not exactly one
User - Class in <Unnamed>
This is the user class which captures profile information of a single user
User(String, String, String, String, List<Message>, List<User>, List<BroadcastList>) - Constructor for class User
A constructor to instantiate this class.
USER_DISPLAY_FOR_SEARCH - Static variable in class Config
This is used as a template while showing user information for search commands

W

WhatsApp - Class in <Unnamed>
The main class.It's a minimal class which hosts only the main method.
WhatsApp() - Constructor for class WhatsApp
 
WhatsAppException - Exception in <Unnamed>
A simple exception class for functional issues that can arise from various operations
WhatsAppException(String) - Constructor for exception WhatsAppException
Construct a new instance of this exception with a custom message
WhatsAppRuntimeException - Exception in <Unnamed>
A simple exception class for validation errors like null or empty values
WhatsAppRuntimeException(String) - Constructor for exception WhatsAppRuntimeException
Construct an instance of this exception with a custom message
WhatsAppRuntimeException() - Constructor for exception WhatsAppRuntimeException
Construct an instance of this exception without any message
A B C D E F G H I L M N P R S U W 
Skip navigation links