On Sun, 23 Jun 2002 17:45, Peter Donald wrote:
> At 05:36 PM 6/23/2002 +1000, you wrote:
> >On Sun, 23 Jun 2002 16:35, Peter Donald wrote:
> > > At 10:23 AM 6/23/2002 +1000, you wrote:
> > > >What do you think of getting rid of the DataType interface? We'd keep
> > > > the role, but drop the requirement that a data-type must implement
> > > > the interface.
> > >
> > > Im not a fan of it - but you already knew that. In effect if we were to
> > > put this in we would be special casing the whole system. It would be
> > > better to do
> > >
> > > if( datatype ) doMagic();
> > > else doNormalStuff();
> >
> >Um, where would it be better to do this? It's not real clear.
>
> No idea - thats your area of expertise ;)
>
> I had a brief look and it looks like the only place where role class is
> actually enforced is in InstantiatingServiceManager. Is there anywhere else
> that it is enforced?
MultiSourceTypeFactory also does a check. Probably should be happening a
little closer to TypeManager, I guess.
The check is skipped if RoleInfo.getImplementationClass() returns null. So, I
was thinking of adding something to the meta-info for the data-type role, so
that the class ends up getting set to null. The policy is not hardcoded in
the container, but is defined by framework. And being in the meta-info, can
be changed easy enough.
How does that sound?
--
Adam
--
To unsubscribe, e-mail: <mailto:ant-dev-unsubscribe@jakarta.apache.org>
For additional commands, e-mail: <mailto:ant-dev-help@jakarta.apache.org>
|