Configuration
Class diagram
Instantiating a new Configuration
Create a new Configuration
object by passing the username and password of the Friedolin account you want to access.
While the KeePassXC
class allows one to retrieve those credentials from the user’s KeePassXC password database,
the Configuration
won’t do that for you.
In other words, it’s the caller’s responsibility to get the username and password from the user or from KeePassXC.
Configuration configuration =
new Configuration("es13nsa", "xkeyscore".toCharArray());
Serialising and deserialising a Configuration
In order to preserve a configuration for later use after the program is closed, you can easily
serialise it to a JSON string and
deserialise a JSON file back to a Configuration
object.
JSON Schema
Validate JSON representations of the Configuration class against this schema.
JSON validation in Java
Use the json-schema library by harrel.dev to validate JSON against schemas.
Settings
User name
The username of the Friedolin account.
Required if use-keepassxc
is false.
Ignored if use-keepassxc
is true.
Type | String |
JSON key | user |
Default | none |
Example | es13nsa |
Password
The login secret of the Friedolin account.
Required if use-keepassxc
is false.
Ignored if use-keepassxc
is true.
Type | char[] |
JSON key | password |
Default | none |
Example | xkeyscore |
Clearname
The real name of the Friedolin user.
Type | String |
JSON key | clearname |
Default | none |
Example | Edward Snowden |
Note
Javadoc has sadly not recognised the Lombok setter for the clearname
field, but it exists.
Academic degrees
The academic degrees pursued by the Friedolin user.
Type | List<String> |
JSON key | academic-degrees |
Default | ["Abschluss 82 Bachelor of Science"] |
Note
Javadoc has sadly not recognised the Lombok getter for the academic-degrees
field, but it exists.
Use KeePassXC
Whether or not Friedolyn should use KeePassXC to store the password. If true, the user and password fields will be ignored.
Type | boolean |
JSON key | use-keepassxc |
Default | false |
Note
Javadoc has sadly not recognised the Lombok getter for the use-keepassxc
field, but it exists.
E-mail address
The user’s university e-mail address and, at the same time, the address that Friedolyn should use to send notifications.
Type | InternetAddress |
JSON key | email |
Default | none |
Example | edward.snowden@uni-jena.de |
Exam PDFs
Which of the available PDF files that include the student’s grades should be downloaded from Friedolin.
Type | List<String> |
Must be one or more of |
|
JSON key | exam-pdfs |
Default | ["EXAMS_PASSED", "EXAMS_FULL"] |
Note
Javadoc has sadly not recognised the Lombok getter for the exam-pdfs
field, but it exists.
Overwrite exam PDFs
When re-downloading an already existing exams PDF file, should it be deleted and replaced with the new, update one? If false, the current date and time will be prepended to the file name.
Type | boolean |
JSON key | overwrite-exam-pdfs |
Default | false |
Note
Javadoc has sadly not recognised the Lombok getter and setter for the overwrite-exam-pdfs
field, but they do exist.
Notifications
How the user wants to be notified about new grades.
Type | Notifications |
JSON key | notifications |
Default | none |
Interval
The interval in minutes in which Friedolyn should check for new grades.
Type | int |
JSON key | interval |
Must be | |
Default | 60 minutes |
Note
Javadoc has sadly not recognised the Lombok getter for the interval
field, but it exists.
Client
Specifies the behaviour of the software part that connects to the Friedolin server.
Type | Client |
JSON key | client |
Default | not applicable |
Contact methods
In case the user wants to contact the developers, their message is automatically encrypted. But how can the developers send their reply to the user, preferably in a secure way?
Type | ContactMethods |
JSON key | contact-methods |
Headless mode
Whether the application’s GUI should be hidden. This has nothing to do with the headless browser.
Type | boolean |
JSON key | headless |
Default | false |
Note
Javadoc has sadly not recognised the Lombok getter and setter for the headless
field, but they do exist.
Debug level
How verbose the application should be.
DEBUG
:
When using the HeadlessBrowser, the browser will not be headless and instead show a graphical user interface. Also, all log messages will be printed to the console. Important: Sensitive data, such as PASSWORDS, WILL BE PRINTED TO THE CONSOLE! Use any other debug level if you want to avoid this.INFO
:
All log messages will be printed to the console. Less sensitive data, such as EMAIL ADDRESSES, USER NAMES, ACADEMIC DEGREES and GRADES, will be printed to the console.WARN
:
Only warnings and errors will be printed to the console. No sensitive data will be printed.ERROR
:
Only errors will be printed to the console. No sensitive data will be printed.
Type | DebugLevel |
Must be one of |
|
JSON key | debug-level |
Default | WARN |
Note
Javadoc has sadly not recognised the Lombok getter for the debug-level
field, but it exists.