 
 class global.Exspresso_Controller
 
-  __hasOwnProperty    = Object.hasOwnProperty
-  __defineProperty    = Object.defineProperty
   __defineProperties  = Object.defineProperties
 
   #

  # @param	function
  # @return	void
  #
  render: ($view, $data = {}, $next) =>

    #
    # View Controller constructor
    #
    #   Wrap view data with controller methods
    #   This gives the view access to all methods and
    #   properties of the controller
    #
    # @access	private
    # @param	object
    #
    Controller = ($data) ->
      for $key, $obj of $data
        @[$key] = $obj
      return

    # Here's the magic -
    # expose the current controller via the prototype

      module    : {enumerable: true, writeable: false, value: $module}
      class     : {enumerable: true, writeable: false, value: $class}
      method    : {enumerable: true, writeable: false, value: $method}
      queue     : {enumerable: true, writeable: false, value: $this.queue}
      run       : {enumerable: true, writeable: false, value: $this.run}
      redirect  : {enumerable: true, writeable: false, value: $this.redirect}
      render    : {enumerable: true, writeable: false, value: $this.render}
      config    : {enumerable: true, writeable: false, value: Exspresso.config}
      server    : {enumerable: true, writeable: false, value: Exspresso.server}
      router    : {enumerable: true, writeable: false, value: Exspresso.router}
      lang      : {enumerable: true, writeable: false, value: Exspresso.lang}

    $BM.mark 'loading_time:_base_classes_start'
    __defineProperties $this,
      load      : {enumerable: true, writeable: false, value: load_new('Loader',  'core', $this)}
      uri       : {enumerable: true, writeable: false, value: load_new('URI',     'core', $this)}
      input     : {enumerable: true, writeable: false, value: load_new('Input',   'core', $this)}

    __defineProperties $this,
      output    : {enumerable: true, writeable: false, value: load_new('Output',  'core', $this)}
      $_SERVER  : {enumerable: true, writeable: false, get: -> $this.input.server()}
      $_GET     : {enumerable: true, writeable: false, get: -> $this.input.get()}
      $_POST    : {enumerable: true, writeable: false, get: -> $this.input.post()}
