We are using a internally developed framework, which define some Aspects. For example :
public aspect AGhostable {
@Column(name = "ghost", columnDefinition = "boolean default false")
public boolean Ghostable.ghost;
public void Ghostable.setGhost(boolean ghost) {
this.ghost = ghost;
}
public boolean Ghostable.isGhost() {
return this.ghost;
}
}
If we use create a class implementing the interface Ghostable in our framework, everything is fine in IntelliJ. But if we create a class implementing the interface Ghostable in a project using our framework IntelliJ does not seems to detect our aspect in the editor : red underline, and says that the class must implements methods from the interface. Note that the project build without any issue, it's just an issue in the editor.
We are using Maven to manage dependencies.
Do you have any idea of how I can fix this?
Thanks.
Initially posted on StackOverflow : https://stackoverflow.com/questions/46696566/intellij-aspect-not-detected-in-editor
|
Please share a sample project to reproduce the problem.
Hi Serge,
Sorry for the late answer.
I've created 2 samples projects on GitHub :
https://github.com/Czternasty/aspectroot : defining the aspect, you will need to "mvn install" this one
https://github.com/Czternasty/aspectexample : using the aspect defined in the other project, and if you look at "MyClass" is marked as error, but in Example you will see that the interface is correctly detected.
Thanks for your help.
`mvn install` fails:
[ERROR] Failed to execute goal on project aspectroot: Could not resolve dependencies for project net.czternasty:aspectroot:jar:1.0-SNAPSHOT: Could not find artifact net.czternasty:aspectroot:jar:1.0-SNAPSHOT -> [Help 1]
My bad, a dependency was wrong, I'v updated the project. Sorry.
Your example project fails to build with Maven as well: