Good day,

Can someone please assist me with the following questions:

1. Create a console application to handle graph details. Considering the required functionality that is required
and OOP design principles (avoiding anti-patterns and having minimal redundant code), create and
implement the appropriate classes necessary to achieve the following.
? A node in the graph would be made up of a label (the name of the node), an (x, y) coordinate indicating
its position, and an indication of its shape. Provide all the necessary getters and setters.
? The application should include a list of nodes.
? The application should also have a list of paths where the user can add paths between labelled nodes
indicating the type of path (for example, --, ->, <->, or <-). It is clearly necessary to check that the
labels exist before adding a path between them.
? The application should be able to output to the console a list of paths in the following format:
a [Square at (1, 1)] -> b [Circle at (5, 5)]
? Test your solution by creating some nodes, adding them to the list of nodes, and then adding some
paths (some acceptable, some not). Finally, display the path list.

2. This question focusses on the concepts of reflection and meta-objects.
Extend the application you wrote in question 1 by fully serialising the node and path lists. Note the following
? Both writer and reader parts of the Serializer should be implemented, serialising to a single file.
? Any text-based file format may be used.
? When writing, use reflection and the meta-objects as far as possible.
? When reading, the various lists should re-created and the data displayed again (to confirm that the
data was successfully serialised).

3. Rewrite the InputForm class in Chapter 14 to include an additional QLineEdit to enter a student
number. A QRegExpValidator should be attached to this QLineEdit so that it only allows a user to
enter a single, uppercase alphabetic character, followed by a 4 or 5 digit number that does not begin with
a 0. The result of the computation should be displayed in a QMessageBox with the student number
(Example: ‘Total Pay for the student S5666 is 183.75’) instead of displaying the message on the input

4. Write a file system browser that allows a user to do the following:
? Use the QFileSystemModel to model the directory structure on your computer.
? Browse the file/folder structure (using a QTreeView)
? Display the following information on any file/folder clicked on: name, path, size (for files), and whether
it is a file or a folder.
Create a folder (using a ‘New folder’ button) as a sub-directory in the selected directory
? Rename an existing file/directory (using the inherent ability of the model class)
? Delete a file/directory (using a ‘Delete’ button) – ensure that you check whether the file/folder should
be deleted, and also ensure that the information displayed remains current once the file/folder has
been deleted.