public aspect WithinPointcutMatching { // rule 1) you can't use generic or parameterized type patterns with within pointcut tryGeneric() : within(Generic); // CE L 4 pointcut tryParameterized() : within(ISore); // CE L5 pointcut tryBeingSneaky() : within(String || (Number || Generic)); // CE L6 } class Generic { T foo = null; T getFoo() { return foo; } } interface ISore { void iSee(E anE); } class UglyBuilding implements ISore { public void iSee(String s) {} }