core/controller/controller.js
function(type, resStr, resArr, resObj) {
        switch(type){
            case 'css':
                var css = resObj;
                for (var res in resArr) {
                    //means that you will find options.
                    if (typeof(resArr[res]) == "object") {
                        //console.info('found object ', resArr[res]);
                        css.media = (resArr[res].options.media) ? resArr[res].options.media : css.media;
                        css.rel = (resArr[res].options.rel) ? resArr[res].options.rel : css.rel;
                        css.type = (resArr[res].options.type) ? resArr[res].options.type : css.type;
                        if (!css.content[resArr[res]._]) {
                            css.content[resArr[res]._] = '<link href="'+ resArr[res]._ +'" media="'+ css.media +'" rel="'+ css.rel +'" type="'+ css.type +'">';
                            resStr += '\n\t' + css.content[resArr[res]._]
                        }

                    } else {
                        css.content[resArr[res]] = '<link href="'+ resArr[res] +'" media="screen" rel="'+ css.rel +'" type="'+ css.type +'">';
                        resStr += '\n\t' + css.content[resArr[res]]
                    }


                }
                return { css : css, cssStr : resStr }
            break;

            case 'js':
                var js = resObj;
                for (var res in resArr) {
                    //means that you will find options
                    if ( typeof(resArr[res]) == "object" ) {
                        js.type = (resArr[res].options.type) ? resArr[res].options.type : js.type;
                        if (!js.content[resArr[res]._]) {
                            js.content[resArr[res]._] = '<script type="'+ js.type +'" src="'+ resArr[res]._ +'"></script>';
                            resStr += '\n' + js.content[resArr[res]._];
                        }

                    } else {
                        js.content[resArr[res]] = '<script type="'+ js.type +'" src="'+ resArr[res] +'"></script>';
                        resStr += '\n' + js.content[resArr[res]]
                    }


                }
                return { js : js, jsStr : resStr }
            break;
        }
    }
function(type, resStr, resArr, resObj) {
        switch(type){
            case 'css':
                var css = resObj;
                for (var res in resArr) {
                    //means that you will find options.
                    if (typeof(resArr[res]) == "object") {
                        //console.info('found object ', resArr[res]);
                        css.media = (resArr[res].options.media) ? resArr[res].options.media : css.media;
                        css.rel = (resArr[res].options.rel) ? resArr[res].options.rel : css.rel;
                        css.type = (resArr[res].options.type) ? resArr[res].options.type : css.type;
                        if (!css.content[resArr[res]._]) {
                            css.content[resArr[res]._] = '<link href="'+ resArr[res]._ +'" media="'+ css.media +'" rel="'+ css.rel +'" type="'+ css.type +'">';
                            resStr += '\n\t' + css.content[resArr[res]._]
                        }

                    } else {
                        css.content[resArr[res]] = '<link href="'+ resArr[res] +'" media="screen" rel="'+ css.rel +'" type="'+ css.type +'">';
                        resStr += '\n\t' + css.content[resArr[res]]
                    }


                }
                return { css : css, cssStr : resStr }
            break;

            case 'js':
                var js = resObj;
                for (var res in resArr) {
                    //means that you will find options
                    if ( typeof(resArr[res]) == "object" ) {
                        js.type = (resArr[res].options.type) ? resArr[res].options.type : js.type;
                        if (!js.content[resArr[res]._]) {
                            js.content[resArr[res]._] = '<script type="'+ js.type +'" src="'+ resArr[res]._ +'"></script>';
                            resStr += '\n' + js.content[resArr[res]._];
                        }

                    } else {
                        js.content[resArr[res]] = '<script type="'+ js.type +'" src="'+ resArr[res] +'"></script>';
                        resStr += '\n' + js.content[resArr[res]]
                    }


                }
                return { js : js, jsStr : resStr }
            break;
        }
    }
function ( type , resStr , resArr , resObj ) { switch ( type ) { case 'css' : var css = resObj ; for ( var res in resArr ) { //means that you will find options. if ( typeof ( resArr [ res ] ) == "object" ) { //console.info('found object ', resArr[res]); css . media = ( resArr [ res ] . options . media ) ? resArr [ res ] . options . media : css . media ; css . rel = ( resArr [ res ] . options . rel ) ? resArr [ res ] . options . rel : css . rel ; css . type = ( resArr [ res ] . options . type ) ? resArr [ res ] . options . type : css . type ; if ( ! css . content [ resArr [ res ] . _ ] ) { css . content [ resArr [ res ] . _ ] = '<link href="' + resArr [ res ] . _ + '" media="' + css . media + '" rel="' + css . rel + '" type="' + css . type + '">' ; resStr += '\n\t' + css . content [ resArr [ res ] . _ ] } } else { css . content [ resArr [ res ] ] = '<link href="' + resArr [ res ] + '" media="screen" rel="' + css . rel + '" type="' + css . type + '">' ; resStr += '\n\t' + css . content [ resArr [ res ] ] } } return { css : css , cssStr : resStr } break ; case 'js' : var js = resObj ; for ( var res in resArr ) { //means that you will find options if ( typeof ( resArr [ res ] ) == "object" ) { js . type = ( resArr [ res ] . options . type ) ? resArr [ res ] . options . type : js . type ; if ( ! js . content [ resArr [ res ] . _ ] ) { js . content [ resArr [ res ] . _ ] = '<script type="' + js . type + '" src="' + resArr [ res ] . _ + '"></script>' ; resStr += '\n' + js . content [ resArr [ res ] . _ ] ; } } else { js . content [ resArr [ res ] ] = '<script type="' + js . type + '" src="' + resArr [ res ] + '"></script>' ; resStr += '\n' + js . content [ resArr [ res ] ] } } return { js : js , jsStr : resStr } break ; } }
Get node resources

@param {string} type
@param {string} resStr
@param {array} resArr
@param {object} resObj

@return {object} content

@private
Get node resources