Hi,
I am trying to write a custom action class for the Actionbar in the config
module of magnolia 5. I want to access the HierarchicalJcrContainer of the
TreeTable in the config module from within the action class. So far I am trying
to do this as follows:
[code]public CustomAction(CustomActionDefinition definition, JcrItemAdapter
item, TreeView view) {
super(definition);
this.item = item;
if(view instanceof CustomTreeViewImpl) {
this.treeView = (CustomTreeViewImpl)view;
}
this.treeTable = treeView.getTreeTable();
}
public void execute() throws ActionExecutionException {
HierarchicalJcrContainer container = (HierarchicalJcrContainer)
treeTable.getContainerDataSource();
container.doSomething();
}[/code]
However, when I run this I get a ClassCastException during runtime saying:
Com.vaadin.data.util.HierarchicalContainer cannot be cast to
info.magnolia.ui.workbench.tree.HierarchicalJcrContainer
This is weird, as I know I have used this classcast before and it should work.
Any ideas on what is going wrong?
--
Context is everything:
http://forum.magnolia-cms.com/forum/thread.html?threadId=15f57892-4d28-4606-a9c2-8d25740aa278
----------------------------------------------------------------
For list details, see http://www.magnolia-cms.com/community/mailing-lists.html
Alternatively, use our forums: http://forum.magnolia-cms.com/
To unsubscribe, E-mail to: <[email protected]>
----------------------------------------------------------------