Getting Started
Core
Relational Databases
NoSQL Databases
Cache
Internationalization
REST Client
Scheduler
Sendmail
Template
Virtual File Storage
Web
Testing
Advanced
Aspect Oriented Programming (AOP) includes programming methods and tools that support the modularization of concerns at the level of the source code. Void Framework manages the AOP via the AspectJ
and Guice
libraries. The first library is more powerful but also more complicated to use, while the latter has fewer capabilities but is simple to use.
AspectJ runtime (aspectjrt
) is already provided by the module voidframework-core
, but you have to add an extra plugin to compile aspects during the compilation of your application.
<plugin>
<!-- https://mvnrepository.com/artifact/org.codehaus.mojo/aspectj-maven-plugin -->
<groupId>org.codehaus.mojo</groupId>
<artifactId>aspectj-maven-plugin</artifactId>
<version>1.16.0</version>
<inherited>true</inherited>
<dependencies>
<dependency>
<groupId>org.aspectj</groupId>
<artifactId>aspectjtools</artifactId>
<version>1.9.22</version> <!-- Match version provided by Void Framework -->
</dependency>
</dependencies>
<configuration>
<complianceLevel>${java.version}</complianceLevel>
<source>${maven.compiler.source}</source>
<target>${maven.compiler.target}</target>
<showWeaveInfo>true</showWeaveInfo>
<verbose>true</verbose>
<Xlint>ignore</Xlint>
<encoding>UTF-8</encoding>
</configuration>
<executions>
<execution>
<goals>
<goal>compile</goal>
<goal>test-compile</goal>
</goals>
</execution>
</executions>
</plugin>
aspectj:compile
before running your application. In IntelliJ, go to Maven tab, plugin, aspectj, left-click on aspectj:compile, choose "Execute before Run/Debug".@Aspect
.Read more about AspectJ at:
Read more about Guice AOP at: