private DOMAccess checkProjectionInstance ( final Object projection ) { if ( java . lang . reflect . Proxy . isProxyClass ( projection . getClass ( ) ) ) { InvocationHandler invocationHandler = java . lang . reflect . Proxy . getInvocationHandler ( projection ) ; if ( invocationHandler instanceof ProjectionInvocationHandler ) { if ( projection instanceof DOMAccess ) { return ( DOMAccess ) projection ; } } } throw new IllegalArgumentException ( "Given object " + projection + " is not a projection." ) ; }
Ensures that the given object is a projection created by a projector .