Changeset 700
- Timestamp:
- 06/02/07 01:36:05 (1 year ago)
- Files:
Legend:
- Unmodified
- Added
- Removed
- Modified
- Copied
- Moved
trunk/src/main/php/net/stubbles/reflection/stubReflectionPackage.php
r699 r700 2 2 /** 3 3 * Extended Reflection class for packages. 4 * 4 * 5 5 * @author Frank Kleine <mikey@stubbles.net> 6 6 * @package stubbles … … 10 10 /** 11 11 * Extended Reflection class for packages. 12 * 12 * 13 13 * @package stubbles 14 14 * @subpackage reflection … … 26 26 * constructor 27 27 * 28 * @param string $className name of classto reflect28 * @param string $className name of package to reflect 29 29 */ 30 30 public function __construct($packageName) … … 34 34 35 35 /** 36 * checks whether a value is equal to the class36 * checks whether a value is equal to the package 37 37 * 38 38 * @param mixed $compare … … 44 44 return ($compare->packageName == $this->packageName); 45 45 } 46 46 47 47 return false; 48 48 } … … 50 50 /** 51 51 * returns a string representation of the class 52 * 52 * 53 53 * The result is a short but informative representation about the class and 54 54 * its values. Per default, this method returns: … … 67 67 68 68 /** 69 * returns the full qualified class name of the reflected class 70 * 71 * If the class has not been loaded with stubClassLoader the non qualified 72 * class name will be returned. 69 * returns the full qualified class name of the reflected package 73 70 * 74 71 * @return string … … 117 114 $classes[] = new stubReflectionClass($fqClassName); 118 115 } 119 116 120 117 return $classes; 121 118 } … … 158 155 continue; 159 156 } 160 157 161 158 $shortName = str_replace($this->packageName . '.', '', $packageName); 162 159 if (strstr($shortName, '.') !== false && false === $recursive) { 163 160 continue; 164 161 } 165 162 166 163 $packages[$shortName] = $shortName; 167 164 } 168 165 169 166 $return = array_keys($packages); 170 167 sort($return); … … 185 182 $refPackages[] = new self($this->packageName . '.' . $package); 186 183 } 187 184 188 185 return $refPackages; 189 186 }
