Fighting AJDT [message #59795] |
Fri, 23 December 2005 16:47 |
Eclipse User |
|
|
|
Originally posted by: as851.columbia.edu
I am fighting the latest AJDT for a couple of hours now. So decided to
just make sure it is not me ... here is the aspect that just would not
let me live :-)
public abstract aspect AbstractPrettyPrintAspect {
protected abstract pointcut toStringMethod(java.lang.Object
targetObject)
;
around (Object targetObject) : toStringMethod(targetObject) {
String result = (String) proceed(targetObject);
if (shouldOverwrite(result,targetObject))
result = "overwrite";
return result;
}
....
}
is there anything wrong with it. I am getting an error form AJDT on the
line that declares the abstract pointcut. Eclipse complains "Syntax
error on token ";", Type expected after this token"
I can not see what is wrong here. The funny part is that I have an
aspect in different project that has a declaration of the pointcut that
matches one-to-one but names and it works just fine.
Any advice?
I am running:
Version: 1.3.0
Build id: 20051220093604
AspectJ version: 1.5.0
|
|
|
Re: Fighting AJDT [message #59822 is a reply to message #59795] |
Fri, 23 December 2005 16:59 |
Eclipse User |
|
|
|
Originally posted by: as851.columbia.edu
sorry for the noise, the around needs return type which I do not have on
the next line. I guess the line that AJDT was pointing to threw me off
the track.
I am good now. No need to call 911 :-)
a.shneyderman wrote:
> I am fighting the latest AJDT for a couple of hours now. So decided to
> just make sure it is not me ... here is the aspect that just would not
> let me live :-)
>
> public abstract aspect AbstractPrettyPrintAspect {
>
> protected abstract pointcut toStringMethod(java.lang.Object
> targetObject)
>
>
> ;
>
> around (Object targetObject) : toStringMethod(targetObject) {
> String result = (String) proceed(targetObject);
> if (shouldOverwrite(result,targetObject))
> result = "overwrite";
> return result;
> }
>
> ....
>
> }
>
> is there anything wrong with it. I am getting an error form AJDT on the
> line that declares the abstract pointcut. Eclipse complains "Syntax
> error on token ";", Type expected after this token"
>
> I can not see what is wrong here. The funny part is that I have an
> aspect in different project that has a declaration of the pointcut that
> matches one-to-one but names and it works just fine.
>
> Any advice?
>
> I am running:
> Version: 1.3.0
> Build id: 20051220093604
> AspectJ version: 1.5.0
|
|
|
|
Re: Fighting AJDT [message #591464 is a reply to message #59795] |
Fri, 23 December 2005 16:59 |
Eclipse User |
|
|
|
Originally posted by: as851.columbia.edu
sorry for the noise, the around needs return type which I do not have on
the next line. I guess the line that AJDT was pointing to threw me off
the track.
I am good now. No need to call 911 :-)
a.shneyderman wrote:
> I am fighting the latest AJDT for a couple of hours now. So decided to
> just make sure it is not me ... here is the aspect that just would not
> let me live :-)
>
> public abstract aspect AbstractPrettyPrintAspect {
>
> protected abstract pointcut toStringMethod(java.lang.Object
> targetObject)
>
>
> ;
>
> around (Object targetObject) : toStringMethod(targetObject) {
> String result = (String) proceed(targetObject);
> if (shouldOverwrite(result,targetObject))
> result = "overwrite";
> return result;
> }
>
> ....
>
> }
>
> is there anything wrong with it. I am getting an error form AJDT on the
> line that declares the abstract pointcut. Eclipse complains "Syntax
> error on token ";", Type expected after this token"
>
> I can not see what is wrong here. The funny part is that I have an
> aspect in different project that has a declaration of the pointcut that
> matches one-to-one but names and it works just fine.
>
> Any advice?
>
> I am running:
> Version: 1.3.0
> Build id: 20051220093604
> AspectJ version: 1.5.0
|
|
|
|
Powered by
FUDForum. Page generated in 0.03553 seconds