avalon-phoenix-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Peter Donald <pe...@realityforge.org>
Subject Re: Context: usage recommendations? ( Re: [SUMMARY] Context )
Date Tue, 03 Dec 2002 15:00:05 GMT
On Wed, 4 Dec 2002 01:30, Berin Loritsch wrote:
> Link?

It was part of the initial documentation dump that went with JSR111 that you 
are part of. HP has since mothballed development of it but you can see the 
remanents of it at;


> And I fail to see why we can't have stuff like that handled
> for us automatically....

It can when it manages the creation and passing of references. What happens 
when a component wants to pass a reference to itself but wants the reference 
to be the proxy (and thus isolated/protected).

Under CSF you did something like

Object me = getServiceContext().getProxy()

//pass me to foreign component here

Or if you wanted to create a new object and pass that object - but make sure 
it was correctly proxied and isolated you would do something like

MagicEventListener listener = new MyMagicEventListenerImpl()
MagicEventListener safeListener = (MagicEventListener)
  getServiceContext().getProxy( MagicEventListener.class, listener );

//pass safeListener to the foreign event service here

To do anything like this requires interaction with the container and sharing 
of the isolation stuff that opnly the container maintains.


Peter Donald
"Only two things are infinite, the universe and 
human stupidity, and I'm not sure about the 
former." -Albert Einstein 

To unsubscribe, e-mail:   <mailto:avalon-dev-unsubscribe@jakarta.apache.org>
For additional commands, e-mail: <mailto:avalon-dev-help@jakarta.apache.org>

View raw message