On Mon, 2004-01-12 at 14:51, Alex Karasulu wrote: > Jason, > > > > > From: Jason van Zyl <[EMAIL PROTECTED]> > > Date: 2004/01/12 Mon AM 10:45:28 EST > > To: Maven Developers List <[EMAIL PROTECTED]> > > Subject: Re: ModelFactory interface (was: maven-model-tools to ...) > > > > On Mon, 2004-01-12 at 01:28, Alex Karasulu wrote: > > > Hi, > > > > > > As I recommended I would use the factory method pattern here where > > > the creator is the factory. The ModelFactory interface is the > > > interface for all factory implementations. I would go with something > > > like so which is based on CRUD: > > > > I'll take a peek and see what can be gleaned but essentially Plexus is > > the factory. Plexus components with the addition of a constructor are, > > Let me see if I understand correctly. What you're saying is Plexus is > the ModelFactory implementing the CRUD operations? Or Plexus is the > factory that instantiates the appropriate ModelFactory implementation?
Yes, given a certain criterion, or criteria, a particular implemenation will be selected. Similiar to the avalon selector as you're probably more familiar with that. Plexus would just help assemble the desired model provider into the project component. The configuration might well be different for the various model providers but that is easily dealt with in Plexus. There is no reason you couldn't explicity make a factory component either that returned what you needed given a set of parameters. I think it would just be more elegant to use Plexus' internal mechanisms. We can chat about it on the plexus mailing list if you like. -- jvz. Jason van Zyl [EMAIL PROTECTED] http://maven.apache.org happiness is like a butterfly: the more you chase it, the more it will elude you, but if you turn your attention to other things, it will come and sit softly on your shoulder ... -- Thoreau --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
