what's a "factory"?


Web tier: servlets, JSP, Web frameworks: what's a "factory"?

  1. what's a "factory"? (2 messages)

    as we can seen,there are a lot of "factory" in the java,such as InitialContextFactory,KeyManagerFactory,.........
    so many factories have confused me,but i think there must be some common meaning within the factories,and there must be differences between the factories and other classes,who can help me?

    thank you

    Threaded Messages (2)

  2. what's a "factory"?[ Go to top ]

    factories are creational idioms, or in other words, they are used to create objects for you. usually the factories create objects related to a certain interface.

    there are different types of factories as well (i.e. factory method, abrstract factory, etc.)

    since they are desgin pattern idioms, you can search on google.com for more information (i.e. search 'java factory design pattern')

    hope this helps.

  3. what's a "factory"?[ Go to top ]

    thank you