problem causes:
The following two jar packages are not introduced in the project lib:
Solution:
1. Download AspectJ-related jar packages from the official website
Link: https://www.eclipse.org/aspectj/downloads.php .
2. After installing the jar packages, copy the two jar packages at the beginning of the article to the lib of the project.
3. To develop AspectJ in the professional version of IDEA, you need to ensure that the following plug-ins are activated:
Spring AOP/@AspectJ
AspectJ Support
Open setting—plugins—search for Aspect
4. Then perform the following operations to add the Jar package to the project dependencies:
- Open
Project Structure
the dialog (Ctrl+Shift+Alt+S). - Corresponding to creating a project-level or IDE-level library, select
Libraries
or respectivelyGlobal Libraries
. - Click on the + sign and select java.
- In the pop-up dialog box, select the file in the lib directory we just added to the project
aspectjrt.jar
. - Finally click the OK button.