Hi, please explain concept of factory to me and how to use the factory implementation, factory class, and how to use the code in the main() and what the purpose is.
Please explain concept of factory to mefactory class and how to use it?
Page 1 of 1
8 Replies - 1397 Views - Last Post: 18 August 2009 - 05:47 AM
Replies To: Please explain concept of factory to me
#2
Re: Please explain concept of factory to me
Posted 17 August 2009 - 03:35 PM
#3
Re: Please explain concept of factory to me
Posted 17 August 2009 - 03:45 PM
That link didn't help much. But the link does link to a wikpedia article which is a little more helpfull. I wish there was a tutorial on factories here but there isn't one, i checked. If i ever figure this out I will write a tutorial for you guys.
#4
Re: Please explain concept of factory to me
Posted 17 August 2009 - 04:06 PM
Sadaiy, on 17 Aug, 2009 - 02:45 PM, said:
That link didn't help much. But the link does link to a wikpedia article which is a little more helpfull. I wish there was a tutorial on factories here but there isn't one, i checked. If i ever figure this out I will write a tutorial for you guys.
Not easy to write a tutorial about factory.
There are many ways to implement them an it all depends of the context.
On some GUI elements a factory cannot be implemented... a Factory for JLabel will not work because a JLabel cannot be in 2 different containers at the same time
A Border can use a Factory because the Border is drawn after the Component it is bordering is drawn and the Border is redraw every time it is not a GUI element by itself.
JOptionPane are kind of a factory because the Pane is displayed and delete right after. There is no neeed to keep it has instance variable of an instance of JOptionPane.
Whenever you will need a Factory, I think you will have already solved your problem and just realized that what you wrote is actually a Factory.
#6
Re: Please explain concept of factory to me
Posted 17 August 2009 - 07:06 PM
Give this a read.
http://books.google....i...ory&f=false
http://books.google....i...ory&f=false
This post has been edited by skaoth: 17 August 2009 - 07:06 PM
#7
Re: Please explain concept of factory to me
Posted 17 August 2009 - 08:29 PM
Quote
That link didn't help much.
Epic quote is epic. Q.E.D.
That's almost like trying to get someone to write a tutorial on brain surgery.
#8
Re: Please explain concept of factory to me
Posted 17 August 2009 - 09:47 PM
#9
Re: Please explain concept of factory to me
Posted 18 August 2009 - 05:47 AM
There seem to be a lot of those. I just have a gift for expression methinks.
I am pretty good at writing poetry, expecially haikus
Page 1 of 1
|
|

New Topic/Question
Reply




MultiQuote







|