By: Team CS2113-AY1819S1-T13-2
Since: Aug 2018
Licence: MIT
- 1. Introduction
- 2. Quick Start
- 3. Features
- 3.1. Viewing help :
help
- 3.2. logIn to the forum :
login
- 3.3. Listing all the modules :
listModule
- 3.4. Listing all the forumThreads :
selectModule
- 3.5. Listing all the comments :
selectThread
- 3.6. Creating a new forumThread :
createThread
- 3.7. Creating a new comment :
createComment
- 3.8. Updating a forumThread title :
updateThread
- 3.9. Updating a comment content :
updateComment
- 3.10. deleting a forumThread :
deleteThread
- 3.11. deleting a comment :
deleteComment
- 3.12. Announcing new command :
announce
- 3.13. Checking for the latest announcement :
checkAnnounce
- 3.14. Blocking a user from creating thread or comment :
blockUser
- 3.15. Setting a user as admin or revert an admin to user :
setAdmin
- 3.16. Creating a new module :
createModule
- 3.17. Updating a module :
updateModule
- 3.18. Deleting a module :
deleteModule
- 3.19. Updating password :
updatePass
- 3.20. Delete a user(Admin) :
deleteUser
- 3.21. Delete a user(User) :
deleteMe
- 3.22. Logout from the forum :
logout
- 3.23. Saving the data
- 3.24. Security
- 3.1. Viewing help :
- 4. FAQ
- 5. Command Summary
1. Introduction
ForumBook (FB) is for those who prefer to use a desktop app for module ForumBook. More importantly, FB is optimized for those who prefer to work with a Command Line Interface (CLI) while still having the benefits of a Graphical User Interface (GUI). If you can type fast, FB can be a great place to learn and share comments regarding modules offered in NUS.This can be done faster than traditional GUI apps. Can’t wait? Jump to the Section 2, “Quick Start” to get started. Enjoy!
2. Quick Start
-
Ensure you have Java version
9
or later installed in your Computer. -
Download the latest
ForumBook.jar
here. -
Copy the file to the folder you want to use as the home folder for your Forum Book.
-
Double-click the file to start the app. The GUI should appear in a few seconds.
-
Type the command in the command box and press Enter to execute it.
e.g. typinghelp
and pressing Enter will open the help window. -
There are two types of users in ForumBook: user and admin
-
Without logging in, you could:
-
Register using
addUser uName/john uPass/123
-
Login using
login uName/john uPass/123
-
-
As a user, you could:
-
Show help using
help
-
List all the modules using
listModule
-
Select a module to check the threads under that module using
selectModule mCode/CS2113
-
Select a thread among the threads listed using
selectThread tId/1
-
Create a comment under a thread using
createComment tId/1 cContent/This is a new comment
-
Update a comment created by you using
updateComment cId/1 cContent/This is a new comment
-
Delete a comment created by you using
deleteComment cId/1
-
Create a thread under a module using
createThread mCode/CS2113 tTitle/About exams? cContent/Is there any exam?
-
Update a thread created by you using
updateThread tId/1 tTitle/Is there any midterm?
-
Delete a thread created by you using
deleteThread tId/1
-
Check for latest announcement using
checkAnnounce
-
Delete himself from the ForumBook using 'deleteMe'
-
Logout from ForumBook using
logout
-
Exits the app using
exit
-
-
As an admin, you could do anything that an ordinary user could do and the following:
-
Post new announcement using
announce aTitle/Urgent! aContent/System maintenance from 3pm to 5pm
-
Update a given user’s password using
updatePass uName/john uPass/456
-
Block a given user using
blockUser uName/john block/true
-
Create a new module using
createModule mCode/MA1508E mTitle/Linear Algebra
-
Delete a module using
deleteModule mCode/MA1508E
-
Update a comment created by other user using
updateComment cId/1 cContent/This is a new comment by admin
-
Delete a comment created by other user using
deleteComment cId/1
-
Update a thread created by other user using
updateThread tId/1 tTitle/This is updated by admin
-
Delete a thread created by other user using
deleteThread tId/1
-
Set a user as an admin using
setAdmin uName/john set/true
-
Delete a given user using
deleteUser uName/john
-
-
-
Note that we populate ForumBook with default data:
-
Default admin: uName/admin uPass/admin
-
Default user: uName/user1 uPass/user1
-
Default module: mCode/CS2113 mTitle/Software Eng
-
Default thread under CS2113: tTitle/Hey How is CS2113
-
Default content under that thread: cContent/I am taking this module next sem, how is it?
-
Default announcement: aTitle/Welcome! aContent/Welcome to ForumBook
-
-
Refer to Section 3, “Features” for details of each command.
3. Features
Command Format
-
Words in
UPPER_CASE
are the parameters to be supplied by the user e.g. inaddUser uName/USER_NAME uPass/USER_PASSWORD
,USER_NAME
andUSER_PASSWORD
are parameters supplied by user inaddUser uName/john uPass/123
. -
Parameters can be in any order e.g. if the command specifies
mCode/CS2113 tTitle/Is there mid-terms?
,tTitle/Is there mid-terms? mCode/CS2113
is also acceptable. -
Command keywords are case sensitive. e.g.
adduser
,DELETECOMMENT
is not recognised.
3.1. Viewing help : help
Format: help
=== Register a new User : addUser
Register a New User to the Forum. User Name is unique and case sensitive.
Format: addUser uName/USER NAME uPass/USER PASSWORD
Examples:
-
addUser uName/user1 uPass/user1
3.2. logIn to the forum : login
Login to the forum with a registered user name and password.
Format: login uName/USER NAME uPass/USER PASSWORD
Examples:
-
login uName/user1 uPass/user1
3.3. Listing all the modules : listModule
List all the existing modules in the forum book.
Format: listModule
Examples:
-
listModule
3.4. Listing all the forumThreads : selectModule
List all the existing forumThreads under a specific module that exists as well.
Format: selectModule mCode/MODULE CODE
Examples:
-
selectModule mCode/CS2113
3.5. Listing all the comments : selectThread
List all the existing comments under a specific forumThread that exists as well.
Format: selectThread tId/THREAD ID
Examples:
-
selectThread tId/123
3.6. Creating a new forumThread : createThread
Create a new forumThread under a specific module that exists
Format: createThread mCode/MODULE CODE tTitle/THREAD TITLE cContent/COMMENT CONTENT
Examples:
-
createThread mCode/CS2113 tTitle/Exam Information cContent/All the best for the final guys
3.7. Creating a new comment : createComment
Create a new comment under a specific forumThread that exists.
Format: createComment tId/THREAD ID cContent/COMMENT CONTENT
Examples:
-
createComment tId/1 cContent/This is a new comment
3.8. Updating a forumThread title : updateThread
Update an existing forumThread title in the forum book.
Format: updateThread tId/THREAD ID tTitle/NEW THREAD TITLE
Examples:
-
updateThread tId/123 tTitle/This is a new title
3.9. Updating a comment content : updateComment
Update an existing comment title in the forum book.
Format: updateComment cId/COMMENT ID cContent/NEW COMMENT CONTENT
Examples:
-
updateComment tId/123 tTitle/This is a new title
3.10. deleting a forumThread : deleteThread
Delete an existing forumThread in the forum book.
Format: deleteThread tId/THREAD ID
Examples:
-
deleteThread tId/1
3.11. deleting a comment : deleteComment
Delete an existing comment in the forum book.
Format: deleteComment cId/COMMENT ID
Examples:
-
deleteComment cId/1
3.12. Announcing new command : announce
Announce the new announcement created by admin. The first character of announcement title and content must not be a whitespace.
Format: announce aTitle/ANNOUNCEMENT_TITLE aContent/ANNOUNCEMENT_CONTENT
Example:
-
announce aTitle/Urgent! aContent/System maintenance from 4pm to 5pm.
3.13. Checking for the latest announcement : checkAnnounce
Check for the latest announcement.
Format: checkAnnounce
3.14. Blocking a user from creating thread or comment : blockUser
Block a specific user that match the given argument by admin. User to be blocked must not be an admin. block
only takes true
or false
Format: blockUser uName/USER_NAME block/BLOCK_OR_UNBLOCK
Example:
-
blockUser uName/john block/true
-
blockUser uName/john block/false
3.15. Setting a user as admin or revert an admin to user : setAdmin
Set a user as an admin or revert an admin to user. The user to set as admin must not been blocked. set
only takes true
or false
Format: setAdmin uName/USER_NAME set/SET_OR_REVERT
Examples:
-
setAdmin uName/john set/true
-
setAdmin uName/john set/false
3.16. Creating a new module : createModule
Create a new module by admin. Module code should follow (2 or 3 capital letters) + (4 numbers) + (0 or 1 capital letter) and it should not be blank. E.g. MA1580E, CS2113 or USP1000A, USP1000. Module title should only contain letters and spaces.+
Format: createModule mCode/MODULE_CODE mTitle/MODULE_TITLE
Example:
-
createModule mCode/CS2113 mTitle/Software Engineering and OOP
3.17. Updating a module : updateModule
Update an existing module by admin. Note that either one of mCode and mTitle has to be specified
Format: updateModule mId/MODULE_ID [mCode/MODULE_CODE] [mTitle/MODULE_TITLE]
Examples:
-
updateModule mId/3 mCode/CS1221
-
updateModule mId/3 mTitle/Random CS module
-
updateModule mId/3 mCode/CS1221 mTitle/Random CS module
3.18. Deleting a module : deleteModule
Delete an existing module by admin.
Format: deleteModule mCode/MODULE_CODE
Example:
-
deleteModule mCode/CS2113
3.19. Updating password : updatePass
Update the given user’s password by admin.
Format: updatePass uName/USER_NAME uPass/USER_PASSWORD
Example:
-
updatePass uName/john uPass/098
3.20. Delete a user(Admin) : deleteUser
Delete a given user by admin.
Format: deleteUser uName/USER_NAME
Example:
-
deleteUser uName/john
3.21. Delete a user(User) : deleteMe
User deletes himself from the ForumBook.
Format: deleteMe
Example:
-
deleteMe
3.22. Logout from the forum : logout
Logout from the Forum.
Format: logout
=== Exiting the program : exit
Exits the program.
Format: exit
3.23. Saving the data
Forum book data are saved in the hard disk automatically after any command that changes the data.
There is no need to save manually.
3.24. Security
All data including user credential and application data are encrypted on your disk. You don’t need to worry about other people who have access to your computer steal your information.
4. FAQ
Q: How do I transfer my data to another Computer?
A: Install the app in the other computer and overwrite the empty data file it creates with the file that contains the data of your previous Forum Book folder.`
Q: What if I forget my password?
A: Ask an admin to help, he/she has the privilege to reset your password.
Q: How do I uninstall this application?
A: Just delete the folder containing this application, it does not touch any other part of your computer.
Q: What if I want change my password?
A: Ask an admin to help, he/she has the privilege to change your password. Alternatively, User can delete their account and re-create with your desired Password.
5. Command Summary
-
Help:
help
-
RegisterUser :
addUser uName/USER NAME uPass/USER PASSWORD
e.gaddUser uName/MyName uPass/password
-
Login :
login uName/USER NAME uPass/USER PASSWORD
e.glogin uName/MyName uPass/password
-
createThread :
createThread mCode/MODULE CODE tTitle/THREAD TITLE cContent/COMMENT CONTENT
e.gcreateThread mCode/CS2113 tTitle/Exam Information cContent/All the best for the final guys
-
createComment :
createComment tId/THREAD ID cContent/COMMENT CONTENT
e.gcreateComment tId/1 cContent/This is a new comment
-
updateThread :
updateThread tId/THREAD ID tTitle/NEW THREAD TITLE
e.gupdateThread tId/123 tTitle/This is a new title
-
updateComment :
updateComment cId/COMMENT ID cContent/NEW COMMENT CONTENT
e.gupdateComment tId/123 tTitle/This is a new title
-
deleteThread :
deleteThread tId/THREAD ID
e.gdeleteThread tId/1
-
deleteComment :
deleteComment cId/COMMENT ID
e.gdeleteComment cId/1
-
listModule:
listModule
-
selectModule :
selectModule mCode/MODULE CODE
e.gselectModule mCode/CS2113
-
selectThread :
selectThread tId/THREAD ID
e.gselectThread tId/123
-
Announce :
announce aTitle/ANNOUNCEMENT_TITLE aContent/ANNOUNCEMENT_CONTENT
e.gannounce aTitle/Urgent! aContent/System maintenance from 4pm to 5pm.
-
CheckAnnounce :
checkAnnounce
-
BlockUser :
blockUser uName/USER_NAME block/BLOCK_UNBLOCK
e.gblockUser uName/john block/false
-
SetAdmin :
setAdmin uName/USER_NAME set/SET_OR_REVERT
e.gsetAdmin uName/john set/true
-
CreateModule :
createModule mCode/MODULE_CODE mTitle/MODULE_TITLE
e.gcreateModule mCode/CS2113 mTitle/Software Engineering and OOP
-
UpdateModule :
updateModule mId/MODULE_ID [mCode/MODULE_CODE] [mTitle/MODULE_TITLE]
e.gupdateModule mId/3 mCode/CS1221
e.gupdateModule mId/3 mTitle/Random CS module
e.gupdateModule mId/3 mCode/CS1221 mTitle/Random CS module
-
DeleteModule :
deleteModule mCode/MODULE_CODE
e.gdeleteModule mCode/CS2113
-
UpdatePass :
updatePass uName/USER_NAME uPass/USER_PASSWORD
e.gupdatePass uName/john uPass/098
-
DeleteUser(Admin) :
deleteUser uName/USER_NAME
e.gdeleteUser uName/john
-
DeleteUser(User) :
deleteMe
-
Logout :
logout