Hi,

yer I guess it is a bit of a PITA to work with ;) I wouldn't mind if we
used the method name "release" as that is what is used in other object
models (ie usually there is a pair - aquire/release)



At 09:14  21/2/01 -0500, Berin Loritsch wrote:
>
>
>-------- Original Message --------
>Subject: Proposed addition to ComponentManager/Selector
>Date: Wed, 21 Feb 2001 09:07:33 -0500
>From: Berin Loritsch <[EMAIL PROTECTED]>
>Reply-To: "Avalon Development" <[email protected]>
>To: "[email protected]" <[email protected]>
>
>One thing we have identified at the Cocoon porject is the
>need to hide the implementation facts of whether a Component
>is ThreadSafe, Poolable, Factory, etc.
>
>To date, in order to do that we have had to come up with an
>inelegant Hack.
>
>The truly elegant and IMO correct way of doing things is to
>add a put() or return(Component) method so that every used
>Component has a definite beginning and ending.  It is a standard
>contract for all Composers to lookup and return components,
>that way the implementation details can be absolutely hidden
>from the end client of the Component.
>
>interface ComponentManager {
>    Component lookup (String role);
>    void return (Component usedComponent);
>}
>
>interface ComponentSelector implements Component {
>    Component select (Object hint);
>    void return (Component usedComponent);
>}
>
>This request comes from _hard_ _use_ of the ComponentManager
>system, and I think reflects a natural evolution that we
>should use.
>
>---------------------------------------------------------------------
>To unsubscribe, e-mail: [EMAIL PROTECTED]
>For additional commands, e-mail: [EMAIL PROTECTED]
>
>
>------------------------------------------------------------
>To subscribe:    [EMAIL PROTECTED]
>To unsubscribe:  [EMAIL PROTECTED]
>Problems?:       [EMAIL PROTECTED]
>
>
Cheers,

Pete

*-----------------------------------------------------*
| "Faced with the choice between changing one's mind, |
| and proving that there is no need to do so - almost |
| everyone gets busy on the proof."                   |
|              - John Kenneth Galbraith               |
*-----------------------------------------------------*

Reply via email to