Introduction

450

ClassRepo is database application that is targeted at secondary school users who prefer to use a desktop app for managing all their school-related information. ClassRepo is optimized for those who prefer to work with a Command Line Interface (CLI).

Interested? Jump to the Quick Start to get started. Enjoy!

Quick Start

  1. Ensure you have Java version 9 or later installed in your Computer.

  2. Download the latest ClassRepo.jar here.

  3. Copy the file to the folder you want to use as the home folder for your ClassRepo application.

  4. Double-click the file to start the app. The GUI should appear in a few seconds, as shown below.

    Ui
    Figure 1. UI of ClassRepo

Commands Available

This sections documents all the commands available to the user:

16 commands require Admin privileges to run
16 commands require Tutor privileges to run
16 commands require no privilege to run.

General Commands

Below are the general commands:

Viewing help : help 16

Displays the list of commands the user can run.
Format: help

Help is also shown if you enter an incorrect command e.g. abcd

Exiting the program : exit 16

Exits the program.
Format: exit

Privilege Commands

Below are the commands that deals with privilege:

Raises your privilege level : raise 16

Raises the privilege level to Admin. Requires the master password.
Format: raise PASSWORD

The default master password when first deploying ClassRepo is default_pw.

Example(s):

  • raise default_pw
    Raises your privilege level to Admin.

See your privilege level : viewpri 16

Displays your current privilege level as well as the account you are logged in as
Format: viewpri

Change the master password : editpw 16

Changes the master password. Requires the current master password and Admin privileges.
Format: editpw OLD_PASSWORD NEW_PASSWORD

Changes the master password to NEW_PASSWORD, if the provided OLD_PASSWORD is correct.

It is recommended to change the master password when first deploying ClassRepo.

Example(s):

  • editpw default_pw new_pw
    Changes the master password to "new_pw".

Sets default privilege : perm 16

Sets/Unsets the privilege to be Admin when starting a new session.
Format: perm BOOLEAN

Enter BOOLEAN as true to set the default privilege to Admin.
Enter BOOLEAN as false to set the default privilege to Basic.

This is recommended to be only done on machines that you are certain only administrators of your school have access to.

Example(s):

  • raise default_pw
    perm true
    Sets the default privilege when starting a session to be Admin.

  • raise default_pw
    perm false
    Sets the default privilege when starting a session to be Basic.

Person Commands

Below are the commands that deals with persons in the system:

Adding a person: add 16

Adds a person to the address book.
Format: add NAME [p]p/PHONE_NUMBER [p]e/EMAIL [p]a/ADDRESS [t/TAG]…​

Words in UPPER_CASE are the parameters, items in SQUARE_BRACKETS are optional, items with …​ after them can have multiple instances. Order of parameters is fixed.
Put a p before the phone/ email/address prefixes to mark it as private. private details can only be seen using the viewall command.
Persons can have any number of tags (including 0).

Example(s):

  • add John Doe p/98765432 e/johnd@gmail.com a/John street, block 123, #01-01

  • add Betsy Crowe pp/1234567 e/betsycrowe@gmail.com pa/Newgate Prison t/criminal t/friend

Listing all persons (simplied view): list 16

Shows a list of all persons in the address book.

This shows only the names of each person in the address book.
For a more detailed view, refer to List (detailed view)

Format: list

Listing all persons (detailed view) : listall 16

Displays all persons (showing all non-private details) in the address book as a list with index numbers.
Format: listall

Finding all persons containing any keyword in their name: find 16

Finds persons whose names contain any of the given keywords.
Format: find KEYWORD [MORE_KEYWORDS]

The search is case sensitive, the order of the keywords does not matter, only the name is searched, and persons matching at least one keyword will be returned (i.e. OR search).

Example(s):

  • find John
    Returns John Doe but not john.

  • find Betsy Tim John
    Returns any persons having names Betsy, Tim, or John.

Deleting a person : delete 16

Deletes the specified person from the address book. Irreversible.
Format: delete INDEX

Deletes the person at the specified INDEX. The index refers to the index number shown in the most recent person listing.

Example(s):

  • list
    delete 2
    Deletes the 2nd person in the address book.

  • find Betsy
    delete 1
    Deletes the 1st person in the results of the find command.

View non-private details of a person : view 16

Displays the non-private details of the specified person.
Format: view INDEX

Views the person at the specified INDEX. The index refers to the index number shown in the most recent person listing.

