public static Matcher < TypeCastTree > typeCast ( final Matcher < Tree > typeMatcher , final Matcher < ExpressionTree > expressionMatcher ) { return new Matcher < TypeCastTree > ( ) { @ Override public boolean matches ( TypeCastTree t , VisitorState state ) { return typeMatcher . matches ( t . getType ( ) , state ) && expressionMatcher . matches ( t . getExpression ( ) , state ) ; } } ; }
Matches a type cast AST node if both of the given matchers match .