Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
[cme-users] CME queries for documenting crosscuttingness

Hello,

I am trying to use/extend CME for defining a set of
queries to be associated with standard, atomic
crosscuting concerns (e.g., consistent behavior, role
superimposition, etc.). I believe that more complex
concerns could be expressed as composition of these
atomic concerns, and that the queries will help to
document the crosscutting parts of larger concerns,
like design patterns.

One type of concerns to which I would like to
associate a query is "Context passing" (a.k.a.
Wormhole) - add a parameter to a chain of method calls
in order to pass a context. (An example could be the
Rationale parameters for long running operations in
the CME code).
I imagine the query taking as input the first method
in the calls' chain and the name of the parameter, and
returning the chain of the methods that start from the
input method and receive the specific parameter.

For example:

void m(Context c) {
  a(); 
  n(c);
  b();
}

void n(Context c) {
  ... //c not changed
  Context c1 = c;
  p(c1);
  ...
}

The query getChainOfContextP(m, c) returns {n, p}.


I have already implemented the "invokes" relationship
in CME by adding a loader for the methods'
relationships in ShrikeCTStubImplNotForUnits. So I can
execute queries like: relationship invokes(method *
pckg.ClassA.methoda(), method *) .
However, for the context passing query I would need
more program analysis support.

I would appreciate very much your comments on how
could CME support the implementation of this query. 
(Using external program analysis tool could also be an
option.)

Thank you for help,
Marius



		
__________________________________ 
Yahoo! Mail - PC Magazine Editors' Choice 2005 
http://mail.yahoo.com


Back to the top