這是我的代碼。我想使用流和lambdas將其更改爲Java 8樣式。你可以幫幫我嗎?將嵌套循環更改爲流
Annotation[][] annotations = joinPoint.getTarget().getClass()
.getMethod(methodName, signature.getParameterTypes()).getParameterAnnotations();
for (int i = 0; i < parametersCount; i++) {
for (int j = 0; j < annotations[i].length; j++) {
Annotation annnotation = annotations[i][j];
if (annnotation.annotationType().isAssignableFrom(Hidden.class)) {
args.set(i, "***************");
}
}
}
什麼是'args'? – Eran
你爲什麼要改變它? – Andrew
arraylist與註釋順序連接 – lassa