Example(s):

  • list
    view 2
    Views the 2nd person in the address book.

  • find Betsy
    view 1
    Views the 1st person in the results of the find command.

View all details of a person : viewall 16

Displays all details (including private details) of the specified person.
Format: viewall INDEX

Views all details of the person at the specified INDEX. The index refers to the index number shown in the most recent person listing.

Example(s):

  • list
    viewall 2
    Views all details of the 2nd person in the address book.

  • find Betsy
    viewall 1
    Views all details of the 1st person in the results of the find command.

View your own details : viewself 16

Displays the all the details of the user, provided the user is logged in.
Format: viewself

Clearing all entries : clear 16

Clears all entries from the address book.
Format: clear

Account Commands

Below are the commands that deal with accounts:

Add an account to a person: addacc 16

Adds an account to the target person.
Format: addacc INDEX USERNAME PASSWORD PRIVILEGE_LEVEL

Creates an account for the person with INDEX as specified by the last shown person listing.
USERNAME and PASSWORD will be used for logging in.

PRIVILEGE_LEVEL can be of type "Basic", "Tutor" or "Admin".

Example(s):

  • list
    addacc 1 JohnDoe1337 P455W0RD Admin
    Adds an account with the username of JohnDoe1337, password of P455W0RD and privilege level of Admin to the first person in the list.

Delete the account of a person: deleteacc 16

Deletes the account of the target person.
Format: deleteacc INDEX

Deletes the account of the person with INDEX as specified by the last shown list.

Example(s):

  • list
    deleteacc 1
    Deletes the account of the first person in the list, provided that he has an account.

Login to an account: login 16

Log in to the account with the specified username and password.
Format: login USERNAME PASSWORD

Logs into the account with the given USERNAME and PASSWORD.
Sets the current privilege level to that of the account.

Example(s):

  • login JohnDoe1337 P455W0RD
    Login an account with the username of JohnDoe1337 and password of P455W0RD, provided it exists.

Executing login while logged in will log you out before logging into the new account.

Logout of an account: logout 16

Logout of the current account.
Format: logout

Logout from the currently signed in account.
Also resets the privilege back to the level of a Basic User.

Example(s):

  • logout
    Logs out of the current account, provided there is privilege or account to relinquish.

Displays the list of people with account: listacc 16

Shows a list of all persons with an account in the address book, showing only names and user type.
Format: listacc

Exam Commands

Below are the commands that deals with exam data:

Adding an exam : addexam 16

Adds an exam to the exam book, with the number of takers initialised as 0.
Format: addexam [p]e/EXAM_NAME s/SUBJECT_NAME d/EXAM_DATE st/EXAM_START_TIME et/EXAM_END_TIME dt/EXAM_DETAILS

Words in UPPER_CASE are the parameters, items in SQUARE_BRACKETS are optional. Order of parameters is fixed.
Put a p before the exam name prefix to mark the exam as private.

Example(s):

  • addexam e/Math 2018 Finals s/Mathematics d/01-12-2018 st/09:00 et/12:00 dt/At MPSH

  • addexam pe/2017 English Finals Paper 2 s/English d/01-12-2017 st/08:00 et/10:00 dt/No Pencils Allowed

Listing all exams : listexams 16

Shows a list of all exams in the exam book.
Format: listexams

Deleting an exam : deleteexam 16

Deletes the specified exam from the exam book. Irreversible. Persons registered for the corresponding exam will have the exam deleted as well.
Format: deleteexam INDEX

Deletes the exam at the specified INDEX. The index refers to the index number shown in the most recent exams listing.

Example(s):

  • listexams
    deleteexam 2
    Deletes the 2nd exam in the exam book.

Editing an exam : editexam 16

Edits the specified exam from the exam book. Persons registered for the corresponding exam will have the exam details updated as well.
Format: editexam INDEX [p/PRIVATE_STATUS] [e/EXAM_NAME] [s/SUBJECT_NAME] [d/EXAM_DATE] [st/EXAM_START_TIME] [et/EXAM_END_TIME] [dt/EXAM_DETAILS]

Edits the exam at the specified INDEX. The index refers to the index number shown in the most recent exams listing. Words in UPPER_CASE are the parameters, items in SQUARE_BRACKETS are optional. Order of parameters is fixed. At least 1 item in SQUARE_BRACKETS must be present.

PRIVATE_STATUS is denoted by y for private and n for non-private.

