protected function get_destination($scaffold, $args)
    {
        $sub_dir = '/theme/';

        switch ($scaffold) {
            case 'shortcode':
                $dir = 'Shortcodes';
                $sub_dir .= 'Content/';
                break;
            case 'ajax':
                $dir = 'Ajax';
                $sub_dir .= 'Http/';
                break;
            case 'hookable':
                $dir = \trim(Config::get('theme.hookables_directory'), '/');
                break;
            case 'controller':
                $dir = 'Controllers';
                $sub_dir .= 'Http/';
                break;
            case 'request':
                $dir = 'Requests';
                $sub_dir .= 'Http/';
                break;
            case 'middleware':
                $dir = 'Middleware';
                $sub_dir .= 'Http/';
                break;
            case 'rule':
                $dir = 'Rules';
                $sub_dir .= 'Http/Validation/';
                break;
            case 'posttype':
                $dir = 'Post_Types';
                $sub_dir .= 'Content/';
                break;
            case 'event':
                $dir = 'Events';
                break;
            case 'taxonomy':
                $dir = 'Taxonomies';
                $sub_dir .= 'Content/';
                break;
        }

        $base_dir = $this->theme_dir . $sub_dir;
        $folder = \str_replace('\\', '/', $args['NAMESPACE']);

        $output_path = $base_dir . '/' . $dir . \trailingslashit($folder);

        \wp_mkdir_p($output_path);

        return $output_path . $args['CLASSNAME'] . '.php';
    }
protected function get_destination($scaffold, $args)
    {
        $sub_dir = '/theme/';

        switch ($scaffold) {
            case 'shortcode':
                $dir = 'Shortcodes';
                $sub_dir .= 'Content/';
                break;
            case 'ajax':
                $dir = 'Ajax';
                $sub_dir .= 'Http/';
                break;
            case 'hookable':
                $dir = \trim(Config::get('theme.hookables_directory'), '/');
                break;
            case 'controller':
                $dir = 'Controllers';
                $sub_dir .= 'Http/';
                break;
            case 'request':
                $dir = 'Requests';
                $sub_dir .= 'Http/';
                break;
            case 'middleware':
                $dir = 'Middleware';
                $sub_dir .= 'Http/';
                break;
            case 'rule':
                $dir = 'Rules';
                $sub_dir .= 'Http/Validation/';
                break;
            case 'posttype':
                $dir = 'Post_Types';
                $sub_dir .= 'Content/';
                break;
            case 'event':
                $dir = 'Events';
                break;
            case 'taxonomy':
                $dir = 'Taxonomies';
                $sub_dir .= 'Content/';
                break;
        }

        $base_dir = $this->theme_dir . $sub_dir;
        $folder = \str_replace('\\', '/', $args['NAMESPACE']);

        $output_path = $base_dir . '/' . $dir . \trailingslashit($folder);

        \wp_mkdir_p($output_path);

        return $output_path . $args['CLASSNAME'] . '.php';
    }
protected function get_destination ( $ scaffold , $ args ) { $ sub_dir = '/theme/' ; switch ( $ scaffold ) { case 'shortcode' : $ dir = 'Shortcodes' ; $ sub_dir .= 'Content/' ; break ; case 'ajax' : $ dir = 'Ajax' ; $ sub_dir .= 'Http/' ; break ; case 'hookable' : $ dir = \ trim ( Config :: get ( 'theme.hookables_directory' ) , '/' ) ; break ; case 'controller' : $ dir = 'Controllers' ; $ sub_dir .= 'Http/' ; break ; case 'request' : $ dir = 'Requests' ; $ sub_dir .= 'Http/' ; break ; case 'middleware' : $ dir = 'Middleware' ; $ sub_dir .= 'Http/' ; break ; case 'rule' : $ dir = 'Rules' ; $ sub_dir .= 'Http/Validation/' ; break ; case 'posttype' : $ dir = 'Post_Types' ; $ sub_dir .= 'Content/' ; break ; case 'event' : $ dir = 'Events' ; break ; case 'taxonomy' : $ dir = 'Taxonomies' ; $ sub_dir .= 'Content/' ; break ; } $ base_dir = $ this -> theme_dir . $ sub_dir ; $ folder = \ str_replace ( '\\' , '/' , $ args [ 'NAMESPACE' ] ) ; $ output_path = $ base_dir . '/' . $ dir . \ trailingslashit ( $ folder ) ; \ wp_mkdir_p ( $ output_path ) ; return $ output_path . $ args [ 'CLASSNAME' ] . '.php' ; }
Returns the full path of the new file to be created.

@param  string $scaffold The file to scaffold.
@param  array  $args     The arguments passed from the Maker class.
@return string
Returns the full path of the new file to be created .