PicoContainer是一个“微核心”(micro-kernel)的容器。它利用了Inversion of Control模式和Template Method模式,提供面向组件的开发、运行环境。从名字上就可以看出,PicoContainer是“极小”的容器,只提供了最基本的特性。其他容器可以在它的基础上加入更多特性。因其小,PicoContainer也是剖析、研究的最佳对象。
————————————
The PicoContainer team is proud to announce the release of the first beta of PicoContainer 1.0.
PicoContainer is an embeddable container for type-3 Inversion of Control (IoC) components. It is delivered as a set of abstractions, a couple of instantiable containers, a few adaptors for hierarchies and (optional) lifecycle management as well as support classes. We genuinely believe this to be the logical conclusion of the IoC component model.
Components:
The component model (igoring our lifecycle support) is unencumbered by obligations of API. There is nothing to extend, nothing to implement and nothing to throw. The component model forces no obligations for XML meta-data on the developer or user of PicoContainer components. The design is so simple, that for very tightly coupled deployments, a developer could cherry pick components and embed them in their application without even importing let alone using anything from the org.picocontainer codebase.
Diversity:
From the abstractions, other container developers can build containers compatible and interoperable with PicoContainer. We encourage diversity of implementation as we are not building a single container. In terms of the PicoContainer deliverable, there are no external Jar dependancies, and no use of XML for component declarations. Along with the PicoContainer deliverable, there is a Technology Compatability Kit (TCK). This is in the form of the abstract JUnit test cases. A container developer can use this to ensure than their implementation of a PicoContainer is compatible with the design. Container developers may choose from-scratch designs, wrapping of existing classes, or extending existing classes.
NanoContainer:
As a sister project to PicoContainer, we also have NanoContainer. Like PicoContainer, NanoContainer is more than one container. All are built to the PicoContainer design, and offer different embeddable visions. One interoperates with Nanning (the aspect framework) to provide aspect capability for arbitary components. Another retrofits JMX compatability to arbitary components. Some of the NanoContainers deliver component assembly and configuration via XML.
The Plan:
The plan is to build more containers and to sell the component design further.
- The PicoContainer team.
Visit www.picocontainer.org