module Sinatra

def self.helpers(*extensions, &block)

Include the helper modules provided in Sinatra's request context.
def self.helpers(*extensions, &block)
  Delegator.target.helpers(*extensions, &block)
end

def self.new(base = Base, options = {}, &block)

class scope.
Create a new Sinatra application. The block is evaluated in the new app's
def self.new(base = Base, options = {}, &block)
  base = Class.new(base)
  base.class_eval(&block) if block_given?
  base
end

def self.register(*extensions, &block)

Extend the top-level DSL with the modules provided.
def self.register(*extensions, &block)
  Delegator.target.register(*extensions, &block)
end

def self.use(*args, &block)

Use the middleware for classic applications.
def self.use(*args, &block)
  Delegator.target.use(*args, &block)
end