4 public function __construct($dir) {
6 $this->filenames = array();
9 while (($entry = $d->read()) !== false) {
10 if (!is_dir($this->prefix.'/'.$entry)) {
11 $this->filenames[] = explode('.', $entry, 2);
20 public function instantiate($name) {
21 if (class_exists($name)) {
28 private function __file_load() {
29 $this->formats = array();
31 if ($this->filenames) {
32 foreach ($this->filenames as $filename) {
34 $path = $this->prefix.'/';
36 $path .= $filename[0].'.'.$filename[1];