[
Date Prev][
Date Next][
Thread Prev][
Thread Next][
Date Index][
Thread Index]
[
List Home]
Re: [aspectj-users] AJDT 1.3 Issue already or is just me
|
Phew :)
On 21/12/05, Ron DiFrango <rdifrango@xxxxxxxxxxxxxxxxxxx> wrote:
> OK, it was just me. I should have been patient. I had to completely clear out on the command line my output dir.
>
> Sorry for the noise.
>
> Ron
>
> ________________________________
>
> From: aspectj-users-bounces@xxxxxxxxxxx on behalf of Ronald R. DiFrango
> Sent: Tue 12/20/2005 11:33 PM
> To: aspectj-users@xxxxxxxxxxx
> Subject: [aspectj-users] AJDT 1.3 Issue already or is just me
>
>
> All,
>
> I hope this is just me and my migration, but I just updated to the latest version of AJDT and I am getting the following error on an aspect that previously compiled:
>
> java.lang.NullPointerException
> at org.aspectj.ajdt.internal.compiler.ast.AccessForInlineVisitor.endVisit(AccessForInlineVisitor.java:102)
> at org.aspectj.org.eclipse.jdt.internal.compiler.ast.QualifiedNameReference.traverse (QualifiedNameReference.java:1004)
> at org.aspectj.org.eclipse.jdt.internal.compiler.ast.MessageSend.traverse(MessageSend.java:458)
> at org.aspectj.org.eclipse.jdt.internal.compiler.ast.CastExpression.traverse(CastExpression.java :455)
> at org.aspectj.org.eclipse.jdt.internal.compiler.ast.LocalDeclaration.traverse(LocalDeclaration.java:242)
> at org.aspectj.org.eclipse.jdt.internal.compiler.ast.Block.traverse(Block.java:127)
> at org.aspectj.org.eclipse.jdt.internal.compiler.ast.IfStatement.traverse (IfStatement.java:237)
> at org.aspectj.org.eclipse.jdt.internal.compiler.ast.Block.traverse(Block.java:127)
> at org.aspectj.org.eclipse.jdt.internal.compiler.ast.TryStatement.traverse(TryStatement.java:553)
> at org.aspectj.org.eclipse.jdt.internal.compiler.ast.Block.traverse (Block.java:127)
> at org.aspectj.org.eclipse.jdt.internal.compiler.ast.IfStatement.traverse(IfStatement.java:237)
> at org.aspectj.org.eclipse.jdt.internal.compiler.ast.MethodDeclaration.traverse(MethodDeclaration.java :212)
> at org.aspectj.ajdt.internal.compiler.ast.AdviceDeclaration.resolveStatements(AdviceDeclaration.java:172)
> at org.aspectj.org.eclipse.jdt.internal.compiler.ast.AbstractMethodDeclaration.resolve(AbstractMethodDeclaration.java :400)
> at org.aspectj.org.eclipse.jdt.internal.compiler.ast.TypeDeclaration.resolve(TypeDeclaration.java:1088)
> at org.aspectj.ajdt.internal.compiler.ast.AspectDeclaration.resolve(AspectDeclaration.java:115)
> at org.aspectj.org.eclipse.jdt.internal.compiler.ast.TypeDeclaration.resolve (TypeDeclaration.java:1137)
> at org.aspectj.org.eclipse.jdt.internal.compiler.ast.CompilationUnitDeclaration.resolve(CompilationUnitDeclaration.java:305)
> at org.aspectj.org.eclipse.jdt.internal.compiler.Compiler.process (Compiler.java:514)
> at org.aspectj.org.eclipse.jdt.internal.compiler.Compiler.compile(Compiler.java:329)
> at org.aspectj.ajdt.internal.core.builder.AjBuildManager.performCompilation(AjBuildManager.java:811)
> at org.aspectj.ajdt.internal.core.builder.AjBuildManager.doBuild (AjBuildManager.java:230)
> at org.aspectj.ajdt.internal.core.builder.AjBuildManager.batchBuild(AjBuildManager.java:156)
> at org.aspectj.ajde.internal.CompilerAdapter.compile(CompilerAdapter.java:122)
> at org.aspectj.ajde.internal.AspectJBuildManager$CompilerThread.run (AspectJBuildManager.java:191)
> NullPointerException thrown: null
>
> Here is the aspect:
>
>
> /*
> * Created on Sep 7, 2005
> *
> * TODO To change the template for this generated file go to
> * Window - Preferences - Java - Code Generation - Code and Comments
> */
>
> package com.tascon.tim.sofia.aop;
>
> import java.io.IOException;
> import com.salmonllc.jsp.JspTableCell;
> import com.salmonllc.jsp.JspTableRow;
> import com.salmonllc.sql.DataStoreBuffer;
> import com.salmonllc.sql.DataStoreEvaluator;
> import com.salmonllc.sql.DataStoreExpression ;
> import com.tascon.tim.sofia.util.SofiaUtil;
>
> public aspect SofiaJspTableRow {
> public DataStoreEvaluator JspTableRow._dsEval = null;
> public JspTableRow JspTableRow._otherRow = null;
> public boolean JspTableRow.flipLogic = false;
>
>
> /**
> * Use this method to bind this component to an expression in a DataStore
> * @param ds The DataStore to bind to.
> * @param expression The expression to bind to.
> * @see DataStoreEvaluator
> */
> public void JspTableRow.setExpression(DataStoreBuffer ds, DataStoreExpression expression) throws Exception {
> this._dsEval = new DataStoreEvaluator(ds, expression);
> }
>
> /**
> * Use this method to bind this component to an expression in a DataStore
> * @param ds The DataStore to bind to.
> * @param expression The expression to bind to.
> * @param
> * @see DataStoreEvaluator
> */
> public void JspTableRow.setExpression(DataStoreBuffer ds, DataStoreExpression expression, JspTableRow row) throws Exception {
> this._dsEval = new DataStoreEvaluator(ds, expression);
> this._otherRow = row;
> }
>
> /**
> * Use this method to bind this component to an expression in a DataStore
> * @param ds The DataStore to bind to.
> * @param expression The expression to bind to.
> * @param
> * @param
> * @see DataStoreEvaluator
> */
> public void JspTableRow.setExpression(DataStoreBuffer ds, DataStoreExpression expression, JspTableRow row, boolean flip) throws Exception {
> this._dsEval = new DataStoreEvaluator(ds, expression);
> this._otherRow = row;
> this.flipLogic = flip;
> }
>
> pointcut generateHtml(JspTableRow row) :
> execution(public void JspTableRow.generateHTML(..))
> && target(row);
>
> void around(JspTableRow row) throws IOException : generateHtml(row)
> {
> // no sense processing if the row is not visible
> if (row._dsEval != null && row.getVisible())
> {
> try
> {
> if (row._otherRow != null && row.flipLogic)
> {
> // Check the other to see if this should be enabled.
> Boolean visibile = (Boolean)row._otherRow._dsEval.evaluateRow();
> System.out.println("visibile: " + visibile);
> SofiaUtil.enableOrDisableMe(row, !visibile.booleanValue());
> }
> else
> {
> Boolean visibile = (Boolean)row._dsEval.evaluateRow();
> System.out.println("visibile: " + visibile);
> // Enable or disable this appropriately
> SofiaUtil.enableOrDisableMe(row, visibile.booleanValue());
> // Re-enable the other row is this one is to be visible.
> if (row._otherRow != null && visibile.booleanValue())
> {
> SofiaUtil.enableOrDisableMe(row._otherRow, visibile.booleanValue());
> }
> }
> }
> catch(Exception e)
> {
>
> }
> }
>
> // Now generate the HTML is appropriate
> if (row.getVisible())
> {
> proceed(row);
> }
> }
> }
>
>
> Now I am weaving this into an external JAR file then dropping it into the classes folder of my web app.
>
> Thanks and I hope it just me!
>
> Ron
>
> _______________________________________________
> aspectj-users mailing list
> aspectj-users@xxxxxxxxxxx
> https://dev.eclipse.org/mailman/listinfo/aspectj-users
>
--
-- Adrian
adrian.colyer@xxxxxxxxx