[jsword-devel] [sword-devel] JSword documentation correction required?

Tonny Kohar tonny.kohar at gmail.com
Mon Jul 19 01:17:17 MST 2010


On Sat, Jul 17, 2010 at 3:11 AM, Chris Burrell <chris at burrell.me.uk> wrote:
> Hi DM
> Well my suggestion would be to adopt a IOC/dependency injection. Perhaps a
> "config provider" object can be inserted into those places that need access
> to those statics. We can somehow insert a default provider with default
> config if no user config provider is found.
> The JSword code would ask the config provider for the various settings.
> JSword could also alter the config provider on any changes.
> If the provider is defined as an interface, it gives the people the option
> to write their own Configuration Provider mechanism, and inject/set it at
> runtime. Some might want to carry state and persist it elsewhere, some might
> want it geared towards concurrency usage, etc.


Yes using concept dependency injection is good. However, if possible
please don't use like annotation or non-standard/complex setup. Just
use simple java constructs like service provider with default/abstract
implementation which can be easily inherited/overriden.

Tonny Kohar
Alkitab Bible Study

More information about the jsword-devel mailing list