• Post Reply Bookmark Topic Watch Topic
  • New Topic

Is this is a Mediator Pattern?  RSS feed

 
Mudunuri Raju
Ranch Hand
Posts: 44
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi could you please tell me this is a Medaitor pattern or not?.
I have a Search/Book seats screen containing 4 or 5 buttons. I have a separate class called DataTableModel implemets the AbstractTableModel.
In my GUI screens I wrote only GUI code. All the functionality ralated stuff I wrote in DataTableModel class like book seats, set the data into JTable,Display the header names, Search etc. DataTableModel class interacts with the back end depends on the loca/network mode.
 
Mudunuri Raju
Ranch Hand
Posts: 44
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
can I call DataTableMode class as a mediator.
Thanks in advance.
 
John Smith
Ranch Hand
Posts: 2937
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator

In my GUI screens I wrote only GUI code. All the functionality ralated stuff I wrote in DataTableModel class like book seats, set the data into JTable,Display the header names, Search etc. DataTableModel class interacts with the back end depends on the loca/network mode.

I don't think booking and searching belong to DataTableModel, if it is the model for the JTable. You need another model to implement the business requirements.
Eugene.
 
Chandra Peri
Ranch Hand
Posts: 46
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Originally posted by Mudunuri Raju:
can I call DataTableMode class as a mediator.
Thanks in advance.

Only if the DataTableMode handles the communication between your GUI classes. In other words your GUI classes do not refer each other.
 
Don't get me started about those stupid light bulbs.
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!