Constructor ctor = et.getClass().getConstructor(new Class[] {Object.class});
Method setMethod = PointcutTarget.class.getMethod("setFieldValue", new Class[] {Object.class});
Method getMethod = PointcutTarget.class.getMethod("getFieldValue", null);
for(int i = 0; i < 3; i++) {
EnclosingStaticJoinPoint esjp = (EnclosingStaticJoinPoint) s_enclosingStaticJPList.get(i);
Constructor enclosingCtor = ((ConstructorSignature) esjp.getSignature()).getConstructor();
assertTrue(
ctor.toString(),
ctor.equals(enclosingCtor));
}
for(int i = 3; i < 6; i++) {
EnclosingStaticJoinPoint esjp = (EnclosingStaticJoinPoint) s_enclosingStaticJPList.get(i);
Method method = ((MethodSignature) esjp.getSignature()).getMethod();
assertTrue(
setMethod.toString(),
setMethod.equals(method));
}
for(int i = 6; i < s_enclosingStaticJPList.size(); i++) {
EnclosingStaticJoinPoint esjp = (EnclosingStaticJoinPoint) s_enclosingStaticJPList.get(i);
Method method = ((MethodSignature) esjp.getSignature()).getMethod();
assertTrue(
getMethod.toString(),
getMethod.equals(method));
}