Example(s):

  • listexams
    editexam 2 p/y e/English 2018 Finals dt/In MPSH

  • listexams
    editexam 1 dt/Cancelled

Registering for an exam : regexam 16

Registers a specified person for a specified exam.
Format: regexam PERSON_INDEX EXAM_INDEX

Registers the person at the specified PERSON_INDEX for the exam at the specified EXAM_INDEX. The PERSON_INDEX refers to the index number shown in the most recent persons listing. The EXAM_INDEX refers to the index number shown in the most recent exams listing.

Changes to an exam in the exam book will change the corresponding exam for all persons registered under it, be it an 'edit' or a 'delete'. Exams registered for a person will not be shown in the list command and only viewable under the viewall, viewself and viewexams command.

Example(s):

  • listexams
    list
    regexam 2 2
    Registers the 2nd person in the address book for the 2nd exam in the exam book.

Deregistering for an exam : deregexam 16

Deregister a specified person for a specified exam.
Format: deregexam PERSON_INDEX EXAM_INDEX

Deregisters the person at the specified PERSON_INDEX for the exam at the specified EXAM_INDEX. The PERSON_INDEX refers to the index number shown in the most recent persons listing. The EXAM_INDEX refers to the index number shown in the most recent exams listing.

Example(s):

  • listexams
    list
    deregexam 2 2
    Deregisters the 2nd person in the address book for the 2nd exam in the exam book.

Viewing exams : viewexams 16

View the exams for a specified person in the address book.
Format: viewexams INDEX

Views the exams of the person at the specified INDEX. The index refers to the index number shown in the most recent persons listing.

This command will work for all INDEX only when the user is of Tutor and Admin privileges.
If the user has no privileges, the user must be logged into an account and can execute the command to view only his own non-private exams.

Example(s):

  • login user pw
    list
    viewexams 1
    Views the non-private exams of the 1st person in the address book, if the logged-account belongs to him/her.

  • login admin admin
    list
    viewexams 1
    Views the exams of the 1st person in the address book, if the logged-account belongs to a tutor/admin.

Clearing all entries : clearexams 16

Clears all entries from the exam book. All exams will be cleared in the address book as well.
Format: clearexams

Fees Commands

Below are the commands that deals with fees data:

Editing fees of a person: editfees 16

Edits the numerical fees of a person in the address book.
Format: editfees INDEX FEE DUE_DATE
FEE must have the form of 2 decimal places
DUE_DATE must have the form of DD-MM-YYYY

Words in UPPER_CASE are the parameters, the order of parameters is fixed.

Fees are automatically marked as private. private details can only be seen using the viewall command, or for fees specifically, the viewfees command.

Example(s):

  • list
    editfees 1 344.41 31-10-2018

  • list
    editfees 2 0.60 01-01-2019

Removing the fees of a person: paidfees 16

Removes the fees from a person, once he/she has paid in full, in the address book.
Format: paidfees INDEX

Words in UPPER_CASE are the parameters. The INDEX refers to the index number shown in the most recent person listing.

Example(s):

  • list
    paidfees 2
    Fees of the 2nd person in the address book are now fully paid.

View fees of a person : viewfees 16

Displays the fees(private) of the specified person.
Format: viewfees INDEX

Views the fees of the person at the specified INDEX. The INDEX refers to the index number shown in the most recent person listing.

Example(s):

  • list
    viewfees 2
    Views fees of the 2nd person in the address book.

  • find Betsy
    viewfees 1
    Views fees of the 1st person in the results of the find command.

List all fees of every person : listfees 16

Displays the fees(private) of all the people in the AddressBook.
Format: listfees

Views the fees of all the people with respect to their INDEX. Shows only the index, name and fees.

List only people with due fees : listdue 16

Displays the fees(private) of all the people in the AddressBook with overdue Fees.
Format: listdue

Views the fees of all the people with overdue fees. Shows only the index, name, fee and due status. Adds a "feesdue" tag to the people shown for easier tracking in the future.

Example(s):

  • listdue
    viewall 1
    Views all information of the 1st person in the results of the listdue command.
    Including the "feesdue" tag.

Grade Commands

Below are the commands that deals with grades/assessments of students:

Adding an Assessment : addassess 16

Adds an assessment to the address book.
Format: addassess ASSESSMENT_NAME

Words in UPPER_CASE are the parameters. There is only one parameter for this command, which is the exam or assessment name. Duplicate assessments cannot be added.

