{
final IRootDSE rootDSE = ( IRootDSE ) parent;
if ( !rootDSE.isChildrenInitialized() )
{
new StudioBrowserJob( new InitializeChildrenRunnable( false, rootDSE ) ).execute();
return new String[]
{ Messages.getString( "BrowserContentProvider.FetchingEntries" ) }; //$NON-NLS-1$
}
// get base entries
List<IEntry> entryList = new ArrayList<IEntry>();
entryList.addAll( Arrays.asList( rootDSE.getChildren() ) );
// remove non-visible entries
for ( Iterator<IEntry> it = entryList.iterator(); it.hasNext(); )
{
Object o = it.next();
if ( !preferences.isShowDirectoryMetaEntries() && ( o instanceof DirectoryMetadataEntry ) )
{
it.remove();
}
}
return entryList.toArray();
}
else if ( parent instanceof IEntry )
{
final IEntry parentEntry = ( IEntry ) parent;
if ( parentEntry instanceof IContinuation )
{
IContinuation continuation = ( IContinuation ) parentEntry;
if ( continuation.getState() == State.UNRESOLVED )
{
continuation.resolve();
}
if ( continuation.getState() == State.CANCELED )
{
return new Object[0];
}
}
if ( !parentEntry.isChildrenInitialized() )
{
new StudioBrowserJob( new InitializeChildrenRunnable( false, parentEntry ) ).execute();
return new String[]
{ Messages.getString( "BrowserContentProvider.FetchingEntries" ) }; //$NON-NLS-1$
}
else if ( parentEntry.getChildrenCount() <= preferences.getFoldingSize() || !preferences.isUseFolding() )
{