This week's book giveaway is in the OO, Patterns, UML and Refactoring forum. We're giving away four copies of Refactoring for Software Design Smells: Managing Technical Debt and have Girish Suryanarayana, Ganesh Samarthyam & Tushar Sharma on-line! See this thread for details.
Hi Friends, Thanks for your valuable time.. please comment on my design which will help me to improve.. design My gui contains two panels, one is search pannel and other one is result panel. Search panel has origin combobox, destination combo box, carrier combobox,searchbutton and exit button. Result panel contains JTable and book button at the bottom. like
If user clicks on search panel.. records will be displaced in JTable area. Now user can select the flight that he/she want to book , then click on book button. Then another child window will open with all flight detail(price,origin,desitn..etc.. and "Enter seats" + textbox for seats).
Doubts: 1. Is this design meets the sun's requirement? 2. Any suggestions to improve above design 3.I am confused how to populate child window with all details.. can I use JDialog or JOption Pane for this. How you guys have implemented it?
I appreciate your help [ August 21, 2002: Message edited by: Suresh Babu ]
Hi Suresh, Your search mechanism is almost identical to mine. Your booking is somewhat similar, except that I had a booking panel that followed the selected row in the table. But your method is just as effective. So I would say that your GUI design looks pretty good. You probably want to consider adding a menu though to cinch a perfect score on the GUI. Hope this helps, Michael Morris
Any intelligent fool can make things bigger, more complex, and more violent. It takes a touch of genius - and a lot of courage - to move in the opposite direction. - Ernst F. Schumacher
The main difference I have is that I use a horizontal split panel with my search panel on the left and the results JTable on the right. I don't have a book button, but the user can bring up the book dialog by double-clicking on the flight, or clicking on the appropriate menu item or toolbar icon, or by simply pressing <CTRL-B>. By using the horizontal split, I can add new search criteria without altering the number of flights being displayed. I just figured it is a better use of space.
Joined: Aug 21, 2002
Hi Michael & George, Thanks for Your comments
You probably want to consider adding a menu though to cinch a perfect score on the GUI.
I will add menu to my GUI. I want to know what were componets have you added to menu & menu bar. Could you please answer my 3rd question in original post. Which pattern is good for this (GUI).. MVC or Moderate pattern?. I am new to this design patterns as well as Swing.
3.I am confused how to populate child window with all details.. can I use JDialog or JOption Pane for this. How you guys have implemented it?
What is a child window. Is this a popup that will display results of their booking? If so you can add a method to pop up messages, and inside you will use the JOptionPane. That is what I used to pop up messages. Hoep that answers your question. Mark
What is a child window. Is this a popup that will display results of their booking? If so you can add a method to pop up messages, and inside you will use the JOptionPane. That is what I used to pop up messages
Yes child window is popup window to display the flight information and at the bottom it contains Label : Enter the No of seats and Text Box to enter the number of seats. Can I use JOptionPane (Information Message Type [ August 30, 2002: Message edited by: Suresh Babu ]
Yes you can use JOptionPane. I actually prefer JOptionPane because it is an object that Sun already provides for you, instead of re-inventing the wheel. I hate reinventing the wheel, because each time it will come out square first then a dodecahedren. Then one time it came out as a triangle, I mean can you imagine the embarrasment I had trying to explain to my boss how a triangle wheel was far superior to anything that Firestone puts out. Mark
hi all, thanks to those who are sharing their views on this forum. i am using MVC pattern in my gui design. my question is:- I have three ComboBoxes mainly for Carrier, Origin and Destination.Should i populate these ComboBoxes having a reference to my Model of MVC pattern for my gui or should i just get a reference of DataClient directly in the gui and populate these ComboBoxes? As i see this changes in the size of these comboboxes only occurs ,if FBN enhances its capacity to hold more flights,which is not a every minute operation. For right now i am thinking of having the following items in my Model,which i think will be changing constantly. 1.carrier 2.origin 3.destination 4.search results depends upon the seach string 5.something related to booking of a record (DataInfo) I hope ,this make sense to you guys. Any thoughts thanks, harcharan