src/objects/file/Folder.php
public function process($recursive = false)
		{
			// reset
			$this->folders      = [];
			$this->controllers  = [];
			
			// variables
			$files = array_diff(scandir($this->path), ['.', '..']);

			// loop
			foreach ($files as $file)
			{
				$path = $this->path . $file;
				if(is_dir($path))
				{
					$this->folders[] = new Folder($path, $recursive);
				}
				else if(is_file($path) && preg_match('/Controller.php$/', $path))
				{
					$this->controllers[] = new Controller($path);
				}
			}
		}
public function process($recursive = false)
		{
			// reset
			$this->folders      = [];
			$this->controllers  = [];
			
			// variables
			$files = array_diff(scandir($this->path), ['.', '..']);

			// loop
			foreach ($files as $file)
			{
				$path = $this->path . $file;
				if(is_dir($path))
				{
					$this->folders[] = new Folder($path, $recursive);
				}
				else if(is_file($path) && preg_match('/Controller.php$/', $path))
				{
					$this->controllers[] = new Controller($path);
				}
			}
		}
public function process ( $ recursive = false ) { // reset
 $ this -> folders = [ ] ; $ this -> controllers = [ ] ; // variables
 $ files = array_diff ( scandir ( $ this -> path ) , [ '.' , '..' ] ) ; // loop
 foreach ( $ files as $ file ) { $ path = $ this -> path . $ file ; if ( is_dir ( $ path ) ) { $ this -> folders [ ] = new Folder ( $ path , $ recursive ) ; } else if ( is_file ( $ path ) && preg_match ( '/Controller.php$/' , $ path ) ) { $ this -> controllers [ ] = new Controller ( $ path ) ; } } }
Process contained folders and controllers

@param   bool    $recursive      An optional flag to recursively get child folders
Process contained folders and controllers