[aspectc-user] Need to access Caller to method.

Craig E. Tull cetull at lbl.gov
Wed Jun 16 02:48:27 CEST 2004


We have the following problem we would like to solve with AspectC for 
our presentation at an upcoming conference.

We have a multi-threaded environment with one service (per type) per 
thread and multiple clients of the service per thread.

We have a service locator which registers and locates service by 
(ServiceName,ServiceThread#) pairs.

When a client asks the service locator for a service of 
(ServiceName), we want to return the service with 
(ServiceName,ClientThread#). i.e. The service for the same thread as 
the client.

We are not sure how to access methods/data members of the Client (ie. 
the caller of the serviceLocator::findService(...) method).

Is this possible in aspectc? What is the function/context function we 
should be using?

We thought it should be that(), but apparently not. In the generated 
code That and Target are the same type.

- Craig
-- 
-----------------------------------------------------
  Craig E. Tull, Ph.D.
  National Energy Research Scientific Computing Center
  E.O. Lawrence Berkeley National Laboratory
  EMail: cetull at lbl.gov       WWW: http://iago.lbl.gov/
  Phone: (510)486-7253        FAX: (510)486-4004
   eFAX: (509)694-8759     Assist: (510)486-6586



More information about the aspectc-user mailing list