Adam Murdoch wrote:
-----Original Message-----
From: Stephen Colebourne [mailto:scolebourne@;btopenworld.com]
Sent: Sunday, 27 October 2002 9:22 AM
To: Jakarta Commons Developers List
Subject: Re: [clazz] Type-based or instance-based metadata? Take II
This kind of interface is OK, and should be provided. Its essentially the
equivalent to BeanUtils class in [beanutils].
However, we should focus first on getting the new class/instance model
defined. Users can then call a method on the model object intead
of a static
utility class.
Definitely. This makes it easier to give the client to control things like
which meta-info implementation to use for the model (assuming they are
pluggable), and policies for dealing with the object graph (like, for
example, whether it should be 'type-based' or 'instance-based').
Getting rid of the statics (or having them as a convenience only) means the
meta-info model will fit nicely into a component-oriented or IoC
environment.
Utility classes like StringUtils and such that do not store state, or
cache instances are perfectly acceptable in all environments. There is
no way unauthorized access to information that does not belong to
unauthorized objects.
Anything that should store state or cache values should not be static.
--
"They that give up essential liberty to obtain a little temporary safety
deserve neither liberty nor safety."
- Benjamin Franklin
--
To unsubscribe, e-mail: <mailto:commons-dev-unsubscribe@;jakarta.apache.org>
For additional commands, e-mail: <mailto:commons-dev-help@;jakarta.apache.org>