//TOOLS
import DataUtils, {
    REQUEST_TYPE_GET,
    REQUEST_TYPE_PUT,
    REQUEST_TYPE_POST,
    REQUEST_TYPE_DELETE,
    CONTENT_TYPE_JSON,
    CONTENT_TYPE_FORM
} from '../tools/utilities/DataUtils.jsx';
import DisplayAdmin from './DisplayAdmin.jsx';
import DisplayClient from './DisplayClient.jsx';
class DisplayManager
{
    //--------------------------
    // constructor
    //--------------------------
    constructor()
    {
        this.dataUtils = new DataUtils();
        this.currentDisplay = '';
        this.urlPieces = document.URL.split("/");
        //grab url so system knows what to display 
        this.chooseDisplay(this.urlPieces[3], this.urlPieces[4]);
        
    }
    //--------------------------
    // methods
    //--------------------------
    start()
    {}

    chooseDisplay(section, page)
    {
        this.currentDisplay = '';
        switch (section) {
            case 'admin':
            	this.currentDisplay = new DisplayAdmin(section, page);
                break
        
            default:
                this.currentDisplay = new DisplayClient(section, page);
                break;
        }
    }
    //--------------------------
    // event handlers
    //--------------------------
    
}
export {DisplayManager as default}
