<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML><HEAD>
<META http-equiv=Content-Type content="text/html; charset=iso-8859-1">
<META content="MSHTML 6.00.2800.1400" name=GENERATOR>
<STYLE></STYLE>
</HEAD>
<BODY bgColor=#ffffff>
<DIV><FONT face=Arial size=2>Seems, I found it by myself.... it was
much easier than exepcted:</FONT></DIV>
<DIV><FONT face=Arial size=2></FONT> </DIV>
<DIV><FONT face=Arial size=2>aspect myAspect{</FONT></DIV>
<DIV><FONT face=Arial size=2> TDataContainer*
DataContainer;</FONT></DIV>
<DIV><FONT face=Arial size=2> advice execution("% main(...)")
: around() {</FONT></DIV>
<DIV><FONT face=Arial size=2> DataContainer
= new TDataContainer();</FONT></DIV>
<DIV><FONT face=Arial size=2>
tjp->proceed();</FONT></DIV>
<DIV><FONT face=Arial size=2> delete
DataContainer;</FONT></DIV>
<DIV><FONT face=Arial size=2> }</FONT></DIV>
<DIV><FONT face=Arial size=2>}</FONT></DIV>
<DIV><FONT face=Arial size=2></FONT> </DIV>
<DIV><FONT face=Arial size=2></FONT> </DIV>
<DIV><FONT face=Arial size=2>greets,</FONT></DIV>
<DIV><FONT face=Arial size=2>Steffen Käthner</FONT></DIV>
<BLOCKQUOTE dir=ltr
style="PADDING-RIGHT: 0px; PADDING-LEFT: 5px; MARGIN-LEFT: 5px; BORDER-LEFT: #000000 2px solid; MARGIN-RIGHT: 0px">
<DIV style="FONT: 10pt arial">----- Original Message ----- </DIV>
<DIV
style="BACKGROUND: #e4e4e4; FONT: 10pt arial; font-color: black"><B>From:</B>
<A title=pdm-steve@gmx.de href="mailto:pdm-steve@gmx.de">pdm-steve</A> </DIV>
<DIV style="FONT: 10pt arial"><B>To:</B> <A title=aspectc-user@aspectc.org
href="mailto:aspectc-user@aspectc.org">aspectc-user@aspectc.org</A> </DIV>
<DIV style="FONT: 10pt arial"><B>Sent:</B> Wednesday, June 16, 2004 12:40
AM</DIV>
<DIV style="FONT: 10pt arial"><B>Subject:</B> [aspectc-user] global
definitions</DIV>
<DIV><BR></DIV>
<DIV><FONT face=Arial size=2>Hi,</FONT></DIV>
<DIV><FONT face=Arial size=2></FONT> </DIV>
<DIV><FONT face=Arial size=2>how to add a global object definition with
aspectc?</FONT></DIV>
<DIV><FONT face=Arial size=2></FONT> </DIV>
<DIV><FONT face=Arial size=2>I have this:</FONT></DIV>
<DIV><FONT face=Arial size=2>int main() { ... }</FONT></DIV>
<DIV><FONT face=Arial size=2></FONT> </DIV>
<DIV><FONT face=Arial size=2>and want to have something like
this:</FONT></DIV>
<DIV><FONT face=Arial size=2>TDataContainer* DataContainer;</FONT></DIV>
<DIV><FONT face=Arial size=2>int main() { ... }</FONT></DIV>
<DIV><FONT face=Arial size=2></FONT> </DIV>
<DIV><FONT face=Arial size=2></FONT> </DIV>
<DIV><FONT face=Arial size=2>Like in the AOSD-Tutorial is shown, I can add
members to classes:</FONT></DIV>
<DIV>advice "anyClass" : int counter;</DIV>
<DIV>... but I want to add a global object/variable to the main function</DIV>
<DIV><FONT face=Arial size=2></FONT> </DIV>
<DIV><FONT face=Arial size=2></FONT> </DIV>
<DIV><FONT face=Arial size=2>greetings,</FONT></DIV>
<DIV><FONT face=Arial size=2>Steffen
Käthner</FONT></DIV></BLOCKQUOTE></BODY></HTML>