JFrame1
and JFrame2
are both classes I wrote that extend javax.swing.JFrame
.
There is a button (a JButton
) located in JFrame1
and I registered a MouseClicked
event with it. When I click the button on JFrame1
, it closes and JFrame2
is visible. (They don't have anything that links them other than JFrame2.setVisible(true)
)
So, should there be a relationship (association, aggregation, composition, dependency,...) between these two classes in my class diagram, and if yes, which relatioship?