Example(s):

  • addassess CG2271 Midterm

  • addassess Mathematics final class test

Listing all assessments : listassess 16

Shows a list of all assessments in the address book, along with an index for each
Format: listassess

Deleting an assessment : deleteassess 16

Deletes the specified assessment from the assessment book, based on the index. Irreversible.
Format: deleteassess INDEX

Deletes the assessment at the specified INDEX. The index refers to the index number shown in the most recent assessments listing.

Example(s):

  • listassess
    deleteassess 1

Adding grades to a person : addgrades 16

Adds grades to selected student/person for a specific assessment listed in addressbook.
Format: addgrades PERSON_INDEX ASSESSMENT_INDEX GRADES

Words in UPPER_CASE are the parameters. There are three parameters for this command, which are the index of the person or student, index of the appropriate assessment and the grades themselves.
1. No restriction on upper limit! It is up to the teacher to decide what the total marks are.
2. In case of any mistake in the entry or necessity to update the grade, you can overwrite a previously entered value by simply using the same function again!
addgrades PERSON_INDEX ASSESSMENT_INDEX UPDATED_GRADES

Example(s):

  • list
    listassess
    addgrades 1 1 89

Viewing grades of a person : viewgrades 16

View the grades for all assessments of a selected student/person.
Format: viewgrades PERSON_INDEX

Words in UPPER_CASE are the parameters. There is only one parameter for this command, which is the index of the person or student whose grades you want to view. This is based on the index number shown in the most recent person listing.
Using list command

Example(s):

  • list
    viewgrades 1
    The results will be displayed as a list of assessments the student has taken and their corresponding grades.

Deleting a grade : deletegrades 16

Deletes the specified assessment and respective grades of a particular student. It is irreversible.
Format: deletegrades PERSON_INDEX ASSESSMENT_INDEX

Deletes grades for the specified PERSON_INDEX and their respective assessment at the specified ASSESSMENT_INDEX. The index refers to the index number shown in the most recent person and assessments listing respectively.

Example(s):

  • list
    listassess
    deletegrades 1 2
    listassess — Check the updated list
    Deletes the grades corresponding to the 2nd assessment in the address book for the student at index 1 in the address book.

Adding a statistic : addstatistics 16

Adds a statistic to the statistics book.
Format: addstatistics ASSESSMENT_INDEX

Words in UPPER_CASE are the parameters. There is only one parameter for this command which is the assessment index as shown in the most recent assessments listing.

This command automatically calculates and adds statistics for a given assessment based on all the grades or scores previously entered to students for that particular assessment. These statistics include:
1. Average Score
2. Total Number of Exam Takers
3. Maximum Score
4. Minimum Score

Example(s):

  • listassess

  • addstatistics 1

If you change/ update grades after already generating a statistic, you must delete that statistic and re-add it to the statistics book to ensure that it is up to date.

Listing all statistics : liststatistics 16

Shows a list of all statistics in the statistics book, along with an index for each
Format: liststatistics

If you delete an assessment after generating its statistics, this statistic will still remain in the statistics book. This is to ensure that the school can maintain a record of all its statistics over time if needed, even though the assessment may have ended and the grades are awarded to students. It is up to the school to decide how long they want to store their statistics for.

Deleting a statistic : deletestatistics 16

Deletes the specified statistic from the statistics book, based on the index. Irreversible.
Format: deletstatistics INDEX

Deletes the statistic at the specified INDEX. The index refers to the index number shown in the most recent statistics listing.

Example(s):

  • liststatistics
    deletestatistics 1

Attendance Commands

Below are the commands that deal with attendance data:

Updates the attendance of a person: attendance 16

Updates the attendance of the target person.
Format: attendance INDEX d/DATE att/ATTENDANCE

Updates the attendance of the person with INDEX as specified by the last shown list.
*If the input date is 0 (e.g. d/0), the current date will be used

Example(s):

  • list
    attendance 1 d/29-09-2018 att/1
    Marks the attendance of the first person in the list as present for the date 29th September 2018.

  • list
    attendance 1 d/0 att/0
    Marks the attendance of the first person on the list as absent for today’s date.

Replaces the attendance of a person: replaceAtten 16

Replaces the current attendance of the target person.
Format: replaceAtten INDEX d/DATE att/ATTENDANCE

Replaces the attendance of the person with INDEX as specified by the last shown list.

