This readme contains the steps to launch the Spring 2024 UML Editor. This is a GUI/terminal based program that allows users to create a Class Diagram with Relations, Classes, and Attributes.
The minimum required version of Python to run this program is 3.8. If your version of python, found in the section below, is less than that, please follow this link to install a newer version.
- In the top right corner of your screen, there will be a search bar, a magnifying glass, or both (depending on your version of Mac). Click that.
- Type 'terminal', then hit enter.
- Type 'python3 --version' and hit enter. If you don't have developer tools installed, accept the install and wait for it to complete before retyping this command.
- The terminal will print out "Python x.x.x", where x is a number, if python is installed.
- Hold the windows key and click R.
- Type 'cmd' and hit enter
- Type 'py -V' and hit enter
- "Python x.x.x" will print if python is installed.
- Open a terminal on your preferred Linux distro.
- Type 'python --version'
- "Python x.x.x" will print if python is installed.
If you do not have python installed, install the latest version for your operating system here.
To download the project directly into a terminal, git tools will be required. Follow the instructions here to install git if it is not already installed.
Download the zip here and extract it.
Regardless of operating system, this project will install dependencies when it is built. If the build script is run outside a virtual environment, it may modify files on your computer unpredictably. To setup a virtual environment, follow this link.
The command to execute a python program varies with operating system. On Mac, it is python3. On Windows both py and python work. On Linux it is python. Through the duration of these build instructions, py will be used. Substitute the command appropriate for your operating system in its place.
- Open a terminal and navigate to the folder that the project was cloned/extracted into. Basics of terminal navigation can be found at the links listed below this list.
- Once you are in the source directory of the project (its name should be 2024sp-420-PythonA), type 'py build.py'. If you get a warning about not being in a virtual environment, hit enter to exit the script then follow the instructions at the top of this section to setup and enter a virtual environment before running 'py build.py' again.
- Type 'py main.py' to run the program in its default mode, or refer to the flags section below this for other options.
Mac Terminal Navigation
Windows PowerShell Navigation
Windows Command Prompt Navigation
Linux Terminal Navigation
- `'py main.py' - default operation mode, opens a GUI.
- `'py main.py cli' - runs the program in CLI mode instead of creating a gui.
- `'py main.py debug' - runs the program in CLI debug mode. This mode is nearly identical to the CLI mode, just with slightly less error handling. Use at your own risk.
- 'Ctrl+z' for undo.
- 'Ctrl+y' for redo.
- 'Up' and 'Down' for navigating through the history of input commands.
If you are in the CLI mode, type 'help' for a list of commands. In the gui, use the menu options available at the top of the screen and/or by right clicking to manipulate the diagram to your needs
'pytest' - from the source directory of the project, automatically finds and executes all test files.
- Momento
- The momento.py file, which is located in src/umleditor/mvc_controller, implements the Momento design pattern.
- Singleton
- The diagram.py file, which is located in src/umleditor/mvc_model, implements the Singleton design pattern.
- Controller
- The controller.py file, which is located in src/umleditor/mvc_controller, implements the Controller design pattern.
- Strategy
- The autofill.py file, which is located in src/umleditor/mvc_controller, implements the Strategy design pattern.
- Command
- The main.py file, which is located in the root directory of the project, implements the Command design pattern.
- MVC
- MVC pattern is clearly organized into three separate directories under src/umleditor.
- Zhang Chen
- Jillian Daggs
- Katie Dowlin
- Patrick McCullough
- Danish Zubari
- Ganga Acharya
- Marshall Feng
- Peter Freedman
- Adam Glick-Lynch
- Tim Moser