This script contains the ZenUMLAuto
class, which provides functionalities to interact with the ZenUML desktop Windows application, convert Java functions into ZenUML syntax, and detect certain templates within an image.
pyautogui
time
cv2
fromopencv-python
numpy
re
pandas
Initializes an instance of ZenUMLAuto. Keeps track of a counter to count iterations.
Automate ZenUML desktop Windows app using pyautogui
to input the code and then capture a screenshot of the resultant diagram.
Detect specific template images (template1.jpg
and template2.jpg
) within the given image and returns the total count of detected templates.
Converts a given Java function into ZenUML Syntax and returns the ZenUML formatted function.
Converts Java methods provided in a CSV file into ZenUML Syntax and saves the output in a new CSV.
Automates the process of entering code into ZenUML, capturing a screenshot, and then detecting templates in the resultant image.
Automates the ZenUML process for a single run and updates the internal counter.
Automates the entire process: Convert Java methods in a CSV to ZenUML Syntax, run ZenUML, and detect templates in the resultant images.
To use this script and its functionalities:
z = ZenUMLAuto()
fileName = 'methods_first'
z.convertor_run(fileName)
z.automate_msg_run(fileName)