Example(s):

  • list
    replaceAtten 1 d/29-09-2018 att/1
    Replaces the attendance of the first person in the list as present for the date 29th September 2018.

View the attendance of a person: viewAttenPerson 16

View the attendance of the target person.
Format: viewAttenPerson INDEX

View the attendance of the person with INDEX as specified by the last shown list.

Example(s):

  • list
    viewAttenPerson 1
    Views the attendance of the first person on the list.

View the attendance of a date: viewAttenDate 16

View the attendance of the given date.
Format: viewAttenDate DATE

Shows a list of people who were present and absent on a particular date.
If a person’s attendance has yet to be taken, the person’s name will default be under absent.
*If the input date is 0 (e.g. d/0), the current date will be used

Example(s):

  • viewAttenDate d/28-10-2018
    Shows a list of people who were present on a particular date.

  • viewAttenDate d/0
    Shows a list of people who were present today.

Replaces the attendance of a person: replaceAtten 16

Replaces the current attendance of the target person.
Format: replaceAtten INDEX d/DATE att/ATTENDANCE

Replaces the attendance of the person with INDEX as specified by the last shown list according to the DATE.

Example(s):

  • list
    replaceAtten 1 d/29-09-2018 att/1
    Replaces the attendance of the first person in the list as present for the date 29th September 2018.

Update multiple people attendance: multiAtten 16

Updates the attendance of multiple people based on the list of index.
Format: multiAtten i/MULTIPLE_INDEX d/DATE att/ATTENDANCE

Updates the attendance of muultiple people with a list of INDEX as specified by the last shown list.
*If the input date is 0 (e.g. d/0), the current date will be used
*If the input index is 0 (e.g. i/0), all people in the addressbook will be updated

Example(s):

  • list
    multiAtten i/1 2 4 5 d/29-09-2018 att/1
    Marks the attendance of the people with index 1, 2, 4 and 5 in the list as present for the date 29th September 2018.

  • list
    attendance i/0 d/0 att/0
    Marks the attendance of everybody on the list as absent for today’s date.

Saving the data

Data is saved in the hard disk automatically after any command that changes the data.

There is no need to save manually. Address book data, exam book data and statistics book data are saved in files called addressbook.txt, exams.txt and statistics.txt respectively in the project root folder.

Handling Errors

  1. ClassRepo does not start up when running the jar file.
    Plausible cause: addressbook.txt, exams.txt or statistics.txt contains invalid data.
    Solution: Fix the data error in the problematic file.
    Refer to log.txt to find the underlying error.

  2. ClassRepo shuts down mid-operation.
    Plausible cause: addressbook.txt, exams.txt or statistics.txt was set to read-only during a data saving operation. ClassRepo shuts itself down to ensure synchronisation of AppData and storage data.
    Solution: Ensure that the data files are not set as read-only.

Known Issues

  1. ClassRepo ASCII art may be formatted wrongly on OS’s such as Mac. 500

Summary of All Commands

Commands are sorted in terms of increasing privileges needed to run them.

Click to Expand

Command Basic Tutor Admin

help

Y

Y

Y

exit

Y

Y

Y

help

Y

Y

Y

raise

Y

Y

Y

viewpri

Y

Y

Y

view

Y

Y

Y

list

Y

Y

Y

find

Y

Y

Y

login

Y

Y

Y

logout

Y

Y

Y

listacc

Y

Y

Y

viewexams

Y

Y

Y

liststatistics

Y

Y

Y

listassess

Y

Y

Y

listall

N

Y

Y

viewall

N

Y

Y

listexams

N

Y

Y

regexam

N

Y

Y

deregexam

N

Y

Y

viewfees

N

Y

Y

listfees

N

Y

Y

listdue

N

Y

Y

addassess

N

Y

Y

deleteassess

N

Y

Y

addgrades

N

Y

Y

viewgrades

N

Y

Y

deletegrades

N

Y

Y

addstatistics

N

Y

Y

deletestatistics

N

Y

Y

attendance

N

Y

Y

replaceAtten

N

Y

Y

viewAttenPerson

N

Y

Y

viewAttenDate

N

Y

Y

editpw

N

N

Y

perm

N

N

Y

add

N

N

Y

delete

N

N

Y

clear

N

N

Y

addexam

N

N

Y

deleteexam

N

N

Y

editexam

N

N

Y

clearexams

N

N

Y

addacc

N

N

Y

deleteacc

N

N

Y

editfees

N

N

Y

paidfees

N

N

Y