*/
public Object[] getChildren(Object o)
{
Object result[];
NlpProject nlpProject = (NlpProject) o;
if (nlpProject.getProject().isOpen())
{
LinkedList<Object> childrenList = new LinkedList<Object>();
childrenList.addAll(nlpProject.getCorpora());
if (nlpProject.getTypesystemElement() != null)
{
childrenList.add(nlpProject.getTypesystemElement());
}
IResource[] resources;
try
{
resources = nlpProject.getResources();
}
catch (CoreException e)
{
// TODO just log it
return new Object[]{};
}
if (resources != null)
{
Collections.addAll(childrenList, resources);
}
childrenList.addAll(nlpProject.getCasProcessorFolders());
result = childrenList.toArray();
}
else