@Override public <Q> boolean visit(EditorContext<Q> ctx) { @SuppressWarnings("unchecked") AbstractEditorDelegate<Q, ?> delegate = (AbstractEditorDelegate<Q, ?>) ctx.getEditorDelegate(); // Pass in the EditorDelegate HasEditorDelegate<Q> asHasDelegate = ctx.asHasEditorDelegate(); if (asHasDelegate != null) { asHasDelegate.setDelegate(delegate); } // Set the EditorChain CompositeEditor<Q, ?, ?> asComposite = ctx.asCompositeEditor(); if (asComposite != null) { // Various javac generics compilation problems here @SuppressWarnings("rawtypes") EditorChain chain = delegate.getEditorChain(); asComposite.setEditorChain(chain); } return super.visit(ctx); } }
@Override public <Q> boolean visit(EditorContext<Q> ctx) { @SuppressWarnings("unchecked") AbstractEditorDelegate<Q, ?> delegate = (AbstractEditorDelegate<Q, ?>) ctx.getEditorDelegate(); // Pass in the EditorDelegate HasEditorDelegate<Q> asHasDelegate = ctx.asHasEditorDelegate(); if (asHasDelegate != null) { asHasDelegate.setDelegate(delegate); } // Set the EditorChain CompositeEditor<Q, ?, ?> asComposite = ctx.asCompositeEditor(); if (asComposite != null) { // Various javac generics compilation problems here @SuppressWarnings("rawtypes") EditorChain chain = delegate.getEditorChain(); asComposite.setEditorChain(chain); } return super.visit(ctx); } }
@Override public <Q> boolean visit(EditorContext<Q> ctx) { @SuppressWarnings("unchecked") AbstractEditorDelegate<Q, ?> delegate = (AbstractEditorDelegate<Q, ?>) ctx.getEditorDelegate(); // Pass in the EditorDelegate HasEditorDelegate<Q> asHasDelegate = ctx.asHasEditorDelegate(); if (asHasDelegate != null) { asHasDelegate.setDelegate(delegate); } // Set the EditorChain CompositeEditor<Q, ?, ?> asComposite = ctx.asCompositeEditor(); if (asComposite != null) { // Various javac generics compilation problems here @SuppressWarnings("rawtypes") EditorChain chain = delegate.getEditorChain(); asComposite.setEditorChain(chain); } return super.visit(ctx); } }
((HasEditorDelegate<T>) editor).setDelegate(ctx.getEditorDelegate());