| | Class: ClassesSource Location: /phpDocumentor/Classes.inc
 
 Class Classes
	Class Overview 
		
		| Intermediate class parsing structure.
 The phpDocumentor_IntermediateParser class uses this class and its  cousin, ProceduralPages to organize all parsed source code elements.  Data is fed to each immediately after it is parsed, and at conversion time,  everything is organized. The Classes class is responsible for all inheritance, including resolving  name conflicts between classes, determining which classes extend other  classes, and is responsible for all inheritance of documentation. 
			Located in /phpDocumentor/Classes.inc [line 70]
		Author(s):
		
		
		
Information Tags: 
 | Methods |  
		Method Summary 
			
				
																																																																																																																																																
											| void | addClass() | While parsing, add a class to the list of parsed classes |  
											| void | addConst() | While parsing, add a variable to the list of parsed variables |  
											| void | addMethod() | While parsing, add a method to the list of parsed methods |  
											| void | addVar() | While parsing, add a variable to the list of parsed variables |  
											| mixed | getConflicts() | If a package contains two classes with the same name, this function finds  that conflict |  
											| mixed | getDefiniteChildren() | Get all classes confirmed in parsing  to be descended class $parclass in file $file |  
											| array | getRoots() | Get a list of all root classes indexed by package.  Used to generate  class trees by Converter |  
											| void | Inherit() | Main processing engine for setting up class inheritance. |  
											| void | nextFile() | Prepare to parse a new file |  
											| void | setClassParent() | Find the parent class of $class, and set up structures to note this fact |  
		Methods 
			
	
	While parsing, add a class to the list of parsed classes
 sets up the $classesbyfile, $classesbynamefile, $extendsbyfile,  $classchildrenbyfile, $roots arrays, and sets $curclassParameters:
			
	
	API Tags: 
	
	While parsing, add a variable to the list of parsed variables
 sets up the $constsbyfile array using $curfile  and $curclassParameters: 
	
	While parsing, add a method to the list of parsed methods
 sets up the $methodsbyfile array using $curfile and  $curclassParameters: 
	
    | | void addPackageToFile(
string
$package 
) | 
 | 
 Mark a package as being used in a class
 
Parameters:    {        if (!isset($this->revcpbf[$this->curfile][$package]))        $this->classpackagebyfile[$this->curfile][] = $package;        $this->revcpbf[$this->curfile][$package]    = 1;    } 
					API Tags:| string | $package: | package name |  
	
	While parsing, add a variable to the list of parsed variables
 sets up the $varsbyfile array using $curfile  and $curclassParameters: 
	
	Get the parserClass representation of a class from its name and file
Parameters: 
					| string | $class: | classname |  | string | $file: | file classname is located in |  
	
    | | mixed &getClassByPackage(
string
$class, string
$package 
) | 
 | 
 Search for a class in a package
Parameters: 
					API Tags:| string | $class: | classname |  | string | $package: | package classname is in |  
  
    | Return: | returns false if no class in $package,                otherwise returns a parserClass |  
	
    | | mixed getClassesInPath(
string
$path 
) | 
 | 
 Used by parserData::getClasses()  to retrieve classes defined in file $path
 retrieves the array entry from $classesbyfile for $pathParameters: 
					API Tags:| string | $path: | full path to filename |  
  
    | Return: | returns false if no classes defined in the file,                otherwise returns an array of parserClasses |  
	
    | | mixed getConflicts(
mixed
$class 
) | 
 | 
 If a package contains two classes with the same name, this function finds  that conflict
 Returns the $classconflicts entry for class $class, minus its own pathParameters: 
					API Tags:| mixed | $class: | the class name to search for |  
  
    | Return: | returns false if no conflicts,                or an array of paths containing conflicts |  
	
    | | mixed getDefiniteChildren(
string
$parclass, string
$file 
) | 
 | 
 Get all classes confirmed in parsing  to be descended class $parclass in file $file
Parameters: 
					API Tags:| string | $parclass: | name of parent class |  | string | $file: | file parent class is found in |  
  
    | Return: | either false if no children, or array of format          array(childname => childfile,childname2 => childfile2,...) |  
    | See: | parserClass::getChildClassList() |  
    | Uses: | $definitechild |  
	
    | | mixed getParentClass(
string
$class, string
$file 
) | 
 | 
 Find the parent class of a class in file $file
 uses 3 tests to find the parent classname:   Parameters:only one class with the parent classnamemore than one class, but only one in the same file as the childonly one parent class in the same package as the child
 
					API Tags:| string | $class: | classname |  | string | $file: | file classname is located in |  
  
    | Return: | false if no parent class,                a string if no parent class found by that name,                and an array(file parentclass is in, parentclassname) |  
    | Usedby: | Classes::setClassParent() - to find the parent class |  
	
    | | array getRoots(
[boolean
$all = false] 
) | 
 | 
 Get a list of all root classes indexed by package.  Used to generate  class trees by Converter
Parameters: 
					API Tags:| boolean | $all: | [since phpDocumentor 1.3.0RC6] determines whether to                      return class trees that extend non-parsed classes |  
  
    | Return: | array(package => array(rootclassname, rootclassname,...),...) |  
	
	Main processing engine for setting up class inheritance.
 This function uses $roots to traverse the inheritance tree via  processChild() and returns the data structures  phpDocumentor_IntermediateParser needs to convert parsed data  to output using phpDocumentor_IntermediateParser::Convert()Parameters:
			
	
	API Tags:
Information Tags: 
  
    | Todo: | CS Cleanup - rename to "inherit" for CamelCaps naming standard |  
	
    | | void nextFile(
string
$file 
) | 
 | 
 Prepare to parse a new file
 sets $curfile to $file and $curclass  to false (no class being parsed)Parameters: 
					| string | $file: | file currently being parsed |  
	
	This function recursively climbs up the class tree, setting inherited  information like package and adds the elements to  phpDocumentor_IntermediateParser.
 Using structures defined in Classes,  the function first sets package information,  and then seeks out child classes.  It uses 3 tests to determine whether a class is a child class.   Parameters:child class is in the same file as the parent class
        and extends parent classchild class is in a different file and specifies
        the parent's @package in its docblockchild class is in a different file and is in a
        different @package, with one possible parent class
 
					API Tags:| phpDocumentor_IntermediateParser | &$render: | the renderer object |  | string | $class: | class to process |  | string | $file: | name of file $class                                                   is located in |  | boolean | $furb: | flag used privately                                                   to control informational                                                   output while parsing                                                   (used when processing                                                   leftover classes in                                                   Inherit() |  
	
    | | void setClassParent(
string
$class, string
$file 
) | 
 | 
 Find the parent class of $class, and set up structures to note this fact
 Modifies the parserClass element in $classesbyfile to use  the parent's package, and inherit methods/varsParameters: 
					API Tags:| string | $class: | child class to find parent class |  | string | $file: | file child class is located in |  
  
    | Uses: | Classes::getParentClass() - to find the parent class |  
    | Uses: | $definitechild - if a match is made between a parent class and parameter
                      $class in file $file, then definitechild is set here |  | 
 |