My Project
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
Classes | Functions
dirdef.h File Reference
#include "sortdict.h"
#include "definition.h"
#include <qlist.h>

Go to the source code of this file.

Classes

class  DirList
 
class  DirDef
 
class  FilePair
 
class  FilePairDict
 
class  UsedDir
 
class  DirRelation
 
class  DirSDict
 

Functions

void buildDirectories ()
 
void generateDirDocs (OutputList &ol)
 
void computeDirDependencies ()
 
void writeDirDependencyGraph (const char *file)
 

Function Documentation

void buildDirectories ( )

Definition at line 917 of file dirdef.cpp.

References DirDef::addFile(), DirDef::addSubDir(), computeCommonDirPrefix(), Doxygen::directories, SDict< T >::find(), FileDef::getPath(), Definition::getReference(), Doxygen::inputNameList, FileDef::isDocumentationFile(), SDict< DirDef >::Iterator, DirDef::mergeDirectoryInTree(), Definition::name(), DirDef::sort(), and SDict< T >::sort().

Referenced by parseInput().

{
// for each input file
FileName *fn;
for (fnli.toFirst();(fn=fnli.current());++fnli)
{
FileNameIterator fni(*fn);
FileDef *fd;
for (;(fd=fni.current());++fni)
{
//printf("buildDirectories %s\n",fd->name().data());
if (fd->getReference().isEmpty() && !fd->isDocumentationFile())
{
DirDef *dir;
if ((dir=Doxygen::directories->find(fd->getPath()))==0) // new directory
{
}
if (dir) dir->addFile(fd);
}
else
{
// do something for file imported via tag files.
}
}
}
//DirDef *root = new DirDef("root:");
// compute relations between directories => introduce container dirs.
DirDef *dir;
for (sdi.toFirst();(dir=sdi.current());++sdi)
{
QCString name = dir->name();
int i=name.findRev('/',name.length()-2);
if (i>0)
{
DirDef *parent = Doxygen::directories->find(name.left(i+1));
//if (parent==0) parent=root;
if (parent)
{
parent->addSubDir(dir);
//printf("DirDef::addSubdir(): Adding subdir\n%s to\n%s\n",
// dir->displayName().data(), parent->displayName().data());
}
}
}
for (sdi.toFirst();(dir=sdi.current());++sdi)
{
dir->sort();
}
}
void computeDirDependencies ( )

Definition at line 973 of file dirdef.cpp.

References DirDef::computeDependencies(), Doxygen::directories, SDict< DirDef >::Iterator, and DirDef::setLevel().

Referenced by parseInput().

{
DirDef *dir;
// compute nesting level for each directory
for (sdi.toFirst();(dir=sdi.current());++sdi)
{
dir->setLevel();
}
// compute uses dependencies between directories
for (sdi.toFirst();(dir=sdi.current());++sdi)
{
//printf("computeDependencies for %s: #dirs=%d\n",dir->name().data(),Doxygen::directories.count());
}
}
void generateDirDocs ( OutputList ol)

Definition at line 991 of file dirdef.cpp.

References Config_getBool, Doxygen::directories, Doxygen::dirRelations, SDict< DirDef >::Iterator, DirDef::writeDocumentation(), and DirRelation::writeDocumentation().

Referenced by generateOutput().

{
DirDef *dir;
for (sdi.toFirst();(dir=sdi.current());++sdi)
{
}
if (Config_getBool(DIRECTORY_GRAPH))
{
for (rdi.toFirst();(dr=rdi.current());++rdi)
{
}
}
}
void writeDirDependencyGraph ( const char *  file)