Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

AspectJ ProceedingJoinPoint.getArgs when method args are null

I was looking at the Javadocs for ProceedingJoinPoint/JoinPoint in AspectJ, but they don't seem to tell me what the expected behavior is for method getArgs is when null values are passed as one or more of the arguments. I am assuming I will get a value for each defined parameter, including nulls when appropriate.

like image 708
Kevin Welker Avatar asked Sep 01 '25 20:09

Kevin Welker


1 Answers

Yes, you will get back a null for the appropriate indexed argument value:

for eg, if the your 2nd argument is null calling pjp.getArgs()[1] will return null.

like image 128
Biju Kunjummen Avatar answered Sep 03 '25 10:09

Biju Kunjummen